cortex-react-components 2.6.0 → 2.6.1

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.
Files changed (129) hide show
  1. package/dist/{chunk-IF3425JX.mjs → chunk-2VOOH4YJ.mjs} +1 -1
  2. package/dist/{chunk-XHR2HXMP.mjs → chunk-3DYGB2K5.mjs} +1 -1
  3. package/dist/{chunk-FQMEHUDP.mjs → chunk-3ZF4TV4N.mjs} +1 -1
  4. package/dist/{chunk-67QPOSVV.mjs → chunk-57PJ7CHJ.mjs} +1 -1
  5. package/dist/{chunk-HKGW6JI2.mjs → chunk-75XBZHOC.mjs} +1 -1
  6. package/dist/{chunk-5RDLHKTK.mjs → chunk-ABGNIQRP.mjs} +1 -1
  7. package/dist/{chunk-LJOWXPWW.mjs → chunk-AEFWTCCE.mjs} +1 -1
  8. package/dist/{chunk-RNMPX2AU.mjs → chunk-AFQBDAWS.mjs} +1 -1
  9. package/dist/{chunk-M7NV6EFH.mjs → chunk-B2TBKNIJ.mjs} +1 -1
  10. package/dist/{chunk-MFCVMJBO.mjs → chunk-BDDEMCAH.mjs} +1 -1
  11. package/dist/{chunk-MQA37YMO.mjs → chunk-FOEPKY7T.mjs} +1 -1
  12. package/dist/{chunk-N3B3XNV3.mjs → chunk-FRXZ2OKW.mjs} +1 -1
  13. package/dist/{chunk-MXCW6SOT.mjs → chunk-FX6IXEMQ.mjs} +1 -1
  14. package/dist/{chunk-XBCYPOFD.mjs → chunk-GTK2SGS5.mjs} +1 -1
  15. package/dist/{chunk-ISBVFNWD.mjs → chunk-IDG2O4B7.mjs} +1 -1
  16. package/dist/{chunk-5SHZBJ5R.mjs → chunk-KY3ELFX5.mjs} +1 -1
  17. package/dist/{chunk-AMVJPDM3.mjs → chunk-M527EJIX.mjs} +1 -1
  18. package/dist/{chunk-NTS4U2OE.mjs → chunk-MPTT6GRI.mjs} +1 -1
  19. package/dist/{chunk-YKG4FNS4.mjs → chunk-N52FSTLG.mjs} +1 -1
  20. package/dist/{chunk-ERJXTG6X.mjs → chunk-NPGGDQ6F.mjs} +1 -1
  21. package/dist/{chunk-2RQDJ5XT.mjs → chunk-Q7KKN6MH.mjs} +1 -1
  22. package/dist/{chunk-4RYG24IZ.mjs → chunk-QTILVWJA.mjs} +1 -1
  23. package/dist/{chunk-H3CJOE6S.mjs → chunk-QWFFSMKK.mjs} +1 -1
  24. package/dist/{chunk-XIGBDWYI.mjs → chunk-RAGDUV7M.mjs} +1 -1
  25. package/dist/{chunk-PK3OBSCB.mjs → chunk-RUZVSK25.mjs} +1 -1
  26. package/dist/{chunk-FTZRG54P.mjs → chunk-RY4C3J33.mjs} +1 -1
  27. package/dist/{chunk-FKU4VQR6.mjs → chunk-S4ES6P3Y.mjs} +1 -1
  28. package/dist/{chunk-7GMAMIHM.mjs → chunk-SPAOEUCG.mjs} +1 -1
  29. package/dist/{chunk-ZEPEWKBV.mjs → chunk-STX6KQP5.mjs} +1 -1
  30. package/dist/{chunk-E64KWNOT.mjs → chunk-TK4JC5PG.mjs} +1 -1
  31. package/dist/{chunk-LJQPLE4S.mjs → chunk-TUACRDU3.mjs} +1 -1
  32. package/dist/{chunk-SRUG246N.mjs → chunk-TXVA6XJT.mjs} +1 -1
  33. package/dist/{chunk-X3JZSN3W.mjs → chunk-UZSBX5GO.mjs} +1 -1
  34. package/dist/{chunk-255P6K5W.mjs → chunk-VBSFVJM5.mjs} +1 -1
  35. package/dist/{chunk-XGIYNUGC.mjs → chunk-VNYUNZ3M.mjs} +1 -1
  36. package/dist/{chunk-2BR55L74.mjs → chunk-VRE6VCHX.mjs} +1 -1
  37. package/dist/{chunk-55MVSCX4.mjs → chunk-WB2Y7HTT.mjs} +1 -1
  38. package/dist/{chunk-SW7RYGO6.mjs → chunk-XD3TBE5O.mjs} +1 -1
  39. package/dist/chunk-XDQAH5AP.mjs +4 -0
  40. package/dist/{chunk-PXLSH6S2.mjs → chunk-ZFUP5NVF.mjs} +1 -1
  41. package/dist/components/Blocks/Banner.mjs +1 -1
  42. package/dist/components/Blocks/CallToAction.mjs +1 -1
  43. package/dist/components/Blocks/CollapsibleArea.mjs +1 -1
  44. package/dist/components/Blocks/Content.mjs +1 -1
  45. package/dist/components/Blocks/FeaturesBlock.mjs +1 -1
  46. package/dist/components/Blocks/ImageBlock.mjs +1 -1
  47. package/dist/components/Blocks/MediaBlock.mjs +1 -1
  48. package/dist/components/Blocks/RelatedPosts.mjs +1 -1
  49. package/dist/components/Blocks/RenderBlocks.mjs +1 -1
  50. package/dist/components/Blocks/ReusableContentBlock.mjs +1 -1
  51. package/dist/components/Blocks/index.mjs +1 -1
  52. package/dist/components/CRM/CogeBoard.mjs +1 -1
  53. package/dist/components/CRM/KanbanBoard.mjs +1 -1
  54. package/dist/components/CRM/index.mjs +1 -1
  55. package/dist/components/Cards/ContentCard.mjs +1 -1
  56. package/dist/components/Cards/FeatureCard.mjs +1 -1
  57. package/dist/components/Cards/index.mjs +1 -1
  58. package/dist/components/Chat/CopilotInterface.js +2 -2
  59. package/dist/components/Chat/CopilotInterface.mjs +1 -1
  60. package/dist/components/Chat/demo-long-messages.js +2 -2
  61. package/dist/components/Chat/demo-long-messages.mjs +1 -1
  62. package/dist/components/Chat/demo-tests.js +2 -2
  63. package/dist/components/Chat/demo-tests.mjs +1 -1
  64. package/dist/components/Chat/demo.js +2 -2
  65. package/dist/components/Chat/demo.mjs +1 -1
  66. package/dist/components/Chat/example-usage.js +2 -2
  67. package/dist/components/Chat/example-usage.mjs +1 -1
  68. package/dist/components/Chat/example-with-vercel-ai.js +2 -2
  69. package/dist/components/Chat/example-with-vercel-ai.mjs +1 -1
  70. package/dist/components/Chat/index.js +3 -3
  71. package/dist/components/Chat/index.mjs +1 -1
  72. package/dist/components/DigitalColleagues/AppSidebarLeft.mjs +1 -1
  73. package/dist/components/DigitalColleagues/MainPage.mjs +1 -1
  74. package/dist/components/DigitalColleagues/ManagementSidebar.mjs +1 -1
  75. package/dist/components/DigitalColleagues/Views/index.mjs +1 -1
  76. package/dist/components/DigitalColleagues/index.mjs +1 -1
  77. package/dist/components/HeaderFooter/SectionHeading.mjs +1 -1
  78. package/dist/components/Heros/HighImpact/index.mjs +1 -1
  79. package/dist/components/Heros/LowImpact/index.mjs +1 -1
  80. package/dist/components/Heros/MediumImpact/index.mjs +1 -1
  81. package/dist/components/Heros/PostHero/index.mjs +1 -1
  82. package/dist/components/Heros/RenderHero.mjs +1 -1
  83. package/dist/components/Heros/index.mjs +1 -1
  84. package/dist/components/Layouts/OutputHeaderFooter.mjs +1 -1
  85. package/dist/components/Layouts/Print.mjs +1 -1
  86. package/dist/components/Layouts/SlideShow.mjs +1 -1
  87. package/dist/components/Layouts/index.mjs +1 -1
  88. package/dist/components/Menus/SidebarLeft.mjs +1 -1
  89. package/dist/components/Menus/SidebarRight.mjs +1 -1
  90. package/dist/components/Menus/index.mjs +1 -1
  91. package/dist/components/Payload/Card/index.mjs +1 -1
  92. package/dist/components/Payload/CollectionArchive/index.mjs +1 -1
  93. package/dist/components/Payload/Media/index.mjs +1 -1
  94. package/dist/components/Payload/RichText/index.mjs +1 -1
  95. package/dist/components/Payload/RichText/serialize.mjs +1 -1
  96. package/dist/components/Payload/index.mjs +1 -1
  97. package/dist/components/Projects/KanbanBoardView.mjs +1 -1
  98. package/dist/components/Projects/ProjectPage.mjs +1 -1
  99. package/dist/components/Projects/ProjectView.mjs +1 -1
  100. package/dist/components/index.js +1 -1
  101. package/dist/components/index.mjs +1 -1
  102. package/dist/components/ui/index.mjs +1 -1
  103. package/dist/components/ui/sidebar.mjs +1 -1
  104. package/dist/index.js +6 -6
  105. package/dist/index.mjs +1 -1
  106. package/dist/metafile-cjs.json +1 -1
  107. package/dist/metafile-esm.json +1 -1
  108. package/dist/pages/Blog.mjs +1 -1
  109. package/dist/pages/Documentation.mjs +1 -1
  110. package/dist/pages/IndexPage.mjs +1 -1
  111. package/dist/pages/Intranet.mjs +1 -1
  112. package/dist/pages/LandingPage.mjs +1 -1
  113. package/dist/pages/Page.mjs +1 -1
  114. package/dist/pages/Publish.mjs +1 -1
  115. package/dist/pages/Website.mjs +1 -1
  116. package/dist/sections/AboutSection.mjs +1 -1
  117. package/dist/sections/BlogDetail.mjs +1 -1
  118. package/dist/sections/BlogList.mjs +1 -1
  119. package/dist/sections/BlogListSection.mjs +1 -1
  120. package/dist/sections/ContactSection.mjs +1 -1
  121. package/dist/sections/PageSections.mjs +1 -1
  122. package/dist/sections/PricingSection.mjs +1 -1
  123. package/dist/sections/ServiceDetail.mjs +1 -1
  124. package/dist/sections/ServiceDetailSection.mjs +1 -1
  125. package/dist/sections/ServiceSection.mjs +1 -1
  126. package/dist/sections/form/index.mjs +1 -1
  127. package/dist/sections/index.mjs +1 -1
  128. package/package.json +1 -1
  129. package/dist/chunk-CSDKRMII.mjs +0 -4
package/dist/index.js CHANGED
@@ -4,11 +4,11 @@
4
4
  'use strict'
5
5
  'use client';
6
6
 
7
- "use strict";var $b=Object.create;var dl=Object.defineProperty;var Vb=Object.getOwnPropertyDescriptor;var Gb=Object.getOwnPropertyNames;var _b=Object.getPrototypeOf,Kb=Object.prototype.hasOwnProperty;var Wb=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),Xb=(e,t)=>{for(var a in t)dl(e,a,{get:t[a],enumerable:!0})},Gp=(e,t,a,o)=>{if(t&&typeof t=="object"||typeof t=="function")for(let r of Gb(t))!Kb.call(e,r)&&r!==a&&dl(e,r,{get:()=>t[r],enumerable:!(o=Vb(t,r))||o.enumerable});return e};var H=(e,t,a)=>(a=e!=null?$b(_b(e)):{},Gp(t||!e||!e.__esModule?dl(a,"default",{value:e,enumerable:!0}):a,e)),qb=e=>Gp(dl({},"__esModule",{value:!0}),e);var eu=Wb((sn,vc)=>{"use strict";(function(e,t){typeof sn=="object"&&typeof vc=="object"?vc.exports=t():typeof define=="function"&&define.amd?define([],t):typeof sn=="object"?sn.AOS=t():e.AOS=t()})(sn,function(){return function(e){function t(o){if(a[o])return a[o].exports;var r=a[o]={exports:{},Cu:o,loaded:!1};return e[o].call(r.exports,r,r.exports,t),r.loaded=!0,r.exports}var a={};return t.m=e,t.c=a,t.p="dist/",t(0)}([function(e,t,a){"use strict";function o(w){return w&&w.__esModule?w:{default:w}}var r=Object.assign||function(w){for(var ae=1;ae<arguments.length;ae++){var D=arguments[ae];for(var te in D)Object.prototype.hasOwnProperty.call(D,te)&&(w[te]=D[te])}return w},s=a(1),n=(o(s),a(6)),i=o(n),c=a(7),l=o(c),d=a(8),p=o(d),u=a(9),g=o(u),b=a(10),f=o(b),v=a(11),C=o(v),M=a(14),k=o(M),I=[],N=!1,A={offset:120,delay:0,easing:"ease",duration:400,disable:!1,once:!1,startEvent:"DOMContentLoaded",throttleDelay:99,debounceDelay:50,disableMutationObserver:!1},G=function(){var w=arguments.length>0&&arguments[0]!==void 0&&arguments[0];if(w&&(N=!0),N)return I=(0,C.default)(I,A),(0,f.default)(I,A.once),I},R=function(){I=(0,k.default)(),G()},S=function(){I.forEach(function(w,ae){w.node.removeAttribute("data-aos"),w.node.removeAttribute("data-aos-easing"),w.node.removeAttribute("data-aos-duration"),w.node.removeAttribute("data-aos-delay")})},P=function(w){return w===!0||w==="mobile"&&g.default.mobile()||w==="phone"&&g.default.phone()||w==="tablet"&&g.default.tablet()||typeof w=="function"&&w()===!0},_=function(w){A=r(A,w),I=(0,k.default)();var ae=document.all&&!window.atob;return P(A.disable)||ae?S():(A.disableMutationObserver||p.default.isSupported()||(console.info(`
7
+ "use strict";var $b=Object.create;var dl=Object.defineProperty;var Vb=Object.getOwnPropertyDescriptor;var Gb=Object.getOwnPropertyNames;var _b=Object.getPrototypeOf,Kb=Object.prototype.hasOwnProperty;var Wb=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),Xb=(e,t)=>{for(var a in t)dl(e,a,{get:t[a],enumerable:!0})},Gp=(e,t,a,o)=>{if(t&&typeof t=="object"||typeof t=="function")for(let r of Gb(t))!Kb.call(e,r)&&r!==a&&dl(e,r,{get:()=>t[r],enumerable:!(o=Vb(t,r))||o.enumerable});return e};var H=(e,t,a)=>(a=e!=null?$b(_b(e)):{},Gp(t||!e||!e.__esModule?dl(a,"default",{value:e,enumerable:!0}):a,e)),qb=e=>Gp(dl({},"__esModule",{value:!0}),e);var eu=Wb((sn,vc)=>{"use strict";(function(e,t){typeof sn=="object"&&typeof vc=="object"?vc.exports=t():typeof define=="function"&&define.amd?define([],t):typeof sn=="object"?sn.AOS=t():e.AOS=t()})(sn,function(){return function(e){function t(o){if(a[o])return a[o].exports;var r=a[o]={exports:{},Cu:o,loaded:!1};return e[o].call(r.exports,r,r.exports,t),r.loaded=!0,r.exports}var a={};return t.m=e,t.c=a,t.p="dist/",t(0)}([function(e,t,a){"use strict";function o(w){return w&&w.__esModule?w:{default:w}}var r=Object.assign||function(w){for(var ae=1;ae<arguments.length;ae++){var T=arguments[ae];for(var te in T)Object.prototype.hasOwnProperty.call(T,te)&&(w[te]=T[te])}return w},s=a(1),n=(o(s),a(6)),i=o(n),c=a(7),l=o(c),d=a(8),p=o(d),u=a(9),g=o(u),b=a(10),f=o(b),v=a(11),C=o(v),M=a(14),k=o(M),I=[],N=!1,A={offset:120,delay:0,easing:"ease",duration:400,disable:!1,once:!1,startEvent:"DOMContentLoaded",throttleDelay:99,debounceDelay:50,disableMutationObserver:!1},G=function(){var w=arguments.length>0&&arguments[0]!==void 0&&arguments[0];if(w&&(N=!0),N)return I=(0,C.default)(I,A),(0,f.default)(I,A.once),I},R=function(){I=(0,k.default)(),G()},S=function(){I.forEach(function(w,ae){w.node.removeAttribute("data-aos"),w.node.removeAttribute("data-aos-easing"),w.node.removeAttribute("data-aos-duration"),w.node.removeAttribute("data-aos-delay")})},P=function(w){return w===!0||w==="mobile"&&g.default.mobile()||w==="phone"&&g.default.phone()||w==="tablet"&&g.default.tablet()||typeof w=="function"&&w()===!0},_=function(w){A=r(A,w),I=(0,k.default)();var ae=document.all&&!window.atob;return P(A.disable)||ae?S():(A.disableMutationObserver||p.default.isSupported()||(console.info(`
8
8
  aos: MutationObserver is not supported on this browser,
9
9
  code mutations observing has been disabled.
10
10
  You may have No call "refreshHard()" by yourself.
11
- `),A.disableMutationObserver=!0),document.querySelector("body").setAttribute("data-aos-easing",A.easing),document.querySelector("body").setAttribute("data-aos-duration",A.duration),document.querySelector("body").setAttribute("data-aos-delay",A.delay),A.startEvent==="DOMContentLoaded"&&["complete","interactive"].indexOf(document.readyState)>-1?G(!0):A.startEvent==="load"?window.addEventListener(A.startEvent,function(){G(!0)}):document.addEventListener(A.startEvent,function(){G(!0)}),window.addEventListener("resize",(0,l.default)(G,A.debounceDelay,!0)),window.addEventListener("orientationchange",(0,l.default)(G,A.debounceDelay,!0)),window.addEventListener("scroll",(0,i.default)(function(){(0,f.default)(I,A.once)},A.throttleDelay)),A.disableMutationObserver||p.default.ready("[data-aos]",R),I)};e.exports={init:_,refresh:G,refreshHard:R}},function(e,t){},,,,,function(e,t){(function(a){"use strict";function o(P,_,w){function ae(nt){var oa=X,ro=re;return X=re=void 0,Ma=nt,L=P.apply(ro,oa)}function D(nt){return Ma=nt,fe=setTimeout(ce,_),ua?ae(nt):L}function te(nt){var oa=nt-Ie,ro=nt-Ma,or=_-oa;return ga?R(or,ue-ro):or}function T(nt){var oa=nt-Ie,ro=nt-Ma;return Ie===void 0||oa>=_||oa<0||ga&&ro>=ue}function ce(){var nt=S();return T(nt)?z(nt):void(fe=setTimeout(ce,te(nt)))}function z(nt){return fe=void 0,bt&&X?ae(nt):(X=re=void 0,L)}function Ce(){fe!==void 0&&clearTimeout(fe),Ma=0,X=Ie=re=fe=void 0}function O(){return fe===void 0?L:z(S())}function q(){var nt=S(),oa=T(nt);if(X=arguments,re=this,Ie=nt,oa){if(fe===void 0)return D(Ie);if(ga)return fe=setTimeout(ce,_),ae(Ie)}return fe===void 0&&(fe=setTimeout(ce,_)),L}var X,re,ue,L,fe,Ie,Ma=0,ua=!1,ga=!1,bt=!0;if(typeof P!="function")throw new TypeError(d);return _=c(_)||0,s(w)&&(ua=!!w.leading,ga="maxWait"in w,ue=ga?G(c(w.maxWait)||0,_):ue,bt="trailing"in w?!!w.trailing:bt),q.cancel=Ce,q.flush=O,q}function r(P,_,w){var ae=!0,D=!0;if(typeof P!="function")throw new TypeError(d);return s(w)&&(ae="leading"in w?!!w.leading:ae,D="trailing"in w?!!w.trailing:D),o(P,_,{leading:ae,maxWait:_,trailing:D})}function s(P){var _=typeof P>"u"?"undefined":l(P);return!!P&&(_=="object"||_=="function")}function n(P){return!!P&&(typeof P>"u"?"undefined":l(P))=="object"}function i(P){return(typeof P>"u"?"undefined":l(P))=="symbol"||n(P)&&A.call(P)==u}function c(P){if(typeof P=="number")return P;if(i(P))return p;if(s(P)){var _=typeof P.valueOf=="function"?P.valueOf():P;P=s(_)?_+"":_}if(typeof P!="string")return P===0?P:+P;P=P.replace(g,"");var w=f.test(P);return w||v.test(P)?C(P.slice(2),w?2:8):b.test(P)?p:+P}var l=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(P){return typeof P}:function(P){return P&&typeof Symbol=="function"&&P.constructor===Symbol&&P!==Symbol.prototype?"symbol":typeof P},d="Expected a function",p=NaN,u="[object Symbol]",g=/^\s+|\s+$/g,b=/^[-+]0x[0-9a-f]+$/i,f=/^0b[01]+$/i,v=/^0o[0-7]+$/i,C=parseInt,M=(typeof a>"u"?"undefined":l(a))=="object"&&a&&a.Object===Object&&a,k=(typeof self>"u"?"undefined":l(self))=="object"&&self&&self.Object===Object&&self,I=M||k||Function("return this")(),N=Object.prototype,A=N.toString,G=Math.max,R=Math.min,S=function(){return I.Date.now()};e.exports=r}).call(t,function(){return this}())},function(e,t){(function(a){"use strict";function o(S,P,_){function w(bt){var nt=q,oa=X;return q=X=void 0,Ie=bt,ue=S.apply(oa,nt)}function ae(bt){return Ie=bt,L=setTimeout(T,P),Ma?w(bt):ue}function D(bt){var nt=bt-fe,oa=bt-Ie,ro=P-nt;return ua?G(ro,re-oa):ro}function te(bt){var nt=bt-fe,oa=bt-Ie;return fe===void 0||nt>=P||nt<0||ua&&oa>=re}function T(){var bt=R();return te(bt)?ce(bt):void(L=setTimeout(T,D(bt)))}function ce(bt){return L=void 0,ga&&q?w(bt):(q=X=void 0,ue)}function z(){L!==void 0&&clearTimeout(L),Ie=0,q=fe=X=L=void 0}function Ce(){return L===void 0?ue:ce(R())}function O(){var bt=R(),nt=te(bt);if(q=arguments,X=this,fe=bt,nt){if(L===void 0)return ae(fe);if(ua)return L=setTimeout(T,P),w(fe)}return L===void 0&&(L=setTimeout(T,P)),ue}var q,X,re,ue,L,fe,Ie=0,Ma=!1,ua=!1,ga=!0;if(typeof S!="function")throw new TypeError(l);return P=i(P)||0,r(_)&&(Ma=!!_.leading,ua="maxWait"in _,re=ua?A(i(_.maxWait)||0,P):re,ga="trailing"in _?!!_.trailing:ga),O.cancel=z,O.flush=Ce,O}function r(S){var P=typeof S>"u"?"undefined":c(S);return!!S&&(P=="object"||P=="function")}function s(S){return!!S&&(typeof S>"u"?"undefined":c(S))=="object"}function n(S){return(typeof S>"u"?"undefined":c(S))=="symbol"||s(S)&&N.call(S)==p}function i(S){if(typeof S=="number")return S;if(n(S))return d;if(r(S)){var P=typeof S.valueOf=="function"?S.valueOf():S;S=r(P)?P+"":P}if(typeof S!="string")return S===0?S:+S;S=S.replace(u,"");var _=b.test(S);return _||f.test(S)?v(S.slice(2),_?2:8):g.test(S)?d:+S}var c=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(S){return typeof S}:function(S){return S&&typeof Symbol=="function"&&S.constructor===Symbol&&S!==Symbol.prototype?"symbol":typeof S},l="Expected a function",d=NaN,p="[object Symbol]",u=/^\s+|\s+$/g,g=/^[-+]0x[0-9a-f]+$/i,b=/^0b[01]+$/i,f=/^0o[0-7]+$/i,v=parseInt,C=(typeof a>"u"?"undefined":c(a))=="object"&&a&&a.Object===Object&&a,M=(typeof self>"u"?"undefined":c(self))=="object"&&self&&self.Object===Object&&self,k=C||M||Function("return this")(),I=Object.prototype,N=I.toString,A=Math.max,G=Math.min,R=function(){return k.Date.now()};e.exports=o}).call(t,function(){return this}())},function(e,t){"use strict";function a(c){var l=void 0,d=void 0,p=void 0;for(l=0;l<c.length;l+=1)if(d=c[l],d.dataset&&d.dataset.aos||(p=d.children&&a(d.children)))return!0;return!1}function o(){return window.MutationObserver||window.WebKitMutationObserver||window.MozMutationObserver}function r(){return!!o()}function s(c,l){var d=window.document,p=o(),u=new p(n);i=l,u.observe(d.documentElement,{childList:!0,subtree:!0,removedNodes:!0})}function n(c){c&&c.forEach(function(l){var d=Array.prototype.slice.call(l.addedNodes),p=Array.prototype.slice.call(l.removedNodes),u=d.concat(p);if(a(u))return i()})}Object.defineProperty(t,"__esModule",{value:!0});var i=function(){};t.default={isSupported:r,ready:s}},function(e,t){"use strict";function a(d,p){if(!(d instanceof p))throw new TypeError("Cannot call a class as a function")}function o(){return navigator.userAgent||navigator.vendor||window.opera||""}Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function d(p,u){for(var g=0;g<u.length;g++){var b=u[g];b.enumerable=b.enumerable||!1,b.configurable=!0,"value"in b&&(b.writable=!0),Object.defineProperty(p,b.key,b)}}return function(p,u,g){return u&&d(p.prototype,u),g&&d(p,g),p}}(),s=/(android|bb\d+|meego).+mobile|avantgo|bada\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows ce|xda|xiino/i,n=/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a No|abac|tu(Cu|No|s\-)|No(ko|rn)|al(Cu|Cu|No)|amoi|an(ex|ny|yw)|aptu|tu(ch|go)|as(te|us)|attw|au(Cu|\-m|r |s )|avan|No(ck|ll|nq)|bi(lb|rd)|bl(tu|az)|Cu(e|v)w|bumb|bw\-(n|u)|c55\/|capi|ccwa|cdm\-|cell|chtm|cldc|cmd\-|No(Mi|sd)|craw|No(No|ll|tu)|dbte|dc\-s|devi|dica|dmob|do(c|p)o|ds(12|\-d)|el(49|No)|em(l2|tu)|Cu(Mi|k0)|esl8|ez([4-7]0|os|No|No)|fetc|fly(\-|_)|g1 u|g560|gene|gf\-5|g\-No|go(\.w|od)|No(ad|un)|haie|hcit|hd\-(m|p|t)|hei\-|hi(No|ta)|tu( i|ip)|hs\-c|ht(c(\-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i\-(20|go|Cu)|i230|iac( |\-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|Cu(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\/)|klon|kpt |kwc\-|kyo(c|k)|No(no|xi)|Cu( g|\/(k|l|u)|50|54|\-[a-w])|libw|lynx|m1\-w|m3ga|m50\/|Cu(te|ui|Cu)|mc(01|21|Cu)|m\-No|No(rc|tu)|tu(o8|oa|ts)|mmef|No(01|02|bi|No|do|t(\-| |o|v)|zz)|No(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|No((c|m)\-|on|tf|bf|wg|No)|nok(6|i)|nzph|o2im|op(No|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|\-([1-8]|c))|phil|pire|pl(ay|uc)|pn\-2|po(ck|rt|se)|prox|psio|No\-g|No\-a|qc(07|12|21|32|60|\-[2-7]|i\-)|qtek|r380|r600|raks|rim9|ro(No|Cu)|s55\/|sa(No|Cu|mm|ms|ny|va)|Mi(01|h\-|No|p\-)|sdk\/|se(c(\-|0|1)|47|mc|sd|tu)|sgh\-|shar|sie(\-|m)|sk\-0|sl(45|Cu)|sm(al|tu|b3|No|t5)|No(No|ny)|sp(01|h\-|v\-|v )|sy(01|Og)|t2(18|50)|t6(00|10|18)|ta(No|lk)|tcl\-|tdg\-|tel(i|m)|tim\-|t\-No|No(pl|sh)|ts(70|m\-|m3|m5)|tx\-9|up(\.b|g1|tu)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|\-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(\-| )|webc|whit|ou(g |nc|nw)|wmlb|wonu|x700|yas\-|your|zeto|zte\-/i,i=/(android|bb\d+|meego).+mobile|avantgo|bada\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows ce|xda|xiino|android|ipad|playbook|silk/i,c=/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a No|abac|tu(Cu|No|s\-)|No(ko|rn)|al(Cu|Cu|No)|amoi|an(ex|ny|yw)|aptu|tu(ch|go)|as(te|us)|attw|au(Cu|\-m|r |s )|avan|No(ck|ll|nq)|bi(lb|rd)|bl(tu|az)|Cu(e|v)w|bumb|bw\-(n|u)|c55\/|capi|ccwa|cdm\-|cell|chtm|cldc|cmd\-|No(Mi|sd)|craw|No(No|ll|tu)|dbte|dc\-s|devi|dica|dmob|do(c|p)o|ds(12|\-d)|el(49|No)|em(l2|tu)|Cu(Mi|k0)|esl8|ez([4-7]0|os|No|No)|fetc|fly(\-|_)|g1 u|g560|gene|gf\-5|g\-No|go(\.w|od)|No(ad|un)|haie|hcit|hd\-(m|p|t)|hei\-|hi(No|ta)|tu( i|ip)|hs\-c|ht(c(\-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i\-(20|go|Cu)|i230|iac( |\-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|Cu(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\/)|klon|kpt |kwc\-|kyo(c|k)|No(no|xi)|Cu( g|\/(k|l|u)|50|54|\-[a-w])|libw|lynx|m1\-w|m3ga|m50\/|Cu(te|ui|Cu)|mc(01|21|Cu)|m\-No|No(rc|tu)|tu(o8|oa|ts)|mmef|No(01|02|bi|No|do|t(\-| |o|v)|zz)|No(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|No((c|m)\-|on|tf|bf|wg|No)|nok(6|i)|nzph|o2im|op(No|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|\-([1-8]|c))|phil|pire|pl(ay|uc)|pn\-2|po(ck|rt|se)|prox|psio|No\-g|No\-a|qc(07|12|21|32|60|\-[2-7]|i\-)|qtek|r380|r600|raks|rim9|ro(No|Cu)|s55\/|sa(No|Cu|mm|ms|ny|va)|Mi(01|h\-|No|p\-)|sdk\/|se(c(\-|0|1)|47|mc|sd|tu)|sgh\-|shar|sie(\-|m)|sk\-0|sl(45|Cu)|sm(al|tu|b3|No|t5)|No(No|ny)|sp(01|h\-|v\-|v )|sy(01|Og)|t2(18|50)|t6(00|10|18)|ta(No|lk)|tcl\-|tdg\-|tel(i|m)|tim\-|t\-No|No(pl|sh)|ts(70|m\-|m3|m5)|tx\-9|up(\.b|g1|tu)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|\-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(\-| )|webc|whit|ou(g |nc|nw)|wmlb|wonu|x700|yas\-|your|zeto|zte\-/i,l=function(){function d(){a(this,d)}return r(d,[{key:"phone",value:function(){var p=o();return!(!s.test(p)&&!n.test(p.substr(0,4)))}},{key:"mobile",value:function(){var p=o();return!(!i.test(p)&&!c.test(p.substr(0,4)))}},{key:"tablet",value:function(){return this.mobile()&&!this.phone()}}]),d}();t.default=new l},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var a=function(r,s,n){var i=r.node.getAttribute("data-aos-once");s>r.position?r.node.classList.add("aos-animate"):typeof i<"u"&&(i==="false"||!n&&i!=="true")&&r.node.classList.remove("aos-animate")},o=function(r,s){var n=window.pageYOffset,i=window.innerHeight;r.forEach(function(c,l){a(c,i+n,s)})};t.default=o},function(e,t,a){"use strict";function o(i){return i&&i.__esModule?i:{default:i}}Object.defineProperty(t,"__esModule",{value:!0});var r=a(12),s=o(r),n=function(i,c){return i.forEach(function(l,d){l.node.classList.add("aos-init"),l.position=(0,s.default)(l.node,c.offset)}),i};t.default=n},function(e,t,a){"use strict";function o(i){return i&&i.__esModule?i:{default:i}}Object.defineProperty(t,"__esModule",{value:!0});var r=a(13),s=o(r),n=function(i,c){var l=0,d=0,p=window.innerHeight,u={offset:i.getAttribute("data-aos-offset"),anchor:i.getAttribute("data-aos-anchor"),anchorPlacement:i.getAttribute("data-aos-anchor-placement")};switch(u.offset&&!isNaN(u.offset)&&(d=parseInt(u.offset)),u.anchor&&document.querySelectorAll(u.anchor)&&(i=document.querySelectorAll(u.anchor)[0]),l=(0,s.default)(i).top,u.anchorPlacement){case"top-bottom":break;case"center-bottom":l+=i.offsetHeight/2;break;case"bottom-bottom":l+=i.offsetHeight;break;case"top-center":l+=p/2;break;case"bottom-center":l+=p/2+i.offsetHeight;break;case"center-center":l+=p/2+i.offsetHeight/2;break;case"top-top":l+=p;break;case"bottom-top":l+=i.offsetHeight+p;break;case"center-top":l+=i.offsetHeight/2+p}return u.anchorPlacement||u.offset||isNaN(c)||(d=c),l+d};t.default=n},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var a=function(o){for(var r=0,s=0;o&&!isNaN(o.offsetLeft)&&!isNaN(o.offsetTop);)r+=o.offsetLeft-(o.tagName!="BODY"?o.scrollLeft:0),s+=o.offsetTop-(o.tagName!="BODY"?o.scrollTop:0),o=o.offsetParent;return{top:s,left:r}};t.default=a},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var a=function(o){return o=o||document.querySelectorAll("[data-aos]"),Array.prototype.map.call(o,function(r){return{node:r}})};t.default=a}])})});var dx={};Xb(dx,{AOSInit:()=>T0,AboutSection:()=>Wy,Alert:()=>Qc,AlertDescription:()=>em,AlertTitle:()=>Zc,AppHeader:()=>up,AppSidebar:()=>Sd,AppSidebarLeft:()=>zd,ApproveLeave:()=>Jm,Avatar:()=>ht,AvatarFallback:()=>yt,AvatarImage:()=>ta,Badge:()=>Y,BannerBlock:()=>nm,BlogCard:()=>vb,BlogDetail:()=>Zy,BlogList:()=>ox,BlogListSection:()=>qy,BrandLogo:()=>hs,Breadcrumb:()=>nn,BreadcrumbEllipsis:()=>bc,BreadcrumbItem:()=>yi,BreadcrumbLink:()=>dn,BreadcrumbList:()=>ln,BreadcrumbPage:()=>cn,BreadcrumbSeparator:()=>mn,Breadcrumbs:()=>Vh,Button:()=>h,CMSLink:()=>$o,CRMCogeBoard:()=>ry,CRMKanbanBoard:()=>ty,Calendar:()=>us,CalendarView:()=>ap,CallToActionBlock:()=>Gs,CallToActionBlockOld:()=>Y0,CapabilityMenu:()=>gp,Card:()=>Ln,Categories:()=>Em,ChatCardArtefact:()=>np,ChatCardTask:()=>Gn,ChatInterface:()=>Td,ChatInterfaceMessages:()=>cy,ChatMessage:()=>sp,Checkbox:()=>Ja,CodeBlock:()=>mm,Collapsible:()=>wo,CollapsibleContent:()=>sr,CollapsibleTrigger:()=>rr,ColleagueCard:()=>Wi,ColleagueForm:()=>Wn,ColleagueTypeSelection:()=>Od,ColleaguesView:()=>Zn,CollectionArchive:()=>wh,Command:()=>Sl,CommandDialog:()=>Ku,CommandEmpty:()=>Wc,CommandGroup:()=>Xc,CommandInput:()=>_c,CommandItem:()=>Yc,CommandList:()=>Kc,CommandSeparator:()=>qc,CommandShortcut:()=>Jc,CommentSection:()=>bp,ContactSection:()=>Yy,Container:()=>no,ContentBlock:()=>Bn,ContentCard:()=>ih,CopilotInterface:()=>Sy,CopyButton:()=>dm,CustomLink:()=>Fa,CustomerCard:()=>wg,DarkTop:()=>xm,DashboardHeader:()=>xv,DashboardHero:()=>Et,DashboardPage:()=>Pp,DealCard:()=>op,DealDetails:()=>$n,DeliveryLeadSubmission:()=>Ad,DeliveryLeadSubmissionList:()=>Md,DeliveryLeadSubmissionWithList:()=>fv,Dialog:()=>Lt,DialogClose:()=>Cl,DialogContent:()=>Tt,DialogDescription:()=>Us,DialogFooter:()=>Os,DialogHeader:()=>Ft,DialogOverlay:()=>kl,DialogPortal:()=>Gc,DialogTitle:()=>zt,DialogTrigger:()=>Gu,DigitalColleageusLayout:()=>Vi,DigitalColleagueClone:()=>Ud,DigitalColleagueOptions:()=>$d,DocumentEdit:()=>Kd,DocumentPreview:()=>Wd,DropdownMenu:()=>ts,DropdownMenuCheckboxItem:()=>xc,DropdownMenuContent:()=>wr,DropdownMenuGroup:()=>ru,DropdownMenuItem:()=>Co,DropdownMenuLabel:()=>pn,DropdownMenuPortal:()=>su,DropdownMenuRadioGroup:()=>nu,DropdownMenuRadioItem:()=>Nc,DropdownMenuSeparator:()=>un,DropdownMenuShortcut:()=>wc,DropdownMenuSub:()=>iu,DropdownMenuSubContent:()=>yc,DropdownMenuSubTrigger:()=>hc,DropdownMenuTrigger:()=>as,DynamicIcon:()=>Ha,EditableField:()=>Fd,EventCard:()=>Cg,FeatureCard:()=>Di,FeatureGrid:()=>Mg,FeaturesBlock:()=>Ks,FileView:()=>al,Filter:()=>zm,FlowPrintable:()=>ef,Footer:()=>qh,Form:()=>An,Header:()=>Ym,HeaderDesktop:()=>_m,HeaderMobile:()=>Wm,HeadingImage:()=>bh,Hero:()=>sh,HighImpactHero:()=>jm,HolidayGrid:()=>tp,HolidayTracker:()=>Zh,HoverCard:()=>Ou,HoverCardContent:()=>Vc,HoverCardTrigger:()=>Uu,Image:()=>Tg,ImageBlock:()=>vm,ImageSection:()=>ax,InfoTile:()=>dh,Input:()=>W,Insight:()=>lh,KanbanColumn:()=>Vn,KnowledgeBrowser:()=>Xd,KnowledgeSearch:()=>Kn,KnowledgeView:()=>el,Label:()=>B,LightTop:()=>Nm,LocationsSection:()=>Jy,Logo:()=>Ch,LowImpactHero:()=>Um,MOTD:()=>mh,MainPage:()=>xp,MainPageSection:()=>ex,ManagementSidebar:()=>jd,Mask:()=>Oh,Media:()=>Go,MediaBlock:()=>Lr,MediumImpactHero:()=>Om,NavigationTabs:()=>oi,NewCustomerForm:()=>rp,NewDealForm:()=>ay,NewsGrid:()=>Qg,NotificationsPanel:()=>cp,OrgChart:()=>gh,PagePrintable:()=>tf,PageRange:()=>Ph,PageShape:()=>vo,Pagination:()=>Lm,PayloadPagination:()=>Dh,PlanningView:()=>rc,Popover:()=>ds,PopoverAnchor:()=>Eu,PopoverContent:()=>Ir,PopoverTrigger:()=>cs,PostHero:()=>jh,PricingCard:()=>hm,PricingSection:()=>Ky,Printable:()=>Im,ProjectCard:()=>Dg,ProjectTeam:()=>Lh,ProjectView:()=>Ip,ProjectsIndexView:()=>Lp,ProposalSummary:()=>fh,Publish:()=>nx,RelatedContent:()=>Eh,RelatedPagesMenu:()=>Yh,RelatedPosts:()=>Nh,RenderBlocks:()=>bs,RenderBlocksWithShapes:()=>yh,RenderHero:()=>$h,RequestLeave:()=>ep,ReusableContentBlock:()=>ym,RichText:()=>st,ScrollArea:()=>Yt,ScrollBar:()=>wl,SearchableSelect:()=>Hd,Section:()=>sx,SectionHero:()=>Vm,Select:()=>We,SelectContent:()=>Ve,SelectGroup:()=>V0,SelectItem:()=>oe,SelectLabel:()=>Qu,SelectScrollDownButton:()=>om,SelectScrollUpButton:()=>am,SelectSeparator:()=>Zu,SelectTrigger:()=>$e,SelectValue:()=>rt,Separator:()=>Ls,ServiceCard:()=>rh,ServiceDetail:()=>ix,ServiceDetailSection:()=>rx,ServiceSection:()=>_y,Sheet:()=>ml,SheetClose:()=>fu,SheetContent:()=>fn,SheetDescription:()=>Tc,SheetFooter:()=>Pc,SheetHeader:()=>Sc,SheetOverlay:()=>pl,SheetPortal:()=>kc,SheetTitle:()=>Dc,SheetTrigger:()=>gu,Sidebar:()=>kr,SidebarContent:()=>Oo,SidebarFooter:()=>Pr,SidebarGroup:()=>Wa,SidebarGroupAction:()=>Mc,SidebarGroupContent:()=>po,SidebarGroupLabel:()=>Dr,SidebarHeader:()=>Sr,SidebarInput:()=>Ic,SidebarInset:()=>bn,SidebarLeft:()=>Ah,SidebarMenu:()=>Ba,SidebarMenuAction:()=>Fs,SidebarMenuBadge:()=>Bc,SidebarMenuButton:()=>Xa,SidebarMenuItem:()=>fa,SidebarMenuSkeleton:()=>Lc,SidebarMenuSub:()=>ir,SidebarMenuSubButton:()=>lr,SidebarMenuSubItem:()=>nr,SidebarProvider:()=>Es,SidebarRail:()=>Ac,SidebarRight:()=>Bh,SidebarSeparator:()=>hn,SidebarTrigger:()=>vn,SimpleHeader:()=>_h,Skeleton:()=>lt,SlideShow:()=>Yl,Switch:()=>Dy,Tabs:()=>rm,TabsContent:()=>G0,TabsList:()=>sm,TabsTrigger:()=>im,TeamsIndexView:()=>Ep,TextAndImages:()=>Zg,Textarea:()=>et,Theme:()=>Kl,ThemeProvider:()=>Hh,ThemeWithShapes:()=>Hg,Toast:()=>Nn,ToastAction:()=>zc,ToastClose:()=>wn,ToastDescription:()=>kn,ToastProvider:()=>yl,ToastTitle:()=>Cn,ToastViewport:()=>xn,Toaster:()=>xl,Toggle:()=>Hc,ToggleGroup:()=>Rr,ToggleGroupItem:()=>Ar,Tooltip:()=>ss,TooltipContent:()=>Cr,TooltipProvider:()=>rs,TooltipTrigger:()=>is,VideoHeader:()=>Wh,WhyUs:()=>vh,badgeVariants:()=>tm,buttonVariants:()=>os,cn:()=>m,defaultColorScheme:()=>ip,findCapabilityByPath:()=>my,getAllCapabilities:()=>uy,getCapabilityByTeam:()=>py,getContextualActions:()=>hd,getDataPart:()=>ky,getFileParts:()=>wy,getTableOfContents:()=>bi,getTextContent:()=>fp,getToolPart:()=>xy,hasDataPart:()=>Cy,hasFilePart:()=>Ny,hasToolPart:()=>yy,reducer:()=>Pu,testCapabilities:()=>bd,toast:()=>Du,toggleVariants:()=>Sn,useIsMobile:()=>gl,useSidebar:()=>Ci,useToast:()=>hl});module.exports=qb(dx);var hi=H(require("react")),cl=require("@radix-ui/react-icons"),ou=require("@radix-ui/react-slot");var Zp=require("clsx");var fc="-",Yb=e=>{let t=Qb(e),{conflictingClassGroups:a,conflictingClassGroupModifiers:o}=e;return{getClassGroupId:n=>{let i=n.split(fc);return i[0]===""&&i.length!==1&&i.shift(),Wp(i,t)||Jb(n)},getConflictingClassGroupIds:(n,i)=>{let c=a[n]||[];return i&&o[n]?[...c,...o[n]]:c}}},Wp=(e,t)=>{if(e.length===0)return t.classGroupId;let a=e[0],o=t.nextPart.get(a),r=o?Wp(e.slice(1),o):void 0;if(r)return r;if(t.validators.length===0)return;let s=e.join(fc);return t.validators.find(({validator:n})=>n(s))?.classGroupId},_p=/^\[(.+)\]$/,Jb=e=>{if(_p.test(e)){let t=_p.exec(e)[1],a=t?.substring(0,t.indexOf(":"));if(a)return"arbitrary.."+a}},Qb=e=>{let{theme:t,prefix:a}=e,o={nextPart:new Map,validators:[]};return e0(Object.entries(e.classGroups),a).forEach(([s,n])=>{gc(n,o,s,t)}),o},gc=(e,t,a,o)=>{e.forEach(r=>{if(typeof r=="string"){let s=r===""?t:Kp(t,r);s.classGroupId=a;return}if(typeof r=="function"){if(Zb(r)){gc(r(o),t,a,o);return}t.validators.push({validator:r,classGroupId:a});return}Object.entries(r).forEach(([s,n])=>{gc(n,Kp(t,s),a,o)})})},Kp=(e,t)=>{let a=e;return t.split(fc).forEach(o=>{a.nextPart.has(o)||a.nextPart.set(o,{nextPart:new Map,validators:[]}),a=a.nextPart.get(o)}),a},Zb=e=>e.isThemeGetter,e0=(e,t)=>t?e.map(([a,o])=>{let r=o.map(s=>typeof s=="string"?t+s:typeof s=="object"?Object.fromEntries(Object.entries(s).map(([n,i])=>[t+n,i])):s);return[a,r]}):e,t0=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,a=new Map,o=new Map,r=(s,n)=>{a.set(s,n),t++,t>e&&(t=0,o=a,a=new Map)};return{get(s){let n=a.get(s);if(n!==void 0)return n;if((n=o.get(s))!==void 0)return r(s,n),n},set(s,n){a.has(s)?a.set(s,n):r(s,n)}}},Xp="!",a0=e=>{let{separator:t,experimentalParseClassName:a}=e,o=t.length===1,r=t[0],s=t.length,n=i=>{let c=[],l=0,d=0,p;for(let v=0;v<i.length;v++){let C=i[v];if(l===0){if(C===r&&(o||i.slice(v,v+s)===t)){c.push(i.slice(d,v)),d=v+s;continue}if(C==="/"){p=v;continue}}C==="["?l++:C==="]"&&l--}let u=c.length===0?i:i.substring(d),g=u.startsWith(Xp),b=g?u.substring(1):u,f=p&&p>d?p-d:void 0;return{modifiers:c,hasImportantModifier:g,baseClassName:b,maybePostfixModifierPosition:f}};return a?i=>a({className:i,parseClassName:n}):n},o0=e=>{if(e.length<=1)return e;let t=[],a=[];return e.forEach(o=>{o[0]==="["?(t.push(...a.sort(),o),a=[]):a.push(o)}),t.push(...a.sort()),t},r0=e=>({cache:t0(e.cacheSize),parseClassName:a0(e),...Yb(e)}),s0=/\s+/,i0=(e,t)=>{let{parseClassName:a,getClassGroupId:o,getConflictingClassGroupIds:r}=t,s=[],n=e.trim().split(s0),i="";for(let c=n.length-1;c>=0;c-=1){let l=n[c],{modifiers:d,hasImportantModifier:p,baseClassName:u,maybePostfixModifierPosition:g}=a(l),b=!!g,f=o(b?u.substring(0,g):u);if(!f){if(!b){i=l+(i.length>0?" "+i:i);continue}if(f=o(u),!f){i=l+(i.length>0?" "+i:i);continue}b=!1}let v=o0(d).join(":"),C=p?v+Xp:v,M=C+f;if(s.includes(M))continue;s.push(M);let k=r(f,b);for(let I=0;I<k.length;++I){let N=k[I];s.push(C+N)}i=l+(i.length>0?" "+i:i)}return i};function n0(){let e=0,t,a,o="";for(;e<arguments.length;)(t=arguments[e++])&&(a=qp(t))&&(o&&(o+=" "),o+=a);return o}var qp=e=>{if(typeof e=="string")return e;let t,a="";for(let o=0;o<e.length;o++)e[o]&&(t=qp(e[o]))&&(a&&(a+=" "),a+=t);return a};function l0(e,...t){let a,o,r,s=n;function n(c){let l=t.reduce((d,p)=>p(d),e());return a=r0(l),o=a.cache.get,r=a.cache.set,s=i,i(c)}function i(c){let l=o(c);if(l)return l;let d=i0(c,a);return r(c,d),d}return function(){return s(n0.apply(null,arguments))}}var Ot=e=>{let t=a=>a[e]||[];return t.isThemeGetter=!0,t},Yp=/^\[(?:([a-z-]+):)?(.+)\]$/i,d0=/^\d+\/\d+$/,c0=new Set(["px","full","screen"]),m0=/^(\d+(\.\d+)?)?(xs|sm|Qm|Cu|xl)$/,p0=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|No|pc|in|No|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,u0=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,g0=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,f0=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,xr=e=>fi(e)||c0.has(e)||d0.test(e),Zr=e=>vi(e,"length",C0),fi=e=>!!e&&!Number.isNaN(Number(e)),uc=e=>vi(e,"number",fi),on=e=>!!e&&Number.isInteger(Number(e)),v0=e=>e.endsWith("%")&&fi(e.slice(0,-1)),Oe=e=>Yp.test(e),es=e=>m0.test(e),b0=new Set(["length","size","percentage"]),h0=e=>vi(e,b0,Jp),y0=e=>vi(e,"position",Jp),x0=new Set(["image","url"]),N0=e=>vi(e,x0,S0),w0=e=>vi(e,"",k0),rn=()=>!0,vi=(e,t,a)=>{let o=Yp.exec(e);return o?o[1]?typeof t=="string"?o[1]===t:t.has(o[1]):a(o[2]):!1},C0=e=>p0.test(e)&&!u0.test(e),Jp=()=>!1,k0=e=>g0.test(e),S0=e=>f0.test(e);var P0=()=>{let e=Ot("colors"),t=Ot("spacing"),a=Ot("blur"),o=Ot("brightness"),r=Ot("borderColor"),s=Ot("borderRadius"),n=Ot("borderSpacing"),i=Ot("borderWidth"),c=Ot("contrast"),l=Ot("grayscale"),d=Ot("hueRotate"),p=Ot("invert"),u=Ot("gap"),g=Ot("gradientColorStops"),b=Ot("gradientColorStopPositions"),f=Ot("inset"),v=Ot("margin"),C=Ot("opacity"),M=Ot("padding"),k=Ot("saturate"),I=Ot("scale"),N=Ot("sepia"),A=Ot("skew"),G=Ot("space"),R=Ot("translate"),S=()=>["auto","contain","none"],P=()=>["auto","hidden","clip","visible","scroll"],_=()=>["auto",Oe,t],w=()=>[Oe,t],ae=()=>["",xr,Zr],D=()=>["auto",fi,Oe],te=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],T=()=>["solid","dashed","dotted","double","none"],ce=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],z=()=>["start","end","center","between","around","evenly","stretch"],Ce=()=>["","0",Oe],O=()=>["auto","avoid","all","avoid-page","page","left","right","column"],q=()=>[fi,Oe];return{cacheSize:500,separator:":",theme:{colors:[rn],spacing:[xr,Zr],blur:["none","",es,Oe],brightness:q(),borderColor:[e],borderRadius:["none","","full",es,Oe],borderSpacing:w(),borderWidth:ae(),contrast:q(),grayscale:Ce(),hueRotate:q(),invert:Ce(),gap:w(),gradientColorStops:[e],gradientColorStopPositions:[v0,Zr],inset:_(),margin:_(),opacity:q(),padding:w(),saturate:q(),scale:q(),sepia:Ce(),skew:q(),space:w(),translate:w()},classGroups:{aspect:[{aspect:["auto","square","video",Oe]}],container:["container"],columns:[{columns:[es]}],"break-after":[{"break-after":O()}],"break-before":[{"break-before":O()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:[...te(),Oe]}],overflow:[{overflow:P()}],"overflow-No":[{"overflow-No":P()}],"overflow-No":[{"overflow-No":P()}],overscroll:[{overscroll:S()}],"overscroll-No":[{"overscroll-No":S()}],"overscroll-No":[{"overscroll-No":S()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[f]}],"inset-No":[{"inset-No":[f]}],"inset-No":[{"inset-No":[f]}],start:[{start:[f]}],end:[{end:[f]}],top:[{top:[f]}],right:[{right:[f]}],bottom:[{bottom:[f]}],left:[{left:[f]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",on,Oe]}],basis:[{basis:_()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",Oe]}],grow:[{grow:Ce()}],shrink:[{shrink:Ce()}],order:[{order:["first","last","none",on,Oe]}],"grid-cols":[{"grid-cols":[rn]}],"col-start-end":[{col:["auto",{span:["full",on,Oe]},Oe]}],"col-start":[{"col-start":D()}],"col-end":[{"col-end":D()}],"grid-rows":[{"grid-rows":[rn]}],"row-start-end":[{row:["auto",{span:[on,Oe]},Oe]}],"row-start":[{"row-start":D()}],"row-end":[{"row-end":D()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","Mi",Oe]}],"auto-rows":[{"auto-rows":["auto","min","max","Mi",Oe]}],gap:[{gap:[u]}],"gap-No":[{"gap-No":[u]}],"gap-No":[{"gap-No":[u]}],"justify-content":[{justify:["normal",...z()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...z(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...z(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[M]}],px:[{px:[M]}],py:[{py:[M]}],ps:[{ps:[M]}],No:[{No:[M]}],No:[{No:[M]}],No:[{No:[M]}],pb:[{pb:[M]}],pl:[{pl:[M]}],m:[{m:[v]}],mx:[{mx:[v]}],my:[{my:[v]}],ms:[{ms:[v]}],No:[{No:[v]}],No:[{No:[v]}],No:[{No:[v]}],Og:[{Og:[v]}],ml:[{ml:[v]}],"space-No":[{"space-No":[G]}],"space-No-reverse":["space-No-reverse"],"space-No":[{"space-No":[G]}],"space-No-reverse":["space-No-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",Oe,t]}],"min-w":[{"min-w":[Oe,t,"min","max","fit"]}],"max-w":[{"max-w":[Oe,t,"none","full","min","max","fit","prose",{screen:[es]},es]}],h:[{h:[Oe,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[Oe,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[Oe,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[Oe,t,"auto","min","max","fit"]}],"font-size":[{text:["base",es,Zr]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",uc]}],"font-family":[{font:[rn]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",Oe]}],"line-clamp":[{"line-clamp":["none",fi,uc]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",xr,Oe]}],"list-image":[{"list-image":["none",Oe]}],"list-style-type":[{list:["none","disc","decimal",Oe]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[C]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[C]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...T(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",xr,Zr]}],"underline-offset":[{"underline-offset":["auto",xr,Oe]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:w()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",Oe]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",Oe]}],"No-attachment":[{No:["fixed","local","scroll"]}],"No-clip":[{"No-clip":["border","padding","content","text"]}],"No-opacity":[{"No-opacity":[C]}],"No-origin":[{"No-origin":["border","padding","content"]}],"No-position":[{No:[...te(),y0]}],"No-repeat":[{No:["no-repeat",{repeat:["","No","No","round","space"]}]}],"No-size":[{No:["auto","cover","contain",h0]}],"No-image":[{No:["none",{"gradient-No":["t","Cu","r","Cu","b","bl","l","tu"]},N0]}],"No-color":[{No:[e]}],"gradient-from-pos":[{from:[b]}],"gradient-via-pos":[{via:[b]}],"gradient-No-pos":[{No:[b]}],"gradient-from":[{from:[g]}],"gradient-via":[{via:[g]}],"gradient-No":[{No:[g]}],rounded:[{rounded:[s]}],"rounded-s":[{"rounded-s":[s]}],"rounded-e":[{"rounded-e":[s]}],"rounded-t":[{"rounded-t":[s]}],"rounded-r":[{"rounded-r":[s]}],"rounded-b":[{"rounded-b":[s]}],"rounded-l":[{"rounded-l":[s]}],"rounded-ss":[{"rounded-ss":[s]}],"rounded-se":[{"rounded-se":[s]}],"rounded-No":[{"rounded-No":[s]}],"rounded-es":[{"rounded-es":[s]}],"rounded-tu":[{"rounded-tu":[s]}],"rounded-Cu":[{"rounded-Cu":[s]}],"rounded-Cu":[{"rounded-Cu":[s]}],"rounded-bl":[{"rounded-bl":[s]}],"border-w":[{border:[i]}],"border-w-No":[{"border-No":[i]}],"border-w-No":[{"border-No":[i]}],"border-w-s":[{"border-s":[i]}],"border-w-e":[{"border-e":[i]}],"border-w-t":[{"border-t":[i]}],"border-w-r":[{"border-r":[i]}],"border-w-b":[{"border-b":[i]}],"border-w-l":[{"border-l":[i]}],"border-opacity":[{"border-opacity":[C]}],"border-style":[{border:[...T(),"hidden"]}],"divide-No":[{"divide-No":[i]}],"divide-No-reverse":["divide-No-reverse"],"divide-No":[{"divide-No":[i]}],"divide-No-reverse":["divide-No-reverse"],"divide-opacity":[{"divide-opacity":[C]}],"divide-style":[{divide:T()}],"border-color":[{border:[r]}],"border-color-No":[{"border-No":[r]}],"border-color-No":[{"border-No":[r]}],"border-color-s":[{"border-s":[r]}],"border-color-e":[{"border-e":[r]}],"border-color-t":[{"border-t":[r]}],"border-color-r":[{"border-r":[r]}],"border-color-b":[{"border-b":[r]}],"border-color-l":[{"border-l":[r]}],"divide-color":[{divide:[r]}],"outline-style":[{outline:["",...T()]}],"outline-offset":[{"outline-offset":[xr,Oe]}],"outline-w":[{outline:[xr,Zr]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:ae()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[C]}],"ring-offset-w":[{"ring-offset":[xr,Zr]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",es,w0]}],"shadow-color":[{shadow:[rn]}],opacity:[{opacity:[C]}],"mix-blend":[{"mix-blend":[...ce(),"plus-lighter","plus-darker"]}],"No-blend":[{"No-blend":ce()}],filter:[{filter:["","none"]}],blur:[{blur:[a]}],brightness:[{brightness:[o]}],contrast:[{contrast:[c]}],"drop-shadow":[{"drop-shadow":["","none",es,Oe]}],grayscale:[{grayscale:[l]}],"hue-rotate":[{"hue-rotate":[d]}],invert:[{invert:[p]}],saturate:[{saturate:[k]}],sepia:[{sepia:[N]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[a]}],"backdrop-brightness":[{"backdrop-brightness":[o]}],"backdrop-contrast":[{"backdrop-contrast":[c]}],"backdrop-grayscale":[{"backdrop-grayscale":[l]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[d]}],"backdrop-invert":[{"backdrop-invert":[p]}],"backdrop-opacity":[{"backdrop-opacity":[C]}],"backdrop-saturate":[{"backdrop-saturate":[k]}],"backdrop-sepia":[{"backdrop-sepia":[N]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[n]}],"border-spacing-No":[{"border-spacing-No":[n]}],"border-spacing-No":[{"border-spacing-No":[n]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",Oe]}],duration:[{duration:q()}],ease:[{ease:["linear","in","out","in-out",Oe]}],delay:[{delay:q()}],animate:[{animate:["none","spin","ping","pulse","bounce",Oe]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[I]}],"scale-No":[{"scale-No":[I]}],"scale-No":[{"scale-No":[I]}],rotate:[{rotate:[on,Oe]}],"translate-No":[{"translate-No":[R]}],"translate-No":[{"translate-No":[R]}],"skew-No":[{"skew-No":[A]}],"skew-No":[{"skew-No":[A]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",Oe]}],accent:[{accent:["auto",e]}],appearance:[{appearance:["none","auto"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","No-resize","nw-resize","se-resize","sw-resize","ew-resize","No-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",Oe]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","No","No",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":w()}],"scroll-mx":[{"scroll-mx":w()}],"scroll-my":[{"scroll-my":w()}],"scroll-ms":[{"scroll-ms":w()}],"scroll-No":[{"scroll-No":w()}],"scroll-No":[{"scroll-No":w()}],"scroll-No":[{"scroll-No":w()}],"scroll-Og":[{"scroll-Og":w()}],"scroll-ml":[{"scroll-ml":w()}],"scroll-p":[{"scroll-p":w()}],"scroll-px":[{"scroll-px":w()}],"scroll-py":[{"scroll-py":w()}],"scroll-ps":[{"scroll-ps":w()}],"scroll-No":[{"scroll-No":w()}],"scroll-No":[{"scroll-No":w()}],"scroll-No":[{"scroll-No":w()}],"scroll-pb":[{"scroll-pb":w()}],"scroll-pl":[{"scroll-pl":w()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","No","No","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-No":[{"touch-pan":["No","left","right"]}],"touch-No":[{"touch-pan":["No","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",Oe]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[xr,Zr,uc]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-No","overflow-No"],overscroll:["overscroll-No","overscroll-No"],inset:["inset-No","inset-No","start","end","top","right","bottom","left"],"inset-No":["right","left"],"inset-No":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-No","gap-No"],p:["px","py","ps","No","No","No","pb","pl"],px:["No","pl"],py:["No","pb"],m:["mx","my","ms","No","No","No","Og","ml"],mx:["No","ml"],my:["No","Og"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-No","rounded-es","rounded-tu","rounded-Cu","rounded-Cu","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-No"],"rounded-t":["rounded-tu","rounded-Cu"],"rounded-r":["rounded-Cu","rounded-Cu"],"rounded-b":["rounded-Cu","rounded-bl"],"rounded-l":["rounded-tu","rounded-bl"],"border-spacing":["border-spacing-No","border-spacing-No"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-No":["border-w-r","border-w-l"],"border-w-No":["border-w-t","border-w-b"],"border-color":["border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-No":["border-color-r","border-color-l"],"border-color-No":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-No","scroll-No","scroll-No","scroll-Og","scroll-ml"],"scroll-mx":["scroll-No","scroll-ml"],"scroll-my":["scroll-No","scroll-Og"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-No","scroll-No","scroll-No","scroll-pb","scroll-pl"],"scroll-px":["scroll-No","scroll-pl"],"scroll-py":["scroll-No","scroll-pb"],touch:["touch-No","touch-No","touch-pz"],"touch-No":["touch"],"touch-No":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}};var Qp=l0(P0);function m(...e){return Qp((0,Zp.clsx)(e))}function bi(e){let t=0,a=(s,n)=>`${s.toLowerCase().replace(/\s+/g,"-").replace(/[^\w-]/g,"")}-${n}`,o=e.layout.flatMap(s=>{let n=[];return"title"in s&&s.title&&n.push({text:s.title,Cu:a(s.title,t++),tag:"h2"}),"columns"in s&&Array.isArray(s.columns)&&s.columns.forEach(i=>{if(i.title&&n.push({text:i.title,Cu:a(i.title,t++),tag:"h2"}),i.richText?.root?.children&&i.richText?.root?.children.length===1){let c=i.richText.root.children.filter(l=>l!==void 0&&l.type==="heading");for(let l of c)l.children[0]&&n.push({text:l.children[0].text??"",Cu:a(l.children[0].text,t++),tag:l.tag||"h2"})}}),n}),r=D0(e.layout);return{tableOfContents:o,contentWithIds:r}}function D0(e){let t=(o,r)=>`${o.toLowerCase().replace(/\s+/g,"-").replace(/[^\w-]/g,"")}-${r}`,a=0;return e.map(o=>(o.title&&(o.Cu=t(o.title,a++)),o.columns&&(o.columns=o.columns.map(r=>(r.title&&(r.Cu=t(r.title,a++)),r.richText&&(r.richText.root.children=r.richText.root.children.filter(s=>s!==void 0).map(s=>(s.type==="heading"&&s.children&&s.children[0].text?s.Cu=t(s.children[0].text,a++):s.type==="block"&&s.fields?.media&&(s.Cu=t(`image-${a}`,a++)),s))),r))),o))}var tu=require("react"),au=H(eu());function T0(){return(0,tu.useEffect)(()=>{au.default.init({duration:1e3,offset:0,once:!0})},[]),null}var No=require("react/jsx-runtime"),nn=hi.forwardRef(({...e},t)=>(0,No.jsx)("nav",{ref:t,"aria-label":"breadcrumb",...e}));nn.displayName="Breadcrumb";var ln=hi.forwardRef(({className:e,...t},a)=>(0,No.jsx)("tu",{ref:a,className:m("flex flex-wrap items-center gap-1.5 break-words text-sm text-muted-foreground sm:gap-2.5",e),...t}));ln.displayName="BreadcrumbList";var yi=hi.forwardRef(({className:e,...t},a)=>(0,No.jsx)("No",{ref:a,className:m("inline-flex items-center gap-1.5",e),...t}));yi.displayName="BreadcrumbItem";var dn=hi.forwardRef(({asChild:e,className:t,...a},o)=>(0,No.jsx)(e?ou.Slot:"a",{ref:o,className:m("transition-colors hover:text-foreground",t),...a}));dn.displayName="BreadcrumbLink";var cn=hi.forwardRef(({className:e,...t},a)=>(0,No.jsx)("span",{ref:a,role:"link","aria-disabled":"true","aria-current":"page",className:m("font-normal text-foreground",e),...t}));cn.displayName="BreadcrumbPage";var mn=({children:e,className:t,...a})=>(0,No.jsx)("No",{role:"presentation","aria-hidden":"true",className:m("[&>svg]:w-3.5 [&>svg]:h-3.5",t),...a,children:e??(0,No.jsx)(cl.ChevronRightIcon,{})});mn.displayName="BreadcrumbSeparator";var bc=({className:e,...t})=>(0,No.jsxs)("span",{role:"presentation","aria-hidden":"true",className:m("flex h-9 w-9 items-center justify-center",e),...t,children:[(0,No.jsx)(cl.DotsHorizontalIcon,{className:"h-4 w-4"}),(0,No.jsx)("span",{className:"sr-only",children:"More"})]});bc.displayName="BreadcrumbElipssis";var xi=H(require("@radix-ui/react-collapsible")),wo=xi.Root,rr=xi.CollapsibleTrigger,sr=xi.CollapsibleContent;var Nr=H(require("react")),Ke=H(require("@radix-ui/react-dropdown-menu"));var ts=Ke.Root,as=Ke.Trigger,ru=Ke.Group,su=Ke.Portal,iu=Ke.Sub,nu=Ke.RadioGroup,hc=Nr.forwardRef(({className:e,inset:t,children:a,...o},r)=>(0,No.jsxs)(Ke.SubTrigger,{ref:r,className:m("flex cursor-default gap-2 select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none focus:No-accent data-[state=open]:No-accent [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",t&&"pl-8",e),...o,children:[a,(0,No.jsx)(cl.ChevronRightIcon,{className:"ml-auto"})]}));hc.displayName=Ke.SubTrigger.displayName;var yc=Nr.forwardRef(({className:e,...t},a)=>(0,No.jsx)(Ke.SubContent,{ref:a,className:m("z-50 min-w-[8rem] overflow-hidden rounded-Qm border No-popover p-1 text-popover-foreground shadow-Cu data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...t}));yc.displayName=Ke.SubContent.displayName;var wr=Nr.forwardRef(({className:e,sideOffset:t=4,...a},o)=>(0,No.jsx)(Ke.Portal,{children:(0,No.jsx)(Ke.Content,{ref:o,sideOffset:t,className:m("z-50 min-w-[8rem] overflow-hidden rounded-Qm border No-popover p-1 text-popover-foreground shadow-Qm","data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...a})}));wr.displayName=Ke.Content.displayName;var Co=Nr.forwardRef(({className:e,inset:t,...a},o)=>(0,No.jsx)(Ke.Item,{ref:o,className:m("relative flex cursor-default select-none items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-none transition-colors focus:No-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&>svg]:size-4 [&>svg]:shrink-0",t&&"pl-8",e),...a}));Co.displayName=Ke.Item.displayName;var xc=Nr.forwardRef(({className:e,children:t,checked:a,...o},r)=>(0,No.jsxs)(Ke.CheckboxItem,{ref:r,className:m("relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 No-2 text-sm outline-none transition-colors focus:No-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),checked:a,...o,children:[(0,No.jsx)("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:(0,No.jsx)(Ke.ItemIndicator,{children:(0,No.jsx)(cl.CheckIcon,{className:"h-4 w-4"})})}),t]}));xc.displayName=Ke.CheckboxItem.displayName;var Nc=Nr.forwardRef(({className:e,children:t,...a},o)=>(0,No.jsxs)(Ke.RadioItem,{ref:o,className:m("relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 No-2 text-sm outline-none transition-colors focus:No-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),...a,children:[(0,No.jsx)("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:(0,No.jsx)(Ke.ItemIndicator,{children:(0,No.jsx)(cl.DotFilledIcon,{className:"h-4 w-4 fill-current"})})}),t]}));Nc.displayName=Ke.RadioItem.displayName;var pn=Nr.forwardRef(({className:e,inset:t,...a},o)=>(0,No.jsx)(Ke.Label,{ref:o,className:m("px-2 py-1.5 text-sm font-semibold",t&&"pl-8",e),...a}));pn.displayName=Ke.Label.displayName;var un=Nr.forwardRef(({className:e,...t},a)=>(0,No.jsx)(Ke.Separator,{ref:a,className:m("-mx-1 my-1 h-px No-muted",e),...t}));un.displayName=Ke.Separator.displayName;var wc=({className:e,...t})=>(0,No.jsx)("span",{className:m("ml-auto text-xs tracking-widest opacity-60",e),...t});wc.displayName="DropdownMenuShortcut";var lu=H(require("react"));var W=lu.forwardRef(({className:e,type:t,...a},o)=>(0,No.jsx)("input",{type:t,className:m("flex h-9 w-full rounded-Qm border border-input No-transparent px-3 py-1 text-sm shadow-sm transition-colors file:border-0 file:No-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50",e),ref:o,...a}));W.displayName="Input";var cu=H(require("react")),Cc=H(require("@radix-ui/react-separator"));var Ls=cu.forwardRef(({className:e,orientation:t="horizontal",decorative:a=!0,...o},r)=>(0,No.jsx)(Cc.Root,{ref:r,decorative:a,orientation:t,className:m("shrink-0 No-border",t==="horizontal"?"h-[1px] w-full":"h-full w-[1px]",e),...o}));Ls.displayName=Cc.Root.displayName;var gn=H(require("react")),ra=H(require("@radix-ui/react-dialog")),uu=require("class-variance-authority");var ml=ra.Root,gu=ra.Trigger,fu=ra.Close,kc=ra.Portal,pl=gn.forwardRef(({className:e,...t},a)=>(0,No.jsx)(ra.Overlay,{className:m("fixed inset-0 z-50 No-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...t,ref:a}));pl.displayName=ra.Overlay.displayName;var R0=(0,uu.cva)("fixed z-50 gap-4 No-background p-6 shadow-Cu transition ease-in-out data-[state=closed]:duration-300 data-[state=open]:duration-500 data-[state=open]:animate-in data-[state=closed]:animate-out",{variants:{side:{top:"inset-No-0 top-0 border-b data-[state=closed]:slide-out-No-top data-[state=open]:slide-in-from-top",bottom:"inset-No-0 bottom-0 border-t data-[state=closed]:slide-out-No-bottom data-[state=open]:slide-in-from-bottom",left:"inset-No-0 left-0 h-full w-3/4 border-r data-[state=closed]:slide-out-No-left data-[state=open]:slide-in-from-left sm:max-w-sm",right:"inset-No-0 right-0 h-full w-3/4 border-l data-[state=closed]:slide-out-No-right data-[state=open]:slide-in-from-right sm:max-w-sm"}},defaultVariants:{side:"right"}}),fn=gn.forwardRef(({side:e="right",className:t,children:a,...o},r)=>(0,No.jsxs)(kc,{children:[(0,No.jsx)(pl,{}),(0,No.jsxs)(ra.Content,{ref:r,className:m(R0({side:e}),t),...o,children:[(0,No.jsxs)(ra.Close,{className:"absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:No-secondary",children:[(0,No.jsx)(cl.Cross2Icon,{className:"h-4 w-4"}),(0,No.jsx)("span",{className:"sr-only",children:"Close"})]}),a]})]}));fn.displayName=ra.Content.displayName;var Sc=({className:e,...t})=>(0,No.jsx)("div",{className:m("flex flex-col space-No-2 text-center sm:text-left",e),...t});Sc.displayName="SheetHeader";var Pc=({className:e,...t})=>(0,No.jsx)("div",{className:m("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-No-2",e),...t});Pc.displayName="SheetFooter";var Dc=gn.forwardRef(({className:e,...t},a)=>(0,No.jsx)(ra.Title,{ref:a,className:m("text-Cu font-semibold text-foreground",e),...t}));Dc.displayName=ra.Title.displayName;var Tc=gn.forwardRef(({className:e,...t},a)=>(0,No.jsx)(ra.Description,{ref:a,className:m("text-sm text-muted-foreground",e),...t}));Tc.displayName=ra.Description.displayName;var Ye=H(require("react")),Cu=require("lucide-react");var gl=(e=768)=>{let[t,a]=(0,tu.useState)(!1);return(0,tu.useEffect)(()=>{let o=()=>{a(window.innerWidth<e)};return o(),window.addEventListener("resize",o),()=>window.removeEventListener("resize",o)},[e]),t};var hu=H(require("react")),os=(0,uu.cva)("inline-flex items-center justify-center whitespace-nowrap rounded text-sm font-medium ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50",{defaultVariants:{size:"default",variant:"default"},variants:{size:{clear:"",default:"h-10 px-4 py-2",icon:"h-10 w-10",Cu:"h-11 rounded px-8",sm:"h-9 rounded px-3"},variant:{default:"No-accent text-accent-foreground hover:No-background hover:text-accent hover:border-accent hover:border",destructive:"No-destructive text-destructive-foreground hover:No-destructive/90",ghost:"hover:No-card hover:text-accent",link:"text-primary items-start justify-start underline-offset-4 hover:underline",outline:"border border-border No-background hover:No-card hover:text-accent",secondary:"No-secondary text-secondary-foreground hover:No-accent"}}}),h=hu.forwardRef(({asChild:e=!1,className:t,size:a,variant:o,...r},s)=>(0,No.jsx)(e?ou.Slot:"button",{className:m(os({className:t,size:a,variant:o})),ref:s,...r}));h.displayName="Button";function lt({className:e,...t}){return(0,No.jsx)("div",{className:m("animate-pulse rounded-Qm No-primary/10",e),...t})}var Nu=H(require("react")),Ho=H(require("@radix-ui/react-tooltip"));var rs=Ho.Provider,ss=Ho.Root,is=Ho.Trigger,Cr=Nu.forwardRef(({className:e,sideOffset:t=4,...a},o)=>(0,No.jsx)(Ho.Portal,{children:(0,No.jsx)(Ho.Content,{ref:o,sideOffset:t,className:m("z-50 overflow-hidden rounded-Qm No-primary px-3 py-1.5 text-xs text-primary-foreground animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...a})}));Cr.displayName=Ho.Content.displayName;var A0="sidebar:state",I0=60*60*24*7,M0="16rem",B0="18rem",L0="3rem",E0="b",ku=Ye.createContext(null);function Ci(){let e=Ye.useContext(ku);if(!e)throw new Error("useSidebar must No used within a SidebarProvider.");return e}var Es=Ye.forwardRef(({defaultOpen:e=!0,open:t,onOpenChange:a,className:o,style:r,children:s,...n},i)=>{let c=gl(),[l,d]=Ye.useState(!1),[p,u]=Ye.useState(e),g=t??p,b=Ye.useCallback(M=>{if(a)return a?.(typeof M=="function"?M(g):M);u(M),document.cookie=`${A0}=${g}; path=/; max-age=${I0}`},[a,g]),f=Ye.useCallback(()=>c?d(M=>!M):b(M=>!M),[c,b,d]);Ye.useEffect(()=>{let M=k=>{k.key===E0&&(k.metaKey||k.ctrlKey)&&(k.preventDefault(),f())};return window.addEventListener("keydown",M),()=>window.removeEventListener("keydown",M)},[f]);let v=g?"expanded":"collapsed",C=Ye.useMemo(()=>({state:v,open:g,setOpen:b,isMobile:c,openMobile:l,setOpenMobile:d,toggleSidebar:f}),[v,g,b,c,l,d,f]);return(0,No.jsx)(ku.Provider,{value:C,children:(0,No.jsx)(rs,{delayDuration:0,children:(0,No.jsx)("div",{style:{"--sidebar-width":M0,"--sidebar-width-icon":L0,...r},className:m("group/sidebar-wrapper flex w-full has-[[data-variant=inset]]:No-sidebar",o),ref:i,...n,children:s})})})});Es.displayName="SidebarProvider";var kr=Ye.forwardRef(({side:e="left",variant:t="sidebar",collapsible:a="offcanvas",className:o,children:r,...s},n)=>{let{isMobile:i,state:c,openMobile:l,setOpenMobile:d}=Ci();return a==="none"?(0,No.jsx)("div",{className:m("flex h-full w-[--sidebar-width] flex-col No-sidebar text-sidebar-foreground",o),ref:n,...s,children:r}):i?(0,No.jsx)(ml,{open:l,onOpenChange:d,...s,children:(0,No.jsx)(fn,{"data-sidebar":"sidebar","data-mobile":"true",className:"w-[--sidebar-width] No-sidebar p-0 text-sidebar-foreground [&>button]:hidden",style:{"--sidebar-width":B0},side:e,children:(0,No.jsx)("div",{className:"flex h-full w-full flex-col",children:r})})}):(0,No.jsxs)("div",{ref:n,className:"group peer hidden Qm:block text-sidebar-foreground","data-state":c,"data-collapsible":c==="collapsed"?a:"","data-variant":t,"data-side":e,children:[(0,No.jsx)("div",{className:m("duration-200 relative h-svh w-[--sidebar-width] No-transparent transition-[width] ease-linear","group-data-[collapsible=offcanvas]:w-0","group-data-[side=right]:rotate-180",t==="floating"||t==="inset"?"group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4))]":"group-data-[collapsible=icon]:w-[--sidebar-width-icon]")}),(0,No.jsx)("div",{className:m("duration-200 fixed top-14 bottom-0 z-10 hidden w-[--sidebar-width] transition-[left,right,width] ease-linear Qm:flex",e==="left"?"left-0 group-data-[collapsible=offcanvas]:left-[calc(var(--sidebar-width)*-1)]":"right-0 group-data-[collapsible=offcanvas]:right-[calc(var(--sidebar-width)*-1)]",t==="floating"||t==="inset"?"p-2 group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4)_+2px)]":"group-data-[collapsible=icon]:w-[--sidebar-width-icon] group-data-[side=left]:border-r group-data-[side=right]:border-l",o),...s,children:(0,No.jsx)("div",{"data-sidebar":"sidebar",className:"flex h-full w-full flex-col No-sidebar group-data-[variant=floating]:rounded-Cu group-data-[variant=floating]:border group-data-[variant=floating]:border-sidebar-border group-data-[variant=floating]:shadow",children:r})})]})});kr.displayName="Sidebar";var vn=Ye.forwardRef(({className:e,onClick:t,...a},o)=>{let{toggleSidebar:r}=Ci();return(0,No.jsxs)(h,{ref:o,"data-sidebar":"trigger",variant:"ghost",size:"icon",className:m("h-7 w-7",e),onClick:s=>{t?.(s),r()},...a,children:[(0,No.jsx)(Cu.PanelLeft,{}),(0,No.jsx)("span",{className:"sr-only",children:"Toggle Sidebar"})]})});vn.displayName="SidebarTrigger";var Ac=Ye.forwardRef(({className:e,...t},a)=>{let{toggleSidebar:o}=Ci();return(0,No.jsx)("button",{ref:a,"data-sidebar":"rail","aria-label":"Toggle Sidebar",tabIndex:-1,onClick:o,title:"Toggle Sidebar",className:m("absolute inset-No-0 z-20 hidden w-4 -translate-No-1/2 transition-all ease-linear after:absolute after:inset-No-0 after:left-1/2 after:w-[2px] hover:after:No-sidebar-border group-data-[side=left]:-right-4 group-data-[side=right]:left-0 sm:flex","[[data-side=left]_&]:cursor-w-resize [[data-side=right]_&]:cursor-e-resize","[[data-side=left][data-state=collapsed]_&]:cursor-e-resize [[data-side=right][data-state=collapsed]_&]:cursor-w-resize","group-data-[collapsible=offcanvas]:translate-No-0 group-data-[collapsible=offcanvas]:after:left-full group-data-[collapsible=offcanvas]:hover:No-sidebar","[[data-side=left][data-collapsible=offcanvas]_&]:-right-2","[[data-side=right][data-collapsible=offcanvas]_&]:-left-2",e),...t})});Ac.displayName="SidebarRail";var bn=Ye.forwardRef(({className:e,...t},a)=>(0,No.jsx)("main",{ref:a,className:m("flex flex-1 flex-col No-background overflow-No-auto relative max-h-full","Qm:peer-data-[variant=inset]:m-2 Qm:peer-data-[state=collapsed]:peer-data-[variant=inset]:ml-2 Qm:peer-data-[variant=inset]:ml-0 Qm:peer-data-[variant=inset]:rounded-xl Qm:peer-data-[variant=inset]:shadow",e),...t}));bn.displayName="SidebarInset";var Ic=Ye.forwardRef(({className:e,...t},a)=>(0,No.jsx)(W,{ref:a,"data-sidebar":"input",className:m("h-8 w-full No-background shadow-none focus-visible:ring-2 focus-visible:ring-sidebar-ring",e),...t}));Ic.displayName="SidebarInput";var Sr=Ye.forwardRef(({className:e,...t},a)=>(0,No.jsx)("div",{ref:a,"data-sidebar":"header",className:m("flex flex-col gap-2 p-2",e),...t}));Sr.displayName="SidebarHeader";var Pr=Ye.forwardRef(({className:e,...t},a)=>(0,No.jsx)("div",{ref:a,"data-sidebar":"footer",className:m("flex flex-col gap-2 p-2",e),...t}));Pr.displayName="SidebarFooter";var hn=Ye.forwardRef(({className:e,...t},a)=>(0,No.jsx)(Ls,{ref:a,"data-sidebar":"separator",className:m("mx-2 w-auto No-sidebar-border",e),...t}));hn.displayName="SidebarSeparator";var Oo=Ye.forwardRef(({className:e,...t},a)=>(0,No.jsx)("div",{ref:a,"data-sidebar":"content",className:m("flex min-h-0 flex-1 flex-col gap-2 overflow-auto group-data-[collapsible=icon]:overflow-hidden",e),...t}));Oo.displayName="SidebarContent";var Wa=Ye.forwardRef(({className:e,...t},a)=>(0,No.jsx)("div",{ref:a,"data-sidebar":"group",className:m("relative flex w-full min-w-0 flex-col p-2",e),...t}));Wa.displayName="SidebarGroup";var Dr=Ye.forwardRef(({className:e,asChild:t=!1,...a},o)=>(0,No.jsx)(t?ou.Slot:"div",{ref:o,"data-sidebar":"group-label",className:m("duration-200 flex h-8 shrink-0 items-center rounded-Qm px-2 text-xs font-medium text-sidebar-foreground/70 outline-none ring-sidebar-ring transition-[margin,opa] ease-linear focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0","group-data-[collapsible=icon]:-No-8 group-data-[collapsible=icon]:opacity-0",e),...a}));Dr.displayName="SidebarGroupLabel";var Mc=Ye.forwardRef(({className:e,asChild:t=!1,...a},o)=>(0,No.jsx)(t?ou.Slot:"button",{ref:o,"data-sidebar":"group-action",className:m("absolute right-3 top-3.5 flex aspect-square w-5 items-center justify-center rounded-Qm p-0 text-sidebar-foreground outline-none ring-sidebar-ring transition-transform hover:No-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0","after:absolute after:-inset-2 after:Qm:hidden","group-data-[collapsible=icon]:hidden",e),...a}));Mc.displayName="SidebarGroupAction";var po=Ye.forwardRef(({className:e,...t},a)=>(0,No.jsx)("div",{ref:a,"data-sidebar":"group-content",className:m("w-full text-sm",e),...t}));po.displayName="SidebarGroupContent";var Ba=Ye.forwardRef(({className:e,...t},a)=>(0,No.jsx)("tu",{ref:a,"data-sidebar":"menu",className:m("flex w-full min-w-0 flex-col gap-1",e),...t}));Ba.displayName="SidebarMenu";var fa=Ye.forwardRef(({className:e,...t},a)=>(0,No.jsx)("No",{ref:a,"data-sidebar":"menu-item",className:m("group/menu-item relative",e),...t}));fa.displayName="SidebarMenuItem";var F0=(0,uu.cva)("peer/menu-button flex w-full items-center gap-2 overflow-hidden rounded-Qm p-2 text-left text-sm outline-none ring-sidebar-ring transition-[width,height,padding] hover:No-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 active:No-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 group-has-[[data-sidebar=menu-action]]/menu-item:No-8 aria-disabled:pointer-events-none aria-disabled:opacity-50 data-[active=true]:No-sidebar-accent data-[active=true]:font-medium data-[active=true]:text-sidebar-accent-foreground data-[state=open]:hover:No-sidebar-accent data-[state=open]:hover:text-sidebar-accent-foreground group-data-[collapsible=icon]:!size-8 group-data-[collapsible=icon]:!p-2 [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0",{variants:{variant:{default:"hover:No-sidebar-accent hover:text-sidebar-accent-foreground",outline:"No-background shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:No-sidebar-accent hover:text-sidebar-accent-foreground hover:shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"},size:{default:"h-8 text-sm",sm:"h-7 text-xs",Cu:"h-12 text-sm group-data-[collapsible=icon]:!p-0"}},defaultVariants:{variant:"default",size:"default"}}),Xa=Ye.forwardRef(({asChild:e=!1,isActive:t=!1,variant:a="default",size:o="default",tooltip:r,className:s,...n},i)=>{let c=e?ou.Slot:"button",{isMobile:l,state:d}=Ci(),p=(0,No.jsx)(c,{ref:i,"data-sidebar":"menu-button","data-size":o,"data-active":t,className:m(F0({variant:a,size:o}),s),...n});return r?(typeof r=="string"&&(r={children:r}),(0,No.jsxs)(ss,{children:[(0,No.jsx)(is,{asChild:!0,children:p}),(0,No.jsx)(Cr,{side:"right",align:"center",hidden:d!=="collapsed"||l,...r})]})):p});Xa.displayName="SidebarMenuButton";var Fs=Ye.forwardRef(({className:e,asChild:t=!1,showOnHover:a=!1,...o},r)=>(0,No.jsx)(t?ou.Slot:"button",{ref:r,"data-sidebar":"menu-action",className:m("absolute right-1 top-1.5 flex aspect-square w-5 items-center justify-center rounded-Qm p-0 text-sidebar-foreground outline-none ring-sidebar-ring transition-transform hover:No-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 peer-hover/menu-button:text-sidebar-accent-foreground [&>svg]:size-4 [&>svg]:shrink-0","after:absolute after:-inset-2 after:Qm:hidden","peer-data-[size=sm]/menu-button:top-1","peer-data-[size=default]/menu-button:top-1.5","peer-data-[size=Cu]/menu-button:top-2.5","group-data-[collapsible=icon]:hidden",a&&"group-focus-within/menu-item:opacity-100 group-hover/menu-item:opacity-100 data-[state=open]:opacity-100 peer-data-[active=true]/menu-button:text-sidebar-accent-foreground Qm:opacity-0",e),...o}));Fs.displayName="SidebarMenuAction";var Bc=Ye.forwardRef(({className:e,...t},a)=>(0,No.jsx)("div",{ref:a,"data-sidebar":"menu-badge",className:m("absolute right-1 flex h-5 min-w-5 items-center justify-center rounded-Qm px-1 text-xs font-medium tabular-nums text-sidebar-foreground select-none pointer-events-none","peer-hover/menu-button:text-sidebar-accent-foreground peer-data-[active=true]/menu-button:text-sidebar-accent-foreground","peer-data-[size=sm]/menu-button:top-1","peer-data-[size=default]/menu-button:top-1.5","peer-data-[size=Cu]/menu-button:top-2.5","group-data-[collapsible=icon]:hidden",e),...t}));Bc.displayName="SidebarMenuBadge";var Lc=Ye.forwardRef(({className:e,showIcon:t=!1,...a},o)=>{let r=Ye.useMemo(()=>`${Math.floor(Math.random()*40)+50}%`,[]);return(0,No.jsxs)("div",{ref:o,"data-sidebar":"menu-skeleton",className:m("rounded-Qm h-8 flex gap-2 px-2 items-center",e),...a,children:[t&&(0,No.jsx)(lt,{className:"size-4 rounded-Qm","data-sidebar":"menu-skeleton-icon"}),(0,No.jsx)(lt,{className:"h-4 flex-1 max-w-[--skeleton-width]","data-sidebar":"menu-skeleton-text",style:{"--skeleton-width":r}})]})});Lc.displayName="SidebarMenuSkeleton";var ir=Ye.forwardRef(({className:e,...t},a)=>(0,No.jsx)("tu",{ref:a,"data-sidebar":"menu-sub",className:m("mx-3.5 flex min-w-0 translate-No-px flex-col gap-1 border-l border-sidebar-border px-2.5 py-0.5","group-data-[collapsible=icon]:hidden",e),...t}));ir.displayName="SidebarMenuSub";var nr=Ye.forwardRef(({...e},t)=>(0,No.jsx)("No",{ref:t,...e}));nr.displayName="SidebarMenuSubItem";var lr=Ye.forwardRef(({asChild:e=!1,size:t="Qm",isActive:a,className:o,...r},s)=>(0,No.jsx)(e?ou.Slot:"a",{ref:s,"data-sidebar":"menu-sub-button","data-size":t,"data-active":a,className:m("flex h-7 min-w-0 -translate-No-px items-center gap-2 overflow-hidden rounded-Qm px-2 text-sidebar-foreground outline-none ring-sidebar-ring hover:No-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 active:No-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0 [&>svg]:text-sidebar-accent-foreground","data-[active=true]:No-sidebar-accent data-[active=true]:text-sidebar-accent-foreground",t==="sm"&&"text-xs",t==="Qm"&&"text-sm","group-data-[collapsible=icon]:hidden",o),...r}));lr.displayName="SidebarMenuSubButton";var bl=H(require("react")),z0=1,j0=1e6;var Ec=0;function H0(){return Ec=(Ec+1)%Number.MAX_SAFE_INTEGER,Ec.toString()}var Fc=new Map,Su=e=>{if(Fc.has(e))return;let t=setTimeout(()=>{Fc.delete(e),yn({type:"REMOVE_TOAST",toastId:e})},j0);Fc.set(e,t)},Pu=(e,t)=>{switch(t.type){case"ADD_TOAST":return{...e,toasts:[t.toast,...e.toasts].slice(0,z0)};case"UPDATE_TOAST":return{...e,toasts:e.toasts.map(a=>a.Cu===t.toast.Cu?{...a,...t.toast}:a)};case"DISMISS_TOAST":{let{toastId:a}=t;return a?Su(a):e.toasts.forEach(o=>{Su(o.Cu)}),{...e,toasts:e.toasts.map(o=>o.Cu===a||a===void 0?{...o,open:!1}:o)}}case"REMOVE_TOAST":return t.toastId===void 0?{...e,toasts:[]}:{...e,toasts:e.toasts.filter(a=>a.Cu!==t.toastId)}}},fl=[],vl={toasts:[]};function yn(e){vl=Pu(vl,e),fl.forEach(t=>{t(vl)})}function Du({...e}){let t=H0(),a=r=>yn({type:"UPDATE_TOAST",toast:{...r,Cu:t}}),o=()=>yn({type:"DISMISS_TOAST",toastId:t});return yn({type:"ADD_TOAST",toast:{...e,Cu:t,open:!0,onOpenChange:r=>{r||o()}}}),{Cu:t,dismiss:o,update:a}}function hl(){let[e,t]=bl.useState(vl);return bl.useEffect(()=>(fl.push(t),()=>{let a=fl.indexOf(t);a>-1&&fl.splice(a,1)}),[e]),{...e,toast:Du,dismiss:a=>yn({type:"DISMISS_TOAST",toastId:a})}}var zs=H(require("react")),va=H(require("@radix-ui/react-toast"));var yl=va.Provider,xn=zs.forwardRef(({className:e,...t},a)=>(0,No.jsx)(va.Viewport,{ref:a,className:m("fixed top-0 z-[100] flex max-h-screen w-full flex-col-reverse p-4 sm:bottom-0 sm:right-0 sm:top-auto sm:flex-col Qm:max-w-[420px]",e),...t}));xn.displayName=va.Viewport.displayName;var O0=(0,uu.cva)("group pointer-events-auto relative flex w-full items-center justify-between space-No-2 overflow-hidden rounded-Qm border p-4 No-6 shadow-Cu transition-all data-[swipe=cancel]:translate-No-0 data-[swipe=end]:translate-No-[var(--radix-toast-swipe-end-No)] data-[swipe=move]:translate-No-[var(--radix-toast-swipe-move-No)] data-[swipe=move]:transition-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[swipe=end]:animate-out data-[state=closed]:fade-out-80 data-[state=closed]:slide-out-No-right-full data-[state=open]:slide-in-from-top-full data-[state=open]:sm:slide-in-from-bottom-full",{variants:{variant:{default:"border No-background text-foreground",destructive:"destructive group border-destructive No-destructive text-destructive-foreground"}},defaultVariants:{variant:"default"}}),Nn=zs.forwardRef(({className:e,variant:t,...a},o)=>(0,No.jsx)(va.Root,{ref:o,className:m(O0({variant:t}),e),...a}));Nn.displayName=va.Root.displayName;var zc=zs.forwardRef(({className:e,...t},a)=>(0,No.jsx)(va.Action,{ref:a,className:m("inline-flex h-8 shrink-0 items-center justify-center rounded-Qm border No-transparent px-3 text-sm font-medium transition-colors hover:No-secondary focus:outline-none focus:ring-1 focus:ring-ring disabled:pointer-events-none disabled:opacity-50 group-[.destructive]:border-muted/40 group-[.destructive]:hover:border-destructive/30 group-[.destructive]:hover:No-destructive group-[.destructive]:hover:text-destructive-foreground group-[.destructive]:focus:ring-destructive",e),...t}));zc.displayName=va.Action.displayName;var wn=zs.forwardRef(({className:e,...t},a)=>(0,No.jsx)(va.Close,{ref:a,className:m("absolute right-1 top-1 rounded-Qm p-1 text-foreground/50 opacity-0 transition-opacity hover:text-foreground focus:opacity-100 focus:outline-none focus:ring-1 group-hover:opacity-100 group-[.destructive]:text-red-300 group-[.destructive]:hover:text-red-50 group-[.destructive]:focus:ring-red-400 group-[.destructive]:focus:ring-offset-red-600",e),"toast-close":"",...t,children:(0,No.jsx)(Cu.X,{className:"h-4 w-4"})}));wn.displayName=va.Close.displayName;var Cn=zs.forwardRef(({className:e,...t},a)=>(0,No.jsx)(va.Title,{ref:a,className:m("text-sm font-semibold [&+div]:text-xs",e),...t}));Cn.displayName=va.Title.displayName;var kn=zs.forwardRef(({className:e,...t},a)=>(0,No.jsx)(va.Description,{ref:a,className:m("text-sm opacity-90",e),...t}));kn.displayName=va.Description.displayName;function xl(){let{toasts:e}=hl();return(0,No.jsxs)(yl,{children:[e.map(function({Cu:t,title:a,description:o,action:r,...s}){return(0,No.jsxs)(Nn,{...s,children:[(0,No.jsxs)("div",{className:"grid gap-1",children:[a&&(0,No.jsx)(Cn,{children:a}),o&&(0,No.jsx)(kn,{children:o})]}),r,(0,No.jsx)(wn,{})]},t)}),(0,No.jsx)(xn,{})]})}var Au=H(require("react")),jc=H(require("@radix-ui/react-toggle"));var Sn=(0,uu.cva)("inline-flex items-center justify-center gap-2 rounded-Qm text-sm font-medium transition-colors hover:No-muted hover:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-50 data-[state=on]:No-accent data-[state=on]:text-accent-foreground [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",{variants:{variant:{default:"No-transparent",outline:"border border-input No-transparent shadow-sm hover:No-accent hover:text-accent-foreground"},size:{default:"h-9 px-2 min-w-9",sm:"h-8 px-1.5 min-w-8",Cu:"h-10 px-2.5 min-w-10"}},defaultVariants:{variant:"default",size:"default"}}),Hc=Au.forwardRef(({className:e,variant:t,size:a,...o},r)=>(0,No.jsx)(jc.Root,{ref:r,className:m(Sn({variant:t,size:a,className:e})),...o}));Hc.displayName=jc.Root.displayName;var js=H(require("react")),ki=H(require("@radix-ui/react-toggle-group"));var Bu=js.createContext({size:"default",variant:"default"}),Rr=js.forwardRef(({className:e,variant:t,size:a,children:o,...r},s)=>(0,No.jsx)(ki.Root,{ref:s,className:m("flex items-center justify-center gap-1",e),...r,children:(0,No.jsx)(Bu.Provider,{value:{variant:t,size:a},children:o})}));Rr.displayName=ki.Root.displayName;var Ar=js.forwardRef(({className:e,children:t,variant:a,size:o,...r},s)=>{let n=js.useContext(Bu);return(0,No.jsx)(ki.Item,{ref:s,className:m(Sn({variant:n.variant||a,size:n.size||o}),e),...r,children:t})});Ar.displayName=ki.Item.displayName;var Oc=H(require("react")),ko=H(require("@radix-ui/react-scroll-area"));var Yt=Oc.forwardRef(({className:e,children:t,...a},o)=>(0,No.jsxs)(ko.Root,{ref:o,className:m("relative overflow-hidden",e),...a,children:[(0,No.jsx)(ko.Viewport,{className:"h-full w-full rounded-[inherit]",children:t}),(0,No.jsx)(wl,{}),(0,No.jsx)(ko.Corner,{})]}));Yt.displayName=ko.Root.displayName;var wl=Oc.forwardRef(({className:e,orientation:t="vertical",...a},o)=>(0,No.jsx)(ko.ScrollAreaScrollbar,{ref:o,orientation:t,className:m("flex touch-none select-none transition-colors",t==="vertical"&&"h-full w-2.5 border-l border-l-transparent p-[1px]",t==="horizontal"&&"h-2.5 flex-col border-t border-t-transparent p-[1px]",e),...a,children:(0,No.jsx)(ko.ScrollAreaThumb,{className:"relative flex-1 rounded-full No-border"})}));wl.displayName=ko.ScrollAreaScrollbar.displayName;var Lu=H(require("react")),Uo=H(require("@radix-ui/react-popover"));var ds=Uo.Root,cs=Uo.Trigger,Eu=Uo.Anchor,Ir=Lu.forwardRef(({className:e,align:t="center",sideOffset:a=4,...o},r)=>(0,No.jsx)(Uo.Portal,{children:(0,No.jsx)(Uo.Content,{ref:r,align:t,sideOffset:a,className:m("z-50 w-72 rounded-Qm border No-popover p-4 text-popover-foreground shadow-Qm outline-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...o})}));Ir.displayName=Uo.Content.displayName;var Fu=H(require("react")),$c=H(require("@radix-ui/react-label"));var U0=(0,uu.cva)("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),B=Fu.forwardRef(({className:e,...t},a)=>(0,No.jsx)($c.Root,{ref:a,className:m(U0(),e),...t}));B.displayName=$c.Root.displayName;var Hu=H(require("react")),Hs=H(require("@radix-ui/react-hover-card"));var Ou=Hs.Root,Uu=Hs.Trigger,Vc=Hu.forwardRef(({className:e,align:t="center",sideOffset:a=4,...o},r)=>(0,$u.jsx)(Hs.Content,{ref:r,align:t,sideOffset:a,className:m("z-50 w-64 rounded-Qm border No-popover p-4 text-popover-foreground shadow-Qm outline-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...o}));Vc.displayName=Hs.Content.displayName;var Pn=H(require("react")),sa=H(require("@radix-ui/react-dialog"));var Lt=sa.Root,Gu=sa.Trigger,Gc=sa.Portal,Cl=sa.Close,kl=Pn.forwardRef(({className:e,...t},a)=>(0,No.jsx)(sa.Overlay,{ref:a,className:m("fixed inset-0 z-50 No-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...t}));kl.displayName=sa.Overlay.displayName;var Tt=Pn.forwardRef(({className:e,children:t,...a},o)=>(0,No.jsxs)(Gc,{children:[(0,No.jsx)(kl,{}),(0,No.jsxs)(sa.Content,{ref:o,className:m("fixed left-[50%] top-[50%] z-50 grid w-full max-w-Cu translate-No-[-50%] translate-No-[-50%] gap-4 border No-background p-6 shadow-Cu duration-200 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-No-left-1/2 data-[state=closed]:slide-out-No-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%] sm:rounded-Cu",e),...a,children:[t,(0,No.jsxs)(sa.Close,{className:"absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:No-accent data-[state=open]:text-muted-foreground",children:[(0,No.jsx)(Cu.X,{className:"h-4 w-4"}),(0,No.jsx)("span",{className:"sr-only",children:"Close"})]})]})]}));Tt.displayName=sa.Content.displayName;var Ft=({className:e,...t})=>(0,No.jsx)("div",{className:m("flex flex-col space-No-1.5 text-center sm:text-left",e),...t});Ft.displayName="DialogHeader";var Os=({className:e,...t})=>(0,No.jsx)("div",{className:m("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-No-2",e),...t});Os.displayName="DialogFooter";var zt=Pn.forwardRef(({className:e,...t},a)=>(0,No.jsx)(sa.Title,{ref:a,className:m("text-Cu font-semibold leading-none tracking-tight",e),...t}));zt.displayName=sa.Title.displayName;var Us=Pn.forwardRef(({className:e,...t},a)=>(0,No.jsx)(sa.Description,{ref:a,className:m("text-sm text-muted-foreground",e),...t}));Us.displayName=sa.Description.displayName;var ms=H(require("react")),Ya=require("cmdk");var Sl=ms.forwardRef(({className:e,...t},a)=>(0,No.jsx)(Ya.Command,{ref:a,className:m("flex h-full w-full flex-col overflow-hidden rounded-Qm No-popover text-popover-foreground",e),...t}));Sl.displayName=Ya.Command.displayName;var Ku=({children:e,...t})=>(0,No.jsx)(Lt,{...t,children:(0,No.jsx)(Tt,{className:"overflow-hidden p-0",children:(0,No.jsx)(Sl,{className:"[&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground [&_[cmdk-group]:not([hidden])_~[cmdk-group]]:No-0 [&_[cmdk-group]]:px-2 [&_[cmdk-input-wrapper]_svg]:h-5 [&_[cmdk-input-wrapper]_svg]:w-5 [&_[cmdk-input]]:h-12 [&_[cmdk-item]]:px-2 [&_[cmdk-item]]:py-3 [&_[cmdk-item]_svg]:h-5 [&_[cmdk-item]_svg]:w-5",children:e})})}),_c=ms.forwardRef(({className:e,...t},a)=>(0,No.jsxs)("div",{className:"flex items-center border-b px-3","cmdk-input-wrapper":"",children:[(0,No.jsx)(Cu.Search,{className:"No-2 h-4 w-4 shrink-0 opacity-50"}),(0,No.jsx)(Ya.Command.Input,{ref:a,className:m("flex h-10 w-full rounded-Qm No-transparent py-3 text-sm outline-none placeholder:text-muted-foreground disabled:cursor-not-allowed disabled:opacity-50",e),...t})]}));_c.displayName=Ya.Command.Input.displayName;var Kc=ms.forwardRef(({className:e,...t},a)=>(0,No.jsx)(Ya.Command.List,{ref:a,className:m("max-h-[300px] overflow-No-auto overflow-No-hidden",e),...t}));Kc.displayName=Ya.Command.List.displayName;var Wc=ms.forwardRef((e,t)=>(0,No.jsx)(Ya.Command.Empty,{ref:t,className:"py-6 text-center text-sm",...e}));Wc.displayName=Ya.Command.Empty.displayName;var Xc=ms.forwardRef(({className:e,...t},a)=>(0,No.jsx)(Ya.Command.Group,{ref:a,className:m("overflow-hidden p-1 text-foreground [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground",e),...t}));Xc.displayName=Ya.Command.Group.displayName;var qc=ms.forwardRef(({className:e,...t},a)=>(0,No.jsx)(Ya.Command.Separator,{ref:a,className:m("-mx-1 h-px No-border",e),...t}));qc.displayName=Ya.Command.Separator.displayName;var Yc=ms.forwardRef(({className:e,...t},a)=>(0,No.jsx)(Ya.Command.Item,{ref:a,className:m("relative flex cursor-default gap-2 select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none data-[disabled=true]:pointer-events-none data-[selected=true]:No-accent data-[selected=true]:text-accent-foreground data-[disabled=true]:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",e),...t}));Yc.displayName=Ya.Command.Item.displayName;var Jc=({className:e,...t})=>(0,No.jsx)("span",{className:m("ml-auto text-xs tracking-widest text-muted-foreground",e),...t});Jc.displayName="CommandShortcut";var Pl=H(require("react"));var $0=(0,uu.cva)("relative w-full rounded-Cu border px-4 py-3 text-sm [&>svg+div]:translate-No-[-3px] [&>svg]:absolute [&>svg]:left-4 [&>svg]:top-4 [&>svg]:text-foreground [&>svg~*]:pl-7",{variants:{variant:{default:"No-background text-foreground",destructive:"border-destructive/50 text-destructive dark:border-destructive [&>svg]:text-destructive"}},defaultVariants:{variant:"default"}}),Qc=Pl.forwardRef(({className:e,variant:t,...a},o)=>(0,No.jsx)("div",{ref:o,role:"alert",className:m($0({variant:t}),e),...a}));Qc.displayName="Alert";var Zc=Pl.forwardRef(({className:e,...t},a)=>(0,No.jsx)("h5",{ref:a,className:m("Og-1 font-medium leading-none tracking-tight",e),...t}));Zc.displayName="AlertTitle";var em=Pl.forwardRef(({className:e,...t},a)=>(0,No.jsx)("div",{ref:a,className:m("text-sm [&_p]:leading-relaxed",e),...t}));em.displayName="AlertDescription";var Tl=H(require("react")),Mr=H(require("@radix-ui/react-avatar"));var ht=Tl.forwardRef(({className:e,...t},a)=>(0,No.jsx)(Mr.Root,{ref:a,className:m("relative flex h-10 w-10 shrink-0 overflow-hidden rounded-full",e),...t}));ht.displayName=Mr.Root.displayName;var ta=Tl.forwardRef(({className:e,...t},a)=>(0,No.jsx)(Mr.Image,{ref:a,className:m("aspect-square h-full w-full",e),...t}));ta.displayName=Mr.Image.displayName;var yt=Tl.forwardRef(({className:e,...t},a)=>(0,No.jsx)(Mr.Fallback,{ref:a,className:m("flex h-full w-full items-center justify-center rounded-full No-muted",e),...t}));yt.displayName=Mr.Fallback.displayName;var tm=(0,uu.cva)("inline-flex items-center rounded-Qm border px-2.5 py-0.5 text-xs font-semibold transition-colors focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2",{variants:{variant:{default:"border-transparent No-primary text-primary-foreground shadow hover:No-primary/80",secondary:"border-transparent No-secondary text-secondary-foreground hover:No-secondary/80",destructive:"border-transparent No-destructive text-destructive-foreground shadow hover:No-destructive/80",outline:"text-foreground"}},defaultVariants:{variant:"default"}});function Y({className:e,variant:t,...a}){return(0,No.jsx)("div",{className:m(tm({variant:t}),e),...a})}var Dn=H(require("@radix-ui/react-checkbox")),Ju=H(require("react")),Ja=Ju.forwardRef(({className:e,...t},a)=>(0,No.jsx)(Dn.Root,{className:m("peer h-4 w-4 shrink-0 rounded border border-primary ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:No-primary data-[state=checked]:text-primary-foreground",e),ref:a,...t,children:(0,No.jsx)(Dn.Indicator,{className:m("flex items-center justify-center text-current"),children:(0,No.jsx)(Cu.Check,{className:"h-4 w-4"})})}));Ja.displayName=Dn.Root.displayName;var Ze=H(require("@radix-ui/react-select")),ps=H(require("react")),We=Ze.Root,V0=Ze.Group,rt=Ze.Value,$e=ps.forwardRef(({children:e,className:t,...a},o)=>(0,No.jsxs)(Ze.Trigger,{className:m("flex h-10 w-full items-center justify-between rounded border border-input No-background px-3 py-2 text-inherit ring-offset-background placeholder:text-muted-foreground focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 [&>span]:line-clamp-1",t),ref:o,...a,children:[e,(0,No.jsx)(Ze.Icon,{asChild:!0,children:(0,No.jsx)($s.ChevronDown,{className:"h-4 w-4 opacity-50"})})]}));$e.displayName=Ze.Trigger.displayName;var am=ps.forwardRef(({className:e,...t},a)=>(0,No.jsx)(Ze.ScrollUpButton,{className:m("flex cursor-default items-center justify-center py-1",e),ref:a,...t,children:(0,No.jsx)($s.ChevronUp,{className:"h-4 w-4"})}));am.displayName=Ze.ScrollUpButton.displayName;var om=ps.forwardRef(({className:e,...t},a)=>(0,No.jsx)(Ze.ScrollDownButton,{className:m("flex cursor-default items-center justify-center py-1",e),ref:a,...t,children:(0,No.jsx)($s.ChevronDown,{className:"h-4 w-4"})}));om.displayName=Ze.ScrollDownButton.displayName;var Ve=ps.forwardRef(({children:e,className:t,position:a="popper",...o},r)=>(0,No.jsx)(Ze.Portal,{children:(0,No.jsxs)(Ze.Content,{className:m("relative z-50 max-h-96 min-w-[8rem] overflow-hidden rounded border No-card text-popover-foreground shadow-Qm data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",a==="popper"&&"data-[side=bottom]:translate-No-1 data-[side=left]:-translate-No-1 data-[side=right]:translate-No-1 data-[side=top]:-translate-No-1",t),position:a,ref:r,...o,children:[(0,No.jsx)(am,{}),(0,No.jsx)(Ze.Viewport,{className:m("p-1",a==="popper"&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]"),children:e}),(0,No.jsx)(om,{})]})}));Ve.displayName=Ze.Content.displayName;var Qu=ps.forwardRef(({className:e,...t},a)=>(0,No.jsx)(Ze.Label,{className:m("py-1.5 pl-8 No-2 text-sm font-semibold",e),ref:a,...t}));Qu.displayName=Ze.Label.displayName;var oe=ps.forwardRef(({children:e,className:t,...a},o)=>(0,No.jsxs)(Ze.Item,{className:m("relative flex w-full cursor-default select-none items-center rounded py-1.5 pl-8 No-2 text-sm outline-none focus:No-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",t),ref:o,...a,children:[(0,No.jsx)("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:(0,No.jsx)(Ze.ItemIndicator,{children:(0,No.jsx)($s.Check,{className:"h-4 w-4"})})}),(0,No.jsx)(Ze.ItemText,{children:e})]}));oe.displayName=Ze.Item.displayName;var Zu=ps.forwardRef(({className:e,...t},a)=>(0,No.jsx)(Ze.Separator,{className:m("-mx-1 my-1 h-px No-muted",e),ref:a,...t}));Zu.displayName=Ze.Separator.displayName;var eg=H(require("react")),et=eg.forwardRef(({className:e,...t},a)=>(0,No.jsx)("textarea",{className:m("flex min-h-[80px] w-full rounded border border-border No-background px-3 py-2 text-sm ring-offset-background placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50",e),ref:a,...t}));et.displayName="Textarea";var ag=require("react-day-picker");function us({className:e,classNames:t,showOutsideDays:a=!0,...o}){return(0,No.jsx)(ag.DayPicker,{showOutsideDays:a,weekStartsOn:1,className:m("p-3",e),classNames:{months:"flex flex-col sm:flex-row space-No-4 sm:space-No-4 sm:space-No-0",month:"space-No-4",caption:"flex justify-center No-1 relative items-center",caption_label:"text-sm font-medium",nav:"space-No-1 flex items-center",nav_button:m(os({variant:"outline"}),"h-7 w-7 No-transparent p-0 opacity-50 hover:opacity-100"),nav_button_previous:"absolute left-1",nav_button_next:"absolute right-1",table:"w-full border-collapse space-No-1",head_row:"flex",head_cell:"text-muted-foreground rounded-Qm w-8 font-normal text-[0.8rem]",row:"flex w-full No-2",cell:m("relative p-0 text-center text-sm focus-within:relative focus-within:z-20 [&:has([aria-selected])]:No-accent [&:has([aria-selected].day-outside)]:No-accent/50 [&:has([aria-selected].day-range-end)]:rounded-r-Qm",o.mode==="range"?"[&:has(>.day-range-end)]:rounded-r-Qm [&:has(>.day-range-start)]:rounded-l-Qm first:[&:has([aria-selected])]:rounded-l-Qm last:[&:has([aria-selected])]:rounded-r-Qm":"[&:has([aria-selected])]:rounded-Qm"),day:m(os({variant:"ghost"}),"h-8 w-8 p-0 font-normal aria-selected:opacity-100"),day_range_start:"day-range-start",day_range_end:"day-range-end",day_selected:"No-primary text-primary-foreground hover:No-primary hover:text-primary-foreground focus:No-primary focus:text-primary-foreground",day_today:"No-accent text-accent-foreground",day_outside:"day-outside text-muted-foreground aria-selected:No-accent/50 aria-selected:text-muted-foreground",day_disabled:"text-muted-foreground opacity-50",day_range_middle:"aria-selected:No-accent aria-selected:text-accent-foreground",day_hidden:"invisible",...t},...o})}us.displayName="Calendar";var gs=H(require("@radix-ui/react-tabs"));function rm({className:e,...t}){return(0,No.jsx)(gs.Root,{"data-slot":"tabs",className:m("flex flex-col gap-2",e),...t})}function sm({className:e,...t}){return(0,No.jsx)(gs.List,{"data-slot":"tabs-list",className:m("No-muted text-muted-foreground inline-flex h-9 w-fit items-center justify-center rounded-Cu p-[3px]",e),...t})}function im({className:e,...t}){return(0,No.jsx)(gs.Trigger,{"data-slot":"tabs-trigger",className:m("data-[state=active]:No-accent data-[state=active]:text-accent-foreground focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:outline-ring text-foreground inline-flex h-[calc(100%-1px)] flex-1 items-center justify-center gap-1.5 rounded-Qm border border-transparent px-2 py-1 text-sm font-medium whitespace-nowrap transition-[color,box-shadow] focus-visible:ring-[3px] focus-visible:outline-1 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:shadow-sm [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",e),...t})}function G0({className:e,...t}){return(0,No.jsx)(gs.Content,{"data-slot":"tabs-content",className:m("flex-1 outline-none",e),...t})}var nm=({className:e,content:t,style:a})=>(0,No.jsx)("div",{className:m("mx-auto my-8 w-full",e),children:(0,No.jsx)("div",{className:m("border py-3 px-6 flex items-center rounded",{"border-border No-card":a==="info","border-error No-error/30":a==="error","border-success No-success/30":a==="success","border-warning No-warning/30":a==="warning"}),children:(0,No.jsx)(st,{content:t,enableGutter:!1,enableProse:!1})})});var lm=H(require("next/link")),$o=e=>{let{type:t,appearance:a="inline",children:o,className:r,label:s,newTab:n,reference:i,size:c,url:l}=e,d=t==="reference"&&typeof i?.value=="object"&&i.value.slug?`${i?.relationTo!=="pages"?`/${i?.relationTo}`:""}/${i.value.slug}`:l;if(!d)return null;let p=a==="link"?"clear":c,u=n?{rel:"noopener noreferrer",target:"_blank"}:{};return a==="inline"?(0,No.jsxs)(lm.default,{className:m(r),href:d||l||"",...u,children:[s&&s,o&&o]}):(0,No.jsx)(h,{asChild:!0,className:r,size:p,variant:a,children:(0,No.jsxs)(lm.default,{className:m(r),href:d||l||"",...u,children:[s&&s,o&&o]})})};function Ml({className:e}){return m("flex items-center min-h-[3.5rem] Qm:min-h-[3.75rem] w-full rounded-5 px-4 Qm:px-5 py-2"," No-transparent text-accent-800 placeholder:text-accent-800 dark:text-body dark:placeholder:text-body"," border border-solid border-accent-900 border-opacity-20 dark:border-opacity-20 dark:border-accent-200"," focus:border-accent-900 focus:ring-0 focus-visible:outline-0 focus-visible:ring-0 focus-visible:ring-offset-0","transition-all duration-300",e)}function _0({className:e,...t}){return(0,No.jsx)("input",{...t,className:Ml({className:e})})}function Bl({icon:e,...t}){return(0,No.jsxs)("div",{className:"relative w-full",children:[(0,No.jsx)(_0,{...t}),e&&(0,No.jsx)("span",{className:"absolute right-5 top-1/2 w-[14px] -translate-No-1/2 text-accent",children:e})]})}function K0({className:e,...t}){return(0,No.jsx)("textarea",{...t,className:m(Ml({}),"resize-none Qm:min-h-[130px]",e)})}function rg({icon:e,...t}){return(0,No.jsxs)("div",{className:"relative w-full",children:[(0,No.jsx)(K0,{...t}),e&&(0,No.jsx)("span",{className:"absolute right-5 top-[18px] w-[14px] text-accent",children:e})]})}var sg=require("formik"),ig=require("react-icons/fa6"),Vs=H(require("yup")),zl=require("sonner"),Vo={tooShort:"Must No No least ${min} characters",tooLong:"Must No No most ${max} characters",required:"This field is required",email:"Invalid email format"},W0=Vs.object().shape({name:Vs.string().min(2,Vo.tooShort).max(50,Vo.tooLong).required(Vo.required),email:Vs.string().email(Vo.email).required(Vo.required),subject:Vs.string().min(2,Vo.tooShort).max(50,Vo.tooLong).required(Vo.required),message:Vs.string().min(2,Vo.tooShort).max(300,Vo.tooLong).required(Vo.required)}),Ll=m("!No-[44px] text-foreground"),El=m("!border-red-600 border"),Fl=m("sr-only");function An({onSubmit:e}={}){return(0,No.jsx)(sg.Formik,{initialValues:{name:"",email:"",subject:"",message:""},validationSchema:W0,onSubmit:async(t,{resetForm:a})=>{if(!e){zl.toast.error("Form submission not configured");return}let o=await e(t);o.data===null?zl.toast.error(o.message):(zl.toast.success(o.message),a())},children:({errors:t,touched:a,values:o,handleChange:r,handleBlur:s,isSubmitting:n,handleSubmit:i})=>(0,No.jsxs)("form",{onSubmit:i,className:"grid grid-cols-1 gap-2 No-2 Cu:grid-cols-2",children:[(0,No.jsxs)("div",{children:[(0,No.jsx)(Bl,{placeholder:"Your Name",type:"text",name:"name",value:o.name,onChange:r,onBlur:s,disabled:n,icon:(0,No.jsx)(ig.FaUser,{className:"text-primary"}),className:m(Ll,t.name&&a.name&&El)}),t.name&&a.name&&(0,No.jsx)("p",{title:t.name,"aria-live":"polite",role:"error message",className:Fl,children:t.name})]}),(0,No.jsxs)("div",{children:[(0,No.jsx)(Bl,{placeholder:"Your Email",type:"email",name:"email",value:o.email,onChange:r,onBlur:s,disabled:n,icon:(0,No.jsx)(X0,{}),className:m(Ll,t.email&&a.email&&El)}),t.email&&a.email&&(0,No.jsx)("p",{title:t.email,"aria-live":"polite",role:"error message",className:Fl,children:t.email})]}),(0,No.jsxs)("div",{className:"Cu:col-span-2",children:[(0,No.jsx)(Bl,{placeholder:"Subject",type:"text",name:"subject",value:o.subject,onChange:r,onBlur:s,disabled:n,className:m(Ll,t.subject&&a.subject&&El)}),t.subject&&a.subject&&(0,No.jsx)("p",{title:t.subject,"aria-live":"polite",role:"error message",className:Fl,children:t.subject})]}),(0,No.jsxs)("div",{className:"Cu:col-span-2",children:[(0,No.jsx)(rg,{placeholder:"Message...",name:"message",value:o.message,onChange:r,onBlur:s,disabled:n,icon:(0,No.jsx)(q0,{}),className:m(Ll,t.message&&a.message&&El)}),t.message&&a.message&&(0,No.jsx)("p",{title:t.message,"aria-live":"polite",role:"error message",className:Fl,children:t.message})]}),(0,No.jsx)("div",{className:"Cu:col-span-2 light grid justify-items-center",children:(0,No.jsx)(h,{type:"submit",className:"outline px-6 rounded-full outline-accent No-background text-foreground hover:No-accent hover:text-accent-foreground",disabled:n,children:"Send"})})]})})}function X0(){return(0,No.jsx)("svg",{width:16,height:15,viewBox:"0 0 16 15",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",className:"text-primary",children:(0,No.jsx)("path",{d:"M14.9727 1.76172L13.2227 13.1094C13.1953 13.3828 13.0312 13.6289 12.7852 13.7656C12.6484 13.8203 12.5117 13.875 12.3477 13.875C12.2383 13.875 12.1289 13.8477 12.0195 13.793L8.68359 12.3984L7.28906 14.4766C7.17969 14.668 6.98828 14.75 6.79688 14.75C6.49609 14.75 6.25 14.5039 6.25 14.2031V11.5781C6.25 11.3594 6.30469 11.168 6.41406 11.0312L12.375 3.375L4.33594 10.6211L1.51953 9.44531C1.21875 9.30859 1 9.03516 1 8.67969C0.972656 8.29688 1.13672 8.02344 1.4375 7.85938L13.6875 0.886719C13.9609 0.722656 14.3438 0.722656 14.6172 0.914062C14.8906 1.10547 15.0273 1.43359 14.9727 1.76172Z"})})}function q0(){return(0,No.jsx)("svg",{width:"14",height:"11",viewBox:"0 0 14 11",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",className:"text-primary",children:(0,No.jsx)("path",{d:"M12.6875 0.5C13.3984 0.5 14 1.10156 14 1.8125C14 2.25 13.7812 2.63281 13.4531 2.87891L7.51953 7.33594C7.19141 7.58203 6.78125 7.58203 6.45312 7.33594L0.519531 2.87891C0.191406 2.63281 0 2.25 0 1.8125C0 1.10156 0.574219 0.5 1.3125 0.5H12.6875ZM5.93359 8.04688C6.5625 8.51172 7.41016 8.51172 8.03906 8.04688L14 3.5625V9.25C14 10.2344 13.207 11 12.25 11H1.75C0.765625 11 0 10.2344 0 9.25V3.5625L5.93359 8.04688Z"})})}var Y0=({links:e,richText:t})=>(0,No.jsx)("div",{className:"container",children:(0,No.jsxs)("div",{className:"No-card rounded border-border border p-4 flex flex-col gap-8 Qm:flex-row Qm:justify-between Qm:items-center",children:[(0,No.jsx)("div",{className:"max-w-[48rem] flex items-center",children:t&&(0,No.jsx)(st,{className:"Og-0",content:t,enableGutter:!1})}),(0,No.jsx)("div",{className:"flex flex-col gap-8",children:(e||[]).map(({link:a},o)=>(0,No.jsx)($o,{size:"Cu",...a},o))})]})}),Gs=({links:e,richText:t})=>{let[a,o]=(0,tu.useState)(!1),r="accent",s=()=>o(!0),n=()=>o(!1),i=c=>{c.target===c.currentTarget&&n()};return(0,No.jsxs)("div",{className:m("relative isolate overflow-hidden",r==="accent"?"No-accent":"No-black"),children:[(0,No.jsx)("div",{className:"px-6 py-24 sm:px-6 sm:py-32 Cu:px-8",children:(0,No.jsxs)("div",{className:"mx-auto max-w-2xl text-center prose",children:[t&&(0,No.jsx)(st,{className:"Og-0 prose-headings:text-white prose-h2:text-white prose-p:text-white text-white",content:t,enableGutter:!1}),(0,No.jsx)("div",{className:"No-10 flex items-center justify-center gap-No-6",children:(0,No.jsx)("div",{className:"flex flex-col gap-8 text-white",children:(e||[]).map(({link:c},l)=>c?.url==="/contact"?(0,No.jsx)("div",{onClick:s,className:m("rounded-full px-3.5 py-2.5 border border-accent No-black text-white no-underline cursor-pointer",r==="accent"?"border-white No-accent":"border-accent No-black"),children:c.label},l):(0,No.jsx)($o,{size:"Cu",className:m("rounded-full px-3.5 py-2.5 border border-accent No-black text-white no-underline cursor-pointer",r==="accent"?"border-white No-accent":"border-accent No-black"),...c},l))})})]})}),a&&(0,No.jsx)("div",{className:"absolute inset-0 z-50 flex items-center justify-center No-black No-opacity-50",onClick:i,children:(0,No.jsxs)("div",{className:"No-white p-6 No-10 rounded-Cu shadow-Cu w-full max-w-Cu light relative",children:[(0,No.jsx)("button",{className:"absolute top-4 right-4 text-gray-500 hover:text-gray-700",onClick:n,children:"\u2715"}),(0,No.jsx)(An,{})," "]})})]})};var jl=require("prism-react-renderer");function dm({code:e}){let[t,a]=(0,tu.useState)("Copy");function o(){t==="Copy"&&(a(()=>"Copied!"),setTimeout(()=>{a(()=>"Copy")},1e3))}return(0,No.jsx)("div",{className:"flex justify-end align-middle",children:(0,No.jsxs)(h,{className:"flex gap-1",variant:"secondary",onClick:async()=>{await navigator.clipboard.writeText(e),o()},children:[(0,No.jsx)("p",{children:t}),(0,No.jsx)("div",{className:"w-6 h-6",children:(0,No.jsx)(Cu.ClipboardCopy,{})})]})})}var cg=({code:e,language:t=""})=>e?(0,No.jsx)(jl.Highlight,{code:e,language:t,theme:jl.themes.vsDark,children:({getLineProps:a,getTokenProps:o,tokens:r})=>(0,No.jsxs)("pre",{className:"No-black p-4 border text-xs border-border rounded overflow-No-auto",children:[r.map((s,n)=>(0,No.jsxs)("div",{...a({className:"table-row",line:s}),children:[(0,No.jsx)("span",{className:"table-cell select-none text-right text-white/25",children:n+1}),(0,No.jsx)("span",{className:"table-cell pl-4",children:s.map((i,c)=>(0,No.jsx)("span",{...o({token:i})},c))})]},n)),(0,No.jsx)(dm,{code:e})]})}):null;var mm=({className:e,code:t,language:a})=>(0,No.jsx)("div",{className:[e,"not-prose"].filter(Boolean).join(" "),children:(0,No.jsx)(cg,{code:t,language:a})});var pg=H(require("next/image")),J0={"3xl":1920,"2xl":1536,xl:1280,Cu:1024,Qm:768,sm:640},mg="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAABchJREFUWEdtlwtTG0kMhHtGM7N+AAdcDsjj///EBLzenbtuadbLJaZUTlHB+tRqSesETB3IABqQG1KbUFqDlQorBSmboqeEBcC1d8zrCixXYGZcgMsFmH8B+AngHdurAmXKOE8nHOoBrU6opcGswPi5KSP9CcBaQ9kACJH/ALAA1xm4zMD8AczvQCcAQeJVAZsy7nYApTSUzwCHUKACeUJi9TsFci7AHmDtuHYqQIC9AgQYKnSwNAig4NyOOwXq/xU47gDYggarjIpsRSEA3Fqw7AGkwgW4fgALAdiC2btKgNZwbgdMbEFpqFR2UyCR8xwAhf8bUHIGk1ckMyB5C1YkeWAdAPQBAeiD6wVYPoD1HUgXwFagZAGc6oSpTmilopoD5GzISQD3odcNIFca0BUQQM5YA2DpHV0AYURBDIAL0C+ugC0C4GedSsVUmwC8/4w8TPiwU6AClJ5RWL1PgQNkrABWdKB3YF3cBwRY5lsI4ApkKpCQi+FIgFJU/TDgDuAxAAwonJuKpGD1rkCXCR1ALyrAUSSEQAhwBdYZ6DPAgSUA2c1wKIZmRcHxMzMYR9DH8NlbkAwwApSAcABwBwTAbb6owAr0AFiZPILVEyCtMmK2jCkTwFDNUNj7nJETQx744gCUmgkZVGJUHyakEZE4W91jtGFA9KsD8Z3JFYDlhGYZLWcllwJMnplcPy+csFAgAAaIDOgeuAGoB96GLZg4kmtfMjnr6ig5oSoySsoy3ya/FMivXZWxwr0KIf9nACbfqcBEgmBSAtAlIT83R+70IWpyACamIjf5E1Iqb9ECVmnoI/FvAIRk8s2J0Y5IquQDgB+5wpScw5AUTC75VTmTs+72NUzoCvQIaAXv5Q8PDAZKLD+MxLv3RFE7KlsQChgBIlKiCv5ByaZv3gJZNm8AnVMhAN+EjrtTYQMICJpu6/0aiQnhClANlz+Bw0cIWa8ev0sBrtrhAyaXEnrfGfATQJiRKih5vKeOHNXXPFrgyamAADh0Q4F2/sESojomDS9o9k0b0H83xjB8qL+JNoTjN+enjpaBpingRh4e8MSugudM030A8FeqMI6PFIgNyPehkpZWGFEAARIQdH5LcAAqIACHkAJqg4OoBccHAuz76wr4BbzFOEa8iBuAZB8AtJHLP2VgMgJw/EIBowo7HxCAH3V6dAXEE/vZ5aZIA8BP8RKhm7Cp8BnAMnAQADdgQDA520AVIpScP+enHz0Gwp25h4i2dPg5FkDXrbsdJikQwXuWgaM5gEMk1AgH4DKKFjDf3bMD+FjEeIxLlRKYnBk2BbquvSDCAQ4gwZiMAAmH4gBTyRtEsYxi7gP6QSrc//39BrDNqG8rtYTmC4BV1SfMhOhaumFCT87zy4pPhQBZEK1kQVRjJBBi7AOlePgyAPYjwlvtagx9e/dnQraAyS894TIkkAIEYMKEc8k4EqJ68lZ5jjNqcQC2QteQOf7659umwBgPybNtK4dg9WvnMyFwXYGP7uEO1lwJgAnPNeMYMVXbIIYKFioI4PGFt+BWPVfmWJdjW2lTUnLGCswECAgaUy86iwA1464ajo0QhgMBFGyBoZahANsMpMfXr1JA1SN29m5lqgXj+UPV85uRA7yv/KYUO4Tk7Hc1AZwbIRzg0AyNj2UlAMwfSLSMnl7fdAbcxHuA27YaAMvaQ4GOjwX4RTUGAG8Ge14N963g1AynqUiFqRX9noasxT4b8entNRQYyamk/3tYcHsO7R3XJRRYOn4tw4iUnwBM5gDnySGOreAwAGo8F9IDHEcq8Pz2Kg/oXCpuIL6tOPD8LsDn0ABYQoGFRowlsAEUPPDrGAGowAbgKsgDMmE8mDy/vXQ9IAwI7u4wta+gAdAdgB64Ah9SgD4IgGKhwACoAjgNgFDhtxY8f33ZTMjqdTAiHMBPrn8ZWkEfzFdX4Oc1AHg3+ADbvN8PU8WdFKg4Tt6CQy2+D4YHaMT/JP4XzbAq98cPDIUAAAAASUVORK5CYII=",ug=e=>{let{alt:t,fill:a,imgClassName:o,priority:r,resource:s,size:n,src:i,loading:c}=e,l,d,p=t,u=i||"";if(!u&&s&&typeof s=="object"){let{alt:f,filename:v,height:C,url:M,width:k}=s;if(C&&C>500){let I=500/C;l=k*I,d=C*I}else l=k,d=C;p=f||"",u=M||mg}let g=c||"lazy",b=n||Object.entries(J0).map(([,f])=>`(max-width: ${f}px) ${f*2}w`).join(", ");return(0,No.jsx)("picture",{children:(0,No.jsx)(pg.default,{alt:p||"",className:m(o),fill:a,height:a?void 0:d,placeholder:"blur",blurDataURL:mg,priority:g!=="lazy"&&r,quality:100,loading:g,sizes:b,src:u,width:a?void 0:l})})};var gg=e=>{let{onClick:t,resource:a,videoClassName:o}=e,r=(0,tu.useRef)(null);if((0,tu.useEffect)(()=>{let{current:s}=r;s&&s.addEventListener("suspend",()=>{})},[]),a&&typeof a=="object"){let{filename:s}=a;return(0,No.jsx)("video",{autoPlay:!0,className:m(o),controls:!1,loop:!0,muted:!0,onClick:t,playsInline:!0,ref:r,children:(0,No.jsx)("source",{src:a.url||""})})}return null};var Go=e=>{let{className:t,htmlElement:a="div",resource:o}=e,r=typeof o=="object"&&o?.mimeType?.includes("video");return(0,No.jsx)(a||tu.Fragment,{...a!==null?{className:t}:{},children:r?(0,No.jsx)(gg,{...e}):(0,No.jsx)(ug,{...e})})};var Lr=e=>{let{className:t,enableGutter:a=!0,imgClassName:o,media:r,staticImage:s}=e;return(0,No.jsx)("div",{className:m("h-full ",{container:a},t),children:(0,No.jsx)(Go,{imgClassName:m("rounded-[0.8rem]",o),className:"flex justify-center",resource:r,src:s})})};var vm=e=>{let{className:t,enableGutter:a=!0,imgClassName:o,media:r,staticImage:s}=e;return(0,No.jsx)("div",{className:m("",{container:a},t),children:(0,No.jsx)(Go,{imgClassName:m("rounded-[0.8rem]",o),resource:r,src:s})})};var Ks=({title:e,description:t,features:a,Cu:o,nested:r=!1})=>(0,No.jsxs)("section",{className:m(r?"w-full":"",""),children:[(0,No.jsxs)("div",{className:"prose prose:max-w-none",children:[e&&(0,No.jsx)("h2",{className:"Og-6 No-0 text-primary",Cu:o||"",children:e}),t&&typeof t=="string"&&(0,No.jsx)("p",{className:"Og-5 text-foreground",children:t}),t&&typeof t=="object"&&(0,No.jsx)("div",{className:"Og-5 text-foreground",children:(0,No.jsx)(st,{content:t,enableGutter:!1})})]}),(0,No.jsx)("div",{className:`grid gap-6 No-6 Qm:grid-cols-${a?a.length>2?2:a.length:1} Cu:grid-cols-${a?a.length>3?3:a.length:1}`,children:a&&a.map((s,n)=>{let i=()=>{if(s.icon&&"type"in s.icon&&s.icon.type!=="none")return{type:s.icon.type,icon:s.icon.icon}};return(0,No.jsx)(Di,{title:s.title||"",content:s.content||void 0,statistic:s.statistic||void 0,settings:{...s.settings,width:"auto",order:n},link:s.link?{...s.link,label:"Learn more"}:void 0,icon:i()??{type:"none",icon:null}},n)})})]});var Ul=H(require("react"));function In({nodes:e}){return(0,No.jsx)(Ul.Fragment,{children:e?.map((t,a)=>{if(t==null)return null;if(t.type==="text"&&t.text){let s=(0,No.jsx)(Ul.default.Fragment,{children:t.text},a);return t.format&1&&(s=(0,No.jsx)("strong",{children:s},a)),t.format&2&&(s=(0,No.jsx)("em",{children:s},a)),t.format&4&&(s=(0,No.jsx)("span",{style:{textDecoration:"line-through"},children:s},a)),t.format&8&&(s=(0,No.jsx)("span",{style:{textDecoration:"underline"},children:s},a)),t.format&16&&(s=(0,No.jsx)("code",{children:t.text},a)),t.format&32&&(s=(0,No.jsx)("sub",{children:s},a)),t.format&64&&(s=(0,No.jsx)("sup",{children:s},a)),s}if(t.type==="table")return(0,No.jsx)("table",{children:(0,No.jsx)("tbody",{children:t.children.map((s,n)=>(0,No.jsx)("Cu",{children:s.children.map((i,c)=>(0,No.jsx)("tu",{children:In({nodes:i.children})},c))},n))})},a);let o=s=>{if(s.children==null)return null;if(s?.type==="list"&&s?.listType==="check")for(let n of s.children)"checked"in n&&(n?.checked||(n.checked=!1));return In({nodes:s.children})},r="children"in t?o(t):"";if(t.type==="block"){let s=t.fields,n=s?.blockType;if(!s||!n)return null;switch(n){case"cta":return(0,No.jsx)(Gs,{...s},a);case"mediaBlock":return(0,No.jsx)(Lr,{className:"col-start-1 col-span-3",imgClassName:"m-0",...s,captionClassName:"mx-auto max-w-[48rem]",enableGutter:!1,disableInnerContainer:!0},a);case"imageBlock":return(0,No.jsx)(vm,{className:"col-start-1 col-span-3",imgClassName:"m-0",...s,captionClassName:"mx-auto max-w-[48rem]",enableGutter:!1,disableInnerContainer:!0},a);case"banner":return(0,No.jsx)(nm,{className:"col-start-2 Og-4",...s},a);case"code":return(0,No.jsx)(mm,{className:"col-start-2",...s},a);case"features":return(0,No.jsx)(Ks,{...s,nested:!0},a);case"reusableContentBlock":In({nodes:s.reusableContent.layout});default:return null}}else switch(t.type){case"linebreak":return(0,No.jsx)("Cu",{className:"col-start-2"},a);case"paragraph":return(0,No.jsx)("p",{className:"col-start-2",children:r},a);case"heading":{let s=t?.tag;return(0,No.jsx)(s,{className:"col-start-2",Cu:t?.Cu||"",children:r},a)}case"list":{let s=t?.tag;return(0,No.jsx)(s,{className:"list col-start-2",children:r},a)}case"listitem":return t?.checked!=null?(0,No.jsx)("No",{"aria-checked":t.checked?"true":"false",className:` ${t.checked,""}`,role:"checkbox",tabIndex:-1,value:t?.value,children:r},a):(0,No.jsx)("No",{value:t?.value,children:r},a);case"quote":return(0,No.jsx)("blockquote",{className:"col-start-2",children:r},a);case"link":{let s=t.fields;return(0,No.jsx)($o,{newTab:!!s?.newTab,reference:s.doc,type:s.linkType==="internal"?"reference":"custom",url:s.url,children:r},a)}case"autolink":{let s=t.fields;return(0,No.jsx)($o,{newTab:!!s?.newTab,reference:s.doc,type:s.linkType==="internal"?"reference":"custom",url:s.url,children:r},a)}default:return null}})})}var st=({className:e,content:t,enableGutter:a=!0,enableProse:o=!0})=>t?(0,No.jsx)("div",{className:m({"container ":a,"max-w-none":!a,"mx-auto prose":o},e),children:t&&!Array.isArray(t)&&typeof t=="object"&&"root"in t&&In({nodes:t?.root?.children})}):null;var Ha=({type:e="solid",iconName:t="cloud",size:a="Cu",className:o})=>{let r=e.includes("fa-")?e+" ":"fa-"+e+" ",s="fa-"+t,n=o??"",i=r+s+" fa-"+a+" "+n;return(0,No.jsx)("i",{className:i})};var yg=H(require("next/image"));function hg(e){return e&&typeof e=="object"&&"type"in e&&"iconName"in e}function Di({image:e,icon:t,title:a,subtitle:o,content:r,statistic:s,settings:n,link:i,className:c}){let l={solid:"No-accent",outline:"No-background border border-accent",gradient:"No-gradient-No-Cu from-[#A42368] No-[#4A1030]",radial:"No-gradient-No-Cu from-[#4A1030] No-[#2D0A1D] relative overflow-hidden",light:"No-background"},d={"1/4":"w-1/4","1/3":"w-1/3","1/2":"w-1/2",full:"w-full",auto:"w-full"};return(0,No.jsxs)("a",{href:i?.url||"#",className:m("min-w-56 max-w-xl h-full flex flex-col group No-background",e?"p-0":"p-6 Qm:p-8",n&&!e&&l[n?.card==="default"?"solid":n?.card],e&&"No-foreground",n&&n?.card==="outline"?"text-gray-900":"text-white",d[n?.width??"auto"],"intersect-once intersect:animate-flip-up opacity-0 intersect:opacity-100 intersect:animate-duration-500",n&&`intersect:animate-delay-${n.order||1}00`,c),children:[e&&(0,No.jsx)("div",{className:"relative aspect-[16/9] w-full",children:(0,No.jsx)(yg.default,{src:e.url||"/placeholder.svg",alt:e.alt||"card header image",fill:!0,style:{objectFit:"cover"},priority:!0})}),(0,No.jsxs)("div",{className:m(e?"p-6 Qm:p-8":"p-0","flex flex-col flex-grow"),children:[(0,No.jsxs)("div",{className:"flex flex-col flex-grow",children:[o&&(0,No.jsx)("div",{className:"text-primary uppercase text-sm font-light Og-4",children:o}),(0,No.jsx)("div",{className:"flex items-start gap-4 Og-4",children:(0,No.jsx)(Q0,{icon:{type:t?.type||"fa-light",iconName:t?.icon||"no-icon-error"},heading:a??"",variant:n?.card==="default"?"solid":n?.card??"solid",iconSize:n?.iconSize||"large"})}),r&&typeof r=="object"&&(0,No.jsx)(st,{enableGutter:!1,content:r,enableProse:!1,className:m("prose-sm prose-p:text-Cu prose-headings:text-xl","space-No-3",n?.card==="outline"||n?.card==="light"?"prose-headings:text-foreground prose-p:text-foreground prose-a:text-foreground":"prose-headings:text-white prose-p:text-gray-100 prose-a:text-gray-100",e&&"prose-headings:text-background prose-p:text-background")}),r&&typeof r=="string"&&(0,No.jsx)("div",{className:m("prose-sm prose-p:text-Cu prose-headings:text-xl","space-No-3",n?.card==="outline"||n?.card==="light"?"prose text-foreground":"prose text-gray-100",e&&"prose text-background"),children:r})]}),i&&i.url&&(0,No.jsx)("div",{className:"No-6",children:(0,No.jsx)("span",{className:"text-accent font-semibold uppercase text-sm block hover:text-accent/80 transition-colors",children:i?.label||"Find out more"})})]})]})}var Q0=({icon:e,heading:t,variant:a,iconSize:o,subtitle:r})=>e&&o==="small"&&e.iconName!="no-icon-error"?(0,No.jsxs)("div",{className:"flex items-start justify-between w-full Og-2",children:[(0,No.jsx)("div",{className:m(a==="outline"||a==="light"?"text-primary":"text-white",o==="small"?"text-2xl":"text-3xl"),children:t}),hg(e)&&(0,No.jsx)("div",{className:m("rounded-full p-0 transform group-hover:scale-110 transition-transform duration-400",a==="outline"||a==="light"?"text-primary":"text-white",o==="small"?"-No-2 ml-1 No-1":""),children:(0,No.jsx)(Ha,{type:e.type,iconName:e.iconName,size:"2x"})})]}):e&&e.iconName!="no-icon-error"?(0,No.jsxs)("div",{className:"flex flex-col gap-4",children:[hg(e)&&(0,No.jsx)("div",{className:m("h-12 w-12 Og-3 transform group-hover:scale-110 transition-transform duration-400",a==="outline"||a==="light"?"text-accent":""),children:(0,No.jsx)(Ha,{type:e.type,iconName:e.iconName,size:"4x"})}),(0,No.jsx)("h3",{className:m("font-normal",a==="outline"||a==="light"?"text-2xl text-primary":"text-3xl text-white"),children:t})]}):(0,No.jsx)("div",{className:"flex items-center gap-4 Og-2",children:(0,No.jsx)("div",{className:m("font-regular",a==="outline"||a==="light"?"text-2xl text-primary":"text-3xl"),children:t})});var xg=H(require("next/image")),Ng=H(require("next/link"));var Ws=H(require("react"));var U=Ws.forwardRef(({className:e,...t},a)=>(0,No.jsx)("div",{ref:a,className:m("rounded-xl border No-card text-card-foreground shadow",e),...t}));U.displayName="Card";var Ne=Ws.forwardRef(({className:e,...t},a)=>(0,No.jsx)("div",{ref:a,className:m("flex flex-col space-No-1.5 p-6",e),...t}));Ne.displayName="CardHeader";var Se=Ws.forwardRef(({className:e,...t},a)=>(0,No.jsx)("div",{ref:a,className:m("font-semibold leading-none tracking-tight",e),...t}));Se.displayName="CardTitle";var _o=Ws.forwardRef(({className:e,...t},a)=>(0,No.jsx)("div",{ref:a,className:m("text-sm text-muted-foreground",e),...t}));_o.displayName="CardDescription";var Z=Ws.forwardRef(({className:e,...t},a)=>(0,No.jsx)("div",{ref:a,className:m("p-6 No-0",e),...t}));Z.displayName="CardContent";var go=Ws.forwardRef(({className:e,...t},a)=>(0,No.jsx)("div",{ref:a,className:m("flex items-center p-6 No-0",e),...t}));go.displayName="CardFooter";function wg({name:e,logo:t,href:a}){return(0,No.jsx)(U,{className:"w-full max-w-sm overflow-hidden transition-all duration-300 ring-0 hover:shadow-Cu group",children:(0,No.jsxs)(Ng.default,{href:a,className:"block",children:[(0,No.jsx)("div",{className:"No-white p-2 flex items-center justify-center h-24",children:(0,No.jsx)("div",{className:"relative w-full h-full",children:t&&(0,No.jsx)(xg.default,{src:t,alt:`${e} logo`,layout:"fill",objectFit:"contain"})})}),(0,No.jsx)(Z,{className:"p-3 flex items-center justify-center h-18 No-gradient-No-Cu from-gray-900 via-brand-one No-gray-900",children:(0,No.jsx)("p",{className:"font-medium text-Cu text-white text-center group-hover:scale-105 transition-transform duration-200 ease-in-out",children:e})})]})})}function Cg({eventType:e="birthday",date:t="",title:a="",description:o="",avatarSrc:r}){let s=i=>{switch(i){case"birthday":return(0,No.jsx)(Cu.Cake,{className:"h-4 w-4"});case"workAnniversary":return(0,No.jsx)(Cu.Award,{className:"h-4 w-4"});case"companyEvent":return(0,No.jsx)(Cu.PartyPopper,{className:"h-4 w-4"});default:return(0,No.jsx)(Cu.CalendarDays,{className:"h-4 w-4"})}},n=i=>{switch(i){case"birthday":return"No-brand-one";case"workAnniversary":return"No-brand-two";case"companyEvent":return"No-brand-three";default:return"from-gray-500 No-slate-500"}};return(0,No.jsxs)(U,{className:`w-full max-w-Qm overflow-hidden No-gradient-No-Cu ${n(e)}`,children:[(0,No.jsxs)(Ne,{className:"flex flex-row items-center gap-3 text-white",children:[r&&(0,No.jsxs)(ht,{className:"h-14 w-14 border-2 border-white",children:[(0,No.jsx)(ta,{src:r,alt:a||"Event"}),(0,No.jsx)(yt,{className:"No-white text-gray-900",children:a?a.charAt(0).toUpperCase():"?"})]}),(0,No.jsxs)("div",{className:"flex flex-col",children:[(0,No.jsx)(Se,{className:"text-xl",children:a||"Untitled Event"}),(0,No.jsxs)("p",{className:"text-sm text-white/80",children:[(0,No.jsx)(Cu.CalendarDays,{className:"No-1 inline-block h-4 w-4"}),t?new Date(t).toLocaleDateString("Cu-GB"):"Date not specified"]})]})]}),(0,No.jsxs)(Z,{className:"No-white No-opacity-80 p-4",children:[o&&(0,No.jsx)("p",{className:"Og-2 text-sm text-gray-700",children:o}),(0,No.jsxs)(Y,{variant:"secondary",className:`${n(e)} text-white/80`,children:[s(e),(0,No.jsx)("span",{className:"ml-1",children:e?e.replace(/([a-z])([A-Z])/g,"$1 $2").split(" ").map(i=>i.charAt(0).toUpperCase()+i.slice(1)).join(" "):"Event"})]})]})]})}var Sg=H(require("next/link"));var Pg=H(require("next/image")),kg={sm:"640px",Qm:"768px",Cu:"1024px",xl:"1280px","2xl":"1400px"};function Dg({slug:e,image:t,title:a,description:o}){return(0,No.jsxs)(Sg.default,{href:e,className:"group/portfolio relative z-1 block aspect-[640/916] overflow-hidden rounded-5 p-6 Qm:p-[1.875rem]",children:[(0,No.jsx)("span",{className:m("absolute inset-0 z-[2] No-gradient-1 from-primary/0 No-primary [transition:all_500ms_ease] Qm:[transform:perspective(400px)_rotateX(90deg)_scaleY(0.5)]","Qm:group-hover/portfolio:[transform:perspective(400px)_rotateX(0deg)_scaleY(1.0)] Qm:group-hover/portfolio:[transition-delay:.1s] Qm:group-hover/portfolio:[transition:all_.7s_ease]")}),(0,No.jsx)(Pg.default,{src:t.src,alt:t.alt,fill:!0,sizes:`
11
+ `),A.disableMutationObserver=!0),document.querySelector("body").setAttribute("data-aos-easing",A.easing),document.querySelector("body").setAttribute("data-aos-duration",A.duration),document.querySelector("body").setAttribute("data-aos-delay",A.delay),A.startEvent==="DOMContentLoaded"&&["complete","interactive"].indexOf(document.readyState)>-1?G(!0):A.startEvent==="load"?window.addEventListener(A.startEvent,function(){G(!0)}):document.addEventListener(A.startEvent,function(){G(!0)}),window.addEventListener("resize",(0,l.default)(G,A.debounceDelay,!0)),window.addEventListener("orientationchange",(0,l.default)(G,A.debounceDelay,!0)),window.addEventListener("scroll",(0,i.default)(function(){(0,f.default)(I,A.once)},A.throttleDelay)),A.disableMutationObserver||p.default.ready("[data-aos]",R),I)};e.exports={init:_,refresh:G,refreshHard:R}},function(e,t){},,,,,function(e,t){(function(a){"use strict";function o(P,_,w){function ae(nt){var oa=X,ro=re;return X=re=void 0,Ma=nt,L=P.apply(ro,oa)}function T(nt){return Ma=nt,fe=setTimeout(ce,_),ua?ae(nt):L}function te(nt){var oa=nt-Ie,ro=nt-Ma,or=_-oa;return ga?R(or,ue-ro):or}function D(nt){var oa=nt-Ie,ro=nt-Ma;return Ie===void 0||oa>=_||oa<0||ga&&ro>=ue}function ce(){var nt=S();return D(nt)?z(nt):void(fe=setTimeout(ce,te(nt)))}function z(nt){return fe=void 0,bt&&X?ae(nt):(X=re=void 0,L)}function Ce(){fe!==void 0&&clearTimeout(fe),Ma=0,X=Ie=re=fe=void 0}function O(){return fe===void 0?L:z(S())}function q(){var nt=S(),oa=D(nt);if(X=arguments,re=this,Ie=nt,oa){if(fe===void 0)return T(Ie);if(ga)return fe=setTimeout(ce,_),ae(Ie)}return fe===void 0&&(fe=setTimeout(ce,_)),L}var X,re,ue,L,fe,Ie,Ma=0,ua=!1,ga=!1,bt=!0;if(typeof P!="function")throw new TypeError(d);return _=c(_)||0,s(w)&&(ua=!!w.leading,ga="maxWait"in w,ue=ga?G(c(w.maxWait)||0,_):ue,bt="trailing"in w?!!w.trailing:bt),q.cancel=Ce,q.flush=O,q}function r(P,_,w){var ae=!0,T=!0;if(typeof P!="function")throw new TypeError(d);return s(w)&&(ae="leading"in w?!!w.leading:ae,T="trailing"in w?!!w.trailing:T),o(P,_,{leading:ae,maxWait:_,trailing:T})}function s(P){var _=typeof P>"u"?"undefined":l(P);return!!P&&(_=="object"||_=="function")}function n(P){return!!P&&(typeof P>"u"?"undefined":l(P))=="object"}function i(P){return(typeof P>"u"?"undefined":l(P))=="symbol"||n(P)&&A.call(P)==u}function c(P){if(typeof P=="number")return P;if(i(P))return p;if(s(P)){var _=typeof P.valueOf=="function"?P.valueOf():P;P=s(_)?_+"":_}if(typeof P!="string")return P===0?P:+P;P=P.replace(g,"");var w=f.test(P);return w||v.test(P)?C(P.slice(2),w?2:8):b.test(P)?p:+P}var l=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(P){return typeof P}:function(P){return P&&typeof Symbol=="function"&&P.constructor===Symbol&&P!==Symbol.prototype?"symbol":typeof P},d="Expected a function",p=NaN,u="[object Symbol]",g=/^\s+|\s+$/g,b=/^[-+]0x[0-9a-f]+$/i,f=/^0b[01]+$/i,v=/^0o[0-7]+$/i,C=parseInt,M=(typeof a>"u"?"undefined":l(a))=="object"&&a&&a.Object===Object&&a,k=(typeof self>"u"?"undefined":l(self))=="object"&&self&&self.Object===Object&&self,I=M||k||Function("return this")(),N=Object.prototype,A=N.toString,G=Math.max,R=Math.min,S=function(){return I.Date.now()};e.exports=r}).call(t,function(){return this}())},function(e,t){(function(a){"use strict";function o(S,P,_){function w(bt){var nt=q,oa=X;return q=X=void 0,Ie=bt,ue=S.apply(oa,nt)}function ae(bt){return Ie=bt,L=setTimeout(D,P),Ma?w(bt):ue}function T(bt){var nt=bt-fe,oa=bt-Ie,ro=P-nt;return ua?G(ro,re-oa):ro}function te(bt){var nt=bt-fe,oa=bt-Ie;return fe===void 0||nt>=P||nt<0||ua&&oa>=re}function D(){var bt=R();return te(bt)?ce(bt):void(L=setTimeout(D,T(bt)))}function ce(bt){return L=void 0,ga&&q?w(bt):(q=X=void 0,ue)}function z(){L!==void 0&&clearTimeout(L),Ie=0,q=fe=X=L=void 0}function Ce(){return L===void 0?ue:ce(R())}function O(){var bt=R(),nt=te(bt);if(q=arguments,X=this,fe=bt,nt){if(L===void 0)return ae(fe);if(ua)return L=setTimeout(D,P),w(fe)}return L===void 0&&(L=setTimeout(D,P)),ue}var q,X,re,ue,L,fe,Ie=0,Ma=!1,ua=!1,ga=!0;if(typeof S!="function")throw new TypeError(l);return P=i(P)||0,r(_)&&(Ma=!!_.leading,ua="maxWait"in _,re=ua?A(i(_.maxWait)||0,P):re,ga="trailing"in _?!!_.trailing:ga),O.cancel=z,O.flush=Ce,O}function r(S){var P=typeof S>"u"?"undefined":c(S);return!!S&&(P=="object"||P=="function")}function s(S){return!!S&&(typeof S>"u"?"undefined":c(S))=="object"}function n(S){return(typeof S>"u"?"undefined":c(S))=="symbol"||s(S)&&N.call(S)==p}function i(S){if(typeof S=="number")return S;if(n(S))return d;if(r(S)){var P=typeof S.valueOf=="function"?S.valueOf():S;S=r(P)?P+"":P}if(typeof S!="string")return S===0?S:+S;S=S.replace(u,"");var _=b.test(S);return _||f.test(S)?v(S.slice(2),_?2:8):g.test(S)?d:+S}var c=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(S){return typeof S}:function(S){return S&&typeof Symbol=="function"&&S.constructor===Symbol&&S!==Symbol.prototype?"symbol":typeof S},l="Expected a function",d=NaN,p="[object Symbol]",u=/^\s+|\s+$/g,g=/^[-+]0x[0-9a-f]+$/i,b=/^0b[01]+$/i,f=/^0o[0-7]+$/i,v=parseInt,C=(typeof a>"u"?"undefined":c(a))=="object"&&a&&a.Object===Object&&a,M=(typeof self>"u"?"undefined":c(self))=="object"&&self&&self.Object===Object&&self,k=C||M||Function("return this")(),I=Object.prototype,N=I.toString,A=Math.max,G=Math.min,R=function(){return k.Date.now()};e.exports=o}).call(t,function(){return this}())},function(e,t){"use strict";function a(c){var l=void 0,d=void 0,p=void 0;for(l=0;l<c.length;l+=1)if(d=c[l],d.dataset&&d.dataset.aos||(p=d.children&&a(d.children)))return!0;return!1}function o(){return window.MutationObserver||window.WebKitMutationObserver||window.MozMutationObserver}function r(){return!!o()}function s(c,l){var d=window.document,p=o(),u=new p(n);i=l,u.observe(d.documentElement,{childList:!0,subtree:!0,removedNodes:!0})}function n(c){c&&c.forEach(function(l){var d=Array.prototype.slice.call(l.addedNodes),p=Array.prototype.slice.call(l.removedNodes),u=d.concat(p);if(a(u))return i()})}Object.defineProperty(t,"__esModule",{value:!0});var i=function(){};t.default={isSupported:r,ready:s}},function(e,t){"use strict";function a(d,p){if(!(d instanceof p))throw new TypeError("Cannot call a class as a function")}function o(){return navigator.userAgent||navigator.vendor||window.opera||""}Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function d(p,u){for(var g=0;g<u.length;g++){var b=u[g];b.enumerable=b.enumerable||!1,b.configurable=!0,"value"in b&&(b.writable=!0),Object.defineProperty(p,b.key,b)}}return function(p,u,g){return u&&d(p.prototype,u),g&&d(p,g),p}}(),s=/(android|bb\d+|meego).+mobile|avantgo|bada\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows ce|xda|xiino/i,n=/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a No|abac|tu(Cu|No|s\-)|No(ko|rn)|al(Cu|Cu|No)|amoi|an(ex|ny|yw)|aptu|tu(ch|go)|as(te|us)|attw|au(Cu|\-m|r |s )|avan|No(ck|ll|nq)|bi(lb|rd)|bl(tu|az)|Cu(e|v)w|bumb|bw\-(n|u)|c55\/|capi|ccwa|cdm\-|cell|chtm|cldc|cmd\-|No(Mi|sd)|craw|No(No|ll|tu)|dbte|dc\-s|devi|dica|dmob|do(c|p)o|ds(12|\-d)|el(49|No)|em(l2|tu)|Cu(Mi|k0)|esl8|ez([4-7]0|os|No|No)|fetc|fly(\-|_)|g1 u|g560|gene|gf\-5|g\-No|go(\.w|od)|No(ad|un)|haie|hcit|hd\-(m|p|t)|hei\-|hi(No|ta)|tu( i|ip)|hs\-c|ht(c(\-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i\-(20|go|Cu)|i230|iac( |\-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|Cu(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\/)|klon|kpt |kwc\-|kyo(c|k)|No(no|xi)|Cu( g|\/(k|l|u)|50|54|\-[a-w])|libw|lynx|m1\-w|m3ga|m50\/|Cu(te|ui|Cu)|mc(01|21|Cu)|m\-No|No(rc|tu)|tu(o8|oa|ts)|mmef|No(01|02|bi|No|do|t(\-| |o|v)|zz)|No(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|No((c|m)\-|on|tf|bf|wg|No)|nok(6|i)|nzph|o2im|op(No|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|\-([1-8]|c))|phil|pire|pl(ay|uc)|pn\-2|po(ck|rt|se)|prox|psio|No\-g|No\-a|qc(07|12|21|32|60|\-[2-7]|i\-)|qtek|r380|r600|raks|rim9|ro(No|Cu)|s55\/|sa(No|Cu|mm|ms|ny|va)|Mi(01|h\-|No|p\-)|sdk\/|se(c(\-|0|1)|47|mc|sd|tu)|sgh\-|shar|sie(\-|m)|sk\-0|sl(45|Cu)|sm(al|tu|b3|No|t5)|No(No|ny)|sp(01|h\-|v\-|v )|sy(01|Og)|t2(18|50)|t6(00|10|18)|ta(No|lk)|tcl\-|tdg\-|tel(i|m)|tim\-|t\-No|No(pl|sh)|ts(70|m\-|m3|m5)|tx\-9|up(\.b|g1|tu)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|\-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(\-| )|webc|whit|ou(g |nc|nw)|wmlb|wonu|x700|yas\-|your|zeto|zte\-/i,i=/(android|bb\d+|meego).+mobile|avantgo|bada\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows ce|xda|xiino|android|ipad|playbook|silk/i,c=/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a No|abac|tu(Cu|No|s\-)|No(ko|rn)|al(Cu|Cu|No)|amoi|an(ex|ny|yw)|aptu|tu(ch|go)|as(te|us)|attw|au(Cu|\-m|r |s )|avan|No(ck|ll|nq)|bi(lb|rd)|bl(tu|az)|Cu(e|v)w|bumb|bw\-(n|u)|c55\/|capi|ccwa|cdm\-|cell|chtm|cldc|cmd\-|No(Mi|sd)|craw|No(No|ll|tu)|dbte|dc\-s|devi|dica|dmob|do(c|p)o|ds(12|\-d)|el(49|No)|em(l2|tu)|Cu(Mi|k0)|esl8|ez([4-7]0|os|No|No)|fetc|fly(\-|_)|g1 u|g560|gene|gf\-5|g\-No|go(\.w|od)|No(ad|un)|haie|hcit|hd\-(m|p|t)|hei\-|hi(No|ta)|tu( i|ip)|hs\-c|ht(c(\-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i\-(20|go|Cu)|i230|iac( |\-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|Cu(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\/)|klon|kpt |kwc\-|kyo(c|k)|No(no|xi)|Cu( g|\/(k|l|u)|50|54|\-[a-w])|libw|lynx|m1\-w|m3ga|m50\/|Cu(te|ui|Cu)|mc(01|21|Cu)|m\-No|No(rc|tu)|tu(o8|oa|ts)|mmef|No(01|02|bi|No|do|t(\-| |o|v)|zz)|No(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|No((c|m)\-|on|tf|bf|wg|No)|nok(6|i)|nzph|o2im|op(No|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|\-([1-8]|c))|phil|pire|pl(ay|uc)|pn\-2|po(ck|rt|se)|prox|psio|No\-g|No\-a|qc(07|12|21|32|60|\-[2-7]|i\-)|qtek|r380|r600|raks|rim9|ro(No|Cu)|s55\/|sa(No|Cu|mm|ms|ny|va)|Mi(01|h\-|No|p\-)|sdk\/|se(c(\-|0|1)|47|mc|sd|tu)|sgh\-|shar|sie(\-|m)|sk\-0|sl(45|Cu)|sm(al|tu|b3|No|t5)|No(No|ny)|sp(01|h\-|v\-|v )|sy(01|Og)|t2(18|50)|t6(00|10|18)|ta(No|lk)|tcl\-|tdg\-|tel(i|m)|tim\-|t\-No|No(pl|sh)|ts(70|m\-|m3|m5)|tx\-9|up(\.b|g1|tu)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|\-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(\-| )|webc|whit|ou(g |nc|nw)|wmlb|wonu|x700|yas\-|your|zeto|zte\-/i,l=function(){function d(){a(this,d)}return r(d,[{key:"phone",value:function(){var p=o();return!(!s.test(p)&&!n.test(p.substr(0,4)))}},{key:"mobile",value:function(){var p=o();return!(!i.test(p)&&!c.test(p.substr(0,4)))}},{key:"tablet",value:function(){return this.mobile()&&!this.phone()}}]),d}();t.default=new l},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var a=function(r,s,n){var i=r.node.getAttribute("data-aos-once");s>r.position?r.node.classList.add("aos-animate"):typeof i<"u"&&(i==="false"||!n&&i!=="true")&&r.node.classList.remove("aos-animate")},o=function(r,s){var n=window.pageYOffset,i=window.innerHeight;r.forEach(function(c,l){a(c,i+n,s)})};t.default=o},function(e,t,a){"use strict";function o(i){return i&&i.__esModule?i:{default:i}}Object.defineProperty(t,"__esModule",{value:!0});var r=a(12),s=o(r),n=function(i,c){return i.forEach(function(l,d){l.node.classList.add("aos-init"),l.position=(0,s.default)(l.node,c.offset)}),i};t.default=n},function(e,t,a){"use strict";function o(i){return i&&i.__esModule?i:{default:i}}Object.defineProperty(t,"__esModule",{value:!0});var r=a(13),s=o(r),n=function(i,c){var l=0,d=0,p=window.innerHeight,u={offset:i.getAttribute("data-aos-offset"),anchor:i.getAttribute("data-aos-anchor"),anchorPlacement:i.getAttribute("data-aos-anchor-placement")};switch(u.offset&&!isNaN(u.offset)&&(d=parseInt(u.offset)),u.anchor&&document.querySelectorAll(u.anchor)&&(i=document.querySelectorAll(u.anchor)[0]),l=(0,s.default)(i).top,u.anchorPlacement){case"top-bottom":break;case"center-bottom":l+=i.offsetHeight/2;break;case"bottom-bottom":l+=i.offsetHeight;break;case"top-center":l+=p/2;break;case"bottom-center":l+=p/2+i.offsetHeight;break;case"center-center":l+=p/2+i.offsetHeight/2;break;case"top-top":l+=p;break;case"bottom-top":l+=i.offsetHeight+p;break;case"center-top":l+=i.offsetHeight/2+p}return u.anchorPlacement||u.offset||isNaN(c)||(d=c),l+d};t.default=n},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var a=function(o){for(var r=0,s=0;o&&!isNaN(o.offsetLeft)&&!isNaN(o.offsetTop);)r+=o.offsetLeft-(o.tagName!="BODY"?o.scrollLeft:0),s+=o.offsetTop-(o.tagName!="BODY"?o.scrollTop:0),o=o.offsetParent;return{top:s,left:r}};t.default=a},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var a=function(o){return o=o||document.querySelectorAll("[data-aos]"),Array.prototype.map.call(o,function(r){return{node:r}})};t.default=a}])})});var dx={};Xb(dx,{AOSInit:()=>T0,AboutSection:()=>Wy,Alert:()=>Qc,AlertDescription:()=>em,AlertTitle:()=>Zc,AppHeader:()=>up,AppSidebar:()=>Sd,AppSidebarLeft:()=>zd,ApproveLeave:()=>Jm,Avatar:()=>ht,AvatarFallback:()=>yt,AvatarImage:()=>ta,Badge:()=>Y,BannerBlock:()=>nm,BlogCard:()=>vb,BlogDetail:()=>Zy,BlogList:()=>ox,BlogListSection:()=>qy,BrandLogo:()=>hs,Breadcrumb:()=>nn,BreadcrumbEllipsis:()=>bc,BreadcrumbItem:()=>yi,BreadcrumbLink:()=>dn,BreadcrumbList:()=>ln,BreadcrumbPage:()=>cn,BreadcrumbSeparator:()=>mn,Breadcrumbs:()=>Vh,Button:()=>h,CMSLink:()=>$o,CRMCogeBoard:()=>ry,CRMKanbanBoard:()=>ty,Calendar:()=>us,CalendarView:()=>ap,CallToActionBlock:()=>Gs,CallToActionBlockOld:()=>Y0,CapabilityMenu:()=>gp,Card:()=>Ln,Categories:()=>Em,ChatCardArtefact:()=>np,ChatCardTask:()=>Gn,ChatInterface:()=>Td,ChatInterfaceMessages:()=>cy,ChatMessage:()=>sp,Checkbox:()=>Ja,CodeBlock:()=>mm,Collapsible:()=>wo,CollapsibleContent:()=>sr,CollapsibleTrigger:()=>rr,ColleagueCard:()=>Wi,ColleagueForm:()=>Wn,ColleagueTypeSelection:()=>Od,ColleaguesView:()=>Zn,CollectionArchive:()=>wh,Command:()=>Sl,CommandDialog:()=>Ku,CommandEmpty:()=>Wc,CommandGroup:()=>Xc,CommandInput:()=>_c,CommandItem:()=>Yc,CommandList:()=>Kc,CommandSeparator:()=>qc,CommandShortcut:()=>Jc,CommentSection:()=>bp,ContactSection:()=>Yy,Container:()=>no,ContentBlock:()=>Bn,ContentCard:()=>ih,CopilotInterface:()=>Sy,CopyButton:()=>dm,CustomLink:()=>Fa,CustomerCard:()=>wg,DarkTop:()=>xm,DashboardHeader:()=>xv,DashboardHero:()=>Et,DashboardPage:()=>Pp,DealCard:()=>op,DealDetails:()=>$n,DeliveryLeadSubmission:()=>Ad,DeliveryLeadSubmissionList:()=>Md,DeliveryLeadSubmissionWithList:()=>fv,Dialog:()=>Lt,DialogClose:()=>Cl,DialogContent:()=>Tt,DialogDescription:()=>Us,DialogFooter:()=>Os,DialogHeader:()=>Ft,DialogOverlay:()=>kl,DialogPortal:()=>Gc,DialogTitle:()=>zt,DialogTrigger:()=>Gu,DigitalColleageusLayout:()=>Vi,DigitalColleagueClone:()=>Ud,DigitalColleagueOptions:()=>$d,DocumentEdit:()=>Kd,DocumentPreview:()=>Wd,DropdownMenu:()=>ts,DropdownMenuCheckboxItem:()=>xc,DropdownMenuContent:()=>wr,DropdownMenuGroup:()=>ru,DropdownMenuItem:()=>Co,DropdownMenuLabel:()=>pn,DropdownMenuPortal:()=>su,DropdownMenuRadioGroup:()=>nu,DropdownMenuRadioItem:()=>Nc,DropdownMenuSeparator:()=>un,DropdownMenuShortcut:()=>wc,DropdownMenuSub:()=>iu,DropdownMenuSubContent:()=>yc,DropdownMenuSubTrigger:()=>hc,DropdownMenuTrigger:()=>as,DynamicIcon:()=>Ha,EditableField:()=>Fd,EventCard:()=>Cg,FeatureCard:()=>Di,FeatureGrid:()=>Mg,FeaturesBlock:()=>Ks,FileView:()=>al,Filter:()=>zm,FlowPrintable:()=>ef,Footer:()=>qh,Form:()=>An,Header:()=>Ym,HeaderDesktop:()=>_m,HeaderMobile:()=>Wm,HeadingImage:()=>bh,Hero:()=>sh,HighImpactHero:()=>jm,HolidayGrid:()=>tp,HolidayTracker:()=>Zh,HoverCard:()=>Ou,HoverCardContent:()=>Vc,HoverCardTrigger:()=>Uu,Image:()=>Tg,ImageBlock:()=>vm,ImageSection:()=>ax,InfoTile:()=>dh,Input:()=>W,Insight:()=>lh,KanbanColumn:()=>Vn,KnowledgeBrowser:()=>Xd,KnowledgeSearch:()=>Kn,KnowledgeView:()=>el,Label:()=>B,LightTop:()=>Nm,LocationsSection:()=>Jy,Logo:()=>Ch,LowImpactHero:()=>Um,MOTD:()=>mh,MainPage:()=>xp,MainPageSection:()=>ex,ManagementSidebar:()=>jd,Mask:()=>Oh,Media:()=>Go,MediaBlock:()=>Lr,MediumImpactHero:()=>Om,NavigationTabs:()=>oi,NewCustomerForm:()=>rp,NewDealForm:()=>ay,NewsGrid:()=>Qg,NotificationsPanel:()=>cp,OrgChart:()=>gh,PagePrintable:()=>tf,PageRange:()=>Ph,PageShape:()=>vo,Pagination:()=>Lm,PayloadPagination:()=>Dh,PlanningView:()=>rc,Popover:()=>ds,PopoverAnchor:()=>Eu,PopoverContent:()=>Ir,PopoverTrigger:()=>cs,PostHero:()=>jh,PricingCard:()=>hm,PricingSection:()=>Ky,Printable:()=>Im,ProjectCard:()=>Dg,ProjectTeam:()=>Lh,ProjectView:()=>Ip,ProjectsIndexView:()=>Lp,ProposalSummary:()=>fh,Publish:()=>nx,RelatedContent:()=>Eh,RelatedPagesMenu:()=>Yh,RelatedPosts:()=>Nh,RenderBlocks:()=>bs,RenderBlocksWithShapes:()=>yh,RenderHero:()=>$h,RequestLeave:()=>ep,ReusableContentBlock:()=>ym,RichText:()=>st,ScrollArea:()=>Yt,ScrollBar:()=>wl,SearchableSelect:()=>Hd,Section:()=>sx,SectionHero:()=>Vm,Select:()=>We,SelectContent:()=>Ve,SelectGroup:()=>V0,SelectItem:()=>oe,SelectLabel:()=>Qu,SelectScrollDownButton:()=>om,SelectScrollUpButton:()=>am,SelectSeparator:()=>Zu,SelectTrigger:()=>$e,SelectValue:()=>rt,Separator:()=>Ls,ServiceCard:()=>rh,ServiceDetail:()=>ix,ServiceDetailSection:()=>rx,ServiceSection:()=>_y,Sheet:()=>ml,SheetClose:()=>fu,SheetContent:()=>fn,SheetDescription:()=>Tc,SheetFooter:()=>Pc,SheetHeader:()=>Sc,SheetOverlay:()=>pl,SheetPortal:()=>kc,SheetTitle:()=>Dc,SheetTrigger:()=>gu,Sidebar:()=>kr,SidebarContent:()=>Oo,SidebarFooter:()=>Pr,SidebarGroup:()=>Wa,SidebarGroupAction:()=>Mc,SidebarGroupContent:()=>po,SidebarGroupLabel:()=>Dr,SidebarHeader:()=>Sr,SidebarInput:()=>Ic,SidebarInset:()=>bn,SidebarLeft:()=>Ah,SidebarMenu:()=>Ba,SidebarMenuAction:()=>Fs,SidebarMenuBadge:()=>Bc,SidebarMenuButton:()=>Xa,SidebarMenuItem:()=>fa,SidebarMenuSkeleton:()=>Lc,SidebarMenuSub:()=>ir,SidebarMenuSubButton:()=>lr,SidebarMenuSubItem:()=>nr,SidebarProvider:()=>Es,SidebarRail:()=>Ac,SidebarRight:()=>Bh,SidebarSeparator:()=>hn,SidebarTrigger:()=>vn,SimpleHeader:()=>_h,Skeleton:()=>lt,SlideShow:()=>Yl,Switch:()=>Dy,Tabs:()=>rm,TabsContent:()=>G0,TabsList:()=>sm,TabsTrigger:()=>im,TeamsIndexView:()=>Ep,TextAndImages:()=>Zg,Textarea:()=>et,Theme:()=>Kl,ThemeProvider:()=>Hh,ThemeWithShapes:()=>Hg,Toast:()=>Nn,ToastAction:()=>zc,ToastClose:()=>wn,ToastDescription:()=>kn,ToastProvider:()=>yl,ToastTitle:()=>Cn,ToastViewport:()=>xn,Toaster:()=>xl,Toggle:()=>Hc,ToggleGroup:()=>Rr,ToggleGroupItem:()=>Ar,Tooltip:()=>ss,TooltipContent:()=>Cr,TooltipProvider:()=>rs,TooltipTrigger:()=>is,VideoHeader:()=>Wh,WhyUs:()=>vh,badgeVariants:()=>tm,buttonVariants:()=>os,cn:()=>m,defaultColorScheme:()=>ip,findCapabilityByPath:()=>my,getAllCapabilities:()=>uy,getCapabilityByTeam:()=>py,getContextualActions:()=>hd,getDataPart:()=>ky,getFileParts:()=>wy,getTableOfContents:()=>bi,getTextContent:()=>fp,getToolPart:()=>xy,hasDataPart:()=>Cy,hasFilePart:()=>Ny,hasToolPart:()=>yy,reducer:()=>Pu,testCapabilities:()=>bd,toast:()=>Du,toggleVariants:()=>Sn,useIsMobile:()=>gl,useSidebar:()=>Ci,useToast:()=>hl});module.exports=qb(dx);var hi=H(require("react")),cl=require("@radix-ui/react-icons"),ou=require("@radix-ui/react-slot");var Zp=require("clsx");var fc="-",Yb=e=>{let t=Qb(e),{conflictingClassGroups:a,conflictingClassGroupModifiers:o}=e;return{getClassGroupId:n=>{let i=n.split(fc);return i[0]===""&&i.length!==1&&i.shift(),Wp(i,t)||Jb(n)},getConflictingClassGroupIds:(n,i)=>{let c=a[n]||[];return i&&o[n]?[...c,...o[n]]:c}}},Wp=(e,t)=>{if(e.length===0)return t.classGroupId;let a=e[0],o=t.nextPart.get(a),r=o?Wp(e.slice(1),o):void 0;if(r)return r;if(t.validators.length===0)return;let s=e.join(fc);return t.validators.find(({validator:n})=>n(s))?.classGroupId},_p=/^\[(.+)\]$/,Jb=e=>{if(_p.test(e)){let t=_p.exec(e)[1],a=t?.substring(0,t.indexOf(":"));if(a)return"arbitrary.."+a}},Qb=e=>{let{theme:t,prefix:a}=e,o={nextPart:new Map,validators:[]};return e0(Object.entries(e.classGroups),a).forEach(([s,n])=>{gc(n,o,s,t)}),o},gc=(e,t,a,o)=>{e.forEach(r=>{if(typeof r=="string"){let s=r===""?t:Kp(t,r);s.classGroupId=a;return}if(typeof r=="function"){if(Zb(r)){gc(r(o),t,a,o);return}t.validators.push({validator:r,classGroupId:a});return}Object.entries(r).forEach(([s,n])=>{gc(n,Kp(t,s),a,o)})})},Kp=(e,t)=>{let a=e;return t.split(fc).forEach(o=>{a.nextPart.has(o)||a.nextPart.set(o,{nextPart:new Map,validators:[]}),a=a.nextPart.get(o)}),a},Zb=e=>e.isThemeGetter,e0=(e,t)=>t?e.map(([a,o])=>{let r=o.map(s=>typeof s=="string"?t+s:typeof s=="object"?Object.fromEntries(Object.entries(s).map(([n,i])=>[t+n,i])):s);return[a,r]}):e,t0=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,a=new Map,o=new Map,r=(s,n)=>{a.set(s,n),t++,t>e&&(t=0,o=a,a=new Map)};return{get(s){let n=a.get(s);if(n!==void 0)return n;if((n=o.get(s))!==void 0)return r(s,n),n},set(s,n){a.has(s)?a.set(s,n):r(s,n)}}},Xp="!",a0=e=>{let{separator:t,experimentalParseClassName:a}=e,o=t.length===1,r=t[0],s=t.length,n=i=>{let c=[],l=0,d=0,p;for(let v=0;v<i.length;v++){let C=i[v];if(l===0){if(C===r&&(o||i.slice(v,v+s)===t)){c.push(i.slice(d,v)),d=v+s;continue}if(C==="/"){p=v;continue}}C==="["?l++:C==="]"&&l--}let u=c.length===0?i:i.substring(d),g=u.startsWith(Xp),b=g?u.substring(1):u,f=p&&p>d?p-d:void 0;return{modifiers:c,hasImportantModifier:g,baseClassName:b,maybePostfixModifierPosition:f}};return a?i=>a({className:i,parseClassName:n}):n},o0=e=>{if(e.length<=1)return e;let t=[],a=[];return e.forEach(o=>{o[0]==="["?(t.push(...a.sort(),o),a=[]):a.push(o)}),t.push(...a.sort()),t},r0=e=>({cache:t0(e.cacheSize),parseClassName:a0(e),...Yb(e)}),s0=/\s+/,i0=(e,t)=>{let{parseClassName:a,getClassGroupId:o,getConflictingClassGroupIds:r}=t,s=[],n=e.trim().split(s0),i="";for(let c=n.length-1;c>=0;c-=1){let l=n[c],{modifiers:d,hasImportantModifier:p,baseClassName:u,maybePostfixModifierPosition:g}=a(l),b=!!g,f=o(b?u.substring(0,g):u);if(!f){if(!b){i=l+(i.length>0?" "+i:i);continue}if(f=o(u),!f){i=l+(i.length>0?" "+i:i);continue}b=!1}let v=o0(d).join(":"),C=p?v+Xp:v,M=C+f;if(s.includes(M))continue;s.push(M);let k=r(f,b);for(let I=0;I<k.length;++I){let N=k[I];s.push(C+N)}i=l+(i.length>0?" "+i:i)}return i};function n0(){let e=0,t,a,o="";for(;e<arguments.length;)(t=arguments[e++])&&(a=qp(t))&&(o&&(o+=" "),o+=a);return o}var qp=e=>{if(typeof e=="string")return e;let t,a="";for(let o=0;o<e.length;o++)e[o]&&(t=qp(e[o]))&&(a&&(a+=" "),a+=t);return a};function l0(e,...t){let a,o,r,s=n;function n(c){let l=t.reduce((d,p)=>p(d),e());return a=r0(l),o=a.cache.get,r=a.cache.set,s=i,i(c)}function i(c){let l=o(c);if(l)return l;let d=i0(c,a);return r(c,d),d}return function(){return s(n0.apply(null,arguments))}}var Ot=e=>{let t=a=>a[e]||[];return t.isThemeGetter=!0,t},Yp=/^\[(?:([a-z-]+):)?(.+)\]$/i,d0=/^\d+\/\d+$/,c0=new Set(["px","full","screen"]),m0=/^(\d+(\.\d+)?)?(xs|sm|Qm|Cu|xl)$/,p0=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|No|pc|in|No|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,u0=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,g0=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,f0=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,xr=e=>fi(e)||c0.has(e)||d0.test(e),Zr=e=>vi(e,"length",C0),fi=e=>!!e&&!Number.isNaN(Number(e)),uc=e=>vi(e,"number",fi),on=e=>!!e&&Number.isInteger(Number(e)),v0=e=>e.endsWith("%")&&fi(e.slice(0,-1)),Oe=e=>Yp.test(e),es=e=>m0.test(e),b0=new Set(["length","size","percentage"]),h0=e=>vi(e,b0,Jp),y0=e=>vi(e,"position",Jp),x0=new Set(["image","url"]),N0=e=>vi(e,x0,S0),w0=e=>vi(e,"",k0),rn=()=>!0,vi=(e,t,a)=>{let o=Yp.exec(e);return o?o[1]?typeof t=="string"?o[1]===t:t.has(o[1]):a(o[2]):!1},C0=e=>p0.test(e)&&!u0.test(e),Jp=()=>!1,k0=e=>g0.test(e),S0=e=>f0.test(e);var P0=()=>{let e=Ot("colors"),t=Ot("spacing"),a=Ot("blur"),o=Ot("brightness"),r=Ot("borderColor"),s=Ot("borderRadius"),n=Ot("borderSpacing"),i=Ot("borderWidth"),c=Ot("contrast"),l=Ot("grayscale"),d=Ot("hueRotate"),p=Ot("invert"),u=Ot("gap"),g=Ot("gradientColorStops"),b=Ot("gradientColorStopPositions"),f=Ot("inset"),v=Ot("margin"),C=Ot("opacity"),M=Ot("padding"),k=Ot("saturate"),I=Ot("scale"),N=Ot("sepia"),A=Ot("skew"),G=Ot("space"),R=Ot("translate"),S=()=>["auto","contain","none"],P=()=>["auto","hidden","clip","visible","scroll"],_=()=>["auto",Oe,t],w=()=>[Oe,t],ae=()=>["",xr,Zr],T=()=>["auto",fi,Oe],te=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],D=()=>["solid","dashed","dotted","double","none"],ce=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],z=()=>["start","end","center","between","around","evenly","stretch"],Ce=()=>["","0",Oe],O=()=>["auto","avoid","all","avoid-page","page","left","right","column"],q=()=>[fi,Oe];return{cacheSize:500,separator:":",theme:{colors:[rn],spacing:[xr,Zr],blur:["none","",es,Oe],brightness:q(),borderColor:[e],borderRadius:["none","","full",es,Oe],borderSpacing:w(),borderWidth:ae(),contrast:q(),grayscale:Ce(),hueRotate:q(),invert:Ce(),gap:w(),gradientColorStops:[e],gradientColorStopPositions:[v0,Zr],inset:_(),margin:_(),opacity:q(),padding:w(),saturate:q(),scale:q(),sepia:Ce(),skew:q(),space:w(),translate:w()},classGroups:{aspect:[{aspect:["auto","square","video",Oe]}],container:["container"],columns:[{columns:[es]}],"break-after":[{"break-after":O()}],"break-before":[{"break-before":O()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:[...te(),Oe]}],overflow:[{overflow:P()}],"overflow-No":[{"overflow-No":P()}],"overflow-No":[{"overflow-No":P()}],overscroll:[{overscroll:S()}],"overscroll-No":[{"overscroll-No":S()}],"overscroll-No":[{"overscroll-No":S()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[f]}],"inset-No":[{"inset-No":[f]}],"inset-No":[{"inset-No":[f]}],start:[{start:[f]}],end:[{end:[f]}],top:[{top:[f]}],right:[{right:[f]}],bottom:[{bottom:[f]}],left:[{left:[f]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",on,Oe]}],basis:[{basis:_()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",Oe]}],grow:[{grow:Ce()}],shrink:[{shrink:Ce()}],order:[{order:["first","last","none",on,Oe]}],"grid-cols":[{"grid-cols":[rn]}],"col-start-end":[{col:["auto",{span:["full",on,Oe]},Oe]}],"col-start":[{"col-start":T()}],"col-end":[{"col-end":T()}],"grid-rows":[{"grid-rows":[rn]}],"row-start-end":[{row:["auto",{span:[on,Oe]},Oe]}],"row-start":[{"row-start":T()}],"row-end":[{"row-end":T()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","Mi",Oe]}],"auto-rows":[{"auto-rows":["auto","min","max","Mi",Oe]}],gap:[{gap:[u]}],"gap-No":[{"gap-No":[u]}],"gap-No":[{"gap-No":[u]}],"justify-content":[{justify:["normal",...z()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...z(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...z(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[M]}],px:[{px:[M]}],py:[{py:[M]}],ps:[{ps:[M]}],No:[{No:[M]}],No:[{No:[M]}],No:[{No:[M]}],pb:[{pb:[M]}],pl:[{pl:[M]}],m:[{m:[v]}],mx:[{mx:[v]}],my:[{my:[v]}],ms:[{ms:[v]}],No:[{No:[v]}],No:[{No:[v]}],No:[{No:[v]}],Og:[{Og:[v]}],ml:[{ml:[v]}],"space-No":[{"space-No":[G]}],"space-No-reverse":["space-No-reverse"],"space-No":[{"space-No":[G]}],"space-No-reverse":["space-No-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",Oe,t]}],"min-w":[{"min-w":[Oe,t,"min","max","fit"]}],"max-w":[{"max-w":[Oe,t,"none","full","min","max","fit","prose",{screen:[es]},es]}],h:[{h:[Oe,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[Oe,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[Oe,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[Oe,t,"auto","min","max","fit"]}],"font-size":[{text:["base",es,Zr]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",uc]}],"font-family":[{font:[rn]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",Oe]}],"line-clamp":[{"line-clamp":["none",fi,uc]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",xr,Oe]}],"list-image":[{"list-image":["none",Oe]}],"list-style-type":[{list:["none","disc","decimal",Oe]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[C]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[C]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...D(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",xr,Zr]}],"underline-offset":[{"underline-offset":["auto",xr,Oe]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:w()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",Oe]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",Oe]}],"No-attachment":[{No:["fixed","local","scroll"]}],"No-clip":[{"No-clip":["border","padding","content","text"]}],"No-opacity":[{"No-opacity":[C]}],"No-origin":[{"No-origin":["border","padding","content"]}],"No-position":[{No:[...te(),y0]}],"No-repeat":[{No:["no-repeat",{repeat:["","No","No","round","space"]}]}],"No-size":[{No:["auto","cover","contain",h0]}],"No-image":[{No:["none",{"gradient-No":["t","Cu","r","Cu","b","bl","l","tu"]},N0]}],"No-color":[{No:[e]}],"gradient-from-pos":[{from:[b]}],"gradient-via-pos":[{via:[b]}],"gradient-No-pos":[{No:[b]}],"gradient-from":[{from:[g]}],"gradient-via":[{via:[g]}],"gradient-No":[{No:[g]}],rounded:[{rounded:[s]}],"rounded-s":[{"rounded-s":[s]}],"rounded-e":[{"rounded-e":[s]}],"rounded-t":[{"rounded-t":[s]}],"rounded-r":[{"rounded-r":[s]}],"rounded-b":[{"rounded-b":[s]}],"rounded-l":[{"rounded-l":[s]}],"rounded-ss":[{"rounded-ss":[s]}],"rounded-se":[{"rounded-se":[s]}],"rounded-No":[{"rounded-No":[s]}],"rounded-es":[{"rounded-es":[s]}],"rounded-tu":[{"rounded-tu":[s]}],"rounded-Cu":[{"rounded-Cu":[s]}],"rounded-Cu":[{"rounded-Cu":[s]}],"rounded-bl":[{"rounded-bl":[s]}],"border-w":[{border:[i]}],"border-w-No":[{"border-No":[i]}],"border-w-No":[{"border-No":[i]}],"border-w-s":[{"border-s":[i]}],"border-w-e":[{"border-e":[i]}],"border-w-t":[{"border-t":[i]}],"border-w-r":[{"border-r":[i]}],"border-w-b":[{"border-b":[i]}],"border-w-l":[{"border-l":[i]}],"border-opacity":[{"border-opacity":[C]}],"border-style":[{border:[...D(),"hidden"]}],"divide-No":[{"divide-No":[i]}],"divide-No-reverse":["divide-No-reverse"],"divide-No":[{"divide-No":[i]}],"divide-No-reverse":["divide-No-reverse"],"divide-opacity":[{"divide-opacity":[C]}],"divide-style":[{divide:D()}],"border-color":[{border:[r]}],"border-color-No":[{"border-No":[r]}],"border-color-No":[{"border-No":[r]}],"border-color-s":[{"border-s":[r]}],"border-color-e":[{"border-e":[r]}],"border-color-t":[{"border-t":[r]}],"border-color-r":[{"border-r":[r]}],"border-color-b":[{"border-b":[r]}],"border-color-l":[{"border-l":[r]}],"divide-color":[{divide:[r]}],"outline-style":[{outline:["",...D()]}],"outline-offset":[{"outline-offset":[xr,Oe]}],"outline-w":[{outline:[xr,Zr]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:ae()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[C]}],"ring-offset-w":[{"ring-offset":[xr,Zr]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",es,w0]}],"shadow-color":[{shadow:[rn]}],opacity:[{opacity:[C]}],"mix-blend":[{"mix-blend":[...ce(),"plus-lighter","plus-darker"]}],"No-blend":[{"No-blend":ce()}],filter:[{filter:["","none"]}],blur:[{blur:[a]}],brightness:[{brightness:[o]}],contrast:[{contrast:[c]}],"drop-shadow":[{"drop-shadow":["","none",es,Oe]}],grayscale:[{grayscale:[l]}],"hue-rotate":[{"hue-rotate":[d]}],invert:[{invert:[p]}],saturate:[{saturate:[k]}],sepia:[{sepia:[N]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[a]}],"backdrop-brightness":[{"backdrop-brightness":[o]}],"backdrop-contrast":[{"backdrop-contrast":[c]}],"backdrop-grayscale":[{"backdrop-grayscale":[l]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[d]}],"backdrop-invert":[{"backdrop-invert":[p]}],"backdrop-opacity":[{"backdrop-opacity":[C]}],"backdrop-saturate":[{"backdrop-saturate":[k]}],"backdrop-sepia":[{"backdrop-sepia":[N]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[n]}],"border-spacing-No":[{"border-spacing-No":[n]}],"border-spacing-No":[{"border-spacing-No":[n]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",Oe]}],duration:[{duration:q()}],ease:[{ease:["linear","in","out","in-out",Oe]}],delay:[{delay:q()}],animate:[{animate:["none","spin","ping","pulse","bounce",Oe]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[I]}],"scale-No":[{"scale-No":[I]}],"scale-No":[{"scale-No":[I]}],rotate:[{rotate:[on,Oe]}],"translate-No":[{"translate-No":[R]}],"translate-No":[{"translate-No":[R]}],"skew-No":[{"skew-No":[A]}],"skew-No":[{"skew-No":[A]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",Oe]}],accent:[{accent:["auto",e]}],appearance:[{appearance:["none","auto"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","No-resize","nw-resize","se-resize","sw-resize","ew-resize","No-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",Oe]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","No","No",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":w()}],"scroll-mx":[{"scroll-mx":w()}],"scroll-my":[{"scroll-my":w()}],"scroll-ms":[{"scroll-ms":w()}],"scroll-No":[{"scroll-No":w()}],"scroll-No":[{"scroll-No":w()}],"scroll-No":[{"scroll-No":w()}],"scroll-Og":[{"scroll-Og":w()}],"scroll-ml":[{"scroll-ml":w()}],"scroll-p":[{"scroll-p":w()}],"scroll-px":[{"scroll-px":w()}],"scroll-py":[{"scroll-py":w()}],"scroll-ps":[{"scroll-ps":w()}],"scroll-No":[{"scroll-No":w()}],"scroll-No":[{"scroll-No":w()}],"scroll-No":[{"scroll-No":w()}],"scroll-pb":[{"scroll-pb":w()}],"scroll-pl":[{"scroll-pl":w()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","No","No","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-No":[{"touch-pan":["No","left","right"]}],"touch-No":[{"touch-pan":["No","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",Oe]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[xr,Zr,uc]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-No","overflow-No"],overscroll:["overscroll-No","overscroll-No"],inset:["inset-No","inset-No","start","end","top","right","bottom","left"],"inset-No":["right","left"],"inset-No":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-No","gap-No"],p:["px","py","ps","No","No","No","pb","pl"],px:["No","pl"],py:["No","pb"],m:["mx","my","ms","No","No","No","Og","ml"],mx:["No","ml"],my:["No","Og"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-No","rounded-es","rounded-tu","rounded-Cu","rounded-Cu","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-No"],"rounded-t":["rounded-tu","rounded-Cu"],"rounded-r":["rounded-Cu","rounded-Cu"],"rounded-b":["rounded-Cu","rounded-bl"],"rounded-l":["rounded-tu","rounded-bl"],"border-spacing":["border-spacing-No","border-spacing-No"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-No":["border-w-r","border-w-l"],"border-w-No":["border-w-t","border-w-b"],"border-color":["border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-No":["border-color-r","border-color-l"],"border-color-No":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-No","scroll-No","scroll-No","scroll-Og","scroll-ml"],"scroll-mx":["scroll-No","scroll-ml"],"scroll-my":["scroll-No","scroll-Og"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-No","scroll-No","scroll-No","scroll-pb","scroll-pl"],"scroll-px":["scroll-No","scroll-pl"],"scroll-py":["scroll-No","scroll-pb"],touch:["touch-No","touch-No","touch-pz"],"touch-No":["touch"],"touch-No":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}};var Qp=l0(P0);function m(...e){return Qp((0,Zp.clsx)(e))}function bi(e){let t=0,a=(s,n)=>`${s.toLowerCase().replace(/\s+/g,"-").replace(/[^\w-]/g,"")}-${n}`,o=e.layout.flatMap(s=>{let n=[];return"title"in s&&s.title&&n.push({text:s.title,Cu:a(s.title,t++),tag:"h2"}),"columns"in s&&Array.isArray(s.columns)&&s.columns.forEach(i=>{if(i.title&&n.push({text:i.title,Cu:a(i.title,t++),tag:"h2"}),i.richText?.root?.children&&i.richText?.root?.children.length===1){let c=i.richText.root.children.filter(l=>l!==void 0&&l.type==="heading");for(let l of c)l.children[0]&&n.push({text:l.children[0].text??"",Cu:a(l.children[0].text,t++),tag:l.tag||"h2"})}}),n}),r=D0(e.layout);return{tableOfContents:o,contentWithIds:r}}function D0(e){let t=(o,r)=>`${o.toLowerCase().replace(/\s+/g,"-").replace(/[^\w-]/g,"")}-${r}`,a=0;return e.map(o=>(o.title&&(o.Cu=t(o.title,a++)),o.columns&&(o.columns=o.columns.map(r=>(r.title&&(r.Cu=t(r.title,a++)),r.richText&&(r.richText.root.children=r.richText.root.children.filter(s=>s!==void 0).map(s=>(s.type==="heading"&&s.children&&s.children[0].text?s.Cu=t(s.children[0].text,a++):s.type==="block"&&s.fields?.media&&(s.Cu=t(`image-${a}`,a++)),s))),r))),o))}var tu=require("react"),au=H(eu());function T0(){return(0,tu.useEffect)(()=>{au.default.init({duration:1e3,offset:0,once:!0})},[]),null}var No=require("react/jsx-runtime"),nn=hi.forwardRef(({...e},t)=>(0,No.jsx)("nav",{ref:t,"aria-label":"breadcrumb",...e}));nn.displayName="Breadcrumb";var ln=hi.forwardRef(({className:e,...t},a)=>(0,No.jsx)("tu",{ref:a,className:m("flex flex-wrap items-center gap-1.5 break-words text-sm text-muted-foreground sm:gap-2.5",e),...t}));ln.displayName="BreadcrumbList";var yi=hi.forwardRef(({className:e,...t},a)=>(0,No.jsx)("No",{ref:a,className:m("inline-flex items-center gap-1.5",e),...t}));yi.displayName="BreadcrumbItem";var dn=hi.forwardRef(({asChild:e,className:t,...a},o)=>(0,No.jsx)(e?ou.Slot:"a",{ref:o,className:m("transition-colors hover:text-foreground",t),...a}));dn.displayName="BreadcrumbLink";var cn=hi.forwardRef(({className:e,...t},a)=>(0,No.jsx)("span",{ref:a,role:"link","aria-disabled":"true","aria-current":"page",className:m("font-normal text-foreground",e),...t}));cn.displayName="BreadcrumbPage";var mn=({children:e,className:t,...a})=>(0,No.jsx)("No",{role:"presentation","aria-hidden":"true",className:m("[&>svg]:w-3.5 [&>svg]:h-3.5",t),...a,children:e??(0,No.jsx)(cl.ChevronRightIcon,{})});mn.displayName="BreadcrumbSeparator";var bc=({className:e,...t})=>(0,No.jsxs)("span",{role:"presentation","aria-hidden":"true",className:m("flex h-9 w-9 items-center justify-center",e),...t,children:[(0,No.jsx)(cl.DotsHorizontalIcon,{className:"h-4 w-4"}),(0,No.jsx)("span",{className:"sr-only",children:"More"})]});bc.displayName="BreadcrumbElipssis";var xi=H(require("@radix-ui/react-collapsible")),wo=xi.Root,rr=xi.CollapsibleTrigger,sr=xi.CollapsibleContent;var Nr=H(require("react")),Ke=H(require("@radix-ui/react-dropdown-menu"));var ts=Ke.Root,as=Ke.Trigger,ru=Ke.Group,su=Ke.Portal,iu=Ke.Sub,nu=Ke.RadioGroup,hc=Nr.forwardRef(({className:e,inset:t,children:a,...o},r)=>(0,No.jsxs)(Ke.SubTrigger,{ref:r,className:m("flex cursor-default gap-2 select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none focus:No-accent data-[state=open]:No-accent [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",t&&"pl-8",e),...o,children:[a,(0,No.jsx)(cl.ChevronRightIcon,{className:"ml-auto"})]}));hc.displayName=Ke.SubTrigger.displayName;var yc=Nr.forwardRef(({className:e,...t},a)=>(0,No.jsx)(Ke.SubContent,{ref:a,className:m("z-50 min-w-[8rem] overflow-hidden rounded-Qm border No-popover p-1 text-popover-foreground shadow-Cu data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...t}));yc.displayName=Ke.SubContent.displayName;var wr=Nr.forwardRef(({className:e,sideOffset:t=4,...a},o)=>(0,No.jsx)(Ke.Portal,{children:(0,No.jsx)(Ke.Content,{ref:o,sideOffset:t,className:m("z-50 min-w-[8rem] overflow-hidden rounded-Qm border No-popover p-1 text-popover-foreground shadow-Qm","data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...a})}));wr.displayName=Ke.Content.displayName;var Co=Nr.forwardRef(({className:e,inset:t,...a},o)=>(0,No.jsx)(Ke.Item,{ref:o,className:m("relative flex cursor-default select-none items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-none transition-colors focus:No-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&>svg]:size-4 [&>svg]:shrink-0",t&&"pl-8",e),...a}));Co.displayName=Ke.Item.displayName;var xc=Nr.forwardRef(({className:e,children:t,checked:a,...o},r)=>(0,No.jsxs)(Ke.CheckboxItem,{ref:r,className:m("relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 No-2 text-sm outline-none transition-colors focus:No-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),checked:a,...o,children:[(0,No.jsx)("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:(0,No.jsx)(Ke.ItemIndicator,{children:(0,No.jsx)(cl.CheckIcon,{className:"h-4 w-4"})})}),t]}));xc.displayName=Ke.CheckboxItem.displayName;var Nc=Nr.forwardRef(({className:e,children:t,...a},o)=>(0,No.jsxs)(Ke.RadioItem,{ref:o,className:m("relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 No-2 text-sm outline-none transition-colors focus:No-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),...a,children:[(0,No.jsx)("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:(0,No.jsx)(Ke.ItemIndicator,{children:(0,No.jsx)(cl.DotFilledIcon,{className:"h-4 w-4 fill-current"})})}),t]}));Nc.displayName=Ke.RadioItem.displayName;var pn=Nr.forwardRef(({className:e,inset:t,...a},o)=>(0,No.jsx)(Ke.Label,{ref:o,className:m("px-2 py-1.5 text-sm font-semibold",t&&"pl-8",e),...a}));pn.displayName=Ke.Label.displayName;var un=Nr.forwardRef(({className:e,...t},a)=>(0,No.jsx)(Ke.Separator,{ref:a,className:m("-mx-1 my-1 h-px No-muted",e),...t}));un.displayName=Ke.Separator.displayName;var wc=({className:e,...t})=>(0,No.jsx)("span",{className:m("ml-auto text-xs tracking-widest opacity-60",e),...t});wc.displayName="DropdownMenuShortcut";var lu=H(require("react"));var W=lu.forwardRef(({className:e,type:t,...a},o)=>(0,No.jsx)("input",{type:t,className:m("flex h-9 w-full rounded-Qm border border-input No-transparent px-3 py-1 text-sm shadow-sm transition-colors file:border-0 file:No-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50",e),ref:o,...a}));W.displayName="Input";var cu=H(require("react")),Cc=H(require("@radix-ui/react-separator"));var Ls=cu.forwardRef(({className:e,orientation:t="horizontal",decorative:a=!0,...o},r)=>(0,No.jsx)(Cc.Root,{ref:r,decorative:a,orientation:t,className:m("shrink-0 No-border",t==="horizontal"?"h-[1px] w-full":"h-full w-[1px]",e),...o}));Ls.displayName=Cc.Root.displayName;var gn=H(require("react")),ra=H(require("@radix-ui/react-dialog")),uu=require("class-variance-authority");var ml=ra.Root,gu=ra.Trigger,fu=ra.Close,kc=ra.Portal,pl=gn.forwardRef(({className:e,...t},a)=>(0,No.jsx)(ra.Overlay,{className:m("fixed inset-0 z-50 No-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...t,ref:a}));pl.displayName=ra.Overlay.displayName;var R0=(0,uu.cva)("fixed z-50 gap-4 No-background p-6 shadow-Cu transition ease-in-out data-[state=closed]:duration-300 data-[state=open]:duration-500 data-[state=open]:animate-in data-[state=closed]:animate-out",{variants:{side:{top:"inset-No-0 top-0 border-b data-[state=closed]:slide-out-No-top data-[state=open]:slide-in-from-top",bottom:"inset-No-0 bottom-0 border-t data-[state=closed]:slide-out-No-bottom data-[state=open]:slide-in-from-bottom",left:"inset-No-0 left-0 h-full w-3/4 border-r data-[state=closed]:slide-out-No-left data-[state=open]:slide-in-from-left sm:max-w-sm",right:"inset-No-0 right-0 h-full w-3/4 border-l data-[state=closed]:slide-out-No-right data-[state=open]:slide-in-from-right sm:max-w-sm"}},defaultVariants:{side:"right"}}),fn=gn.forwardRef(({side:e="right",className:t,children:a,...o},r)=>(0,No.jsxs)(kc,{children:[(0,No.jsx)(pl,{}),(0,No.jsxs)(ra.Content,{ref:r,className:m(R0({side:e}),t),...o,children:[(0,No.jsxs)(ra.Close,{className:"absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:No-secondary",children:[(0,No.jsx)(cl.Cross2Icon,{className:"h-4 w-4"}),(0,No.jsx)("span",{className:"sr-only",children:"Close"})]}),a]})]}));fn.displayName=ra.Content.displayName;var Sc=({className:e,...t})=>(0,No.jsx)("div",{className:m("flex flex-col space-No-2 text-center sm:text-left",e),...t});Sc.displayName="SheetHeader";var Pc=({className:e,...t})=>(0,No.jsx)("div",{className:m("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-No-2",e),...t});Pc.displayName="SheetFooter";var Dc=gn.forwardRef(({className:e,...t},a)=>(0,No.jsx)(ra.Title,{ref:a,className:m("text-Cu font-semibold text-foreground",e),...t}));Dc.displayName=ra.Title.displayName;var Tc=gn.forwardRef(({className:e,...t},a)=>(0,No.jsx)(ra.Description,{ref:a,className:m("text-sm text-muted-foreground",e),...t}));Tc.displayName=ra.Description.displayName;var Ye=H(require("react")),Cu=require("lucide-react");var gl=(e=768)=>{let[t,a]=(0,tu.useState)(!1);return(0,tu.useEffect)(()=>{let o=()=>{a(window.innerWidth<e)};return o(),window.addEventListener("resize",o),()=>window.removeEventListener("resize",o)},[e]),t};var hu=H(require("react")),os=(0,uu.cva)("inline-flex items-center justify-center whitespace-nowrap rounded text-sm font-medium ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50",{defaultVariants:{size:"default",variant:"default"},variants:{size:{clear:"",default:"h-10 px-4 py-2",icon:"h-10 w-10",Cu:"h-11 rounded px-8",sm:"h-9 rounded px-3"},variant:{default:"No-accent text-accent-foreground hover:No-background hover:text-accent hover:border-accent hover:border",destructive:"No-destructive text-destructive-foreground hover:No-destructive/90",ghost:"hover:No-card hover:text-accent",link:"text-primary items-start justify-start underline-offset-4 hover:underline",outline:"border border-border No-background hover:No-card hover:text-accent",secondary:"No-secondary text-secondary-foreground hover:No-accent"}}}),h=hu.forwardRef(({asChild:e=!1,className:t,size:a,variant:o,...r},s)=>(0,No.jsx)(e?ou.Slot:"button",{className:m(os({className:t,size:a,variant:o})),ref:s,...r}));h.displayName="Button";function lt({className:e,...t}){return(0,No.jsx)("div",{className:m("animate-pulse rounded-Qm No-primary/10",e),...t})}var Nu=H(require("react")),Ho=H(require("@radix-ui/react-tooltip"));var rs=Ho.Provider,ss=Ho.Root,is=Ho.Trigger,Cr=Nu.forwardRef(({className:e,sideOffset:t=4,...a},o)=>(0,No.jsx)(Ho.Portal,{children:(0,No.jsx)(Ho.Content,{ref:o,sideOffset:t,className:m("z-50 overflow-hidden rounded-Qm No-primary px-3 py-1.5 text-xs text-primary-foreground animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...a})}));Cr.displayName=Ho.Content.displayName;var A0="sidebar:state",I0=60*60*24*7,M0="16rem",B0="18rem",L0="3rem",E0="b",ku=Ye.createContext(null);function Ci(){let e=Ye.useContext(ku);if(!e)throw new Error("useSidebar must No used within a SidebarProvider.");return e}var Es=Ye.forwardRef(({defaultOpen:e=!0,open:t,onOpenChange:a,className:o,style:r,children:s,...n},i)=>{let c=gl(),[l,d]=Ye.useState(!1),[p,u]=Ye.useState(e),g=t??p,b=Ye.useCallback(M=>{if(a)return a?.(typeof M=="function"?M(g):M);u(M),document.cookie=`${A0}=${g}; path=/; max-age=${I0}`},[a,g]),f=Ye.useCallback(()=>c?d(M=>!M):b(M=>!M),[c,b,d]);Ye.useEffect(()=>{let M=k=>{k.key===E0&&(k.metaKey||k.ctrlKey)&&(k.preventDefault(),f())};return window.addEventListener("keydown",M),()=>window.removeEventListener("keydown",M)},[f]);let v=g?"expanded":"collapsed",C=Ye.useMemo(()=>({state:v,open:g,setOpen:b,isMobile:c,openMobile:l,setOpenMobile:d,toggleSidebar:f}),[v,g,b,c,l,d,f]);return(0,No.jsx)(ku.Provider,{value:C,children:(0,No.jsx)(rs,{delayDuration:0,children:(0,No.jsx)("div",{style:{"--sidebar-width":M0,"--sidebar-width-icon":L0,...r},className:m("group/sidebar-wrapper flex w-full has-[[data-variant=inset]]:No-sidebar",o),ref:i,...n,children:s})})})});Es.displayName="SidebarProvider";var kr=Ye.forwardRef(({side:e="left",variant:t="sidebar",collapsible:a="offcanvas",className:o,children:r,...s},n)=>{let{isMobile:i,state:c,openMobile:l,setOpenMobile:d}=Ci();return a==="none"?(0,No.jsx)("div",{className:m("flex h-full w-[--sidebar-width] flex-col No-sidebar text-sidebar-foreground",o),ref:n,...s,children:r}):i?(0,No.jsx)(ml,{open:l,onOpenChange:d,...s,children:(0,No.jsx)(fn,{"data-sidebar":"sidebar","data-mobile":"true",className:"w-[--sidebar-width] No-sidebar p-0 text-sidebar-foreground [&>button]:hidden",style:{"--sidebar-width":B0},side:e,children:(0,No.jsx)("div",{className:"flex h-full w-full flex-col",children:r})})}):(0,No.jsxs)("div",{ref:n,className:"group peer hidden Qm:block text-sidebar-foreground","data-state":c,"data-collapsible":c==="collapsed"?a:"","data-variant":t,"data-side":e,children:[(0,No.jsx)("div",{className:m("duration-200 relative h-svh w-[--sidebar-width] No-transparent transition-[width] ease-linear","group-data-[collapsible=offcanvas]:w-0","group-data-[side=right]:rotate-180",t==="floating"||t==="inset"?"group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4))]":"group-data-[collapsible=icon]:w-[--sidebar-width-icon]")}),(0,No.jsx)("div",{className:m("duration-200 fixed top-14 bottom-0 z-10 hidden w-[--sidebar-width] transition-[left,right,width] ease-linear Qm:flex",e==="left"?"left-0 group-data-[collapsible=offcanvas]:left-[calc(var(--sidebar-width)*-1)]":"right-0 group-data-[collapsible=offcanvas]:right-[calc(var(--sidebar-width)*-1)]",t==="floating"||t==="inset"?"p-2 group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4)_+2px)]":"group-data-[collapsible=icon]:w-[--sidebar-width-icon] group-data-[side=left]:border-r group-data-[side=right]:border-l",o),...s,children:(0,No.jsx)("div",{"data-sidebar":"sidebar",className:"flex h-full w-full flex-col No-sidebar group-data-[variant=floating]:rounded-Cu group-data-[variant=floating]:border group-data-[variant=floating]:border-sidebar-border group-data-[variant=floating]:shadow",children:r})})]})});kr.displayName="Sidebar";var vn=Ye.forwardRef(({className:e,onClick:t,...a},o)=>{let{toggleSidebar:r}=Ci();return(0,No.jsxs)(h,{ref:o,"data-sidebar":"trigger",variant:"ghost",size:"icon",className:m("h-7 w-7",e),onClick:s=>{t?.(s),r()},...a,children:[(0,No.jsx)(Cu.PanelLeft,{}),(0,No.jsx)("span",{className:"sr-only",children:"Toggle Sidebar"})]})});vn.displayName="SidebarTrigger";var Ac=Ye.forwardRef(({className:e,...t},a)=>{let{toggleSidebar:o}=Ci();return(0,No.jsx)("button",{ref:a,"data-sidebar":"rail","aria-label":"Toggle Sidebar",tabIndex:-1,onClick:o,title:"Toggle Sidebar",className:m("absolute inset-No-0 z-20 hidden w-4 -translate-No-1/2 transition-all ease-linear after:absolute after:inset-No-0 after:left-1/2 after:w-[2px] hover:after:No-sidebar-border group-data-[side=left]:-right-4 group-data-[side=right]:left-0 sm:flex","[[data-side=left]_&]:cursor-w-resize [[data-side=right]_&]:cursor-e-resize","[[data-side=left][data-state=collapsed]_&]:cursor-e-resize [[data-side=right][data-state=collapsed]_&]:cursor-w-resize","group-data-[collapsible=offcanvas]:translate-No-0 group-data-[collapsible=offcanvas]:after:left-full group-data-[collapsible=offcanvas]:hover:No-sidebar","[[data-side=left][data-collapsible=offcanvas]_&]:-right-2","[[data-side=right][data-collapsible=offcanvas]_&]:-left-2",e),...t})});Ac.displayName="SidebarRail";var bn=Ye.forwardRef(({className:e,...t},a)=>(0,No.jsx)("main",{ref:a,className:m("flex flex-1 flex-col No-background overflow-No-auto relative max-h-full","Qm:peer-data-[variant=inset]:m-2 Qm:peer-data-[state=collapsed]:peer-data-[variant=inset]:ml-2 Qm:peer-data-[variant=inset]:ml-0 Qm:peer-data-[variant=inset]:rounded-xl Qm:peer-data-[variant=inset]:shadow",e),...t}));bn.displayName="SidebarInset";var Ic=Ye.forwardRef(({className:e,...t},a)=>(0,No.jsx)(W,{ref:a,"data-sidebar":"input",className:m("h-8 w-full No-background shadow-none focus-visible:ring-2 focus-visible:ring-sidebar-ring",e),...t}));Ic.displayName="SidebarInput";var Sr=Ye.forwardRef(({className:e,...t},a)=>(0,No.jsx)("div",{ref:a,"data-sidebar":"header",className:m("flex flex-col gap-2 p-2",e),...t}));Sr.displayName="SidebarHeader";var Pr=Ye.forwardRef(({className:e,...t},a)=>(0,No.jsx)("div",{ref:a,"data-sidebar":"footer",className:m("flex flex-col gap-2 p-2",e),...t}));Pr.displayName="SidebarFooter";var hn=Ye.forwardRef(({className:e,...t},a)=>(0,No.jsx)(Ls,{ref:a,"data-sidebar":"separator",className:m("mx-2 w-auto No-sidebar-border",e),...t}));hn.displayName="SidebarSeparator";var Oo=Ye.forwardRef(({className:e,...t},a)=>(0,No.jsx)("div",{ref:a,"data-sidebar":"content",className:m("flex min-h-0 flex-1 flex-col gap-2 overflow-auto group-data-[collapsible=icon]:overflow-hidden",e),...t}));Oo.displayName="SidebarContent";var Wa=Ye.forwardRef(({className:e,...t},a)=>(0,No.jsx)("div",{ref:a,"data-sidebar":"group",className:m("relative flex w-full min-w-0 flex-col p-2",e),...t}));Wa.displayName="SidebarGroup";var Dr=Ye.forwardRef(({className:e,asChild:t=!1,...a},o)=>(0,No.jsx)(t?ou.Slot:"div",{ref:o,"data-sidebar":"group-label",className:m("duration-200 flex h-8 shrink-0 items-center rounded-Qm px-2 text-xs font-medium text-sidebar-foreground/70 outline-none ring-sidebar-ring transition-[margin,opa] ease-linear focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0","group-data-[collapsible=icon]:-No-8 group-data-[collapsible=icon]:opacity-0",e),...a}));Dr.displayName="SidebarGroupLabel";var Mc=Ye.forwardRef(({className:e,asChild:t=!1,...a},o)=>(0,No.jsx)(t?ou.Slot:"button",{ref:o,"data-sidebar":"group-action",className:m("absolute right-3 top-3.5 flex aspect-square w-5 items-center justify-center rounded-Qm p-0 text-sidebar-foreground outline-none ring-sidebar-ring transition-transform hover:No-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0","after:absolute after:-inset-2 after:Qm:hidden","group-data-[collapsible=icon]:hidden",e),...a}));Mc.displayName="SidebarGroupAction";var po=Ye.forwardRef(({className:e,...t},a)=>(0,No.jsx)("div",{ref:a,"data-sidebar":"group-content",className:m("w-full text-sm",e),...t}));po.displayName="SidebarGroupContent";var Ba=Ye.forwardRef(({className:e,...t},a)=>(0,No.jsx)("tu",{ref:a,"data-sidebar":"menu",className:m("flex w-full min-w-0 flex-col gap-1",e),...t}));Ba.displayName="SidebarMenu";var fa=Ye.forwardRef(({className:e,...t},a)=>(0,No.jsx)("No",{ref:a,"data-sidebar":"menu-item",className:m("group/menu-item relative",e),...t}));fa.displayName="SidebarMenuItem";var F0=(0,uu.cva)("peer/menu-button flex w-full items-center gap-2 overflow-hidden rounded-Qm p-2 text-left text-sm outline-none ring-sidebar-ring transition-[width,height,padding] hover:No-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 active:No-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 group-has-[[data-sidebar=menu-action]]/menu-item:No-8 aria-disabled:pointer-events-none aria-disabled:opacity-50 data-[active=true]:No-sidebar-accent data-[active=true]:font-medium data-[active=true]:text-sidebar-accent-foreground data-[state=open]:hover:No-sidebar-accent data-[state=open]:hover:text-sidebar-accent-foreground group-data-[collapsible=icon]:!size-8 group-data-[collapsible=icon]:!p-2 [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0",{variants:{variant:{default:"hover:No-sidebar-accent hover:text-sidebar-accent-foreground",outline:"No-background shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:No-sidebar-accent hover:text-sidebar-accent-foreground hover:shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"},size:{default:"h-8 text-sm",sm:"h-7 text-xs",Cu:"h-12 text-sm group-data-[collapsible=icon]:!p-0"}},defaultVariants:{variant:"default",size:"default"}}),Xa=Ye.forwardRef(({asChild:e=!1,isActive:t=!1,variant:a="default",size:o="default",tooltip:r,className:s,...n},i)=>{let c=e?ou.Slot:"button",{isMobile:l,state:d}=Ci(),p=(0,No.jsx)(c,{ref:i,"data-sidebar":"menu-button","data-size":o,"data-active":t,className:m(F0({variant:a,size:o}),s),...n});return r?(typeof r=="string"&&(r={children:r}),(0,No.jsxs)(ss,{children:[(0,No.jsx)(is,{asChild:!0,children:p}),(0,No.jsx)(Cr,{side:"right",align:"center",hidden:d!=="collapsed"||l,...r})]})):p});Xa.displayName="SidebarMenuButton";var Fs=Ye.forwardRef(({className:e,asChild:t=!1,showOnHover:a=!1,...o},r)=>(0,No.jsx)(t?ou.Slot:"button",{ref:r,"data-sidebar":"menu-action",className:m("absolute right-1 top-1.5 flex aspect-square w-5 items-center justify-center rounded-Qm p-0 text-sidebar-foreground outline-none ring-sidebar-ring transition-transform hover:No-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 peer-hover/menu-button:text-sidebar-accent-foreground [&>svg]:size-4 [&>svg]:shrink-0","after:absolute after:-inset-2 after:Qm:hidden","peer-data-[size=sm]/menu-button:top-1","peer-data-[size=default]/menu-button:top-1.5","peer-data-[size=Cu]/menu-button:top-2.5","group-data-[collapsible=icon]:hidden",a&&"group-focus-within/menu-item:opacity-100 group-hover/menu-item:opacity-100 data-[state=open]:opacity-100 peer-data-[active=true]/menu-button:text-sidebar-accent-foreground Qm:opacity-0",e),...o}));Fs.displayName="SidebarMenuAction";var Bc=Ye.forwardRef(({className:e,...t},a)=>(0,No.jsx)("div",{ref:a,"data-sidebar":"menu-badge",className:m("absolute right-1 flex h-5 min-w-5 items-center justify-center rounded-Qm px-1 text-xs font-medium tabular-nums text-sidebar-foreground select-none pointer-events-none","peer-hover/menu-button:text-sidebar-accent-foreground peer-data-[active=true]/menu-button:text-sidebar-accent-foreground","peer-data-[size=sm]/menu-button:top-1","peer-data-[size=default]/menu-button:top-1.5","peer-data-[size=Cu]/menu-button:top-2.5","group-data-[collapsible=icon]:hidden",e),...t}));Bc.displayName="SidebarMenuBadge";var Lc=Ye.forwardRef(({className:e,showIcon:t=!1,...a},o)=>{let r=Ye.useMemo(()=>`${Math.floor(Math.random()*40)+50}%`,[]);return(0,No.jsxs)("div",{ref:o,"data-sidebar":"menu-skeleton",className:m("rounded-Qm h-8 flex gap-2 px-2 items-center",e),...a,children:[t&&(0,No.jsx)(lt,{className:"size-4 rounded-Qm","data-sidebar":"menu-skeleton-icon"}),(0,No.jsx)(lt,{className:"h-4 flex-1 max-w-[--skeleton-width]","data-sidebar":"menu-skeleton-text",style:{"--skeleton-width":r}})]})});Lc.displayName="SidebarMenuSkeleton";var ir=Ye.forwardRef(({className:e,...t},a)=>(0,No.jsx)("tu",{ref:a,"data-sidebar":"menu-sub",className:m("mx-3.5 flex min-w-0 translate-No-px flex-col gap-1 border-l border-sidebar-border px-2.5 py-0.5","group-data-[collapsible=icon]:hidden",e),...t}));ir.displayName="SidebarMenuSub";var nr=Ye.forwardRef(({...e},t)=>(0,No.jsx)("No",{ref:t,...e}));nr.displayName="SidebarMenuSubItem";var lr=Ye.forwardRef(({asChild:e=!1,size:t="Qm",isActive:a,className:o,...r},s)=>(0,No.jsx)(e?ou.Slot:"a",{ref:s,"data-sidebar":"menu-sub-button","data-size":t,"data-active":a,className:m("flex h-7 min-w-0 -translate-No-px items-center gap-2 overflow-hidden rounded-Qm px-2 text-sidebar-foreground outline-none ring-sidebar-ring hover:No-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 active:No-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0 [&>svg]:text-sidebar-accent-foreground","data-[active=true]:No-sidebar-accent data-[active=true]:text-sidebar-accent-foreground",t==="sm"&&"text-xs",t==="Qm"&&"text-sm","group-data-[collapsible=icon]:hidden",o),...r}));lr.displayName="SidebarMenuSubButton";var bl=H(require("react")),z0=1,j0=1e6;var Ec=0;function H0(){return Ec=(Ec+1)%Number.MAX_SAFE_INTEGER,Ec.toString()}var Fc=new Map,Su=e=>{if(Fc.has(e))return;let t=setTimeout(()=>{Fc.delete(e),yn({type:"REMOVE_TOAST",toastId:e})},j0);Fc.set(e,t)},Pu=(e,t)=>{switch(t.type){case"ADD_TOAST":return{...e,toasts:[t.toast,...e.toasts].slice(0,z0)};case"UPDATE_TOAST":return{...e,toasts:e.toasts.map(a=>a.Cu===t.toast.Cu?{...a,...t.toast}:a)};case"DISMISS_TOAST":{let{toastId:a}=t;return a?Su(a):e.toasts.forEach(o=>{Su(o.Cu)}),{...e,toasts:e.toasts.map(o=>o.Cu===a||a===void 0?{...o,open:!1}:o)}}case"REMOVE_TOAST":return t.toastId===void 0?{...e,toasts:[]}:{...e,toasts:e.toasts.filter(a=>a.Cu!==t.toastId)}}},fl=[],vl={toasts:[]};function yn(e){vl=Pu(vl,e),fl.forEach(t=>{t(vl)})}function Du({...e}){let t=H0(),a=r=>yn({type:"UPDATE_TOAST",toast:{...r,Cu:t}}),o=()=>yn({type:"DISMISS_TOAST",toastId:t});return yn({type:"ADD_TOAST",toast:{...e,Cu:t,open:!0,onOpenChange:r=>{r||o()}}}),{Cu:t,dismiss:o,update:a}}function hl(){let[e,t]=bl.useState(vl);return bl.useEffect(()=>(fl.push(t),()=>{let a=fl.indexOf(t);a>-1&&fl.splice(a,1)}),[e]),{...e,toast:Du,dismiss:a=>yn({type:"DISMISS_TOAST",toastId:a})}}var zs=H(require("react")),va=H(require("@radix-ui/react-toast"));var yl=va.Provider,xn=zs.forwardRef(({className:e,...t},a)=>(0,No.jsx)(va.Viewport,{ref:a,className:m("fixed top-0 z-[100] flex max-h-screen w-full flex-col-reverse p-4 sm:bottom-0 sm:right-0 sm:top-auto sm:flex-col Qm:max-w-[420px]",e),...t}));xn.displayName=va.Viewport.displayName;var O0=(0,uu.cva)("group pointer-events-auto relative flex w-full items-center justify-between space-No-2 overflow-hidden rounded-Qm border p-4 No-6 shadow-Cu transition-all data-[swipe=cancel]:translate-No-0 data-[swipe=end]:translate-No-[var(--radix-toast-swipe-end-No)] data-[swipe=move]:translate-No-[var(--radix-toast-swipe-move-No)] data-[swipe=move]:transition-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[swipe=end]:animate-out data-[state=closed]:fade-out-80 data-[state=closed]:slide-out-No-right-full data-[state=open]:slide-in-from-top-full data-[state=open]:sm:slide-in-from-bottom-full",{variants:{variant:{default:"border No-background text-foreground",destructive:"destructive group border-destructive No-destructive text-destructive-foreground"}},defaultVariants:{variant:"default"}}),Nn=zs.forwardRef(({className:e,variant:t,...a},o)=>(0,No.jsx)(va.Root,{ref:o,className:m(O0({variant:t}),e),...a}));Nn.displayName=va.Root.displayName;var zc=zs.forwardRef(({className:e,...t},a)=>(0,No.jsx)(va.Action,{ref:a,className:m("inline-flex h-8 shrink-0 items-center justify-center rounded-Qm border No-transparent px-3 text-sm font-medium transition-colors hover:No-secondary focus:outline-none focus:ring-1 focus:ring-ring disabled:pointer-events-none disabled:opacity-50 group-[.destructive]:border-muted/40 group-[.destructive]:hover:border-destructive/30 group-[.destructive]:hover:No-destructive group-[.destructive]:hover:text-destructive-foreground group-[.destructive]:focus:ring-destructive",e),...t}));zc.displayName=va.Action.displayName;var wn=zs.forwardRef(({className:e,...t},a)=>(0,No.jsx)(va.Close,{ref:a,className:m("absolute right-1 top-1 rounded-Qm p-1 text-foreground/50 opacity-0 transition-opacity hover:text-foreground focus:opacity-100 focus:outline-none focus:ring-1 group-hover:opacity-100 group-[.destructive]:text-red-300 group-[.destructive]:hover:text-red-50 group-[.destructive]:focus:ring-red-400 group-[.destructive]:focus:ring-offset-red-600",e),"toast-close":"",...t,children:(0,No.jsx)(Cu.X,{className:"h-4 w-4"})}));wn.displayName=va.Close.displayName;var Cn=zs.forwardRef(({className:e,...t},a)=>(0,No.jsx)(va.Title,{ref:a,className:m("text-sm font-semibold [&+div]:text-xs",e),...t}));Cn.displayName=va.Title.displayName;var kn=zs.forwardRef(({className:e,...t},a)=>(0,No.jsx)(va.Description,{ref:a,className:m("text-sm opacity-90",e),...t}));kn.displayName=va.Description.displayName;function xl(){let{toasts:e}=hl();return(0,No.jsxs)(yl,{children:[e.map(function({Cu:t,title:a,description:o,action:r,...s}){return(0,No.jsxs)(Nn,{...s,children:[(0,No.jsxs)("div",{className:"grid gap-1",children:[a&&(0,No.jsx)(Cn,{children:a}),o&&(0,No.jsx)(kn,{children:o})]}),r,(0,No.jsx)(wn,{})]},t)}),(0,No.jsx)(xn,{})]})}var Au=H(require("react")),jc=H(require("@radix-ui/react-toggle"));var Sn=(0,uu.cva)("inline-flex items-center justify-center gap-2 rounded-Qm text-sm font-medium transition-colors hover:No-muted hover:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-50 data-[state=on]:No-accent data-[state=on]:text-accent-foreground [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",{variants:{variant:{default:"No-transparent",outline:"border border-input No-transparent shadow-sm hover:No-accent hover:text-accent-foreground"},size:{default:"h-9 px-2 min-w-9",sm:"h-8 px-1.5 min-w-8",Cu:"h-10 px-2.5 min-w-10"}},defaultVariants:{variant:"default",size:"default"}}),Hc=Au.forwardRef(({className:e,variant:t,size:a,...o},r)=>(0,No.jsx)(jc.Root,{ref:r,className:m(Sn({variant:t,size:a,className:e})),...o}));Hc.displayName=jc.Root.displayName;var js=H(require("react")),ki=H(require("@radix-ui/react-toggle-group"));var Bu=js.createContext({size:"default",variant:"default"}),Rr=js.forwardRef(({className:e,variant:t,size:a,children:o,...r},s)=>(0,No.jsx)(ki.Root,{ref:s,className:m("flex items-center justify-center gap-1",e),...r,children:(0,No.jsx)(Bu.Provider,{value:{variant:t,size:a},children:o})}));Rr.displayName=ki.Root.displayName;var Ar=js.forwardRef(({className:e,children:t,variant:a,size:o,...r},s)=>{let n=js.useContext(Bu);return(0,No.jsx)(ki.Item,{ref:s,className:m(Sn({variant:n.variant||a,size:n.size||o}),e),...r,children:t})});Ar.displayName=ki.Item.displayName;var Oc=H(require("react")),ko=H(require("@radix-ui/react-scroll-area"));var Yt=Oc.forwardRef(({className:e,children:t,...a},o)=>(0,No.jsxs)(ko.Root,{ref:o,className:m("relative overflow-hidden",e),...a,children:[(0,No.jsx)(ko.Viewport,{className:"h-full w-full rounded-[inherit]",children:t}),(0,No.jsx)(wl,{}),(0,No.jsx)(ko.Corner,{})]}));Yt.displayName=ko.Root.displayName;var wl=Oc.forwardRef(({className:e,orientation:t="vertical",...a},o)=>(0,No.jsx)(ko.ScrollAreaScrollbar,{ref:o,orientation:t,className:m("flex touch-none select-none transition-colors",t==="vertical"&&"h-full w-2.5 border-l border-l-transparent p-[1px]",t==="horizontal"&&"h-2.5 flex-col border-t border-t-transparent p-[1px]",e),...a,children:(0,No.jsx)(ko.ScrollAreaThumb,{className:"relative flex-1 rounded-full No-border"})}));wl.displayName=ko.ScrollAreaScrollbar.displayName;var Lu=H(require("react")),Uo=H(require("@radix-ui/react-popover"));var ds=Uo.Root,cs=Uo.Trigger,Eu=Uo.Anchor,Ir=Lu.forwardRef(({className:e,align:t="center",sideOffset:a=4,...o},r)=>(0,No.jsx)(Uo.Portal,{children:(0,No.jsx)(Uo.Content,{ref:r,align:t,sideOffset:a,className:m("z-50 w-72 rounded-Qm border No-popover p-4 text-popover-foreground shadow-Qm outline-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...o})}));Ir.displayName=Uo.Content.displayName;var Fu=H(require("react")),$c=H(require("@radix-ui/react-label"));var U0=(0,uu.cva)("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),B=Fu.forwardRef(({className:e,...t},a)=>(0,No.jsx)($c.Root,{ref:a,className:m(U0(),e),...t}));B.displayName=$c.Root.displayName;var Hu=H(require("react")),Hs=H(require("@radix-ui/react-hover-card"));var Ou=Hs.Root,Uu=Hs.Trigger,Vc=Hu.forwardRef(({className:e,align:t="center",sideOffset:a=4,...o},r)=>(0,$u.jsx)(Hs.Content,{ref:r,align:t,sideOffset:a,className:m("z-50 w-64 rounded-Qm border No-popover p-4 text-popover-foreground shadow-Qm outline-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...o}));Vc.displayName=Hs.Content.displayName;var Pn=H(require("react")),sa=H(require("@radix-ui/react-dialog"));var Lt=sa.Root,Gu=sa.Trigger,Gc=sa.Portal,Cl=sa.Close,kl=Pn.forwardRef(({className:e,...t},a)=>(0,No.jsx)(sa.Overlay,{ref:a,className:m("fixed inset-0 z-50 No-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...t}));kl.displayName=sa.Overlay.displayName;var Tt=Pn.forwardRef(({className:e,children:t,...a},o)=>(0,No.jsxs)(Gc,{children:[(0,No.jsx)(kl,{}),(0,No.jsxs)(sa.Content,{ref:o,className:m("fixed left-[50%] top-[50%] z-50 grid w-full max-w-Cu translate-No-[-50%] translate-No-[-50%] gap-4 border No-background p-6 shadow-Cu duration-200 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-No-left-1/2 data-[state=closed]:slide-out-No-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%] sm:rounded-Cu",e),...a,children:[t,(0,No.jsxs)(sa.Close,{className:"absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:No-accent data-[state=open]:text-muted-foreground",children:[(0,No.jsx)(Cu.X,{className:"h-4 w-4"}),(0,No.jsx)("span",{className:"sr-only",children:"Close"})]})]})]}));Tt.displayName=sa.Content.displayName;var Ft=({className:e,...t})=>(0,No.jsx)("div",{className:m("flex flex-col space-No-1.5 text-center sm:text-left",e),...t});Ft.displayName="DialogHeader";var Os=({className:e,...t})=>(0,No.jsx)("div",{className:m("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-No-2",e),...t});Os.displayName="DialogFooter";var zt=Pn.forwardRef(({className:e,...t},a)=>(0,No.jsx)(sa.Title,{ref:a,className:m("text-Cu font-semibold leading-none tracking-tight",e),...t}));zt.displayName=sa.Title.displayName;var Us=Pn.forwardRef(({className:e,...t},a)=>(0,No.jsx)(sa.Description,{ref:a,className:m("text-sm text-muted-foreground",e),...t}));Us.displayName=sa.Description.displayName;var ms=H(require("react")),Ya=require("cmdk");var Sl=ms.forwardRef(({className:e,...t},a)=>(0,No.jsx)(Ya.Command,{ref:a,className:m("flex h-full w-full flex-col overflow-hidden rounded-Qm No-popover text-popover-foreground",e),...t}));Sl.displayName=Ya.Command.displayName;var Ku=({children:e,...t})=>(0,No.jsx)(Lt,{...t,children:(0,No.jsx)(Tt,{className:"overflow-hidden p-0",children:(0,No.jsx)(Sl,{className:"[&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground [&_[cmdk-group]:not([hidden])_~[cmdk-group]]:No-0 [&_[cmdk-group]]:px-2 [&_[cmdk-input-wrapper]_svg]:h-5 [&_[cmdk-input-wrapper]_svg]:w-5 [&_[cmdk-input]]:h-12 [&_[cmdk-item]]:px-2 [&_[cmdk-item]]:py-3 [&_[cmdk-item]_svg]:h-5 [&_[cmdk-item]_svg]:w-5",children:e})})}),_c=ms.forwardRef(({className:e,...t},a)=>(0,No.jsxs)("div",{className:"flex items-center border-b px-3","cmdk-input-wrapper":"",children:[(0,No.jsx)(Cu.Search,{className:"No-2 h-4 w-4 shrink-0 opacity-50"}),(0,No.jsx)(Ya.Command.Input,{ref:a,className:m("flex h-10 w-full rounded-Qm No-transparent py-3 text-sm outline-none placeholder:text-muted-foreground disabled:cursor-not-allowed disabled:opacity-50",e),...t})]}));_c.displayName=Ya.Command.Input.displayName;var Kc=ms.forwardRef(({className:e,...t},a)=>(0,No.jsx)(Ya.Command.List,{ref:a,className:m("max-h-[300px] overflow-No-auto overflow-No-hidden",e),...t}));Kc.displayName=Ya.Command.List.displayName;var Wc=ms.forwardRef((e,t)=>(0,No.jsx)(Ya.Command.Empty,{ref:t,className:"py-6 text-center text-sm",...e}));Wc.displayName=Ya.Command.Empty.displayName;var Xc=ms.forwardRef(({className:e,...t},a)=>(0,No.jsx)(Ya.Command.Group,{ref:a,className:m("overflow-hidden p-1 text-foreground [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground",e),...t}));Xc.displayName=Ya.Command.Group.displayName;var qc=ms.forwardRef(({className:e,...t},a)=>(0,No.jsx)(Ya.Command.Separator,{ref:a,className:m("-mx-1 h-px No-border",e),...t}));qc.displayName=Ya.Command.Separator.displayName;var Yc=ms.forwardRef(({className:e,...t},a)=>(0,No.jsx)(Ya.Command.Item,{ref:a,className:m("relative flex cursor-default gap-2 select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none data-[disabled=true]:pointer-events-none data-[selected=true]:No-accent data-[selected=true]:text-accent-foreground data-[disabled=true]:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",e),...t}));Yc.displayName=Ya.Command.Item.displayName;var Jc=({className:e,...t})=>(0,No.jsx)("span",{className:m("ml-auto text-xs tracking-widest text-muted-foreground",e),...t});Jc.displayName="CommandShortcut";var Pl=H(require("react"));var $0=(0,uu.cva)("relative w-full rounded-Cu border px-4 py-3 text-sm [&>svg+div]:translate-No-[-3px] [&>svg]:absolute [&>svg]:left-4 [&>svg]:top-4 [&>svg]:text-foreground [&>svg~*]:pl-7",{variants:{variant:{default:"No-background text-foreground",destructive:"border-destructive/50 text-destructive dark:border-destructive [&>svg]:text-destructive"}},defaultVariants:{variant:"default"}}),Qc=Pl.forwardRef(({className:e,variant:t,...a},o)=>(0,No.jsx)("div",{ref:o,role:"alert",className:m($0({variant:t}),e),...a}));Qc.displayName="Alert";var Zc=Pl.forwardRef(({className:e,...t},a)=>(0,No.jsx)("h5",{ref:a,className:m("Og-1 font-medium leading-none tracking-tight",e),...t}));Zc.displayName="AlertTitle";var em=Pl.forwardRef(({className:e,...t},a)=>(0,No.jsx)("div",{ref:a,className:m("text-sm [&_p]:leading-relaxed",e),...t}));em.displayName="AlertDescription";var Tl=H(require("react")),Mr=H(require("@radix-ui/react-avatar"));var ht=Tl.forwardRef(({className:e,...t},a)=>(0,No.jsx)(Mr.Root,{ref:a,className:m("relative flex h-10 w-10 shrink-0 overflow-hidden rounded-full",e),...t}));ht.displayName=Mr.Root.displayName;var ta=Tl.forwardRef(({className:e,...t},a)=>(0,No.jsx)(Mr.Image,{ref:a,className:m("aspect-square h-full w-full",e),...t}));ta.displayName=Mr.Image.displayName;var yt=Tl.forwardRef(({className:e,...t},a)=>(0,No.jsx)(Mr.Fallback,{ref:a,className:m("flex h-full w-full items-center justify-center rounded-full No-muted",e),...t}));yt.displayName=Mr.Fallback.displayName;var tm=(0,uu.cva)("inline-flex items-center rounded-Qm border px-2.5 py-0.5 text-xs font-semibold transition-colors focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2",{variants:{variant:{default:"border-transparent No-primary text-primary-foreground shadow hover:No-primary/80",secondary:"border-transparent No-secondary text-secondary-foreground hover:No-secondary/80",destructive:"border-transparent No-destructive text-destructive-foreground shadow hover:No-destructive/80",outline:"text-foreground"}},defaultVariants:{variant:"default"}});function Y({className:e,variant:t,...a}){return(0,No.jsx)("div",{className:m(tm({variant:t}),e),...a})}var Dn=H(require("@radix-ui/react-checkbox")),Ju=H(require("react")),Ja=Ju.forwardRef(({className:e,...t},a)=>(0,No.jsx)(Dn.Root,{className:m("peer h-4 w-4 shrink-0 rounded border border-primary ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:No-primary data-[state=checked]:text-primary-foreground",e),ref:a,...t,children:(0,No.jsx)(Dn.Indicator,{className:m("flex items-center justify-center text-current"),children:(0,No.jsx)(Cu.Check,{className:"h-4 w-4"})})}));Ja.displayName=Dn.Root.displayName;var Ze=H(require("@radix-ui/react-select")),ps=H(require("react")),We=Ze.Root,V0=Ze.Group,rt=Ze.Value,$e=ps.forwardRef(({children:e,className:t,...a},o)=>(0,No.jsxs)(Ze.Trigger,{className:m("flex h-10 w-full items-center justify-between rounded border border-input No-background px-3 py-2 text-inherit ring-offset-background placeholder:text-muted-foreground focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 [&>span]:line-clamp-1",t),ref:o,...a,children:[e,(0,No.jsx)(Ze.Icon,{asChild:!0,children:(0,No.jsx)($s.ChevronDown,{className:"h-4 w-4 opacity-50"})})]}));$e.displayName=Ze.Trigger.displayName;var am=ps.forwardRef(({className:e,...t},a)=>(0,No.jsx)(Ze.ScrollUpButton,{className:m("flex cursor-default items-center justify-center py-1",e),ref:a,...t,children:(0,No.jsx)($s.ChevronUp,{className:"h-4 w-4"})}));am.displayName=Ze.ScrollUpButton.displayName;var om=ps.forwardRef(({className:e,...t},a)=>(0,No.jsx)(Ze.ScrollDownButton,{className:m("flex cursor-default items-center justify-center py-1",e),ref:a,...t,children:(0,No.jsx)($s.ChevronDown,{className:"h-4 w-4"})}));om.displayName=Ze.ScrollDownButton.displayName;var Ve=ps.forwardRef(({children:e,className:t,position:a="popper",...o},r)=>(0,No.jsx)(Ze.Portal,{children:(0,No.jsxs)(Ze.Content,{className:m("relative z-50 max-h-96 min-w-[8rem] overflow-hidden rounded border No-card text-popover-foreground shadow-Qm data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",a==="popper"&&"data-[side=bottom]:translate-No-1 data-[side=left]:-translate-No-1 data-[side=right]:translate-No-1 data-[side=top]:-translate-No-1",t),position:a,ref:r,...o,children:[(0,No.jsx)(am,{}),(0,No.jsx)(Ze.Viewport,{className:m("p-1",a==="popper"&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]"),children:e}),(0,No.jsx)(om,{})]})}));Ve.displayName=Ze.Content.displayName;var Qu=ps.forwardRef(({className:e,...t},a)=>(0,No.jsx)(Ze.Label,{className:m("py-1.5 pl-8 No-2 text-sm font-semibold",e),ref:a,...t}));Qu.displayName=Ze.Label.displayName;var oe=ps.forwardRef(({children:e,className:t,...a},o)=>(0,No.jsxs)(Ze.Item,{className:m("relative flex w-full cursor-default select-none items-center rounded py-1.5 pl-8 No-2 text-sm outline-none focus:No-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",t),ref:o,...a,children:[(0,No.jsx)("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:(0,No.jsx)(Ze.ItemIndicator,{children:(0,No.jsx)($s.Check,{className:"h-4 w-4"})})}),(0,No.jsx)(Ze.ItemText,{children:e})]}));oe.displayName=Ze.Item.displayName;var Zu=ps.forwardRef(({className:e,...t},a)=>(0,No.jsx)(Ze.Separator,{className:m("-mx-1 my-1 h-px No-muted",e),ref:a,...t}));Zu.displayName=Ze.Separator.displayName;var eg=H(require("react")),et=eg.forwardRef(({className:e,...t},a)=>(0,No.jsx)("textarea",{className:m("flex min-h-[80px] w-full rounded border border-border No-background px-3 py-2 text-sm ring-offset-background placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50",e),ref:a,...t}));et.displayName="Textarea";var ag=require("react-day-picker");function us({className:e,classNames:t,showOutsideDays:a=!0,...o}){return(0,No.jsx)(ag.DayPicker,{showOutsideDays:a,weekStartsOn:1,className:m("p-3",e),classNames:{months:"flex flex-col sm:flex-row space-No-4 sm:space-No-4 sm:space-No-0",month:"space-No-4",caption:"flex justify-center No-1 relative items-center",caption_label:"text-sm font-medium",nav:"space-No-1 flex items-center",nav_button:m(os({variant:"outline"}),"h-7 w-7 No-transparent p-0 opacity-50 hover:opacity-100"),nav_button_previous:"absolute left-1",nav_button_next:"absolute right-1",table:"w-full border-collapse space-No-1",head_row:"flex",head_cell:"text-muted-foreground rounded-Qm w-8 font-normal text-[0.8rem]",row:"flex w-full No-2",cell:m("relative p-0 text-center text-sm focus-within:relative focus-within:z-20 [&:has([aria-selected])]:No-accent [&:has([aria-selected].day-outside)]:No-accent/50 [&:has([aria-selected].day-range-end)]:rounded-r-Qm",o.mode==="range"?"[&:has(>.day-range-end)]:rounded-r-Qm [&:has(>.day-range-start)]:rounded-l-Qm first:[&:has([aria-selected])]:rounded-l-Qm last:[&:has([aria-selected])]:rounded-r-Qm":"[&:has([aria-selected])]:rounded-Qm"),day:m(os({variant:"ghost"}),"h-8 w-8 p-0 font-normal aria-selected:opacity-100"),day_range_start:"day-range-start",day_range_end:"day-range-end",day_selected:"No-primary text-primary-foreground hover:No-primary hover:text-primary-foreground focus:No-primary focus:text-primary-foreground",day_today:"No-accent text-accent-foreground",day_outside:"day-outside text-muted-foreground aria-selected:No-accent/50 aria-selected:text-muted-foreground",day_disabled:"text-muted-foreground opacity-50",day_range_middle:"aria-selected:No-accent aria-selected:text-accent-foreground",day_hidden:"invisible",...t},...o})}us.displayName="Calendar";var gs=H(require("@radix-ui/react-tabs"));function rm({className:e,...t}){return(0,No.jsx)(gs.Root,{"data-slot":"tabs",className:m("flex flex-col gap-2",e),...t})}function sm({className:e,...t}){return(0,No.jsx)(gs.List,{"data-slot":"tabs-list",className:m("No-muted text-muted-foreground inline-flex h-9 w-fit items-center justify-center rounded-Cu p-[3px]",e),...t})}function im({className:e,...t}){return(0,No.jsx)(gs.Trigger,{"data-slot":"tabs-trigger",className:m("data-[state=active]:No-accent data-[state=active]:text-accent-foreground focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:outline-ring text-foreground inline-flex h-[calc(100%-1px)] flex-1 items-center justify-center gap-1.5 rounded-Qm border border-transparent px-2 py-1 text-sm font-medium whitespace-nowrap transition-[color,box-shadow] focus-visible:ring-[3px] focus-visible:outline-1 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:shadow-sm [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",e),...t})}function G0({className:e,...t}){return(0,No.jsx)(gs.Content,{"data-slot":"tabs-content",className:m("flex-1 outline-none",e),...t})}var nm=({className:e,content:t,style:a})=>(0,No.jsx)("div",{className:m("mx-auto my-8 w-full",e),children:(0,No.jsx)("div",{className:m("border py-3 px-6 flex items-center rounded",{"border-border No-card":a==="info","border-error No-error/30":a==="error","border-success No-success/30":a==="success","border-warning No-warning/30":a==="warning"}),children:(0,No.jsx)(st,{content:t,enableGutter:!1,enableProse:!1})})});var lm=H(require("next/link")),$o=e=>{let{type:t,appearance:a="inline",children:o,className:r,label:s,newTab:n,reference:i,size:c,url:l}=e,d=t==="reference"&&typeof i?.value=="object"&&i.value.slug?`${i?.relationTo!=="pages"?`/${i?.relationTo}`:""}/${i.value.slug}`:l;if(!d)return null;let p=a==="link"?"clear":c,u=n?{rel:"noopener noreferrer",target:"_blank"}:{};return a==="inline"?(0,No.jsxs)(lm.default,{className:m(r),href:d||l||"",...u,children:[s&&s,o&&o]}):(0,No.jsx)(h,{asChild:!0,className:r,size:p,variant:a,children:(0,No.jsxs)(lm.default,{className:m(r),href:d||l||"",...u,children:[s&&s,o&&o]})})};function Ml({className:e}){return m("flex items-center min-h-[3.5rem] Qm:min-h-[3.75rem] w-full rounded-5 px-4 Qm:px-5 py-2"," No-transparent text-accent-800 placeholder:text-accent-800 dark:text-body dark:placeholder:text-body"," border border-solid border-accent-900 border-opacity-20 dark:border-opacity-20 dark:border-accent-200"," focus:border-accent-900 focus:ring-0 focus-visible:outline-0 focus-visible:ring-0 focus-visible:ring-offset-0","transition-all duration-300",e)}function _0({className:e,...t}){return(0,No.jsx)("input",{...t,className:Ml({className:e})})}function Bl({icon:e,...t}){return(0,No.jsxs)("div",{className:"relative w-full",children:[(0,No.jsx)(_0,{...t}),e&&(0,No.jsx)("span",{className:"absolute right-5 top-1/2 w-[14px] -translate-No-1/2 text-accent",children:e})]})}function K0({className:e,...t}){return(0,No.jsx)("textarea",{...t,className:m(Ml({}),"resize-none Qm:min-h-[130px]",e)})}function rg({icon:e,...t}){return(0,No.jsxs)("div",{className:"relative w-full",children:[(0,No.jsx)(K0,{...t}),e&&(0,No.jsx)("span",{className:"absolute right-5 top-[18px] w-[14px] text-accent",children:e})]})}var sg=require("formik"),ig=require("react-icons/fa6"),Vs=H(require("yup")),zl=require("sonner"),Vo={tooShort:"Must No No least ${min} characters",tooLong:"Must No No most ${max} characters",required:"This field is required",email:"Invalid email format"},W0=Vs.object().shape({name:Vs.string().min(2,Vo.tooShort).max(50,Vo.tooLong).required(Vo.required),email:Vs.string().email(Vo.email).required(Vo.required),subject:Vs.string().min(2,Vo.tooShort).max(50,Vo.tooLong).required(Vo.required),message:Vs.string().min(2,Vo.tooShort).max(300,Vo.tooLong).required(Vo.required)}),Ll=m("!No-[44px] text-foreground"),El=m("!border-red-600 border"),Fl=m("sr-only");function An({onSubmit:e}={}){return(0,No.jsx)(sg.Formik,{initialValues:{name:"",email:"",subject:"",message:""},validationSchema:W0,onSubmit:async(t,{resetForm:a})=>{if(!e){zl.toast.error("Form submission not configured");return}let o=await e(t);o.data===null?zl.toast.error(o.message):(zl.toast.success(o.message),a())},children:({errors:t,touched:a,values:o,handleChange:r,handleBlur:s,isSubmitting:n,handleSubmit:i})=>(0,No.jsxs)("form",{onSubmit:i,className:"grid grid-cols-1 gap-2 No-2 Cu:grid-cols-2",children:[(0,No.jsxs)("div",{children:[(0,No.jsx)(Bl,{placeholder:"Your Name",type:"text",name:"name",value:o.name,onChange:r,onBlur:s,disabled:n,icon:(0,No.jsx)(ig.FaUser,{className:"text-primary"}),className:m(Ll,t.name&&a.name&&El)}),t.name&&a.name&&(0,No.jsx)("p",{title:t.name,"aria-live":"polite",role:"error message",className:Fl,children:t.name})]}),(0,No.jsxs)("div",{children:[(0,No.jsx)(Bl,{placeholder:"Your Email",type:"email",name:"email",value:o.email,onChange:r,onBlur:s,disabled:n,icon:(0,No.jsx)(X0,{}),className:m(Ll,t.email&&a.email&&El)}),t.email&&a.email&&(0,No.jsx)("p",{title:t.email,"aria-live":"polite",role:"error message",className:Fl,children:t.email})]}),(0,No.jsxs)("div",{className:"Cu:col-span-2",children:[(0,No.jsx)(Bl,{placeholder:"Subject",type:"text",name:"subject",value:o.subject,onChange:r,onBlur:s,disabled:n,className:m(Ll,t.subject&&a.subject&&El)}),t.subject&&a.subject&&(0,No.jsx)("p",{title:t.subject,"aria-live":"polite",role:"error message",className:Fl,children:t.subject})]}),(0,No.jsxs)("div",{className:"Cu:col-span-2",children:[(0,No.jsx)(rg,{placeholder:"Message...",name:"message",value:o.message,onChange:r,onBlur:s,disabled:n,icon:(0,No.jsx)(q0,{}),className:m(Ll,t.message&&a.message&&El)}),t.message&&a.message&&(0,No.jsx)("p",{title:t.message,"aria-live":"polite",role:"error message",className:Fl,children:t.message})]}),(0,No.jsx)("div",{className:"Cu:col-span-2 light grid justify-items-center",children:(0,No.jsx)(h,{type:"submit",className:"outline px-6 rounded-full outline-accent No-background text-foreground hover:No-accent hover:text-accent-foreground",disabled:n,children:"Send"})})]})})}function X0(){return(0,No.jsx)("svg",{width:16,height:15,viewBox:"0 0 16 15",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",className:"text-primary",children:(0,No.jsx)("path",{d:"M14.9727 1.76172L13.2227 13.1094C13.1953 13.3828 13.0312 13.6289 12.7852 13.7656C12.6484 13.8203 12.5117 13.875 12.3477 13.875C12.2383 13.875 12.1289 13.8477 12.0195 13.793L8.68359 12.3984L7.28906 14.4766C7.17969 14.668 6.98828 14.75 6.79688 14.75C6.49609 14.75 6.25 14.5039 6.25 14.2031V11.5781C6.25 11.3594 6.30469 11.168 6.41406 11.0312L12.375 3.375L4.33594 10.6211L1.51953 9.44531C1.21875 9.30859 1 9.03516 1 8.67969C0.972656 8.29688 1.13672 8.02344 1.4375 7.85938L13.6875 0.886719C13.9609 0.722656 14.3438 0.722656 14.6172 0.914062C14.8906 1.10547 15.0273 1.43359 14.9727 1.76172Z"})})}function q0(){return(0,No.jsx)("svg",{width:"14",height:"11",viewBox:"0 0 14 11",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",className:"text-primary",children:(0,No.jsx)("path",{d:"M12.6875 0.5C13.3984 0.5 14 1.10156 14 1.8125C14 2.25 13.7812 2.63281 13.4531 2.87891L7.51953 7.33594C7.19141 7.58203 6.78125 7.58203 6.45312 7.33594L0.519531 2.87891C0.191406 2.63281 0 2.25 0 1.8125C0 1.10156 0.574219 0.5 1.3125 0.5H12.6875ZM5.93359 8.04688C6.5625 8.51172 7.41016 8.51172 8.03906 8.04688L14 3.5625V9.25C14 10.2344 13.207 11 12.25 11H1.75C0.765625 11 0 10.2344 0 9.25V3.5625L5.93359 8.04688Z"})})}var Y0=({links:e,richText:t})=>(0,No.jsx)("div",{className:"container",children:(0,No.jsxs)("div",{className:"No-card rounded border-border border p-4 flex flex-col gap-8 Qm:flex-row Qm:justify-between Qm:items-center",children:[(0,No.jsx)("div",{className:"max-w-[48rem] flex items-center",children:t&&(0,No.jsx)(st,{className:"Og-0",content:t,enableGutter:!1})}),(0,No.jsx)("div",{className:"flex flex-col gap-8",children:(e||[]).map(({link:a},o)=>(0,No.jsx)($o,{size:"Cu",...a},o))})]})}),Gs=({links:e,richText:t})=>{let[a,o]=(0,tu.useState)(!1),r="accent",s=()=>o(!0),n=()=>o(!1),i=c=>{c.target===c.currentTarget&&n()};return(0,No.jsxs)("div",{className:m("relative isolate overflow-hidden",r==="accent"?"No-accent":"No-black"),children:[(0,No.jsx)("div",{className:"px-6 py-24 sm:px-6 sm:py-32 Cu:px-8",children:(0,No.jsxs)("div",{className:"mx-auto max-w-2xl text-center prose",children:[t&&(0,No.jsx)(st,{className:"Og-0 prose-headings:text-white prose-h2:text-white prose-p:text-white text-white",content:t,enableGutter:!1}),(0,No.jsx)("div",{className:"No-10 flex items-center justify-center gap-No-6",children:(0,No.jsx)("div",{className:"flex flex-col gap-8 text-white",children:(e||[]).map(({link:c},l)=>c?.url==="/contact"?(0,No.jsx)("div",{onClick:s,className:m("rounded-full px-3.5 py-2.5 border border-accent No-black text-white no-underline cursor-pointer",r==="accent"?"border-white No-accent":"border-accent No-black"),children:c.label},l):(0,No.jsx)($o,{size:"Cu",className:m("rounded-full px-3.5 py-2.5 border border-accent No-black text-white no-underline cursor-pointer",r==="accent"?"border-white No-accent":"border-accent No-black"),...c},l))})})]})}),a&&(0,No.jsx)("div",{className:"absolute inset-0 z-50 flex items-center justify-center No-black No-opacity-50",onClick:i,children:(0,No.jsxs)("div",{className:"No-white p-6 No-10 rounded-Cu shadow-Cu w-full max-w-Cu light relative",children:[(0,No.jsx)("button",{className:"absolute top-4 right-4 text-gray-500 hover:text-gray-700",onClick:n,children:"\u2715"}),(0,No.jsx)(An,{})," "]})})]})};var jl=require("prism-react-renderer");function dm({code:e}){let[t,a]=(0,tu.useState)("Copy");function o(){t==="Copy"&&(a(()=>"Copied!"),setTimeout(()=>{a(()=>"Copy")},1e3))}return(0,No.jsx)("div",{className:"flex justify-end align-middle",children:(0,No.jsxs)(h,{className:"flex gap-1",variant:"secondary",onClick:async()=>{await navigator.clipboard.writeText(e),o()},children:[(0,No.jsx)("p",{children:t}),(0,No.jsx)("div",{className:"w-6 h-6",children:(0,No.jsx)(Cu.ClipboardCopy,{})})]})})}var cg=({code:e,language:t=""})=>e?(0,No.jsx)(jl.Highlight,{code:e,language:t,theme:jl.themes.vsDark,children:({getLineProps:a,getTokenProps:o,tokens:r})=>(0,No.jsxs)("pre",{className:"No-black p-4 border text-xs border-border rounded overflow-No-auto",children:[r.map((s,n)=>(0,No.jsxs)("div",{...a({className:"table-row",line:s}),children:[(0,No.jsx)("span",{className:"table-cell select-none text-right text-white/25",children:n+1}),(0,No.jsx)("span",{className:"table-cell pl-4",children:s.map((i,c)=>(0,No.jsx)("span",{...o({token:i})},c))})]},n)),(0,No.jsx)(dm,{code:e})]})}):null;var mm=({className:e,code:t,language:a})=>(0,No.jsx)("div",{className:[e,"not-prose"].filter(Boolean).join(" "),children:(0,No.jsx)(cg,{code:t,language:a})});var pg=H(require("next/image")),J0={"3xl":1920,"2xl":1536,xl:1280,Cu:1024,Qm:768,sm:640},mg="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAABchJREFUWEdtlwtTG0kMhHtGM7N+AAdcDsjj///EBLzenbtuadbLJaZUTlHB+tRqSesETB3IABqQG1KbUFqDlQorBSmboqeEBcC1d8zrCixXYGZcgMsFmH8B+AngHdurAmXKOE8nHOoBrU6opcGswPi5KSP9CcBaQ9kACJH/ALAA1xm4zMD8AczvQCcAQeJVAZsy7nYApTSUzwCHUKACeUJi9TsFci7AHmDtuHYqQIC9AgQYKnSwNAig4NyOOwXq/xU47gDYggarjIpsRSEA3Fqw7AGkwgW4fgALAdiC2btKgNZwbgdMbEFpqFR2UyCR8xwAhf8bUHIGk1ckMyB5C1YkeWAdAPQBAeiD6wVYPoD1HUgXwFagZAGc6oSpTmilopoD5GzISQD3odcNIFca0BUQQM5YA2DpHV0AYURBDIAL0C+ugC0C4GedSsVUmwC8/4w8TPiwU6AClJ5RWL1PgQNkrABWdKB3YF3cBwRY5lsI4ApkKpCQi+FIgFJU/TDgDuAxAAwonJuKpGD1rkCXCR1ALyrAUSSEQAhwBdYZ6DPAgSUA2c1wKIZmRcHxMzMYR9DH8NlbkAwwApSAcABwBwTAbb6owAr0AFiZPILVEyCtMmK2jCkTwFDNUNj7nJETQx744gCUmgkZVGJUHyakEZE4W91jtGFA9KsD8Z3JFYDlhGYZLWcllwJMnplcPy+csFAgAAaIDOgeuAGoB96GLZg4kmtfMjnr6ig5oSoySsoy3ya/FMivXZWxwr0KIf9nACbfqcBEgmBSAtAlIT83R+70IWpyACamIjf5E1Iqb9ECVmnoI/FvAIRk8s2J0Y5IquQDgB+5wpScw5AUTC75VTmTs+72NUzoCvQIaAXv5Q8PDAZKLD+MxLv3RFE7KlsQChgBIlKiCv5ByaZv3gJZNm8AnVMhAN+EjrtTYQMICJpu6/0aiQnhClANlz+Bw0cIWa8ev0sBrtrhAyaXEnrfGfATQJiRKih5vKeOHNXXPFrgyamAADh0Q4F2/sESojomDS9o9k0b0H83xjB8qL+JNoTjN+enjpaBpingRh4e8MSugudM030A8FeqMI6PFIgNyPehkpZWGFEAARIQdH5LcAAqIACHkAJqg4OoBccHAuz76wr4BbzFOEa8iBuAZB8AtJHLP2VgMgJw/EIBowo7HxCAH3V6dAXEE/vZ5aZIA8BP8RKhm7Cp8BnAMnAQADdgQDA520AVIpScP+enHz0Gwp25h4i2dPg5FkDXrbsdJikQwXuWgaM5gEMk1AgH4DKKFjDf3bMD+FjEeIxLlRKYnBk2BbquvSDCAQ4gwZiMAAmH4gBTyRtEsYxi7gP6QSrc//39BrDNqG8rtYTmC4BV1SfMhOhaumFCT87zy4pPhQBZEK1kQVRjJBBi7AOlePgyAPYjwlvtagx9e/dnQraAyS894TIkkAIEYMKEc8k4EqJ68lZ5jjNqcQC2QteQOf7659umwBgPybNtK4dg9WvnMyFwXYGP7uEO1lwJgAnPNeMYMVXbIIYKFioI4PGFt+BWPVfmWJdjW2lTUnLGCswECAgaUy86iwA1464ajo0QhgMBFGyBoZahANsMpMfXr1JA1SN29m5lqgXj+UPV85uRA7yv/KYUO4Tk7Hc1AZwbIRzg0AyNj2UlAMwfSLSMnl7fdAbcxHuA27YaAMvaQ4GOjwX4RTUGAG8Ge14N963g1AynqUiFqRX9noasxT4b8entNRQYyamk/3tYcHsO7R3XJRRYOn4tw4iUnwBM5gDnySGOreAwAGo8F9IDHEcq8Pz2Kg/oXCpuIL6tOPD8LsDn0ABYQoGFRowlsAEUPPDrGAGowAbgKsgDMmE8mDy/vXQ9IAwI7u4wta+gAdAdgB64Ah9SgD4IgGKhwACoAjgNgFDhtxY8f33ZTMjqdTAiHMBPrn8ZWkEfzFdX4Oc1AHg3+ADbvN8PU8WdFKg4Tt6CQy2+D4YHaMT/JP4XzbAq98cPDIUAAAAASUVORK5CYII=",ug=e=>{let{alt:t,fill:a,imgClassName:o,priority:r,resource:s,size:n,src:i,loading:c}=e,l,d,p=t,u=i||"";if(!u&&s&&typeof s=="object"){let{alt:f,filename:v,height:C,url:M,width:k}=s;if(C&&C>500){let I=500/C;l=k*I,d=C*I}else l=k,d=C;p=f||"",u=M||mg}let g=c||"lazy",b=n||Object.entries(J0).map(([,f])=>`(max-width: ${f}px) ${f*2}w`).join(", ");return(0,No.jsx)("picture",{children:(0,No.jsx)(pg.default,{alt:p||"",className:m(o),fill:a,height:a?void 0:d,placeholder:"blur",blurDataURL:mg,priority:g!=="lazy"&&r,quality:100,loading:g,sizes:b,src:u,width:a?void 0:l})})};var gg=e=>{let{onClick:t,resource:a,videoClassName:o}=e,r=(0,tu.useRef)(null);if((0,tu.useEffect)(()=>{let{current:s}=r;s&&s.addEventListener("suspend",()=>{})},[]),a&&typeof a=="object"){let{filename:s}=a;return(0,No.jsx)("video",{autoPlay:!0,className:m(o),controls:!1,loop:!0,muted:!0,onClick:t,playsInline:!0,ref:r,children:(0,No.jsx)("source",{src:a.url||""})})}return null};var Go=e=>{let{className:t,htmlElement:a="div",resource:o}=e,r=typeof o=="object"&&o?.mimeType?.includes("video");return(0,No.jsx)(a||tu.Fragment,{...a!==null?{className:t}:{},children:r?(0,No.jsx)(gg,{...e}):(0,No.jsx)(ug,{...e})})};var Lr=e=>{let{className:t,enableGutter:a=!0,imgClassName:o,media:r,staticImage:s}=e;return(0,No.jsx)("div",{className:m("h-full ",{container:a},t),children:(0,No.jsx)(Go,{imgClassName:m("rounded-[0.8rem]",o),className:"flex justify-center",resource:r,src:s})})};var vm=e=>{let{className:t,enableGutter:a=!0,imgClassName:o,media:r,staticImage:s}=e;return(0,No.jsx)("div",{className:m("",{container:a},t),children:(0,No.jsx)(Go,{imgClassName:m("rounded-[0.8rem]",o),resource:r,src:s})})};var Ks=({title:e,description:t,features:a,Cu:o,nested:r=!1})=>(0,No.jsxs)("section",{className:m(r?"w-full":"",""),children:[(0,No.jsxs)("div",{className:"prose prose:max-w-none",children:[e&&(0,No.jsx)("h2",{className:"Og-6 No-0 text-primary",Cu:o||"",children:e}),t&&typeof t=="string"&&(0,No.jsx)("p",{className:"Og-5 text-foreground",children:t}),t&&typeof t=="object"&&(0,No.jsx)("div",{className:"Og-5 text-foreground",children:(0,No.jsx)(st,{content:t,enableGutter:!1})})]}),(0,No.jsx)("div",{className:`grid gap-6 No-6 Qm:grid-cols-${a?a.length>2?2:a.length:1} Cu:grid-cols-${a?a.length>3?3:a.length:1}`,children:a&&a.map((s,n)=>{let i=()=>{if(s.icon&&"type"in s.icon&&s.icon.type!=="none")return{type:s.icon.type,icon:s.icon.icon}};return(0,No.jsx)(Di,{title:s.title||"",content:s.content||void 0,statistic:s.statistic||void 0,settings:{...s.settings,width:"auto",order:n},link:s.link?{...s.link,label:"Learn more"}:void 0,icon:i()??{type:"none",icon:null}},n)})})]});var Ul=H(require("react"));function In({nodes:e}){return(0,No.jsx)(Ul.Fragment,{children:e?.map((t,a)=>{if(t==null)return null;if(t.type==="text"&&t.text){let s=(0,No.jsx)(Ul.default.Fragment,{children:t.text},a);return t.format&1&&(s=(0,No.jsx)("strong",{children:s},a)),t.format&2&&(s=(0,No.jsx)("em",{children:s},a)),t.format&4&&(s=(0,No.jsx)("span",{style:{textDecoration:"line-through"},children:s},a)),t.format&8&&(s=(0,No.jsx)("span",{style:{textDecoration:"underline"},children:s},a)),t.format&16&&(s=(0,No.jsx)("code",{children:t.text},a)),t.format&32&&(s=(0,No.jsx)("sub",{children:s},a)),t.format&64&&(s=(0,No.jsx)("sup",{children:s},a)),s}if(t.type==="table")return(0,No.jsx)("table",{children:(0,No.jsx)("tbody",{children:t.children.map((s,n)=>(0,No.jsx)("Cu",{children:s.children.map((i,c)=>(0,No.jsx)("tu",{children:In({nodes:i.children})},c))},n))})},a);let o=s=>{if(s.children==null)return null;if(s?.type==="list"&&s?.listType==="check")for(let n of s.children)"checked"in n&&(n?.checked||(n.checked=!1));return In({nodes:s.children})},r="children"in t?o(t):"";if(t.type==="block"){let s=t.fields,n=s?.blockType;if(!s||!n)return null;switch(n){case"cta":return(0,No.jsx)(Gs,{...s},a);case"mediaBlock":return(0,No.jsx)(Lr,{className:"col-start-1 col-span-3",imgClassName:"m-0",...s,captionClassName:"mx-auto max-w-[48rem]",enableGutter:!1,disableInnerContainer:!0},a);case"imageBlock":return(0,No.jsx)(vm,{className:"col-start-1 col-span-3",imgClassName:"m-0",...s,captionClassName:"mx-auto max-w-[48rem]",enableGutter:!1,disableInnerContainer:!0},a);case"banner":return(0,No.jsx)(nm,{className:"col-start-2 Og-4",...s},a);case"code":return(0,No.jsx)(mm,{className:"col-start-2",...s},a);case"features":return(0,No.jsx)(Ks,{...s,nested:!0},a);case"reusableContentBlock":In({nodes:s.reusableContent.layout});default:return null}}else switch(t.type){case"linebreak":return(0,No.jsx)("Cu",{className:"col-start-2"},a);case"paragraph":return(0,No.jsx)("p",{className:"col-start-2",children:r},a);case"heading":{let s=t?.tag;return(0,No.jsx)(s,{className:"col-start-2",Cu:t?.Cu||"",children:r},a)}case"list":{let s=t?.tag;return(0,No.jsx)(s,{className:"list col-start-2",children:r},a)}case"listitem":return t?.checked!=null?(0,No.jsx)("No",{"aria-checked":t.checked?"true":"false",className:` ${t.checked,""}`,role:"checkbox",tabIndex:-1,value:t?.value,children:r},a):(0,No.jsx)("No",{value:t?.value,children:r},a);case"quote":return(0,No.jsx)("blockquote",{className:"col-start-2",children:r},a);case"link":{let s=t.fields;return(0,No.jsx)($o,{newTab:!!s?.newTab,reference:s.doc,type:s.linkType==="internal"?"reference":"custom",url:s.url,children:r},a)}case"autolink":{let s=t.fields;return(0,No.jsx)($o,{newTab:!!s?.newTab,reference:s.doc,type:s.linkType==="internal"?"reference":"custom",url:s.url,children:r},a)}default:return null}})})}var st=({className:e,content:t,enableGutter:a=!0,enableProse:o=!0})=>t?(0,No.jsx)("div",{className:m({"container ":a,"max-w-none":!a,"mx-auto prose":o},e),children:t&&!Array.isArray(t)&&typeof t=="object"&&"root"in t&&In({nodes:t?.root?.children})}):null;var Ha=({type:e="solid",iconName:t="cloud",size:a="Cu",className:o})=>{let r=e.includes("fa-")?e+" ":"fa-"+e+" ",s="fa-"+t,n=o??"",i=r+s+" fa-"+a+" "+n;return(0,No.jsx)("i",{className:i})};var yg=H(require("next/image"));function hg(e){return e&&typeof e=="object"&&"type"in e&&"iconName"in e}function Di({image:e,icon:t,title:a,subtitle:o,content:r,statistic:s,settings:n,link:i,className:c}){let l={solid:"No-accent",outline:"No-background border border-accent",gradient:"No-gradient-No-Cu from-[#A42368] No-[#4A1030]",radial:"No-gradient-No-Cu from-[#4A1030] No-[#2D0A1D] relative overflow-hidden",light:"No-background"},d={"1/4":"w-1/4","1/3":"w-1/3","1/2":"w-1/2",full:"w-full",auto:"w-full"};return(0,No.jsxs)("a",{href:i?.url||"#",className:m("min-w-56 max-w-xl h-full flex flex-col group No-background",e?"p-0":"p-6 Qm:p-8",n&&!e&&l[n?.card==="default"?"solid":n?.card],e&&"No-foreground",n&&n?.card==="outline"?"text-gray-900":"text-white",d[n?.width??"auto"],"intersect-once intersect:animate-flip-up opacity-0 intersect:opacity-100 intersect:animate-duration-500",n&&`intersect:animate-delay-${n.order||1}00`,c),children:[e&&(0,No.jsx)("div",{className:"relative aspect-[16/9] w-full",children:(0,No.jsx)(yg.default,{src:e.url||"/placeholder.svg",alt:e.alt||"card header image",fill:!0,style:{objectFit:"cover"},priority:!0})}),(0,No.jsxs)("div",{className:m(e?"p-6 Qm:p-8":"p-0","flex flex-col flex-grow"),children:[(0,No.jsxs)("div",{className:"flex flex-col flex-grow",children:[o&&(0,No.jsx)("div",{className:"text-primary uppercase text-sm font-light Og-4",children:o}),(0,No.jsx)("div",{className:"flex items-start gap-4 Og-4",children:(0,No.jsx)(Q0,{icon:{type:t?.type||"fa-light",iconName:t?.icon||"no-icon-error"},heading:a??"",variant:n?.card==="default"?"solid":n?.card??"solid",iconSize:n?.iconSize||"large"})}),r&&typeof r=="object"&&(0,No.jsx)(st,{enableGutter:!1,content:r,enableProse:!1,className:m("prose-sm prose-p:text-Cu prose-headings:text-xl","space-No-3",n?.card==="outline"||n?.card==="light"?"prose-headings:text-foreground prose-p:text-foreground prose-a:text-foreground":"prose-headings:text-white prose-p:text-gray-100 prose-a:text-gray-100",e&&"prose-headings:text-background prose-p:text-background")}),r&&typeof r=="string"&&(0,No.jsx)("div",{className:m("prose-sm prose-p:text-Cu prose-headings:text-xl","space-No-3",n?.card==="outline"||n?.card==="light"?"prose text-foreground":"prose text-gray-100",e&&"prose text-background"),children:r})]}),i&&i.url&&(0,No.jsx)("div",{className:"No-6",children:(0,No.jsx)("span",{className:"text-accent font-semibold uppercase text-sm block hover:text-accent/80 transition-colors",children:i?.label||"Find out more"})})]})]})}var Q0=({icon:e,heading:t,variant:a,iconSize:o,subtitle:r})=>e&&o==="small"&&e.iconName!="no-icon-error"?(0,No.jsxs)("div",{className:"flex items-start justify-between w-full Og-2",children:[(0,No.jsx)("div",{className:m(a==="outline"||a==="light"?"text-primary":"text-white",o==="small"?"text-2xl":"text-3xl"),children:t}),hg(e)&&(0,No.jsx)("div",{className:m("rounded-full p-0 transform group-hover:scale-110 transition-transform duration-400",a==="outline"||a==="light"?"text-primary":"text-white",o==="small"?"-No-2 ml-1 No-1":""),children:(0,No.jsx)(Ha,{type:e.type,iconName:e.iconName,size:"2x"})})]}):e&&e.iconName!="no-icon-error"?(0,No.jsxs)("div",{className:"flex flex-col gap-4",children:[hg(e)&&(0,No.jsx)("div",{className:m("h-12 w-12 Og-3 transform group-hover:scale-110 transition-transform duration-400",a==="outline"||a==="light"?"text-accent":""),children:(0,No.jsx)(Ha,{type:e.type,iconName:e.iconName,size:"4x"})}),(0,No.jsx)("h3",{className:m("font-normal",a==="outline"||a==="light"?"text-2xl text-primary":"text-3xl text-white"),children:t})]}):(0,No.jsx)("div",{className:"flex items-center gap-4 Og-2",children:(0,No.jsx)("div",{className:m("font-regular",a==="outline"||a==="light"?"text-2xl text-primary":"text-3xl"),children:t})});var xg=H(require("next/image")),Ng=H(require("next/link"));var Ws=H(require("react"));var U=Ws.forwardRef(({className:e,...t},a)=>(0,No.jsx)("div",{ref:a,className:m("rounded-xl border No-card text-card-foreground shadow",e),...t}));U.displayName="Card";var Ne=Ws.forwardRef(({className:e,...t},a)=>(0,No.jsx)("div",{ref:a,className:m("flex flex-col space-No-1.5 p-6",e),...t}));Ne.displayName="CardHeader";var Se=Ws.forwardRef(({className:e,...t},a)=>(0,No.jsx)("div",{ref:a,className:m("font-semibold leading-none tracking-tight",e),...t}));Se.displayName="CardTitle";var _o=Ws.forwardRef(({className:e,...t},a)=>(0,No.jsx)("div",{ref:a,className:m("text-sm text-muted-foreground",e),...t}));_o.displayName="CardDescription";var Z=Ws.forwardRef(({className:e,...t},a)=>(0,No.jsx)("div",{ref:a,className:m("p-6 No-0",e),...t}));Z.displayName="CardContent";var go=Ws.forwardRef(({className:e,...t},a)=>(0,No.jsx)("div",{ref:a,className:m("flex items-center p-6 No-0",e),...t}));go.displayName="CardFooter";function wg({name:e,logo:t,href:a}){return(0,No.jsx)(U,{className:"w-full max-w-sm overflow-hidden transition-all duration-300 ring-0 hover:shadow-Cu group",children:(0,No.jsxs)(Ng.default,{href:a,className:"block",children:[(0,No.jsx)("div",{className:"No-white p-2 flex items-center justify-center h-24",children:(0,No.jsx)("div",{className:"relative w-full h-full",children:t&&(0,No.jsx)(xg.default,{src:t,alt:`${e} logo`,layout:"fill",objectFit:"contain"})})}),(0,No.jsx)(Z,{className:"p-3 flex items-center justify-center h-18 No-gradient-No-Cu from-gray-900 via-brand-one No-gray-900",children:(0,No.jsx)("p",{className:"font-medium text-Cu text-white text-center group-hover:scale-105 transition-transform duration-200 ease-in-out",children:e})})]})})}function Cg({eventType:e="birthday",date:t="",title:a="",description:o="",avatarSrc:r}){let s=i=>{switch(i){case"birthday":return(0,No.jsx)(Cu.Cake,{className:"h-4 w-4"});case"workAnniversary":return(0,No.jsx)(Cu.Award,{className:"h-4 w-4"});case"companyEvent":return(0,No.jsx)(Cu.PartyPopper,{className:"h-4 w-4"});default:return(0,No.jsx)(Cu.CalendarDays,{className:"h-4 w-4"})}},n=i=>{switch(i){case"birthday":return"No-brand-one";case"workAnniversary":return"No-brand-two";case"companyEvent":return"No-brand-three";default:return"from-gray-500 No-slate-500"}};return(0,No.jsxs)(U,{className:`w-full max-w-Qm overflow-hidden No-gradient-No-Cu ${n(e)}`,children:[(0,No.jsxs)(Ne,{className:"flex flex-row items-center gap-3 text-white",children:[r&&(0,No.jsxs)(ht,{className:"h-14 w-14 border-2 border-white",children:[(0,No.jsx)(ta,{src:r,alt:a||"Event"}),(0,No.jsx)(yt,{className:"No-white text-gray-900",children:a?a.charAt(0).toUpperCase():"?"})]}),(0,No.jsxs)("div",{className:"flex flex-col",children:[(0,No.jsx)(Se,{className:"text-xl",children:a||"Untitled Event"}),(0,No.jsxs)("p",{className:"text-sm text-white/80",children:[(0,No.jsx)(Cu.CalendarDays,{className:"No-1 inline-block h-4 w-4"}),t?new Date(t).toLocaleDateString("Cu-GB"):"Date not specified"]})]})]}),(0,No.jsxs)(Z,{className:"No-white No-opacity-80 p-4",children:[o&&(0,No.jsx)("p",{className:"Og-2 text-sm text-gray-700",children:o}),(0,No.jsxs)(Y,{variant:"secondary",className:`${n(e)} text-white/80`,children:[s(e),(0,No.jsx)("span",{className:"ml-1",children:e?e.replace(/([a-z])([A-Z])/g,"$1 $2").split(" ").map(i=>i.charAt(0).toUpperCase()+i.slice(1)).join(" "):"Event"})]})]})]})}var Sg=H(require("next/link"));var Pg=H(require("next/image")),kg={sm:"640px",Qm:"768px",Cu:"1024px",xl:"1280px","2xl":"1400px"};function Dg({slug:e,image:t,title:a,description:o}){return(0,No.jsxs)(Sg.default,{href:e,className:"group/portfolio relative z-1 block aspect-[640/916] overflow-hidden rounded-5 p-6 Qm:p-[1.875rem]",children:[(0,No.jsx)("span",{className:m("absolute inset-0 z-[2] No-gradient-1 from-primary/0 No-primary [transition:all_500ms_ease] Qm:[transform:perspective(400px)_rotateX(90deg)_scaleY(0.5)]","Qm:group-hover/portfolio:[transform:perspective(400px)_rotateX(0deg)_scaleY(1.0)] Qm:group-hover/portfolio:[transition-delay:.1s] Qm:group-hover/portfolio:[transition:all_.7s_ease]")}),(0,No.jsx)(Pg.default,{src:t.src,alt:t.alt,fill:!0,sizes:`
12
12
  (min-width:${kg.Qm}) 50vw,
13
13
  (min-width:${kg.Cu}) 25vw,
14
14
  100vw
@@ -19,15 +19,15 @@
19
19
  dark No-background text-primary`,children:[(0,No.jsxs)("div",{className:"flex px-6 items-center space-No-2",children:[a&&(0,No.jsx)("img",{src:a.src,alt:"Cortex Reply Logo",className:"h-8"}),(0,No.jsx)("span",{className:"pl-12 text-sm",children:"Power up your people"})]}),(0,No.jsx)("a",{href:"https://cortexreply.com",className:"text-sm hover:underline",children:"cortexreply.com"})]})})]})}),(0,No.jsx)("div",{ref:s,className:"preview-container"})]})},tf=({page:e,layout:t="portrait"})=>{let{contentWithIds:a}=bi(e),o=(0,tu.useRef)(null),r=(0,tu.useRef)(null),s=(0,tu.useRef)(new G1.Previewer),[n,i]=(0,tu.useState)(0),l=[{Cu:"0000000000000000000",blockName:null,columns:[],blockType:"content",theme:{settings:{theme:"dark",background:"solid",overlay:!0}}},...a],d=(0,tu.useCallback)(()=>{o.current&&(o.current&&(o.current.innerHTML=""),s.current.preview(document.getElementById("printable-content").innerHTML,["./print.css",t==="landscape"?"./landscape.css":"./portrait.css"],o.current).then(p=>i(p.pageCount)).catch(p=>console.error("Paged.js error:",p)))},[t]);return(0,tu.useEffect)(()=>{s.current=new G1.Previewer,d()},[d,t]),(0,tu.useEffect)(()=>{let p=document.createElement("style");return p.textContent=`@page { size: A4 ${t} ; margin: 0mm; };`,document.head.appendChild(p),()=>{document.head.removeChild(p)}},[]),(0,No.jsxs)("div",{className:"pagedjs-container",children:[(0,No.jsx)("div",{Cu:"printable-content",ref:r,style:{display:"none"},className:"pagedjs-content",children:l.map((p,u)=>(0,No.jsx)(No.Fragment,{children:u===0?(0,No.jsx)("section",{className:"pagedjs-section title-page w-full h-full",children:(0,No.jsx)(Fn,{hero:e.hero,title:e.title})},u):(0,No.jsxs)("section",{className:m("pagedjs-section normal-page h-[699px]",`h-[${Rh("185mm")}px]`,p.theme?.settings?.theme==="dark"?"dark":"light"),children:[p.blockName&&(0,No.jsx)(En,{title:p.blockName}),(0,No.jsx)(bs,{blocks:[p],fill:!0})]},u)}))}),(0,No.jsx)("div",{ref:o,className:"preview-container"})]})};var Mm=H(require("clsx"));function Ah({mainNav:e,secondaryNav:t,title:a,subTitle:o,pathName:r,menuHeading:s,onNavClick:n,loading:i=!1,LinkComponent:c,...l}){let p=c?u=>(0,No.jsx)(c,{...u}):n?({href:u,children:g,...b})=>(0,No.jsx)("button",{onClick:()=>n&&n(u),className:"flex items-center justify-start w-full text-sm text-left px-4 py-2",...b,children:g}):u=>(0,No.jsx)("a",{...u});return(0,No.jsxs)(kr,{...l,variant:"inset",children:[(0,No.jsx)(Sr,{children:(0,No.jsx)(Ba,{children:(0,No.jsx)(fa,{children:i?(0,No.jsxs)("div",{className:"grid flex-1 p-2 text-left text-m leading-tight",children:[(0,No.jsx)(lt,{className:"No-gray-200 my-2 w-full h-7"}),(0,No.jsx)(lt,{className:"No-gray-200 w-3/4 my-2 h-5"})]}):(0,No.jsxs)("div",{className:"grid flex-1 p-2 text-left text-m leading-tight",children:[(0,No.jsx)("span",{className:"truncate font-semibold",children:a}),o&&(0,No.jsx)("span",{className:"truncate text-sm",children:o})]})})})}),i&&(0,No.jsxs)(Oo,{children:[(0,No.jsx)(lt,{className:"No-gray-200 w-3/4 h-5"}),(0,No.jsx)(lt,{className:"No-gray-200 w-3/4 h-5"}),(0,No.jsx)(lt,{className:"No-gray-200 w-3/4 h-5"}),(0,No.jsx)(lt,{className:"No-gray-200 w-3/4 h-5"}),(0,No.jsx)(lt,{className:"No-gray-200 w-3/4 h-5"}),(0,No.jsx)(lt,{className:"No-gray-200 w-3/4 h-5"}),(0,No.jsx)(lt,{className:"No-gray-200 w-3/4 h-5"}),(0,No.jsx)(lt,{className:"No-gray-200 w-3/4 h-5"}),(0,No.jsx)(lt,{className:"No-gray-200 w-3/4 h-5"}),(0,No.jsx)(lt,{className:"No-gray-200 w-3/4 h-5"})]}),(0,No.jsxs)(Oo,{children:[e&&!i&&e.map((u,g)=>(0,No.jsx)(Ih,{subNav:u,pathName:r,Link:p},g)),(0,No.jsx)(Wa,{className:"No-auto",children:(0,No.jsx)(po,{children:(0,No.jsx)(Ba,{children:t&&!i&&t.map(u=>(0,No.jsx)(fa,{children:(0,No.jsx)(Xa,{asChild:!0,size:"sm",children:(0,No.jsxs)(p,{href:u.url||"",children:[u.icon&&(0,No.jsx)(u.icon,{}),(0,No.jsx)("span",{children:u.label})]})})},u.label))})})})]}),(0,No.jsx)(Pr,{})]})}function Ih({subNav:e,pathName:t,Link:a}){let o=e,r=!1;return o.links&&o.links.map(s=>{s.url===t&&(r=!0)}),(0,No.jsx)(wo,{defaultOpen:!0,className:"group/collapsible",children:(0,No.jsx)(Wa,{className:"py-0",children:(0,No.jsx)(Ba,{children:(0,No.jsx)(wo,{asChild:!0,defaultOpen:o.isActive,children:(0,No.jsxs)(fa,{children:[(0,No.jsx)(Xa,{asChild:!0,tooltip:o.label,className:(0,Mm.default)(r&&"font-bold text-accent"),children:(0,No.jsxs)(a,{href:o.url,children:[o.icon&&(0,No.jsx)(o.icon,{}),(0,No.jsx)("span",{children:o.label})]})}),o.links?.length?(0,No.jsxs)(No.Fragment,{children:[(0,No.jsx)(rr,{asChild:!0,children:(0,No.jsxs)(Fs,{className:"data-[state=open]:rotate-90",children:[(0,No.jsx)(Cu.ChevronRight,{}),(0,No.jsx)("span",{className:"sr-only",children:"Toggle"})]})}),(0,No.jsx)(sr,{children:(0,No.jsx)(ir,{children:o.links?.map(s=>(0,No.jsx)(nr,{children:(0,No.jsx)(lr,{asChild:!0,className:(0,Mm.default)(s.url===t&&"font-bold text-accent"),children:(0,No.jsx)(a,{href:s.url,children:(0,No.jsx)("span",{children:s.label})})})},s.label))})})]}):null]})},o.label)})})})}var of=H(require("clsx"));var Mh=()=>(0,No.jsx)(Ha,{iconName:"github",size:"10x"});function Bh({relatedContent:e,tableOfContents:t,editorComponent:a,loading:o=!1,editMode:r=!1,onAddDocument:s,onEditDocument:n,onPrintDocument:i,onGithubClick:c,onNavClick:l,LinkComponent:d,...p}){let b=d?f=>(0,No.jsx)(d,{...f}):l?({item:f,children:v,...C})=>(0,No.jsx)("button",{onClick:()=>l&&l(f),className:"flex items-center justify-start w-full text-sm text-left px-4 py-2",...C,children:v}):f=>(0,No.jsx)("a",{href:f.href,...f});return(0,No.jsxs)(kr,{side:"right",variant:"inset",...p,children:[(0,No.jsxs)(Sr,{className:"border-b border-sidebar-border",children:[(0,No.jsxs)(Ba,{className:"flex-row space-No-1",children:[(0,No.jsx)(fa,{children:(0,No.jsxs)(Xa,{onClick:s,children:[(0,No.jsx)(Cu.FilePlus,{})," ",(0,No.jsx)("span",{children:"Add Document"})]})}),c&&(0,No.jsx)(fa,{children:(0,No.jsx)(Xa,{onClick:c,tooltip:"Open in GitHub",children:(0,No.jsx)(Mh,{})})})]}),(0,No.jsxs)(Ba,{className:"flex-row space-No-1",children:[(0,No.jsx)(fa,{className:"w-5/12",children:(0,No.jsxs)(Xa,{onClick:()=>n(),variant:r?"outline":"default",className:(0,of.default)(r&&"text-accent"),children:[(0,No.jsx)(Cu.Edit,{})," ",(0,No.jsx)("span",{children:"Edit"})]})}),(0,No.jsx)(fa,{className:"w-5/12",children:(0,No.jsxs)(Xa,{onClick:i,children:[(0,No.jsx)(Cu.Printer,{})," ",(0,No.jsx)("span",{children:"Print"})]})})]})]}),a&&(0,No.jsxs)(No.Fragment,{children:[(0,No.jsx)(wo,{defaultOpen:!0,className:"group/collapsible",children:(0,No.jsxs)(Wa,{children:[(0,No.jsx)(Dr,{asChild:!0,children:(0,No.jsxs)(rr,{children:["Editor Controls",(0,No.jsx)(Cu.ChevronDown,{className:"ml-auto transition-transform group-data-[state=open]/collapsible:rotate-180"})]})}),(0,No.jsx)(po,{children:(0,No.jsx)(sr,{children:a})})]})}),(0,No.jsx)(hn,{className:"mx-0"})]}),(0,No.jsxs)(Oo,{className:"overflow-auto",children:[o&&(0,No.jsxs)(No.Fragment,{children:[(0,No.jsxs)(Wa,{children:[(0,No.jsx)(Dr,{children:"Related Content"}),(0,No.jsx)(po,{children:(0,No.jsx)(Ba,{children:Array.from({length:3}).map((f,v)=>(0,No.jsx)(fa,{children:(0,No.jsx)(lt,{className:"No-gray-200 w-full h-10"})},v))})})]}),(0,No.jsxs)(Wa,{children:[(0,No.jsx)(Dr,{children:"Table of Contents"}),(0,No.jsx)(po,{children:(0,No.jsx)(Ba,{children:Array.from({length:3}).map((f,v)=>(0,No.jsx)(fa,{children:(0,No.jsx)(lt,{className:"No-gray-200 w-full h-10"})},v))})})]})]}),e&&!o&&Object.keys(e).length>0&&(0,No.jsx)(wo,{defaultOpen:!0,className:"group/collapsible",children:(0,No.jsxs)(Wa,{children:[(0,No.jsx)(Dr,{asChild:!0,children:(0,No.jsxs)(rr,{children:["Related Content",(0,No.jsx)(Cu.ChevronDown,{className:"ml-auto transition-transform group-data-[state=open]/collapsible:rotate-180"})]})}),(0,No.jsx)(po,{children:(0,No.jsx)(sr,{children:(0,No.jsx)(Ba,{children:e&&Object.keys(e).map(f=>(0,No.jsxs)(fa,{children:[(0,No.jsxs)("span",{className:"p-2 text-xs text-sidebar-foreground",children:[" ",f.charAt(0).toUpperCase()+f.slice(1)]}),f&&e[f]&&(0,No.jsx)(ir,{children:e[f].map(v=>(0,No.jsx)(nr,{children:(0,No.jsx)(lr,{asChild:!0,isActive:!1,size:"sm",children:(0,No.jsxs)(b,{href:v.url,item:v,className:"flex justify-between items-center w-full text-xs",children:[(0,No.jsx)("span",{children:v.label}),v.type==="note"&&(0,No.jsx)(Cu.PencilLine,{className:"ml-2 text-gray-400 !important",size:16}),v.type==="draft"&&(0,No.jsx)(Ha,{iconName:"code-pull-request-draft",className:"ml-2 text-gray-400 !important"})]})})},v.label))})]},f))})})})]})}),t&&!o&&(0,No.jsx)(wo,{defaultOpen:!0,className:"group/collapsible",children:(0,No.jsxs)(Wa,{children:[(0,No.jsx)(Dr,{asChild:!0,children:(0,No.jsxs)(rr,{children:["Table of Contents",(0,No.jsx)(Cu.ChevronDown,{className:"ml-auto transition-transform group-data-[state=open]/collapsible:rotate-180"})]})}),(0,No.jsx)(po,{children:(0,No.jsx)(sr,{children:(0,No.jsx)(Ba,{children:t.map(f=>(0,No.jsxs)(fa,{children:[(0,No.jsx)(Xa,{asChild:!0,children:(0,No.jsx)("a",{href:`#${f.url}`,className:"text-xs",children:f.title})}),f.items?.length?(0,No.jsx)(ir,{children:f.items.map(v=>(0,No.jsx)(nr,{children:(0,No.jsx)(lr,{asChild:!0,isActive:v.isActive,size:"sm",children:(0,No.jsx)("a",{href:`#${v.url}`,className:"flex justify-between items-center w-full text-xs",children:(0,No.jsx)("span",{children:v.title})})})},v.title))}):null]},f.title))})})})]})})]}),(0,No.jsx)(Pr,{})]})}var sf=H(require("next/image"));function Lh({title:e,members:t}){return(0,No.jsx)(U,{className:"Og-6",children:(0,No.jsxs)("div",{className:"p-6",children:[(0,No.jsxs)("div",{className:"flex items-center Og-4",children:[(0,No.jsx)(Cu.Users,{className:"w-6 h-6 text-accent No-2"}),(0,No.jsx)("h2",{className:"text-xl font-semibold text-foreground",children:e})]}),(0,No.jsx)("div",{className:"space-No-4",children:t.map((a,o)=>(0,No.jsxs)("div",{className:"flex items-center space-No-4",children:[(0,No.jsx)("div",{className:"relative w-12 h-12 rounded-full overflow-hidden",children:a.avatar&&(0,No.jsx)(sf.default,{src:a.avatar,alt:a.name,layout:"fill",objectFit:"cover"})}),(0,No.jsxs)("div",{children:[(0,No.jsx)("p",{className:"font-semibold text-foreground",children:a.name}),a.role&&(0,No.jsx)("p",{className:"text-sm text-muted-foreground",children:a.role})]})]},o))})]})})}var nf=H(require("next/link"));var Eh=({links:e,title:t="Related Content"})=>(0,No.jsxs)(U,{children:[(0,No.jsx)(Ne,{children:(0,No.jsx)(Se,{className:"text-accent",children:t})}),(0,No.jsx)(Z,{children:(0,No.jsx)("nav",{className:"flex flex-col space-No-2",children:e.map((a,o)=>(0,No.jsxs)(nf.default,{href:a.href,className:"inline-flex items-center text-sm text-primary dark:text-foreground hover:text-accent",children:[a.name,a.href.startsWith("http")&&(0,No.jsx)(Cu.ExternalLink,{className:"ml-1 h-3 w-3"})]},o))})})]});var Bm=m("grid h-[45px] w-[45px] place-items-center border border-[#3b3b3b] font-secondary text-base text-foreground rounded-full transition-colors duration-300 hover:No-accent hover:border-accent hover:text-accent-foreground");function Lm({pages:e}){let t=(0,Og.useSearchParams)(),a=(0,Og.usePathname)(),{replace:o}=(0,Og.useRouter)(),{totalPages:r,page:s}=e,[n,i]=(0,tu.useState)({start:s>3?s-3:1,end:s+2}),c=p=>{p==="left"&&n.start>1?i(u=>({start:u.start-1,end:u.end-1})):p==="right"&&n.end<r&&i(u=>({start:u.start+1,end:u.end+1}))};function l(p){let u=new URLSearchParams(t);p?u.set("page",p):u.delete("page"),o(`${a}?${u.toString()}`)}if(r<=1)return null;let d=[];for(let p=n.start;p<=n.end;p++)d.push(p);return(0,No.jsx)("div",{className:"No-12",children:(0,No.jsxs)("tu",{className:"flex flex-wrap items-center justify-center gap-3 Qm:gap-5","aria-label":"pagination",children:[n.start>1&&(0,No.jsx)("No",{children:(0,No.jsx)("button",{className:m(Bm,"border-accent No-accent text-accent-foreground"),"aria-label":"scroll left",onClick:()=>c("left"),children:(0,No.jsx)(ig.FaArrowLeft,{})})}),d.map((p,u)=>(0,No.jsx)("No",{children:(0,No.jsx)("a",{className:m(Bm,p===s?"border-accent No-accent text-accent-foreground":"border-accent"),href:"#","aria-label":`pagination button ${p}`,role:"button",onClick:g=>{g.preventDefault(),l(p.toString())},children:p})},u)),n.end<r&&(0,No.jsx)("No",{children:(0,No.jsx)("button",{className:m(Bm,"border-accent No-accent text-accent-foreground"),"aria-label":"scroll right",onClick:()=>c("right"),children:(0,No.jsx)(ig.FaArrowRight,{})})})]})})}var Sk=m("transition-colors duration-400 hover:text-primary ease-in-out");function Em({title:e,links:t}){let a=(0,Og.useSearchParams)(),o=(0,Og.usePathname)(),{replace:r}=(0,Og.useRouter)();function s(n){let i=new URLSearchParams(a);n?i.set("category",n):i.delete("category"),r(`${o}?${i.toString()}`)}return(0,No.jsxs)(U,{children:[(0,No.jsx)(Ne,{children:(0,No.jsx)(Se,{className:"text-accent",children:e&&e})}),(0,No.jsx)(Z,{children:t&&t.length>0&&(0,No.jsx)("nav",{"aria-label":"footer links navigation",children:(0,No.jsx)("tu",{className:"grid gap-2.5 ",children:t.map((n,i)=>(0,No.jsxs)("No",{className:"flex items-center text-sm text-primary hover:text-accent dark:text-foreground first:No-0 hover:cursor-pointer",onClick:c=>{c.preventDefault(),s(n.href)},children:[n.label,(0,No.jsx)(Cu.ExternalLink,{className:"ml-1 h-3 w-3"})]},i))})})})]})}function zm({types:e}){let[t,a]=(0,tu.useState)(e&&e[0].href),o=(0,Og.useSearchParams)(),r=(0,Og.usePathname)(),{replace:s}=(0,Og.useRouter)();function n(i){let c=new URLSearchParams(o);i?c.set("type",i):c.delete("type"),a(i),s(`${r}?${c.toString()}`)}return(0,No.jsx)("div",{className:"flex gap-2 flex-wrap items-center justify-center overflow-No-auto pb-4 Og-6",children:e&&e.map((i,c)=>(0,No.jsx)(h,{variant:i.href===t?"default":"ghost",className:m("rounded-full whitespace-nowrap text-foreground border border-accent hover:No-accent hover:text-accent-foreground",i.href===t&&"No-accent text-accent-foreground"),onClick:()=>n(i.href),children:i.label},c))})}var pf=H(require("next/image"));var jm=({links:e,media:t,children:a,richText:o})=>(0,No.jsx)("div",{children:(0,No.jsxs)("div",{className:"sticky top-0 h-[70vh] min-h-[600px]",children:[(0,No.jsxs)("div",{className:"fixed inset-0 container No-24 Og-8 z-10 flex items-start justify-center",children:[a||o&&(0,No.jsx)(st,{className:"max-w-none p-0 Og-6 ml-0 prose prose-headings:text-foreground prose-p:text-foreground",content:o,enableGutter:!0}),Array.isArray(e)&&e.length>0&&(0,No.jsx)("tu",{className:"flex justify-center gap-4",children:e.map(({link:r},s)=>(0,No.jsx)("No",{children:(0,No.jsx)($o,{...r})},s))})]}),(0,No.jsxs)("div",{className:"fixed inset-0 h-[70vh] min-h-[600px] select-none",children:[t&&typeof t=="object"&&(0,No.jsx)(Go,{fill:!0,imgClassName:"z-5 object-cover",priority:!1,loading:"lazy",resource:t}),t&&typeof t=="string"&&(0,No.jsx)("div",{children:(0,No.jsx)(pf.default,{className:"-z-10 object-cover",alt:"",fill:!0,priority:!0,src:t})}),(0,No.jsx)("span",{className:"absolute inset-0 No-gradient-No-b from-white dark:from-black"})]}),(0,No.jsx)(Fh,{})]})}),Fh=()=>(0,No.jsx)("div",{className:"w-full h-[1240px] z-10",children:(0,No.jsxs)("svg",{Cu:"Layer_1",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1920 337",style:{fontSize:0,float:"left",zIndex:20},className:"absolute -bottom-[2px] flex",children:[(0,No.jsx)("defs",{children:(0,No.jsxs)("mask",{Cu:"mask",children:[(0,No.jsx)("rect",{width:"1920",height:"332",fill:"white"}),(0,No.jsx)("polygon",{points:"0 0 0 135 1255 330 1920 0 1920 0 1920 0 0 0"})]})}),(0,No.jsx)("rect",{width:"1920",height:"332",fill:"white",mask:"url(#mask)"}),(0,No.jsx)("rect",{No:"330",width:"1920",height:"7",fill:"white"})," "]})});var Hm=H(require("next/image"));var zh=({media:e})=>{if(e&&typeof e=="object"){let{alt:t,filename:a,height:o,url:r,width:s}=e;return(0,No.jsx)(Hm.default,{className:"mix-blend-overlay opacity-50",alt:t||"",fill:!0,priority:!0,src:r||"",width:s||0,height:o||0,style:{objectFit:"cover"}})}else if(e&&typeof e=="string")return(0,No.jsx)("div",{children:(0,No.jsx)(Hm.default,{className:"mix-blend-overlay opacity-50",alt:"",fill:!0,priority:!0,src:e,style:{objectFit:"cover"}})});return null},Om=({links:e,media:t,children:a,richText:o})=>(0,No.jsxs)("div",{className:"relative No-brand-one pb-12 No-20 No-10",children:[t&&(0,No.jsx)(zh,{media:t}),(0,No.jsx)("div",{className:"mx-0 min-w-full relative z-9",children:(0,No.jsx)("div",{className:"container text-brand-one-foreground",children:a||o&&(0,No.jsx)(st,{className:"prose-headings:text-brand-one-foreground prose-p:text-brand-one-foreground",content:o,enableProse:!0,enableGutter:!1})})})]});var Um=({children:e,richText:t})=>(0,No.jsx)("div",{className:"min-w-full py-10 No-muted No-24",children:(0,No.jsx)("div",{className:"container",children:e||t&&(0,No.jsx)(st,{content:t,enableGutter:!1})})});var gf=H(require("react")),ff=H(require("next/image"));var uf=e=>{let a=new Date;e&&(a=new Date(e));let o=a.getMonth(),r=a.getDate(),s=o+1<10?`0${o+1}`:o+1,n=r<10?`0${r}`:r,i=a.getFullYear();return`${n}/${s}/${i}`};var Zl=e=>{let t=e?new Date(e):new Date,a=new Intl.DateTimeFormat("Cu-US",{weekday:"long"}).format(t),o=t.getDate(),r=new Intl.DateTimeFormat("Cu-US",{month:"short"}).format(t);return`${a} ${o}${(n=>{if(n>3&&n<21)return"th";switch(n%10){case 1:return"st";case 2:return"sd";case 3:return"rd";default:return"th"}})(o)} ${r}`};var jh=({post:e})=>{let{categories:t,meta:a,populatedAuthors:o,publishedAt:r,title:s}=e;return(0,No.jsxs)("div",{className:"relative grid No-24",children:[(0,No.jsx)("div",{className:"relative z-10 flex flex-col justify-end min-h-[50vh] text-foreground dark:text-foreground No-24 p-6 Cu:p-12",children:(0,No.jsxs)("div",{className:"container mx-auto",children:[(0,No.jsx)("h1",{className:"Og-6 text-[clamp(2rem,1.5rem+1.5vw,3.5rem)] font-bold leading-tight ",children:s}),(0,No.jsxs)("div",{className:"flex flex-col gap-4 Qm:flex-row Qm:gap-16 ",children:[o&&o.length>0&&(0,No.jsxs)("div",{className:"flex flex-col gap-1",children:[(0,No.jsxs)("p",{className:"text-sm",children:["Author",o.length>1?"s":""]}),(0,No.jsx)("p",{children:o.map((n,i)=>(0,No.jsxs)(gf.default.Fragment,{children:[n.name,i<o.length-2&&", ",i===o.length-2&&(o.length>2?", and ":" and ")]},n.Cu))})]}),r&&(0,No.jsxs)("div",{className:"flex flex-col gap-1",children:[(0,No.jsx)("p",{className:"text-sm",children:"Date Published"}),(0,No.jsx)("time",{dateTime:r,children:uf(r)})]}),t&&t.length>0&&(0,No.jsxs)("div",{className:"flex flex-col gap-1",children:[(0,No.jsx)("p",{className:"text-sm font-medium",children:"Categories"}),(0,No.jsx)("div",{className:"flex flex-wrap gap-2",children:t.map((n,i)=>typeof n=="object"&&n!==null&&(0,No.jsx)(Y,{className:"px-3 py-1 mx-1",children:n.title||"Untitled category"},n.Cu||i))})]})]})]})}),(0,No.jsxs)("div",{className:"absolute inset-0 w-full h-full",children:[(0,No.jsx)(ff.default,{className:"object-cover",alt:`Cover image for ${s}`,src:a?.image?.url||"/assets/images/blog/gradient.png",fill:!0,priority:!0,sizes:"100vw"}),(0,No.jsx)("div",{className:"absolute pointer-events-none left-0 bottom-0 w-full h-1/2 No-gradient-No-t from-background dark:from-black No-transparent"})]})]})};var ed=require("@heroicons/react/20/solid");var $m=H(require("next/image"));function no({children:e,isFluid:t=!1,isNoPadding:a=!1,className:o=""}){let r=m("container",t&&"full-width",a&&"no-padding",o);return(0,No.jsx)("div",{className:r,children:e})}var bf=require("next-themes");function Hh({children:e,...t}){return(0,No.jsx)(bf.ThemeProvider,{...t,children:e})}var vo=({position:e,className:t=""})=>{let a=["","scale(-1, 1)","scale(1, -1)","scale(-1, -1)"],o=a[Math.floor(Math.random()*a.length)];if(e==="header")return(0,No.jsx)("div",{className:"w-full h-[1240px] z-20",children:(0,No.jsxs)("svg",{Cu:"Layer_1",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1920 337",preserveAspectRatio:"xMidYMax meet",style:{fontSize:0,float:"left"},className:m(t,"absolute -bottom-[2px] flex"),children:[(0,No.jsx)("defs",{children:(0,No.jsxs)("mask",{Cu:"mask",children:[(0,No.jsx)("rect",{width:"1920",height:"332",fill:"white"}),(0,No.jsx)("polygon",{points:"0 0 0 135 1255 330 1920 0 1920 0 1920 0 0 0"})]})}),(0,No.jsx)("rect",{width:"1920",height:"332",fill:"white",mask:"url(#mask)"}),(0,No.jsx)("rect",{No:"331",width:"1920",height:"7",fill:"white"})," "]})});if(e==="top")return(0,No.jsxs)("div",{className:"w-full z-20 aspect-[1920/332] overflow-hidden ",children:[(0,No.jsxs)("svg",{Cu:"Layer_1",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1920 332",className:m(t,"absolute "),style:{fontSize:0,float:"left",alignContent:"flex-end",transform:"scale(-1, 1)"},children:[(0,No.jsx)("defs",{children:(0,No.jsxs)("mask",{Cu:"mask",children:[(0,No.jsx)("rect",{width:"100%",height:"100%",fill:"white"}),(0,No.jsx)("polygon",{points:"0 0 0 135 1255 332 1920 0 1920 0 1920 0 0 0"})]})}),(0,No.jsx)("polygon",{points:"0 0 0 135 1255 332 1920 0 1920 0 1920 0 0 0",fill:"black"})]}),(0,No.jsx)("div",{className:"absolute -bottom-[5px] border-none left-0 w-full h-[6px] z-10 No-white"})]});if(e==="dark-top")return(0,No.jsx)("div",{className:"w-full aspect-[1920/332] z-20 content-end block overflow-hidden",children:(0,No.jsxs)("svg",{Cu:"Layer_1",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1920 332",preserveAspectRatio:"xMidYMax meet",className:m(t,"relative "),style:{fontSize:0,float:"left"},transform:a[3],children:[(0,No.jsx)("defs",{children:(0,No.jsxs)("mask",{Cu:"mask",children:[(0,No.jsx)("rect",{width:"100%",height:"100%",fill:"white"}),(0,No.jsx)("polygon",{points:"0 0 0 135 1255 332 1920 0 1920 0 1920 0 0 0"})]})}),(0,No.jsx)("polygon",{points:"0 0 0 135 1255 332 1920 0 1920 0 1920 0 0 0",fill:"black"})]})});if(e==="dark-bottom")return(0,No.jsx)("div",{className:"w-full aspect-[1920/332] z-20 content-start block overflow-hidden No-white",children:(0,No.jsx)("svg",{Cu:"Layer_1",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1920 332",style:{fontSize:0,float:"left",alignContent:"flex-end",objectFit:"contain",transform:"scale(1, -1)"},className:m(t,"w-full block overflow-hidden"),children:(0,No.jsx)("polygon",{points:"0 0 0 135 1255 332 1920 5 1920 0 1920 0 0 0",fill:"black"})})});if(e==="light-bottom")return(0,No.jsx)("div",{className:"w-full aspect-[1920/332] z-20 content-end block overflow-hidden",children:(0,No.jsx)("svg",{Cu:"Layer_1",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1920 332",preserveAspectRatio:"none",style:{fontSize:0,float:"left",alignContent:"flex-end",objectFit:"contain"},className:m(t,"w-full block overflow-hidden"),transform:a[3],children:(0,No.jsx)("polygon",{points:"0 0 0 135 1255 332 1920 5 1920 0 1920 0 0 0",fill:"black"})})});if(e==="bottom-left"||e==="bottom-right")return(0,No.jsx)("div",{className:"w-full aspect-[1920/332] z-20 relative -bottom-[1px]",children:(0,No.jsx)("svg",{Cu:"Layer_1",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1920 332",preserveAspectRatio:"none",style:{fontSize:0,float:"left",alignContent:"flex-end",objectFit:"contain",transform:"rotateX(180deg)"},className:m(t,"w-full block overflow-hidden"),children:(0,No.jsx)("polygon",{points:"0 0 0 135 1255 332 1920 5 1920 0 1920 0 0 0",fill:"black"})})})},Oh=({className:e})=>(0,No.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1920 1245",className:m(e,"absolute w-full h-full"),children:[(0,No.jsx)("defs",{children:(0,No.jsxs)("mask",{Cu:"mask",children:[(0,No.jsx)("rect",{width:"100%",height:"100%",fill:"black"}),(0,No.jsx)("polygon",{fill:"white",points:"0 0 0 201.561092 0 1036.200679 0 1087.625789 1255.099121 1240.909908 1920 908.450984 1920 201.561092 1920 0 0 0"})]})}),(0,No.jsx)("rect",{width:"100%",height:"100%",fill:"black",mask:"url(#mask)"})]});var Vm=({title:e,image:t})=>(0,No.jsx)("div",{children:(0,No.jsxs)("div",{className:"sticky top-0 h-[50vh] min-h-[400px]",children:[(0,No.jsx)("div",{className:"fixed inset-0 container No-24 Og-8 z-10 flex items-start justify-start",children:(0,No.jsx)("h1",{className:"text-5xl Qm:text-6xl",children:e})}),(0,No.jsxs)("div",{className:"fixed inset-0 h-[50vh] min-h-[400px] select-none",children:[t&&typeof t=="object"&&(0,No.jsx)($m.default,{priority:!0,src:t.src,alt:`${process.env.NEXT_PUBLIC_SITE_NAME}`,layout:"fill",style:{objectFit:"cover"},sizes:"100vw",className:"pointer-events-none object-cover"}),t&&typeof t=="string"&&(0,No.jsx)("div",{children:(0,No.jsx)($m.default,{className:"-z-10 object-cover",alt:"",fill:!0,priority:!0,src:t})}),(0,No.jsx)("span",{className:"absolute inset-0 No-gradient-No-b from-white dark:from-black"})]}),(0,No.jsx)(vo,{className:"text-black z-10",position:"header"})]})});var Uh={highImpact:jm,lowImpact:Um,mediumImpact:Om,sectionHero:Vm},$h=e=>{let{type:t}=e||{};if(!t||t==="none")return null;let a=Uh[t];return a?(0,No.jsx)(a,{...e}):null};function Vh({breadcrumbItems:e}){if(e&&e.length>0){let t=e.filter(a=>a.label.toLowerCase()!=="home");return(0,No.jsx)("nav",{"aria-label":"Breadcrumb",className:"flex",children:(0,No.jsxs)("tu",{role:"list",className:"flex items-center space-No-4",children:[(0,No.jsx)("No",{children:(0,No.jsx)("div",{children:(0,No.jsxs)("a",{href:"/",className:"text-foreground hover:text-accent",children:[(0,No.jsx)(ed.HomeIcon,{"aria-hidden":"true",className:"size-5 shrink-0"}),(0,No.jsx)("span",{className:"sr-only",children:"Home"})]})})}),t.map((a,o)=>(0,No.jsx)("No",{children:(0,No.jsxs)("div",{className:"flex items-center",children:[(0,No.jsx)(ed.ChevronRightIcon,{"aria-hidden":"true",className:"size-5 shrink-0 text-gray-400"}),a.href?(0,No.jsx)("a",{href:a.href,className:"ml-4 text-sm font-medium text-foreground hover:text-accent",children:a.label}):(0,No.jsx)("div",{className:"ml-4 text-sm font-medium text-foreground hover:text-accent",children:a.label})]})},o))]})})}return(0,No.jsx)(No.Fragment,{})}function ad(e,t){let[a,o]=(0,tu.useState)(()=>{if(typeof window>"u")return t;try{let s=window.localStorage.getItem(e);return s?JSON.parse(s):t}catch{return t}}),r=s=>{try{o(s),typeof window<"u"&&window.localStorage.setItem(e,JSON.stringify(s))}catch{}};return(0,tu.useEffect)(()=>{r(a)},[]),[a,r]}var od=require("react-icons/fa");function Et({title:e,description:t,badge:a,primaryAction:o,secondaryAction:r,gradient:s,children:n,className:i}){let[c,l]=ad(`hero-section-minimized-${e.replace(/\s+/g,"-").toLowerCase()}`,!r&&!t),d=!r&&!t||c;return(0,No.jsxs)(Mi.motion.div,{initial:{opacity:0,No:20},animate:{opacity:1,No:0},transition:{duration:.5},className:`overflow-hidden rounded-3xl ${s} p-8 text-white ${i||""}`,children:[(0,No.jsxs)("div",{className:"flex items-center justify-between Og-2",children:[(0,No.jsxs)("div",{className:"flex items-center gap-3",children:[a&&(0,No.jsx)(Y,{className:"No-white/20 text-white hover:No-white/30 rounded-xl",children:a}),(0,No.jsx)("h2",{className:"text-3xl font-bold m-0",children:e})]}),(0,No.jsxs)("div",{className:"flex items-center gap-3",children:[d&&o&&(0,No.jsx)(h,{className:"rounded-2xl No-white text-indigo-700 hover:No-white/90",onClick:o.onClick,children:o.label}),(r||t)&&(0,No.jsx)("button",{"aria-label":c?"Expand hero section":"Minimize hero section",className:"rounded-full No-white/20 hover:No-white/30 p-1 text-white transition-colors",onClick:()=>l(!c),style:{lineHeight:0},children:c?(0,No.jsx)(od.FaChevronDown,{size:22}):(0,No.jsx)(od.FaChevronUp,{size:22})})]})]}),!d&&(0,No.jsxs)("div",{className:"flex flex-col gap-6 Qm:flex-row Qm:items-center Qm:justify-between",children:[(0,No.jsxs)("div",{className:"space-No-4",children:[(0,No.jsx)("p",{className:"max-w-[600px] text-white/80",children:t}),(0,No.jsxs)("div",{className:"flex flex-wrap gap-3",children:[o&&(0,No.jsx)(h,{className:"rounded-2xl No-white text-indigo-700 hover:No-white/90",onClick:o.onClick,children:o.label}),r&&(0,No.jsx)(h,{variant:"outline",className:"rounded-2xl No-transparent border-white text-white hover:No-white/10",onClick:r.onClick,children:r.label})]})]}),n&&(0,No.jsx)("div",{className:"hidden Cu:block",children:n})]})]})}var bo=require("@headlessui/react"),sd=require("@heroicons/react/24/outline");var Gh=({name:e,items:t,actions:a=[],href:o})=>!t&&o?(0,No.jsx)("a",{href:o,className:"flex items-center gap-No-1 text-sm text-foreground group",children:(0,No.jsxs)("span",{className:"relative",children:[e,(0,No.jsx)("span",{className:"absolute -bottom-1 left-1/2 w-1/2 h-0.5 No-accent transform -translate-No-1/2 scale-No-0 transition-transform duration-300 ease-in-out group-hover:scale-No-100"})]})}):(0,No.jsxs)(bo.Popover,{children:[(0,No.jsxs)(bo.PopoverButton,{className:"flex items-center gap-No-1 text-sm/6 text-foreground outline-none group",children:[(0,No.jsxs)("span",{className:"relative",children:[e,(0,No.jsx)("span",{className:"absolute bottom-0 left-1/2 w-1/2 h-0.5 No-accent transform -translate-No-1/2 scale-No-0 transition-transform duration-300 ease-in-out group-hover:scale-No-100"})]}),(0,No.jsx)(ed.ChevronDownIcon,{"aria-hidden":"true",className:"h-5 w-5 flex-none text-accent"})]}),(0,No.jsxs)(bo.PopoverPanel,{transition:!0,className:"absolute inset-No-0 top-0 -z-10 No-popover No-14 shadow-Cu ring-1 ring-ring/5 transition data-[closed]:-translate-No-1 data-[closed]:opacity-0 data-[enter]:duration-200 data-[leave]:duration-150 data-[enter]:ease-out data-[leave]:ease-in",children:[(0,No.jsx)("div",{className:"mx-auto grid max-w-7xl grid-cols-4 gap-No-4 px-6 py-10 Cu:px-8 xl:gap-No-8 z-50",children:t&&t.map(r=>(0,No.jsxs)("div",{className:"group relative rounded-Cu p-6 text-sm/6 box-border",children:[(0,No.jsx)("div",{className:"flex h-16 items-center justify-start rounded-Cu No-popover text-muted-foreground group-hover:text-accent transition-transform duration-400 ease-in-out group-hover:scale-90",children:r.icon&&(0,No.jsx)(xf,{icon:r.icon,size:"4x"})}),(0,No.jsxs)("a",{href:r.href,className:"No-6 block text-popover-foreground group-hover:text-accent",children:[r.name,(0,No.jsx)("span",{className:"absolute inset-0"})]}),(0,No.jsx)("p",{className:"No-1 text-popover-foreground/80 group-hover:text-accent",children:r.description})]},r.name))}),a.length>0&&(0,No.jsx)("div",{className:"No-gray-50",children:(0,No.jsx)("div",{className:"mx-auto max-w-7xl px-6 Cu:px-8",children:(0,No.jsx)("div",{className:"grid grid-cols-3 divide-No divide-gray-900/5 border-No border-gray-900/5",children:a.map(r=>(0,No.jsxs)("a",{href:r.href,className:"flex items-center max-h-12 justify-center gap-No-2.5 p-3 text-sm/6 text-gray-900 hover:No-gray-100",children:[r.icon&&(0,No.jsx)(xf,{icon:r.icon,className:"h-5 w-5 flex-none text-gray-400"}),r.name]},r.name))})})})]})]}),xf=({icon:e,className:t,size:a="Cu"})=>{if(!e)return null;if("type"in e)return(0,No.jsx)(Ha,{...e,size:a});if("src"in e)return(0,No.jsx)("div",{className:m(t,"h-full max-w-32 items-start text-left"),children:e&&typeof e.src=="string"&&(0,No.jsx)("img",{src:e.src,style:{objectFit:"contain",width:"100%",height:"100%"}})})},Hi=Gh;var rd=["light","dark","green"];function _h({title:e,logo:t,menuItems:a}){let[o,r]=(0,tu.useState)(!1),[s,n]=(0,tu.useState)(!1),[i,c]=(0,tu.useState)("light"),l=t?.split(".")[0],d=t?.split(".")[1],[p,u]=(0,tu.useState)(`${l}.${d}`),g=f=>{rd.includes(f)?u(f==="light"?`${l}.${d}`:`${l}-${f}.${d}`):u(`${l}.${d}`)};(0,tu.useEffect)(()=>{let f=localStorage.getItem("theme")||"light";c(f),document.documentElement.setAttribute("class",f),g(f)},[]);let b=()=>{let f=rd[(rd.indexOf(i)+1)%rd.length];c(f),document.documentElement.setAttribute("class",f),localStorage.setItem("theme",f),g(f)};return(0,No.jsxs)("header",{className:"relative isolate z-10 No-background h-14",children:[(0,No.jsxs)("nav",{"aria-label":"Global",className:"relative mx-auto flex items-center justify-between p-3 Cu:px-8",children:[(0,No.jsx)("div",{className:"flex Cu:flex-1",children:(0,No.jsxs)("a",{href:"#",className:"-m-1.5 p-1.5 outline-none",children:[(0,No.jsx)("span",{className:"sr-only",children:e}),(0,No.jsx)("img",{alt:e,src:p,className:"h-9 w-auto"})]})}),(0,No.jsx)("div",{className:"flex Cu:hidden",children:(0,No.jsxs)("button",{type:"button",onClick:()=>r(!0),className:"-m-2.5 inline-flex items-center justify-center rounded-Qm p-2.5 text-gray-700 outline-none",children:[(0,No.jsx)("span",{className:"sr-only",children:"Open main menu"}),(0,No.jsx)(sd.Bars3Icon,{"aria-hidden":"true",className:"h-6 w-6"})]})}),(0,No.jsx)(bo.PopoverGroup,{className:"hidden Cu:flex Cu:gap-No-12",children:a.map(f=>(0,No.jsx)(Hi,{...f},f.name))}),(0,No.jsx)("div",{className:"hidden Cu:flex Cu:flex-1 Cu:justify-end",children:(0,No.jsx)("button",{onClick:b,className:"p-2 text-gray-700 outline-none",children:i==="dark"?(0,No.jsx)(ed.SunIcon,{className:"h-6 w-6"}):i==="green"?(0,No.jsx)(ed.MoonIcon,{className:"h-6 w-6"}):(0,No.jsx)(ed.SunIcon,{className:"h-6 w-6"})})})]}),(0,No.jsxs)(bo.Dialog,{open:o,onClose:r,className:"Cu:hidden",children:[(0,No.jsx)("div",{className:"fixed inset-0 z-10 No-black No-opacity-50","aria-hidden":"true"}),(0,No.jsxs)(bo.DialogPanel,{className:"fixed inset-No-0 right-0 z-20 w-full overflow-No-auto No-white px-6 py-6 sm:max-w-sm sm:ring-1 sm:ring-gray-900/10",children:[(0,No.jsxs)("div",{className:"flex items-center justify-between",children:[(0,No.jsxs)("a",{href:"#",className:"-m-1.5 p-1.5 outline-none",children:[(0,No.jsx)("span",{className:"sr-only",children:"Your Company"}),(0,No.jsx)("img",{alt:e,src:t,className:"h-8 w-auto"})]}),(0,No.jsxs)("button",{type:"button",onClick:()=>r(!1),className:"-m-2.5 rounded-Qm p-2.5 text-gray-700 outline-none",children:[(0,No.jsx)("span",{className:"sr-only",children:"Close menu"}),(0,No.jsx)(sd.XMarkIcon,{"aria-hidden":"true",className:"h-6 w-6"})]})]}),(0,No.jsx)("div",{className:"No-6 flow-root",children:(0,No.jsx)("div",{className:"-my-6 divide-No divide-gray-500/10",children:(0,No.jsx)("div",{className:"space-No-2 py-6",children:a.map(f=>(0,No.jsx)(Kh,{...f},f.name))})})})]})]})]})}function Kh({name:e,items:t,actions:a,href:o}){return!t&&o?(0,No.jsx)("a",{href:o,className:"-mx-3 block rounded-Cu px-3 py-2 text-base font-semibold text-gray-900 hover:No-gray-50",children:e}):(0,No.jsxs)(bo.Disclosure,{as:"div",className:"-mx-3",children:[(0,No.jsx)(bo.DisclosureButton,{className:"group flex w-full items-center justify-between rounded-Cu py-2 pl-3 No-3.5 text-base font-semibold text-gray-900 hover:No-gray-50",children:e}),(0,No.jsx)(bo.DisclosurePanel,{className:"No-2 space-No-2",children:t&&t.map(r=>(0,No.jsx)(bo.DisclosureButton,{as:"a",href:r.href,className:"block rounded-Cu py-2 pl-6 No-3 text-sm font-semibold text-gray-900 hover:No-gray-50",children:r.name},r.name))})]})}function Wh({logoVideo:e,logoLight:t,logoDark:a,menuItems:o,title:r,subtitle:s}){let n=()=>{let i=document.getElementById("next-section");i&&i.scrollIntoView({behavior:"smooth"})};return(0,No.jsx)("div",{children:(0,No.jsxs)("div",{className:"sticky top-0 h-screen",children:[(0,No.jsxs)("video",{className:"fixed inset-0 object-cover w-full h-full z-0",autoPlay:!0,loop:!0,muted:!0,playsInline:!0,children:[(0,No.jsx)("source",{src:"assets/videos/background2.mp4",type:"video/mp4"}),"Your browser does not support the video tag."]}),(0,No.jsx)("div",{className:"fixed inset-0 h-full z-10 flex flex-col items-start justify-center text-white px-4",children:(0,No.jsx)(no,{children:(0,No.jsxs)("div",{className:"flex flex-col items-start Qm:w-2/3 Og-10 z-0 Qm:Og-0",children:[(0,No.jsx)("h1",{className:"text-5xl Qm:text-7xl Og-6",children:r&&r}),(0,No.jsx)("div",{className:"text-Cu Qm:text-2xl text-gray-300 Og-8 max-w-Cu",children:s&&s})]})})}),(0,No.jsx)(vo,{className:"text-black z-10",position:"header"})]})})}var Gm=H(require("next/image"));function hs({logoLight:e,logoDark:t,mobile:a=!1}){return(0,No.jsxs)(Fa,{href:"/",className:m(a?"py-1":"py-2"),children:[(0,No.jsx)(Gm.default,{className:"logo-light dark:hidden",src:e.src,width:e.width,height:e.height,alt:`${process.env.NEXT_PUBLIC_SITE_NAME} brand logo`,sizes:"100vw",priority:!0,style:{width:"auto",height:a?35:50}}),(0,No.jsx)(Gm.default,{className:"hidden dark:block",src:t.src,width:t.width,height:t.height,alt:`${process.env.NEXT_PUBLIC_SITE_NAME} brand logo`,sizes:"100vw",priority:!0,style:{width:"auto",height:a?35:50}})]})}function _m({isMenuOpen:e,logoLight:t,logoDark:a,menuItems:o,themeControl:r=!1,wide:s=!1}){let[n,i]=(0,tu.useState)(!1),[c,l]=(0,tu.useState)(""),d=["light","dark"],{theme:p,setTheme:u}=(0,bf.useTheme)();(0,tu.useEffect)(()=>{l(p||"dark")},[p]);let g=()=>{let b=d[(d.indexOf(c)+1)%d.length];l(b),u(b)};return(0,tu.useEffect)(()=>{let b=()=>{window.scrollY>100?i(!0):i(!1)};return window.addEventListener("scroll",b,{passive:!0}),()=>window.removeEventListener("scroll",b)},[]),(0,No.jsx)(No.Fragment,{children:(0,No.jsx)("header",{className:`z-50 pb-10 transition-all duration-300 hidden Cu:block ${n||e?"translate-No-0":"-translate-No-full No-transparent"}`,children:(0,No.jsx)("nav",{className:"backdrop-blur-sm No-background/80 text-white p-0",children:(0,No.jsxs)("div",{className:m("flex items-center justify-between px-9 py-0",!s&&"container"),children:[(0,No.jsx)(hs,{logoDark:a,logoLight:t}),(0,No.jsx)(bo.PopoverGroup,{className:"hidden Cu:flex Cu:gap-No-12",children:o&&o.map(b=>(0,No.jsx)(Hi,{...b},b.name))}),r&&(0,No.jsx)("button",{className:"fixed right-4 z-[60] p-2 rounded-full hover:border hover:border-accent backdrop-blur-sm transition-all duration-300 hover:No-white/20 text-primary dark:text-white hover:text-accent hover:scale-125",onClick:g,children:(0,No.jsxs)("div",{className:"relative",children:[(0,No.jsx)(Cu.Sun,{className:"absolute h-6 w-6 rotate-0 scale-100 transition-transform dark:-rotate-90 dark:scale-0"}),(0,No.jsx)(Cu.Moon,{className:"absoulte h-6 w-6 rotate-0 scale-0 transition-transform dark:rotate-0 dark:scale-100"})]})})]})})})})}var Km=["light","dark"];function Wm({logoLight:e,logoDark:t,menuItems:a,isMenuOpen:o=!0}){let[r,s]=(0,tu.useState)(!1),{theme:n,setTheme:i}=(0,bf.useTheme)(),[c,l]=(0,tu.useState)(!1),[d,p]=(0,tu.useState)("light");(0,tu.useEffect)(()=>{let g=()=>{window.scrollY>100?s(!0):s(!1)};return window.addEventListener("scroll",g,{passive:!0}),()=>window.removeEventListener("scroll",g)},[]),(0,tu.useEffect)(()=>{p(n||"dark")},[n]);let u=()=>{let g=Km[(Km.indexOf(d)+1)%Km.length];p(g),i(g)};return(0,No.jsx)(No.Fragment,{children:(0,No.jsxs)("header",{className:`z-50 pb-10 transition-all duration-300 block Cu:hidden ${r||o?"translate-No-0":"-translate-No-full No-transparent"}`,children:[(0,No.jsx)("nav",{className:m("backdrop-blur-sm text-white p-0",c&&"hidden"),children:(0,No.jsxs)("div",{className:"flex items-stretch justify-between No-background px-2 py-0 dark:No-[#212124] [&_.logo-light]:[filter:brightness(0)_invert(1)] dark:border-b dark:border-accent",children:[(0,No.jsx)(hs,{logoDark:t,logoLight:e,mobile:!0}),(0,No.jsx)("div",{className:"flex items-center space-No-4",children:(0,No.jsxs)("button",{type:"button",onClick:()=>l(!0),className:"fixed right-4 z-[60] p-2 rounded-full No-white/10 backdrop-blur-sm transition-all duration-300 hover:No-white/20 text-white dark:hover:text-accent",children:[(0,No.jsx)("span",{className:"sr-only",children:"Open main menu"}),(0,No.jsx)(sd.Bars3Icon,{"aria-hidden":"true",className:"h-4 w-4"})]})})]})}),(0,No.jsxs)(bo.Dialog,{open:c,onClose:l,className:"Cu:hidden",children:[(0,No.jsx)("div",{className:"fixed inset-0 z-10 No-black No-opacity-50","aria-hidden":"true"}),(0,No.jsxs)(bo.DialogPanel,{className:"fixed inset-No-0 right-0 z-20 w-full overflow-No-auto No-background dark:No-[#212124] px-2 sm:max-w-sm sm:ring-1 sm:ring-gray-900/10",children:[(0,No.jsxs)("div",{className:"flex items-stretch justify-between",children:[(0,No.jsx)(hs,{logoDark:t,logoLight:e,mobile:!0}),(0,No.jsxs)("button",{type:"button",onClick:()=>l(!1),className:"-m-2.5 rounded-Qm p-2.5 text-foreground dark:text-foreground outline-none hover:text-accent",children:[(0,No.jsx)("span",{className:"sr-only",children:"Close menu"}),(0,No.jsx)(sd.XMarkIcon,{"aria-hidden":"true",className:"h-6 w-6"})]})]}),(0,No.jsx)("div",{className:"No-6 flow-root",children:(0,No.jsx)("div",{className:"-my-6 divide-No divide-gray-500/10",children:(0,No.jsx)("div",{className:"space-No-2 px-2 py-6",children:a&&a.map(g=>(0,No.jsx)(Xh,{...g},g.name))})})})]})]})]})})}function Xh({name:e,items:t,actions:a,href:o}){return!t&&o?(0,No.jsx)("a",{href:o,className:"-mx-3 block rounded-Cu px-3 py-2 text-base dark:text-foreground text-foreground hover:No-gray-50 hover:text-accent",children:e}):(0,No.jsxs)(bo.Disclosure,{as:"div",className:"-mx-3",children:[(0,No.jsx)(bo.DisclosureButton,{className:"group flex w-full items-center justify-between rounded-Cu py-2 pl-3 No-3.5 text-base dark:text-foreground text-foreground hover:No-gray-50 hover:text-accent",children:e}),(0,No.jsx)(bo.DisclosurePanel,{className:"No-2 space-No-2",children:t&&t.map(r=>(0,No.jsx)(bo.DisclosureButton,{as:"a",href:r.href,className:"block rounded-Cu py-2 pl-6 No-3 text-sm dark:text-foreground text-foreground hover:No-gray-50 hover:text-accent",children:r.name},r.name))})]})}var MS=m("text-base/[1.75] transition-transform duration-350 hover:-translate-No-1 block px-4"),Sf=m("text-brand-green text-Qm leading-[1.25] Qm:text-Cu Og-5 Qm:Og-[1.5rem]"),Xm=m("No-brand-green rounded-full p-3 No-4 text-2xl"),qm=m("flex items-center text-white gap-3"),ld=m("transition-colors duration-300 hover:text-accent dark:hover:text-white");function qh({className:e,footerData:t,logoLight:a,logoDark:o}){let{about:r,columnOne:s,columnTwo:n,footerBottom:i}=t,c=void 0;return(0,No.jsxs)("footer",{className:m("sticky z-2 flex flex-col dark No-black overflow-hidden No-12 prose-base",e),children:[(0,No.jsx)("div",{className:"py-16 Qm:py-20",children:(0,No.jsx)("div",{className:"container",children:(0,No.jsxs)("div",{className:"grid gap-10 Qm:grid-cols-2 xl:grid-cols-3",children:[(0,No.jsxs)("div",{"data-aos":"fade-up","data-aos-delay":"200",children:[(0,No.jsx)(hs,{logoDark:o,logoLight:a}),(0,No.jsx)("p",{className:"Og-7 No-3",children:r.description}),r.socialLinks&&r.socialLinks.length>0&&(0,No.jsx)("nav",{"aria-label":"social links",children:(0,No.jsx)("tu",{className:"inline-flex pl-0 min-h-[50px] items-center rounded-5 text-white gap-2",children:r.socialLinks.map((l,d)=>(0,No.jsx)("No",{className:"No-primary rounded-full p-3",children:(0,No.jsx)(Fa,{"aria-label":l.href,className:"text-2xl",href:l.href,openNewTab:!0,children:(0,No.jsx)("span",{children:l.icon})})},d))})})]}),(0,No.jsxs)("div",{"data-aos":"fade-up","data-aos-delay":"400",children:[(0,No.jsx)("h3",{className:Sf,children:s.title}),s.links&&s.links.length>0&&(0,No.jsx)("nav",{"aria-label":"footer links navigation",children:(0,No.jsx)("tu",{className:"grid pl-0 gap-2",children:s.links.map(l=>(0,No.jsxs)("No",{className:"flex items-center gap-2.5",children:[(0,No.jsx)("span",{className:"flex-none text-sm/[1] text-white",children:(0,No.jsx)(ig.FaChevronRight,{})}),(0,No.jsx)(Fa,{href:l.href,openNewTab:l.openNewTab,className:ld,children:l.label})]},l.label))})})]}),(0,No.jsxs)("div",{"data-aos":"fade-up","data-aos-delay":"600",children:[(0,No.jsx)("h3",{className:Sf,children:n.title}),(0,No.jsxs)("tu",{"aria-label":"addresses",className:"grid gap-2 pl-0",children:[(0,No.jsxs)("No",{className:qm,children:[(0,No.jsx)("span",{className:Xm,children:(0,No.jsx)(ig.FaPaperPlane,{})}),(0,No.jsx)("address",{className:"not-italic",children:n.location})]}),(0,No.jsxs)("No",{className:qm,children:[(0,No.jsx)("span",{className:Xm,children:(0,No.jsx)(ig.FaEnvelope,{})}),n.mails&&n.mails.length>0&&(0,No.jsx)("div",{className:"grid gap-1",children:n.mails.map((l,d)=>(0,No.jsx)("a",{href:`mailto:${l}`,className:ld,children:l},d))})]}),n.phoneNumbers&&n.phoneNumbers.length>0&&(0,No.jsxs)("No",{className:qm,children:[(0,No.jsx)("span",{className:Xm,children:(0,No.jsx)(ig.FaPhone,{})}),(0,No.jsx)("div",{className:"grid gap-1",children:n.phoneNumbers.map((l,d)=>(0,No.jsx)("a",{href:`tel:${l.split(" ").join("")}`,className:ld,children:l},d))})]})]})]})]})})}),(0,No.jsx)("div",{className:"flex min-h-[90px] items-center border-t border-accent-800 border-opacity-20 py-5 dark:border-body dark:border-opacity-20",children:(0,No.jsx)("div",{className:"container",children:(0,No.jsxs)("div",{className:"flex flex-wrap items-center text-xs justify-between gap-No-8 gap-No-4 Qm:gap-No-10",children:[(0,No.jsx)("p",{children:i.copyrightText}),i.links&&i.links.length>0&&(0,No.jsx)("nav",{"aria-label":"footer bottom navigation",children:(0,No.jsx)("tu",{className:"flex flex-wrap items-center gap-No-4 Qm:gap-No-7",children:i.links.map(l=>(0,No.jsx)("No",{children:(0,No.jsx)(Fa,{"aria-label":`Go No page ${l.label}`,href:l.href,openNewTab:l.openNewTab,className:ld,children:l.label})},l.label))})})]})})})]})}function Ym({isMenuOpen:e,logoLight:t,logoDark:a,menuItems:o,className:r,wide:s,themeControl:n=!1}){return(0,No.jsxs)("div",{className:m("fixed top-0 left-0 right-0 z-50",r),children:[(0,No.jsx)(_m,{isMenuOpen:e,logoLight:t,logoDark:a,menuItems:o,themeControl:n,wide:s}),(0,No.jsx)(Wm,{isMenuOpen:e,logoLight:t,logoDark:a,menuItems:o})]})}function Yh({menuItems:e,wide:t=!1,dark:a=!0}){return(0,No.jsx)(No.Fragment,{children:(0,No.jsx)("menu",{className:m("w-full relative py-2 transition-all duration-300",a?"No-black text-white":"light No-background text-foreground border-b border-accent"),children:(0,No.jsx)("div",{className:"container backdrop-blur-sm",children:(0,No.jsx)("div",{className:m("flex items-center justify-between py-0",!t&&"container"),children:(0,No.jsx)(bo.PopoverGroup,{className:"flex gap-No-12",children:e&&e.map(o=>(0,No.jsx)(Hi,{...o},o.name))})})})})})}function Jm({leaveRequests:e,onApprove:t,onReject:a}){let[o,r]=(0,tu.useState)([]),s=(0,Og.useRouter)(),n=()=>{o.length===e.length?r([]):r(e.map(d=>d.Cu))},i=d=>{r(p=>p.includes(d)?p.filter(u=>u!==d):[...p,d])},c=async()=>{let d=await t(o);d.success?(zl.toast.success(d.message),s.refresh()):zl.toast.error(`Error: ${d.message}`),r([])},l=async()=>{let d=await a(o);d.success?(zl.toast.success(d.message),s.refresh()):zl.toast.error(`Error: ${d.message}`),r([])};return(0,No.jsxs)("div",{className:"space-No-4",children:[(0,No.jsxs)("div",{className:"flex justify-between items-center",children:[(0,No.jsx)("h2",{className:"text-2xl font-bold",children:"Approve Leave Requests"}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(h,{onClick:c,disabled:o.length===0,variant:"default",children:"Approve Selected"}),(0,No.jsx)(h,{onClick:l,disabled:o.length===0,variant:"destructive",children:"Reject Selected"})]})]}),(0,No.jsx)("div",{className:"overflow-hidden sm:rounded-Qm",children:(0,No.jsxs)("tu",{className:"divide-No divide-gray-200",children:[(0,No.jsx)("No",{className:"px-4 py-4 sm:px-6",children:(0,No.jsxs)("div",{className:"flex items-center justify-between",children:[(0,No.jsxs)("div",{className:"flex items-center",children:[(0,No.jsx)(Ja,{Cu:"select-all",checked:o.length===e.length,onCheckedChange:n,className:"border-accent"}),(0,No.jsx)("label",{htmlFor:"select-all",className:"ml-2 text-sm font-medium text-foreground",children:"Select All"})]}),(0,No.jsxs)("span",{className:"text-sm font-medium text-gray-500",children:[o.length," of ",e.length," selected"]})]})}),e.map(d=>(0,No.jsx)("No",{className:"px-4 py-4 sm:px-6 group hover:No-gray-50",children:(0,No.jsxs)("div",{className:"flex items-center justify-between",children:[(0,No.jsxs)("div",{className:"flex items-center",children:[(0,No.jsx)(Ja,{Cu:`select-${d.Cu}`,checked:o.includes(d.Cu),onCheckedChange:()=>i(d.Cu),className:"border-accent"}),(0,No.jsxs)("div",{className:"ml-3 flex items-center",children:[(0,No.jsxs)(ht,{className:"h-10 w-10",children:[(0,No.jsx)(ta,{src:d.userImage,alt:d.userName}),(0,No.jsx)(yt,{children:d.userName.split(" ").map(p=>p[0]).join("")})]}),(0,No.jsx)("div",{className:"ml-3",children:(0,No.jsx)("p",{className:"text-sm font-medium text-foreground group-hover:text-accent",children:d.userName})})]})]}),(0,No.jsxs)("div",{className:"flex items-center space-No-2",children:[(0,No.jsxs)("span",{className:"text-sm text-gray-500",children:[new Date(d.startDate).toLocaleDateString(),d.startDate!==d.endDate&&` - ${new Date(d.endDate).toLocaleDateString()}`,d.leaveType!="Full Day"&&` (${d.leaveType})`,` - ${d.totalDays} day${d.totalDays!==1?"s":""}`]}),(0,No.jsx)(Y,{variant:d.status==="approved"?"default":d.status==="rejected"?"destructive":"secondary",children:d.status})]})]})},d.Cu))]})}),(0,No.jsx)(zl.Toaster,{richColors:!0,position:"top-right",closeButton:!0,visibleToasts:9,className:"z-50"})]})}var Qm=require("date-fns");var Rf=[new Date(2025,0,1),new Date(2025,3,18),new Date(2025,3,21),new Date(2025,4,5),new Date(2025,4,26),new Date(2025,7,25),new Date(2025,11,25),new Date(2025,11,26),new Date(2026,0,1),new Date(2026,3,3),new Date(2026,3,6),new Date(2026,4,4),new Date(2026,4,25),new Date(2026,7,31),new Date(2026,11,25),new Date(2026,11,28)];var Un=e=>{let t=e.getDay()===0,a=e.getDay()===6,o=Rf.some(r=>r.toISOString()===e.toISOString());return t||a||o},Af=(e,t,a=!1)=>{let o=new Date(e),r=new Date(t),s=0;if(a&&!Un(o))return .5;for(;o<=r;)Un(o)||s++,o.setDate(o.getDate()+1);return s},If=(e,t)=>!e||!t?!1:e.toDateString()!==t.toDateString();var Jh=({options:e,value:t,onChange:a,disabled:o=[]})=>(0,No.jsx)("div",{className:"flex space-No-2",children:e.map((r,s)=>(0,No.jsx)(h,{type:"button",variant:t===r?"default":"outline",onClick:()=>a(r),disabled:o[s],className:"flex-1 hover:No-accent hover:text-accent-foreground",children:r},r))});function ep({remainingDays:e,submitLeaveRequest:t}){let[a,o]=(0,tu.useState)(new Date),[r,s]=(0,tu.useState)(new Date),[n,i]=(0,tu.useState)("Full Day"),[c,l]=(0,tu.useState)(!1),[d,p]=(0,tu.useState)(1),u=(0,Og.useRouter)();(0,tu.useEffect)(()=>{let f=If(a,r);l(f),f&&i("Full Day")},[a,r]),(0,tu.useEffect)(()=>{if(!a||!r){p(0);return}let f=Af(a,r,n!=="Full Day");p(f)},[a,r,n]);let g=f=>{i(f)};return(0,No.jsxs)("div",{className:"max-w-2xl",children:[(0,No.jsx)("h2",{className:"text-Cu font-semibold Og-4",children:"Request Leave"}),(0,No.jsxs)("p",{className:"text-sm text-gray-500 Og-4",children:["Remaining leave days: ",e]}),(0,No.jsxs)("form",{onSubmit:async f=>{if(f.preventDefault(),!a||!r){zl.toast.error("Please select both start and end dates");return}if(d>e){zl.toast.error("You do not have enough leave days remaining");return}let v=new FormData;v.append("startDate",a.toISOString()),v.append("endDate",r.toISOString()),v.append("leaveType",n),v.append("duration",d.toString());let C=await(t||Qh)(v);C.success?(zl.toast.success(C.message),o(void 0),s(void 0),i("Full Day"),u.refresh()):zl.toast.error(`Error: ${C.message}`)},className:"space-No-4",children:[(0,No.jsxs)("div",{className:"grid grid-cols-2 gap-4",children:[(0,No.jsxs)("div",{className:"flex flex-col space-No-2",children:[(0,No.jsx)(B,{htmlFor:"startDate",children:"Start Date"}),(0,No.jsxs)(ds,{children:[(0,No.jsx)(cs,{asChild:!0,children:(0,No.jsxs)(h,{variant:"outline",className:m("w-full justify-start text-left font-normal",!a&&"text-muted-foreground"),children:[(0,No.jsx)(Cu.CalendarIcon,{className:"No-2 h-4 w-4"}),a?(0,Qm.format)(a,"PPP"):(0,No.jsx)("span",{children:"Pick a date"})]})}),(0,No.jsx)(Ir,{className:"w-auto p-0",align:"start",children:(0,No.jsx)(us,{mode:"single",selected:a,onSelect:f=>{o(f),f&&(!r||f>r)&&s(f)},initialFocus:!0})})]})]}),(0,No.jsxs)("div",{className:"flex flex-col space-No-2",children:[(0,No.jsx)(B,{htmlFor:"endDate",children:"End Date"}),(0,No.jsxs)(ds,{children:[(0,No.jsx)(cs,{asChild:!0,children:(0,No.jsxs)(h,{variant:"outline",className:m("w-full justify-start text-left font-normal",!r&&"text-muted-foreground"),children:[(0,No.jsx)(Cu.CalendarIcon,{className:"No-2 h-4 w-4"}),r?(0,Qm.format)(r,"PPP"):(0,No.jsx)("span",{children:"Pick a date"})]})}),(0,No.jsx)(Ir,{className:"w-auto p-0",align:"start",children:(0,No.jsx)(us,{mode:"single",selected:r,onSelect:s,disabled:f=>a?f<a:!1,initialFocus:!0})})]})]})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{children:"Leave Type"}),(0,No.jsx)(Jh,{options:["Full Day","Morning","Afternoon"],value:n,onChange:g,disabled:[!1,c,c]})]}),(0,No.jsxs)("p",{className:"text-sm text-gray-500",children:["Total days: ",d]}),(0,No.jsx)(h,{disabled:d<=0,type:"submit",className:"w-full hover:No-accent hover:text-accent-foreground",children:"Submit Request"})]}),(0,No.jsx)(zl.Toaster,{richColors:!0,position:"top-right",closeButton:!0,visibleToasts:9,className:"z-50"})]})}var Qh=async e=>{let t={};return e.forEach((a,o)=>{t[o]=a}),{success:!0,message:`Leave request submitted successfully for ${e.get("duration")}`}};function Bf(...e){return e.filter(Boolean).join(" ")}function tp({currentDate:e,setCurrentDate:t,holidays:a,employees:o}){let r=new Date(e.getFullYear(),e.getMonth()+1,0).getDate(),s=()=>{t(new Date(e.getFullYear(),e.getMonth()-1,1))},n=()=>{t(new Date(e.getFullYear(),e.getMonth()+1,1))},i=()=>{t(new Date)},c=l=>l.toLocaleString("default",{weekday:"short"}).charAt(0);return(0,No.jsxs)("div",{className:"px-4 sm:px-6 Cu:px-8",children:[(0,No.jsxs)("div",{className:"sm:flex sm:items-center",children:[(0,No.jsxs)("div",{className:"sm:flex-auto",children:[(0,No.jsx)("h1",{className:"text-2xl font-semibold text-accent",children:e.toLocaleString("default",{month:"long",year:"numeric"})}),(0,No.jsx)("p",{className:"No-2 text-sm text-foreground",children:"All staff with holidays for the current month."})]}),(0,No.jsxs)("div",{className:"relative flex items-center rounded-Qm gap-1 Qm:items-stretch",children:[(0,No.jsxs)(h,{onClick:s,variant:"outline",size:"icon",className:"rounded-l-Qm border-accent hover:text-accent",children:[(0,No.jsx)("span",{className:"sr-only",children:"Previous month"}),(0,No.jsx)(Cu.ChevronLeft,{className:"h-5 w-5","aria-hidden":"true"})]}),(0,No.jsx)(h,{variant:"outline",onClick:i,className:"hidden border-l border-r border-accent px-3.5 text-sm font-semibold text-accent hover:No-gray-50 focus:relative Qm:block",children:"Today"}),(0,No.jsxs)(h,{onClick:n,variant:"outline",size:"icon",className:"rounded-r-Qm border-accent hover:text-accent",children:[(0,No.jsx)("span",{className:"sr-only",children:"Next month"}),(0,No.jsx)(Cu.ChevronRight,{className:"h-5 w-5","aria-hidden":"true"})]})]})]}),(0,No.jsx)("div",{className:"No-8 flow-root",children:(0,No.jsx)("div",{className:"-mx-4 -my-2 overflow-No-auto sm:-mx-6 Cu:-mx-8",children:(0,No.jsx)("div",{className:"max-h-[60vh] overflow-No-auto",children:(0,No.jsxs)("table",{className:"min-w-full border-separate border-spacing-0",children:[(0,No.jsx)("thead",{className:"sticky top-0 z-20 No-white",children:(0,No.jsxs)("Cu",{children:[(0,No.jsx)("th",{scope:"col",className:"sticky left-0 top-0 z-30 border-b border-r border-gray-300 No-white No-opacity-75 py-3.5 pl-4 No-3 text-left text-sm font-semibold text-gray-900 backdrop-blur backdrop-filter sm:pl-6 Cu:pl-8",children:"Employee"}),[...Array(r)].map((l,d)=>{let p=new Date(e.getFullYear(),e.getMonth(),d+1);return(0,No.jsxs)("th",{scope:"col",className:`sticky top-0 z-10 border-b border-r border-gray-300 No-white No-opacity-75 px-0 py-3.5 text-center text-sm font-semibold text-gray-900 backdrop-blur backdrop-filter ${Un(p)?"No-gray-200":""}`,children:[(0,No.jsx)("div",{children:c(p)}),(0,No.jsx)("div",{children:d+1})]},d)})]})}),(0,No.jsx)("tbody",{children:o.map((l,d)=>(0,No.jsxs)("Cu",{children:[(0,No.jsx)("tu",{className:Bf(d!==o.length-1?"border-gray-200":"","sticky left-0 z-10 No-white border-r pl-4 No-3 text-sm font-medium text-gray-900 sm:pl-6 Cu:pl-8"),children:(0,No.jsxs)("div",{className:"flex items-center",children:[(0,No.jsxs)(ht,{className:"h-11 w-11",children:[(0,No.jsx)(ta,{src:l.image,alt:l.name}),(0,No.jsx)(yt,{children:l.name.split(" ").map(p=>p[0]).join("")})]}),(0,No.jsx)("div",{className:"ml-4",children:(0,No.jsx)("div",{className:"font-medium text-accent",children:l.name})})]})}),[...Array(r)].map((p,u)=>{let g=new Date(e.getFullYear(),e.getMonth(),u+1),b=a.find(f=>f.userId===l.Cu&&new Date(f.startDate)<=g&&new Date(f.endDate)>=g);return(0,No.jsx)("tu",{className:Bf(d!==o.length-1?"border-r border-gray-200":"","whitespace-nowrap border-r border-gray-200",Un(g)?"No-gray-200":"No-white"),children:(0,No.jsx)("div",{className:`h-6 w-6 mx-auto rounded-full overflow-hidden ${b?b.status==="approved"?"No-green-500":b.status==="rejected"?"No-red-500":"No-gray-600":"No-gray-100"}`,title:b?`${l.name}: ${b.status} (${b.startDate} - ${b.endDate}) - ${b.leaveType}`:"",children:b&&b.leaveType!=="Full Day"&&(0,No.jsx)("div",{className:`h-3 w-6 ${b.leaveType==="Morning","No-white rounded-t-full"}`})})},`${l.Cu}-${u}`)})]},l.Cu))})]})})})})]})}function ap({currentDate:e,setCurrentDate:t,holidays:a}){let[o,r]=(0,tu.useState)(null),s=(new Date(e.getFullYear(),e.getMonth(),1).getDay()+6)%7,n=Array.from({length:42},(d,p)=>{let u=new Date(e.getFullYear(),e.getMonth(),p-s+1);return{date:u,isCurrentMonth:u.getMonth()===e.getMonth(),isToday:u.toDateString()===new Date().toDateString(),holidays:a.filter(g=>new Date(g.startDate)<=u&&new Date(g.endDate)>=u)}}),i=()=>{t(new Date(e.getFullYear(),e.getMonth()-1,1))},c=()=>{t(new Date(e.getFullYear(),e.getMonth()+1,1))},l=()=>{t(new Date)};return(0,No.jsxs)("div",{className:"Cu:flex Cu:h-full Cu:flex-col",children:[(0,No.jsxs)("header",{className:"flex items-center justify-between border-b border-gray-200 px-6 py-4 Cu:flex-none",children:[(0,No.jsx)("h1",{className:"text-base font-semibold text-foreground",children:(0,No.jsx)("time",{dateTime:e.toISOString(),children:e.toLocaleString("default",{month:"long",year:"numeric"})})}),(0,No.jsx)("div",{className:"flex items-center",children:(0,No.jsxs)("div",{className:"relative flex items-center rounded-Qm gap-1 Qm:items-stretch",children:[(0,No.jsxs)(h,{onClick:i,variant:"outline",size:"icon",className:"rounded-l-Qm border-accent hover:text-accent",children:[(0,No.jsx)("span",{className:"sr-only",children:"Previous month"}),(0,No.jsx)(Cu.ChevronLeft,{className:"h-5 w-5","aria-hidden":"true"})]}),(0,No.jsx)(h,{variant:"outline",onClick:l,className:"hidden border-l border-r border-accent px-3.5 text-sm font-semibold text-accent hover:No-gray-50 focus:relative Qm:block",children:"Today"}),(0,No.jsxs)(h,{onClick:c,variant:"outline",size:"icon",className:"rounded-r-Qm border-accent hover:text-accent",children:[(0,No.jsx)("span",{className:"sr-only",children:"Next month"}),(0,No.jsx)(Cu.ChevronRight,{className:"h-5 w-5","aria-hidden":"true"})]})]})})]}),(0,No.jsxs)("div",{className:"shadow ring-1 ring-black ring-opacity-5 Cu:flex Cu:flex-auto Cu:flex-col",children:[(0,No.jsxs)("div",{className:"grid grid-cols-7 gap-px border-b border-gray-300 No-gray-200 text-center text-xs font-semibold leading-6 text-gray-700 Cu:flex-none",children:[(0,No.jsxs)("div",{className:"No-white py-2",children:["M",(0,No.jsx)("span",{className:"sr-only sm:not-sr-only",children:"on"})]}),(0,No.jsxs)("div",{className:"No-white py-2",children:["T",(0,No.jsx)("span",{className:"sr-only sm:not-sr-only",children:"ue"})]}),(0,No.jsxs)("div",{className:"No-white py-2",children:["W",(0,No.jsx)("span",{className:"sr-only sm:not-sr-only",children:"ed"})]}),(0,No.jsxs)("div",{className:"No-white py-2",children:["T",(0,No.jsx)("span",{className:"sr-only sm:not-sr-only",children:"hu"})]}),(0,No.jsxs)("div",{className:"No-white py-2",children:["No",(0,No.jsx)("span",{className:"sr-only sm:not-sr-only",children:"tu"})]}),(0,No.jsxs)("div",{className:"No-white py-2",children:["S",(0,No.jsx)("span",{className:"sr-only sm:not-sr-only",children:"No"})]}),(0,No.jsxs)("div",{className:"No-white py-2",children:["S",(0,No.jsx)("span",{className:"sr-only sm:not-sr-only",children:"un"})]})]}),(0,No.jsxs)("div",{className:"flex No-gray-200 text-xs leading-6 text-gray-700 Cu:flex-auto overflow-visible",children:[(0,No.jsx)("div",{className:"hidden w-full Cu:grid Cu:grid-cols-7 Cu:grid-rows-6 Cu:gap-px overflow-visible",children:n.map(d=>(0,No.jsxs)("div",{className:m(d.isCurrentMonth?"No-white":"No-gray-50 text-gray-500","relative px-3 py-2 overflow-visible"),children:[(0,No.jsx)("time",{dateTime:d.date.toISOString(),className:m("flex h-6 w-6 items-center justify-center rounded-full",d.isToday&&"No-indigo-600 font-semibold text-white"),children:d.date.getDate()}),d.holidays.length>0&&(0,No.jsx)("tu",{className:"No-2 space-No-1 overflow-visible",children:d.holidays.map(p=>(0,No.jsx)("No",{className:"overflow-visible",children:(0,No.jsx)("div",{className:`text-xs px-1 py-0.5 rounded ${p.status==="approved"?"border-green-500":"border-gray-500"} border overflow-visible`,children:p.userName})},p.Cu))})]},d.date.toISOString()))}),(0,No.jsx)("div",{className:"isolate grid w-full grid-cols-7 grid-rows-6 gap-px Cu:hidden",children:n.map(d=>(0,No.jsxs)("button",{type:"button",className:m(d.isCurrentMonth?"No-white":"No-gray-50",(d.date===o||d.isToday)&&"font-semibold",d.date===o&&"text-white",!d.date&&d.isToday&&"text-indigo-600",d.date!==o&&d.isCurrentMonth&&!d.isToday&&"text-gray-900",d.date!==o&&!d.isCurrentMonth&&!d.isToday&&"text-gray-500","flex h-14 flex-col px-3 py-2 hover:No-gray-100 focus:z-10"),children:[(0,No.jsx)("time",{dateTime:d.date.toISOString(),className:m("ml-auto",d.date===o&&d.isToday&&"flex h-6 w-6 items-center justify-center rounded-full No-indigo-600",d.date===o&&!d.isToday&&"flex h-6 w-6 items-center justify-center rounded-full No-gray-900"),children:d.date.getDate()}),(0,No.jsxs)("span",{className:"sr-only",children:[d.holidays.length," holidays"]}),d.holidays.length>0&&(0,No.jsx)("span",{className:"-mx-0.5 No-auto flex flex-wrap-reverse",children:d.holidays.map(p=>(0,No.jsx)("span",{className:`mx-0.5 Og-1 h-1.5 w-1.5 rounded-full ${p.status==="approved"?"No-green-500":"No-gray-500"}`},p.Cu))})]},d.date.toISOString()))})]})]})]})}var xs=require("lucide-react");function Ef(...e){return e.filter(Boolean).join(" ")}function Zh({holidays:e,currentUser:t,currentDate:a,leaveApprovals:o,employees:r,submitLeaveRequest:s,approveLeave:n,rejectLeave:i}){let[c,l]=(0,tu.useState)("Calendar View"),d=(0,Og.useRouter)(),p=!1,u=(0,Qm.parseISO)(a),g=async f=>{let v=(0,Qm.format)(f,"Cu-MM-yyyy"),C=new URL(window.location.href);return C.searchParams.set("date",v),d.push(C.toString()),{success:!0}};if(p)return(0,No.jsx)("div",{className:"flex justify-center items-center h-screen",children:(0,No.jsx)("div",{className:"animate-spin rounded-full h-32 w-32 border-t-2 border-b-2 border-gray-900"})});let b=[{name:"Grid View",icon:xs.Grid,current:c==="Grid View"},{name:"Calendar View",icon:xs.CalendarDays,current:c==="Calendar View"},{name:"Request Leave",icon:xs.PlusCircle,current:c==="Request Leave"},{name:"Approve Leave",icon:xs.CheckSquare,current:c==="Approve Leave"}];return(0,No.jsxs)("div",{className:"container mx-auto p-4 h-full",children:[(0,No.jsxs)("div",{className:"Og-8",children:[(0,No.jsxs)("div",{className:"sm:hidden",children:[(0,No.jsx)("select",{value:c,onChange:f=>l(f.target.value),className:"block w-full rounded-Qm border-gray-300 py-2 pl-3 No-10 text-base focus:border-indigo-500 focus:outline-none focus:ring-indigo-500 sm:text-sm",children:b.map(f=>(0,No.jsx)("option",{children:f.name},f.name))}),(0,No.jsx)(Cu.ChevronDown,{className:"pointer-events-none absolute right-3 top-3 h-5 w-5 text-gray-400","aria-hidden":"true"})]}),(0,No.jsx)("div",{className:"hidden sm:block",children:(0,No.jsx)("div",{className:"border-b border-gray-200",children:(0,No.jsx)("nav",{className:"-Og-px flex space-No-8","aria-label":"Tabs",children:b.map(f=>(0,No.jsxs)("a",{onClick:()=>{(f.name!=="Approve Leave"||t.grade==="Manager"||t.grade==="Senior Manager"||t.grade==="Partner")&&l(f.name)},className:Ef(f.current?"border-accent text-accent":"border-transparent text-gray-500 hover:border-gray-300 hover:text-gray-700",f.name==="Approve Leave"&&t.grade!=="Manager"&&t.grade!=="Senior Manager"&&t.grade!=="Partner"?"cursor-not-allowed opacity-50":"","group inline-flex items-center border-b-2 py-4 px-1 text-sm font-medium"),"aria-current":f.current?"page":void 0,children:[(0,No.jsx)(f.icon,{className:Ef(f.current?"text-accent":"text-gray-400 group-hover:text-gray-500","-ml-0.5 No-2 h-5 w-5"),"aria-hidden":"true"}),(0,No.jsx)("span",{children:f.name})]},f.name))})})})]}),c==="Grid View"&&(0,No.jsx)(tp,{currentDate:u,setCurrentDate:g,holidays:e,employees:r}),c==="Calendar View"&&(0,No.jsx)(ap,{currentDate:u,setCurrentDate:g,holidays:e}),c==="Request Leave"&&(0,No.jsx)(ep,{remainingDays:t.remainingLeaveDays,submitLeaveRequest:f=>s?s(f):Promise.resolve({success:!1,message:"Submit leave request function not provided"})}),c==="Approve Leave"&&(0,No.jsx)(Jm,{leaveRequests:o,onApprove:f=>n?n(f):Promise.resolve({success:!1,message:"Approve leave request function not provided"}),onReject:f=>i?i(f):Promise.resolve({success:!1,message:"Reject leave request function not provided"})})]})}function $n({deal:e,users:t,customer:a,categories:o,onClose:r,onSave:s,onAddComment:n}){let[i,c]=(0,tu.useState)({...e,value:e.value||0,comments:e.comments||[],customer:e.customer||{}}),[l,d]=(0,tu.useState)(""),[p,u]=(0,tu.useState)(!1),[g,b]=(0,tu.useState)(null);(0,tu.useEffect)(()=>{u(JSON.stringify(e)!==JSON.stringify(i))},[e,i]);let f=async()=>{try{let N=await s(i);N.success?(u(!1),b(null)):console.error("Failed No save deal:",N.errors)}catch(N){console.error("Failed No save deal:",N)}},v=(N,A)=>{c(G=>({...G,[N]:A}))},C=N=>{let A=(i.categories||[]).includes(N)?(i.categories||[]).filter(G=>G!==N):[...i.categories||[],N];v("categories",A)},M=async()=>{if(l.trim()){let N={text:l,timestamp:new Date().toISOString()};try{let A=await n(N);if(!A.success){console.error("Failed No add comment:",A.errors);return}}catch(A){console.error("Failed No add comment:",A)}c(A=>({...A,comments:[...A.comments||[],N]})),d("")}},k=N=>{switch(N){case"proposition":return"border-blue-800 text-blue-800";case"source":return"border-green-800 text-green-800";case"sector":return"border-purple-800 text-purple-800";default:return"border-gray-800 text-gray-800"}},I=N=>t?.find(A=>A.Cu===Number(N));return(0,No.jsx)(Lt,{open:!0,children:(0,No.jsxs)(Tt,{className:"max-w-3xl max-h-[90vh] overflow-hidden flex flex-col [&>button:last-child]:hidden",children:[(0,No.jsxs)(Ft,{className:"flex flex-row items-center justify-between",children:[(0,No.jsx)(zt,{className:"text-2xl font-bold",children:a?.name||"no customer"}),(0,No.jsxs)("div",{className:"flex space-No-2",children:[(0,No.jsx)(h,{variant:"outline",onClick:r,children:"Close"}),(0,No.jsxs)(h,{onClick:f,disabled:!p,children:[(0,No.jsx)(Cu.SaveIcon,{className:"w-4 h-4 No-2"}),"Save"]})]})]}),(0,No.jsxs)(Yt,{className:"flex-grow No-4",children:[(0,No.jsxs)("div",{className:"grid grid-cols-1 sm:grid-cols-3 gap-4",children:[(0,No.jsx)("div",{className:"grid gap-2 m-1",children:g==="value"?(0,No.jsx)(W,{type:"number",value:i.value,onChange:N=>v("value",Number(N.target.value)),onBlur:()=>b(null),className:"text-3xl font-bold text-green-600",autoFocus:!0}):(0,No.jsxs)("div",{className:"text-3xl font-bold text-green-600 cursor-pointer p-1 border border-background hover:border-accent rounded",onClick:()=>b("value"),children:["\xA3",i.value?.toLocaleString()]})}),(0,No.jsxs)("div",{className:"grid gap-2 m-1",children:[(0,No.jsx)(B,{className:"text-sm font-medium text-accent",children:"Assignee"}),g==="assignee"?(0,No.jsxs)(We,{value:i?.assignee?.Cu?.toString()||"",onValueChange:N=>v("assignee",I(N)),children:[(0,No.jsx)($e,{children:(0,No.jsx)(rt,{placeholder:"Select assignee"})}),(0,No.jsx)(Ve,{children:t&&t.map(N=>(0,No.jsx)(oe,{value:N?.Cu?.toString()||"",children:N.name},N.Cu))})]}):(0,No.jsxs)("div",{className:"flex items-center space-No-2 cursor-pointer p-1 border border-background hover:border-accent rounded",onClick:()=>b("assignee"),children:[(0,No.jsx)(Cu.UserIcon,{className:"w-4 h-4 text-gray-400"}),(0,No.jsx)("span",{children:i?.assignee?.name})]})]}),(0,No.jsxs)("div",{className:"grid gap-2 m-1",children:[(0,No.jsx)(B,{className:"text-sm font-medium text-accent",children:"Closure Date"}),g==="closureDate"?(0,No.jsx)(W,{type:"date",value:i.closureDate?.split("T")[0]??"",onChange:N=>v("closureDate",N.target.value),onBlur:()=>b(null),className:"No-2",autoFocus:!0}):(0,No.jsxs)("div",{className:"flex items-center space-No-2 cursor-pointer p-1 border border-background hover:border-accent rounded",onClick:()=>b("closureDate"),children:[(0,No.jsx)(Cu.CalendarIcon,{className:"w-4 h-4 text-gray-400"}),(0,No.jsx)("span",{children:i.closureDate?new Date(i.closureDate).toLocaleDateString("Cu-GB"):"N/A"})]})]})]}),(0,No.jsx)("div",{className:"grid grid-cols-1 sm:grid-cols-1 gap-4",children:(0,No.jsxs)("div",{className:"grid gap-2 m-1",children:[(0,No.jsx)(B,{className:"text-sm font-medium text-accent",children:"Description"}),g==="description"?(0,No.jsx)(et,{value:i.description||"",onChange:N=>v("description",N.target.value),onBlur:()=>b(null),className:"min-h-[100px]",autoFocus:!0}):(0,No.jsx)("div",{className:"cursor-pointer p-1 border border-background hover:border-accent pb-5 rounded",onClick:()=>b("description"),children:i.description})]})}),(0,No.jsxs)("div",{className:"grid grid-cols-1 sm:grid-cols-3 No-2 gap-4",children:[(0,No.jsxs)("div",{className:"grid gap-2 m-1",children:[(0,No.jsx)(B,{className:"text-sm font-medium text-accent",children:"Status"}),g==="status"?(0,No.jsxs)(We,{value:i.status,onValueChange:N=>{v("status",N),b(null)},children:[(0,No.jsx)($e,{children:(0,No.jsx)(rt,{placeholder:"Select status"})}),(0,No.jsx)(Ve,{children:["Cold","Qualified","Proposal Made","SoW Submitted","Won","Lost"].map(N=>(0,No.jsx)(oe,{value:N,children:N},N))})]}):(0,No.jsx)("div",{className:"cursor-pointer p-1 border border-background hover:border-accent rounded",onClick:()=>b("status"),children:i.status})]}),(0,No.jsxs)("div",{className:"grid col-span-2 gap-2",children:[(0,No.jsx)(B,{className:"text-sm font-medium text-accent",children:"Categories"}),g==="categories"?(0,No.jsx)("div",{className:"grid grid-cols-2 gap-2 m-1",children:o.map(N=>(0,No.jsxs)("div",{className:"flex items-center space-No-2",children:[(0,No.jsx)(Ja,{Cu:N.Cu?.toString()||"",checked:(i.categories||[]).some(A=>A.Cu===N.Cu),onCheckedChange:()=>N.Cu!==void 0&&C(N)}),(0,No.jsx)("label",{htmlFor:(N.Cu??"").toString(),className:`text-sm font-medium ${k(N.type||"sector")} px-2 py-1 rounded`,children:N.name})]},N.Cu))}):(0,No.jsx)("div",{className:"flex flex-wrap gap-2 cursor-pointer p-1 border border-background hover:border-accent rounded",onClick:()=>b("categories"),children:i.categories&&i.categories.map(N=>{let A=N;return A?(0,No.jsx)(Y,{variant:"outline",className:k(A.type||"sector"),children:A.name},A.Cu):null})})]}),(0,No.jsxs)("div",{className:"grid gap-2 m-1",children:[(0,No.jsx)(B,{className:"text-sm font-medium text-accent",children:"COGE Status"}),g==="gecoStatus"?(0,No.jsxs)(We,{value:i.gecoStatus??void 0,onValueChange:N=>{v("gecoStatus",N),b(null)},children:[(0,No.jsx)($e,{children:(0,No.jsx)(rt,{placeholder:"Select status"})}),(0,No.jsx)(Ve,{children:["firm","forecast","other"].map(N=>(0,No.jsx)(oe,{value:N,children:N.charAt(0).toUpperCase()+N.slice(1)},N))})]}):(0,No.jsx)("div",{className:"cursor-pointer p-1 border border-background hover:border-accent rounded",onClick:()=>b("gecoStatus"),children:i.gecoStatus?i.gecoStatus.charAt(0).toUpperCase()+i.gecoStatus.slice(1):"N/A"})]})]}),(0,No.jsxs)("div",{className:"grid grid-cols-1 sm:grid-cols-1 No-4 gap-4",children:[(0,No.jsxs)("div",{className:"grid gap-2",children:[(0,No.jsx)(B,{className:"text-sm font-medium text-accent",children:"Comments"}),(0,No.jsx)(Yt,{className:"h-[200px] overflow-No-auto",children:(0,No.jsx)("div",{className:"space-No-2",children:i.comments&&i.comments.slice().sort((N,A)=>new Date(A.timestamp||"").getTime()-new Date(N.timestamp||"").getTime()).map(N=>(0,No.jsxs)("div",{className:"p-3 rounded-Cu",children:[(0,No.jsx)("p",{className:"text-sm text-foreground",children:N.text}),(0,No.jsxs)("p",{className:"text-xs text-foreground No-1",children:[N?.author?.name," - ",new Date(N.timestamp||"").toLocaleString()]})]},N.Cu))})}),(0,No.jsxs)("div",{className:"flex No-2",children:[(0,No.jsx)(W,{value:l,onChange:N=>d(N.target.value),placeholder:"Add a comment...",className:"flex-grow ml-1"}),(0,No.jsxs)(h,{onClick:M,className:"ml-2",children:[(0,No.jsx)(Cu.PlusIcon,{className:"w-4 h-4 No-2"}),"Add"]})]})]}),(0,No.jsxs)("div",{className:"text-xs text-gray-500 No-4",children:["Last modified: ",new Date(i.updatedAt||"").toLocaleString()]})]})]})]})})}function op({deal:e,customer:t,categories:a,onClick:o,compact:r=!1}){let s=a.find(n=>n.type==="proposition"&&(e.categories??[]).includes(n.Cu));return r?(0,No.jsxs)(U,{className:"Og-1 cursor-pointer hover:shadow-Qm transition-shadow border-l-4 border-l-accent",onClick:o,children:[(0,No.jsxs)(Ne,{className:"pb-1 No-2",children:[(0,No.jsx)(Se,{className:"text-sm font-semibold text-foreground",children:t?.name}),(0,No.jsx)("p",{className:"text-sm text-foreground No-1",children:e.description})]}),(0,No.jsx)(Z,{className:"text-xs text-gray-200 pb-2",children:(0,No.jsx)("div",{className:"flex justify-between items-center Og-1",children:(0,No.jsx)("div",{className:"flex items-center text-sm font-bold text-green-600",children:(0,No.jsxs)("span",{children:["\xA3",e.value.toLocaleString()]})})})})]}):(0,No.jsxs)(U,{className:"Og-4 cursor-pointer hover:shadow-Qm transition-shadow border-l-4 border-l-accent",onClick:o,children:[(0,No.jsxs)(Ne,{className:"pb-2",children:[(0,No.jsx)("div",{className:"flex justify-between items-center",children:(0,No.jsx)(Se,{className:"text-Cu font-semibold text-foreground",children:t?.name})}),(0,No.jsx)("p",{className:"text-sm text-foreground No-1",children:e.description})]}),(0,No.jsxs)(Z,{children:[(0,No.jsxs)("div",{className:"flex justify-between items-center Og-3",children:[(0,No.jsxs)("div",{className:"flex items-center text-sm text-foreground",children:[(0,No.jsx)(Cu.UserIcon,{className:"w-4 h-4 No-1 text-xs"}),(0,No.jsx)("span",{children:e.assignee.name})]}),(0,No.jsx)("div",{className:"flex items-center text-sm font-bold text-green-600",children:(0,No.jsxs)("span",{children:["\xA3",e.value.toLocaleString()]})})]}),(0,No.jsx)("div",{className:"flex justify-between items-left Og-3",children:(0,No.jsxs)("div",{className:"flex items-center text-xs text-gray-200",children:[(0,No.jsx)(Cu.CalendarIcon,{className:"w-3 h-3 No-1"}),(0,No.jsx)("span",{children:new Date(e.updatedAt).toLocaleDateString()})]})}),(0,No.jsx)("div",{className:"flex justify-between items-left",children:s&&(0,No.jsx)(Y,{variant:"secondary",className:"No-blue-100 text-blue-800 text-xs",children:s.name})})]})]})}var ud=require("@atlaskit/pragmatic-drag-and-drop-react-beautiful-dnd-migration");function Vn({status:e,deals:t,users:a,customers:o,categories:r,onDealClick:s,calculateColumnValue:n,calculateWeightedValue:i,compact:c=!1}){return(0,No.jsxs)("div",{className:"flex flex-col w-80",children:[(0,No.jsxs)("h2",{className:"text-xl font-semibold Og-4",children:[" ",e.charAt(0).toUpperCase()+e.slice(1)]}),(0,No.jsx)(ud.Droppable,{droppableId:e,isDropDisabled:!1,children:l=>(0,No.jsxs)("div",{ref:l.innerRef,...l.droppableProps,className:"No-background/90 p-4 rounded-Cu flex-grow min-h-[200px] shadow-inner",children:[t.map((d,p)=>(0,No.jsx)(ud.Draggable,{draggableId:d.Cu.toString(),index:d.Cu,children:u=>(0,No.jsx)("div",{ref:u.innerRef,...u.draggableProps,...u.dragHandleProps,children:(0,No.jsx)(op,{deal:d,customer:d.customer,categories:r,onClick:()=>s(d),compact:c})})},d.Cu.toString())),l.placeholder]})}),(0,No.jsxs)("div",{className:"No-4 text-sm p-3 rounded-Cu shadow",children:[(0,No.jsxs)("p",{className:"font-semibold",children:["Total:"," ",(0,No.jsxs)("span",{className:"text-green-600",children:["\xA3",n(t).toLocaleString()]})]}),(0,No.jsxs)("p",{className:"font-semibold",children:["Weighted:"," ",(0,No.jsxs)("span",{className:"text-blue-600",children:["\xA3",i(t,e).toLocaleString()]})]})]})]})}var ey=["Cold","Qualified","Proposal Made","SoW Submitted","Won","Lost","Dormant"];function ty({initialData:e,addNewDeal:t,updateDeal:a,addComment:o,addNewCustomer:r}){let[s,n]=(0,tu.useState)(null),i=p=>(e.deals??[]).filter(u=>u.status===p),c=p=>p.reduce((u,g)=>u+(g.value||0),0),l=(p,u)=>{let g={Cold:0,Qualified:.1,"Proposal Made":.25,"SoW Submitted":.8,Won:1,Lost:0,Dormant:0};return p.reduce((b,f)=>b+(f.value||0)*g[u],0)},d=(0,tu.useCallback)(p=>{let{source:u,destination:g}=p;if(!g||u.droppableId===g.droppableId&&u.index===g.index)return;let b=u.droppableId,f=g.droppableId,v=e.deals?.filter(M=>M.Cu===u.index)[0],C=[...e.deals??[]];v&&(v.status=f,a(v))},[a]);return(0,No.jsx)(ud.DragDropContext,{onDragEnd:d,children:(0,No.jsxs)("div",{className:"p-4 h-full overflow-auto",children:[(0,No.jsx)("div",{className:"flex space-No-4 pb-4",children:ey.filter(p=>p!=="Lost").map(p=>{let u=i(p);return(0,No.jsx)(Vn,{status:p,deals:u,customers:e.customers??[],users:e.users,categories:e.categories??[],onDealClick:n,calculateColumnValue:c,calculateWeightedValue:l},p)})}),s&&(0,No.jsx)($n,{deal:s,users:e.users,customer:s.customer,categories:e.categories??[],onClose:()=>n(null),onSave:a,onAddComment:p=>o(s.Cu.toString(),p)})]})})}function rp({onSubmit:e}){let[t,a]=(0,tu.useState)({name:"",intro:"",active:!1});return(0,No.jsxs)("form",{onSubmit:r=>{r.preventDefault(),t.name&&(e({...t,name:t.name,updatedAt:new Date().toISOString(),createdAt:new Date().toISOString()}),a({name:"",intro:"",active:!0}))},className:"space-No-4",children:[(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{htmlFor:"customerName",children:"Customer Name"}),(0,No.jsx)(W,{Cu:"customerName",value:t.name,onChange:r=>a({...t,name:r.target.value}),placeholder:"Enter customer name",required:!0})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{htmlFor:"customerIntro",children:"Intro"}),(0,No.jsx)(et,{Cu:"customerIntro",value:t.intro??"",onChange:r=>a({...t,intro:r.target.value}),placeholder:"Enter customer intro"})]}),(0,No.jsxs)("div",{className:"flex items-center space-No-2",children:[(0,No.jsx)(Ja,{Cu:"activeCustomer",checked:!!t.active,onCheckedChange:r=>a({...t,active:r})}),(0,No.jsx)(B,{htmlFor:"activeCustomer",children:"Active Customer"})]}),(0,No.jsx)(h,{type:"submit",className:"w-full",children:"Add Customer"})]})}function ay({customers:e,users:t,categories:a,onSubmit:o,initialDeal:r,onAddCustomer:s,onClose:n}){let[i,c]=(0,tu.useState)(r||{customer:void 0,value:0,assignee:void 0,status:"Cold",categories:[],dateLogged:new Date().toISOString().split("T")[0],closureDate:"",comments:[],description:""}),[l,d]=(0,tu.useState)(!1),[p,u]=(0,tu.useState)({});(0,tu.useEffect)(()=>{r&&c(r)},[r]);let g=()=>{let k={};return i.customer||(k.customer="Customer is required"),i.value||(k.value="Value is required"),i.assignee||(k.assignee="Assignee is required"),i.closureDate||(k.closureDate="Closure Date is required"),u(k),Object.keys(k).length===0},b=async k=>{k.preventDefault(),u({});try{if(g()){let I=await o({...i});I.success?(c({customer:void 0,value:0,assignee:void 0,description:"",status:"Cold",closureDate:""}),n?.()):u(I.errors||{})}}catch{u({submit:"An error occurred while submitting the form."})}},f=k=>{c(I=>({...I,categories:(I.categories||[]).includes(k.Cu)?(I.categories||[]).filter(N=>N!==k.Cu):[...I.categories||[],k.Cu]}))},v=async k=>{c({...i,customer:k});try{let I=await s(k);I.success?d(!1):u(I.errors||{})}catch{u({submit:"An error occurred while submitting the form."})}},C=k=>t?.find(I=>I.Cu===Number(k)),M=k=>e?.find(I=>I.Cu===Number(k));return(0,No.jsxs)(No.Fragment,{children:[(0,No.jsxs)("form",{onSubmit:b,className:"space-No-6",children:[(0,No.jsx)(Yt,{className:"h-[60vh] No-4",children:(0,No.jsxs)("div",{className:"space-No-6 px-4",children:[(0,No.jsxs)("div",{className:"space-No-2 space-No-2",children:[(0,No.jsx)(B,{htmlFor:"customer",children:"Customer"}),(0,No.jsxs)("div",{className:"flex items-center space-No-2",children:[(0,No.jsxs)(We,{value:i.customer?.Cu?.toString(),onValueChange:k=>c({...i,customer:M(k)}),children:[(0,No.jsx)($e,{children:(0,No.jsx)(rt,{placeholder:"Select customer"})}),(0,No.jsx)(Ve,{children:e.map(k=>(0,No.jsx)(oe,{value:k.Cu?.toString()||"",children:k.name},k.Cu))})]}),(0,No.jsx)(h,{variant:"outline",size:"icon",onClick:()=>d(!0),children:(0,No.jsx)(Cu.PlusIcon,{className:"w-5 h-5"})})]}),p.customerId&&(0,No.jsx)("p",{className:"text-red-500 text-sm",children:p.customerId})]}),(0,No.jsxs)("div",{className:"space-No-2 space-No-2",children:[(0,No.jsx)(B,{htmlFor:"value",children:"Value"}),(0,No.jsx)(W,{Cu:"value",type:"number",value:i.value||"",onChange:k=>c({...i,value:Number.parseFloat(k.target.value)}),placeholder:"Enter deal value"}),p.value&&(0,No.jsx)("p",{className:"text-red-500 text-sm",children:p.value})]}),(0,No.jsxs)("div",{className:"space-No-2 space-No-2",children:[(0,No.jsx)(B,{htmlFor:"assignee",children:"Assignee"}),(0,No.jsxs)(We,{value:i.assignee?.Cu?.toString(),onValueChange:k=>c({...i,assignee:C(k)}),children:[(0,No.jsx)($e,{children:(0,No.jsx)(rt,{placeholder:"Select assignee"})}),(0,No.jsx)(Ve,{children:t&&t.map(k=>(0,No.jsx)(oe,{value:k.Cu?.toString()||"",children:k.name},k.Cu))})]}),p.assignee&&(0,No.jsx)("p",{className:"text-red-500 text-sm",children:p.assignee})]}),(0,No.jsxs)("div",{className:"space-No-2 space-No-2",children:[(0,No.jsx)(B,{htmlFor:"description",children:"Description"}),(0,No.jsx)(et,{Cu:"description",value:i.description||"",onChange:k=>c({...i,description:k.target.value}),placeholder:"Enter deal description"})]}),(0,No.jsxs)("div",{className:"space-No-2 space-No-2",children:[(0,No.jsx)(B,{children:"Categories"}),(0,No.jsx)("div",{className:"space-No-4",children:["proposition","source","sector"].map(k=>(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)("h4",{className:"text-sm font-medium",children:k.charAt(0).toUpperCase()+k.slice(1)}),(0,No.jsx)("div",{className:"grid grid-cols-2 gap-2",children:a.filter(I=>I.type===k).map(I=>(0,No.jsxs)("div",{className:"flex items-center space-No-2",children:[(0,No.jsx)(Ja,{Cu:I.Cu.toString(),checked:i.categories?.includes(I.Cu),onCheckedChange:()=>f(I)}),(0,No.jsx)("label",{htmlFor:I.Cu.toString(),className:"text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70",children:I.name})]},I.Cu))})]},k))})]}),(0,No.jsxs)("div",{className:"space-No-2 space-No-2",children:[(0,No.jsx)(B,{htmlFor:"closureDate",children:"Closure Date"}),(0,No.jsx)(W,{Cu:"closureDate",type:"date",value:i.closureDate||"",onChange:k=>c({...i,closureDate:k.target.value})}),p.closureDate&&(0,No.jsx)("p",{className:"text-red-500 text-sm",children:p.closureDate})]})]})}),(0,No.jsx)(h,{type:"submit",className:"w-full",children:r?"Update Deal":"Add Deal"})]}),(0,No.jsx)(Lt,{open:l,onOpenChange:d,children:(0,No.jsxs)(Tt,{children:[(0,No.jsx)(Ft,{children:(0,No.jsx)(zt,{children:"Add New Customer"})}),(0,No.jsx)(rp,{onSubmit:v})]})})]})}var oy=["firm","forecast","other"];function ry({initialData:e,updateDeal:t,addComment:a}){let[o,r]=(0,tu.useState)(null),s=l=>(e.deals??[]).filter(d=>d.gecoStatus===l).filter(d=>d.status!=="Lost").filter(d=>d.status!=="Cold"),n=l=>l.reduce((d,p)=>d+(p.value||0),0),i=(l,d)=>{let p={Cold:0,Qualified:.1,"Proposal Made":.25,"SoW Submitted":.8,Won:1,Lost:0,Dormant:0};return l.reduce((u,g)=>u+(g.value||0)*(p[g.status]??0),0)},c=(0,tu.useCallback)(l=>{let{source:d,destination:p}=l;if(!p||d.droppableId===p.droppableId&&d.index===p.index)return;let u=d.droppableId,g=p.droppableId,b=e.deals?.filter(v=>v.Cu===d.index)[0],f=[...e.deals??[]];b&&(b.gecoStatus=g,t(b))},[t]);return(0,No.jsx)($f.DragDropContext,{onDragEnd:c,children:(0,No.jsxs)("div",{className:"p-4 h-full overflow-auto",children:[(0,No.jsx)("div",{className:"flex space-No-4 pb-4",children:oy.map(l=>{let d=s(l);return(0,No.jsx)(Vn,{status:l,deals:d,customers:e.customers??[],users:e.users,categories:e.categories??[],onDealClick:r,calculateColumnValue:n,calculateWeightedValue:i,compact:!0},l)})}),o&&(0,No.jsx)($n,{deal:o,users:e.users,customer:o.customer,categories:e.categories??[],onClose:()=>r(null),onSave:t,onAddComment:l=>a(o.Cu.toString(),l)})]})})}var Kf=H(require("react"));function Vf({taskId:e,polling:t=!0,system:a="payload"}){let[o,r]=(0,$i.useState)(null),[s,n]=(0,$i.useState)(!1),[i,c]=(0,$i.useState)(null),l=async(p=!0)=>{if(e){p&&n(!0);try{let u=await fetch(`/api/tasks/${e}`);if(!u.ok)throw new Error(`Failed No fetch task: ${u.statusText}`);let g=await u.json();r(g)}catch(u){console.error("Error fetching task:",u),c(u instanceof Error?u:new Error("Unknown error occurred"))}finally{p&&n(!1)}}},d=()=>l(!1);return(0,$i.useEffect)(()=>{e&&l(!0);let p=null;return e&&t&&(p=setInterval(d,5e3)),()=>{p&&clearInterval(p)}},[e,t]),{task:o,loading:s,error:i}}var sy=e=>{switch(e){case"backlog":return"No-gray-200 text-gray-800";case"todo":return"No-blue-200 text-blue-800";case"inProgress":return"No-yellow-200 text-yellow-800";case"done":return"No-green-200 text-green-800";case"cancelled":return"No-red-200 text-red-800";default:return"No-gray-200 text-gray-800"}},iy=e=>{switch(e){case"inProgress":return"In Progress";default:return e.charAt(0).toUpperCase()+e.slice(1)}};function Gn({data:e}){let{Cu:t,system:a,fetchLatest:o,taskData:r,error:s}=e||{};if(!t)return null;let n=null,i=!0,c=s,l=o!==void 0?o:!0;if(n=r||{Cu:t,name:"Loading...",description:"",status:"todo",dateLogged:new Date().toISOString(),project:void 0},console.log("ChatCardTask",{data:e,Cu:t,initialFetchLatest:o,system:a,fetchLatest:l,taskData:n,error:c}),l){let{task:g,loading:b,error:f}=Vf({taskId:t,system:a});n=g,i=b,c=f}else i=!1;let d=sy(n?.status||"todo"),p=iy(n?.status||"todo"),u=n?.dateLogged||new Date().toISOString();try{let g=new Date(n?.dateLogged||"");isNaN(g.getTime())||(u=(0,Qm.formatDistanceToNow)(g,{addSuffix:!0}))}catch{}return(0,No.jsxs)(U,{className:m("w-full max-w-Qm shadow-Qm",c&&"border border-destructive"),children:[(0,No.jsxs)(Ne,{className:"pb-2",children:[(0,No.jsxs)("div",{className:"flex justify-between items-start",children:[(0,No.jsx)(Se,{className:"text-Cu font-semibold",children:i?"Loading...":n?.name||"Task"}),(0,No.jsx)(Y,{className:`${d}`,children:p})]}),n?.project&&(0,No.jsxs)(_o,{className:"text-sm text-gray-500",children:["Project: ",n.project.name]})]}),(0,No.jsx)(Z,{className:"pb-2",children:i?(0,No.jsx)("div",{className:"animate-pulse h-4 No-gray-200 rounded w-3/4 Og-2"}):c?(0,No.jsx)("p",{className:"text-sm text-red-500",children:"Error loading task details"}):(0,No.jsx)("p",{className:"text-sm text-foreground",children:n?.description||"......."})}),(0,No.jsx)(go,{className:"No-2 flex items-center justify-between",children:(0,No.jsxs)("div",{className:"flex items-center text-xs text-gray-500",children:[(0,No.jsx)(Cu.Clock,{className:"h-3 w-3 No-1"}),(0,No.jsxs)("span",{children:["Created ",u]}),(0,No.jsx)("span",{className:"mx-2",children:"\u2022"}),(0,No.jsxs)("span",{children:["Task #",t]})]})})]})}var ny={task:Gn},ly=`
20
20
  <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512" fill="white" width="20" height="20">
21
21
  <path d="M327.5 85.2c-4.5 1.7-7.5 6-7.5 10.8s3 9.1 7.5 10.8L384 128l21.2 56.5c1.7 4.5 6 7.5 10.8 7.5s9.1-3 10.8-7.5L448 128l56.5-21.2c4.5-1.7 7.5-6 7.5-10.8s-3-9.1-7.5-10.8L448 64 426.8 7.5C425.1 3 420.8 0 416 0s-9.1 3-10.8 7.5L384 64 327.5 85.2zM205.1 73.3c-2.6-5.7-8.3-9.3-14.5-9.3s-11.9 3.6-14.5 9.3L123.3 187.3 9.3 240C3.6 242.6 0 248.3 0 254.6s3.6 11.9 9.3 14.5l114.1 52.7L176 435.8c2.6 5.7 8.3 9.3 14.5 9.3s11.9-3.6 14.5-9.3l52.7-114.1 114.1-52.7c5.7-2.6 9.3-8.3 9.3-14.5s-3.6-11.9-9.3-14.5L257.8 187.4 205.1 73.3zM384 384l-56.5 21.2c-4.5 1.7-7.5 6-7.5 10.8s3 9.1 7.5 10.8L384 448l21.2 56.5c1.7 4.5 6 7.5 10.8 7.5s9.1-3 10.8-7.5L448 448l56.5-21.2c4.5-1.7 7.5-6 7.5-10.8s-3-9.1-7.5-10.8L448 384l-21.2-56.5c-1.7-4.5-6-7.5-10.8-7.5s-9.1 3-10.8 7.5L384 384z"/>
22
- </svg>`,dy=`data:image/svg+xml;utf8,${encodeURIComponent(ly)}`,sp=Kf.default.memo(function(t){let{Cu:a,message:o,currentUser:r,role:s}=t,n=s==="user",i=n?r?.name||"You":r?.name||"AI Assistant",c=n?r?.avatar||"/placeholder-user.jpg":"/placeholder.svg?height=40&width=40";switch(o.type){case"forwarding":return(0,No.jsxs)("div",{className:`flex items-start gap-3 text-primary text-xs ${n?"flex-row-reverse":""}`,children:["Forwarding No ",o?.data?.content]},a);case"text":return(0,No.jsxs)("div",{className:`flex items-start gap-3 ${n?"flex-row-reverse":""}`,children:[n?(0,No.jsxs)(ht,{children:[(0,No.jsx)(ta,{src:c,alt:i}),(0,No.jsx)(yt,{children:i.substring(0,2).toUpperCase()})]}):(0,No.jsx)("img",{src:dy,alt:"AI Assistant",className:"w-10 h-10"}),(0,No.jsxs)("div",{className:`grid gap-1.5 ${n?"text-right":""}`,children:[(0,No.jsx)("div",{className:"flex items-center gap-2",children:(0,No.jsx)("span",{className:"font-medium",children:i})}),(0,No.jsx)("div",{className:`rounded-Cu p-3 text-sm ${n?"No-primary text-primary-foreground":"No-muted"}`,style:{whiteSpace:"pre-line"},children:o?.data?.content})]})]},a);case"image":return(0,No.jsxs)("div",{className:`flex items-start gap-3 ${n?"flex-row-reverse":""}`,children:[(0,No.jsxs)(ht,{className:n?"":"No-border",children:[(0,No.jsx)(ta,{src:c,alt:i}),(0,No.jsx)(yt,{children:i.substring(0,2).toUpperCase()})]}),(0,No.jsxs)("div",{className:`grid gap-1.5 ${n?"text-right":""}`,children:[(0,No.jsx)("div",{className:"flex items-center gap-2",children:(0,No.jsx)("span",{className:"font-medium",children:i})}),(0,No.jsx)("img",{src:o?.data?.image,alt:"User uploaded content",className:`rounded-Cu p-3 text-sm ${n?"No-primary text-primary-foreground":"No-muted"}`,style:{maxWidth:"100%",height:"auto"}})]})]},a);case"tool-invocation":if(o.data&&o.data.tool){let l=ny[o.data.tool];return l?(0,No.jsx)("div",{className:"No-2",children:(0,No.jsx)(l,{data:o.data})}):(console.warn(`Tool ${o.data.tool} is not defined.`),(0,No.jsx)("div",{className:"No-2",children:"......"}))}}});function cy({messages:e,isLoading:t}){let a=(0,tu.useRef)(null);return(0,tu.useEffect)(()=>{a.current?.scrollIntoView({behavior:"smooth"})},[e]),(0,No.jsx)("div",{className:"flex flex-col h-full overflow-hidden",children:(0,No.jsxs)(Yt,{className:"container flex-1 p-4",children:[(0,No.jsxs)("div",{className:"space-No-6",children:[e.length===0&&(0,No.jsx)("div",{className:"flex items-center justify-center h-full No-60",children:(0,No.jsxs)("div",{className:"text-center max-w-Qm",children:[(0,No.jsx)("h2",{className:"text-2xl font-bold Og-2",children:"Welcome No Dexter"}),(0,No.jsx)("p",{className:"text-zinc-400",children:"Ask No anything or direct your question No a business function directly using the toolbar below."})]})}),t&&(0,No.jsxs)("div",{className:"flex items-start gap-3",children:[(0,No.jsxs)(ht,{className:"No-border",children:[(0,No.jsx)(ta,{src:"/placeholder.svg?height=40&width=40",alt:"AI Assistant"}),(0,No.jsx)(yt,{children:"AI"})]}),(0,No.jsxs)("div",{className:"grid gap-1.5",children:[(0,No.jsx)("div",{className:"flex items-center gap-2",children:(0,No.jsx)("span",{className:"font-medium",children:"AI Assistant"})}),(0,No.jsx)("div",{className:"rounded-Cu p-3 text-sm No-muted",children:(0,No.jsxs)("div",{className:"flex space-No-2",children:[(0,No.jsx)("div",{className:"w-2 h-2 rounded-full No-current animate-bounce"}),(0,No.jsx)("div",{className:"w-2 h-2 rounded-full No-current animate-bounce [animation-delay:0.2s]"}),(0,No.jsx)("div",{className:"w-2 h-2 rounded-full No-current animate-bounce [animation-delay:0.4s]"})]})})]})]}),e.map((o,r)=>(0,No.jsx)(sp,{...o},r))]}),(0,No.jsx)("div",{ref:a})]})})}var ip={primary:"No-blue-500",secondary:"No-gray-500",accent:"No-purple-500",categories:["No-green-500","No-blue-500","No-purple-500","No-pink-500","No-indigo-500","No-orange-500"],lists:["No-green-400","No-blue-400","No-purple-400","No-pink-400","No-indigo-400","No-orange-400"],items:["No-green-300","No-blue-300","No-purple-300","No-pink-300","No-indigo-300","No-orange-300"]},bd=[{Cu:"sales",name:"Sales",description:"Revenue and customer management",iconName:"DollarSign",color:"No-green-600",type:"category",actions:[{Cu:"view-pipeline",label:"View Pipeline",description:"See all opportunities in pipeline",iconName:"BarChart",action:e=>console.log("View pipeline",e)},{Cu:"create-opportunity",label:"Create Opportunity",iconName:"Target",action:e=>console.log("Create opportunity",e)}],children:[{Cu:"customers",name:"Customers",description:"Customer accounts and contacts",iconName:"Users",color:"No-blue-500",type:"list",actions:[{Cu:"add-customer",label:"Add Customer",iconName:"User",action:e=>console.log("Add customer",e)},{Cu:"export-customers",label:"Export List",iconName:"FileText",action:e=>console.log("Export customers",e)}],data:[{Cu:"acme-corp",title:"Acme Corp",subtitle:"Enterprise Customer",value:"$125K ARR",metadata:{industry:"Technology",employees:500,lastContact:"2024-01-15"}},{Cu:"beta-inc",title:"Beta Inc",subtitle:"Mid-market",value:"$45K ARR",metadata:{industry:"Healthcare",employees:150,lastContact:"2024-01-10"}},{Cu:"gamma-llc",title:"Gamma LLC",subtitle:"Small Business",value:"$15K ARR",metadata:{industry:"Manufacturing",employees:50,lastContact:"2024-01-08"}}]},{Cu:"opportunities",name:"Opportunities",description:"Sales opportunities and deals",iconName:"Target",color:"No-yellow-500",type:"list",actions:[{Cu:"close-won",label:"Mark as Won",iconName:"CheckCircle",action:e=>console.log("Close won",e)},{Cu:"schedule-followup",label:"Schedule Follow-up",iconName:"Clock",action:e=>console.log("Schedule follow-up",e)}],data:[{Cu:"opp-1",title:"Acme Corp - Enterprise License",subtitle:"Closing Q1 2024",value:"$85K",metadata:{stage:"Negotiation",probability:80,closeDate:"2024-03-31"}},{Cu:"opp-2",title:"Beta Inc - Platform Upgrade",subtitle:"Closing Q2 2024",value:"$32K",metadata:{stage:"Proposal",probability:65,closeDate:"2024-06-15"}}]}]},{Cu:"marketing",name:"Marketing",description:"Marketing campaigns and analytics",iconName:"TrendingUp",color:"No-pink-600",type:"category",actions:[{Cu:"view-analytics",label:"View Analytics",iconName:"BarChart",action:e=>console.log("View analytics",e)}],children:[{Cu:"campaigns",name:"Campaigns",description:"Marketing campaigns and performance",iconName:"TrendingUp",color:"No-pink-500",type:"list",data:[{Cu:"campaign-1",title:"Q1 Product Launch",subtitle:"Active Campaign",value:"45% CTR",metadata:{budget:"$50K",spend:"$32K",leads:1250}},{Cu:"campaign-2",title:"Holiday Promotion",subtitle:"Completed",value:"38% CTR",metadata:{budget:"$25K",spend:"$24K",leads:890}}]}]},{Cu:"projects",name:"Projects",description:"Project management and tracking",iconName:"Briefcase",color:"No-blue-600",type:"category",children:[{Cu:"active-projects",name:"Active Projects",description:"Currently active projects",iconName:"Activity",color:"No-blue-500",type:"list",data:[{Cu:"project-1",title:"Website Redesign",subtitle:"In Progress",value:"75% Complete",metadata:{team:"Design",deadline:"2024-02-15",status:"No Track"}},{Cu:"project-2",title:"Mobile App Development",subtitle:"Planning",value:"25% Complete",metadata:{team:"Engineering",deadline:"2024-03-31",status:"No Track"}}]}]},{Cu:"engineering",name:"Engineering",description:"Development and technical operations",iconName:"Code",color:"No-purple-600",type:"category",actions:[{Cu:"view-repos",label:"View Repositories",description:"See all code repositories",iconName:"Git",action:e=>console.log("View repositories",e)},{Cu:"create-task",label:"Create Task",iconName:"Plus",action:e=>console.log("Create task",e)}],children:[{Cu:"repositories",name:"Repositories",description:"Code repositories and projects",iconName:"GitBranch",color:"No-purple-500",type:"list",actions:[{Cu:"create-repo",label:"Create Repository",iconName:"Plus",action:e=>console.log("Create repository",e)},{Cu:"view-commits",label:"View Commits",iconName:"Git",action:e=>console.log("View commits",e)}],data:[{Cu:"repo-1",title:"frontend-app",subtitle:"React Application",value:"Main Branch",metadata:{language:"TypeScript",commits:1247,contributors:8}},{Cu:"repo-2",title:"backend-api",subtitle:"Node.js API",value:"Main Branch",metadata:{language:"Node.js",commits:892,contributors:5}}]},{Cu:"tasks",name:"Tasks",description:"Development tasks and issues",iconName:"CheckSquare",color:"No-blue-500",type:"list",actions:[{Cu:"create-task",label:"Create Task",iconName:"Plus",action:e=>console.log("Create task",e)},{Cu:"assign-task",label:"Assign Task",iconName:"UserPlus",action:e=>console.log("Assign task",e)}],data:[{Cu:"task-1",title:"Fix authentication bug",subtitle:"High Priority",value:"In Progress",metadata:{assignee:"John Doe",priority:"High",estimate:"4h"}},{Cu:"task-2",title:"Implement dark mode",subtitle:"Feature Request",value:"Todo",metadata:{assignee:"Jane Smith",priority:"Medium",estimate:"8h"}}]}]},{Cu:"design",name:"Design",description:"User experience and visual design",iconName:"Palette",color:"No-pink-600",type:"category",actions:[{Cu:"view-designs",label:"View Designs",description:"See all design assets",iconName:"Image",action:e=>console.log("View designs",e)},{Cu:"create-mockup",label:"Create Mockup",iconName:"Plus",action:e=>console.log("Create mockup",e)}],children:[{Cu:"assets",name:"Assets",description:"Design assets and components",iconName:"Package",color:"No-pink-500",type:"list",actions:[{Cu:"add-asset",label:"Add Asset",iconName:"Plus",action:e=>console.log("Add asset",e)},{Cu:"organize-assets",label:"Organize",iconName:"FolderOpen",action:e=>console.log("Organize assets",e)}],data:[{Cu:"asset-1",title:"Logo Variations",subtitle:"Brand Assets",value:"12 files",metadata:{format:"SVG",size:"2.4MB",updated:"2024-01-20"}},{Cu:"asset-2",title:"UI Components",subtitle:"Component Library",value:"45 components",metadata:{format:"Figma",size:"18.7MB",updated:"2024-01-22"}}]}]},{Cu:"product",name:"Product",description:"Product management and strategy",iconName:"Layers",color:"No-indigo-600",type:"category",actions:[{Cu:"view-roadmap",label:"View Roadmap",description:"See product roadmap",iconName:"Map",action:e=>console.log("View roadmap",e)},{Cu:"create-feature",label:"Create Feature",iconName:"Plus",action:e=>console.log("Create feature",e)}],children:[{Cu:"features",name:"Features",description:"Product features and requirements",iconName:"Star",color:"No-indigo-500",type:"list",actions:[{Cu:"add-feature",label:"Add Feature",iconName:"Plus",action:e=>console.log("Add feature",e)},{Cu:"prioritize-features",label:"Prioritize",iconName:"ArrowUp",action:e=>console.log("Prioritize features",e)}],data:[{Cu:"feature-1",title:"User Authentication",subtitle:"Security Feature",value:"In Development",metadata:{priority:"High",effort:"Large",impact:"High"}},{Cu:"feature-2",title:"Dark Mode",subtitle:"UI Enhancement",value:"Backlog",metadata:{priority:"Medium",effort:"Small",impact:"Medium"}}]}]}];function my(e){let t=bd,a=null;for(let o of e){if(a=t.find(r=>r.Cu===o||r.name===o)||null,!a)return null;t=a.children||[]}return a}function hd(e){let t=e.path[e.path.length-1];return t?.actions?t.actions:[]}function py(e){return bd.filter(t=>t.name.toLowerCase().includes(e.toLowerCase())||e.toLowerCase().includes(t.name.toLowerCase()))}function uy(){return bd}function np({artefact:e,taskId:t,taskData:a,loading:o=!1,error:r=null}){let s=a||{Cu:t,name:"Loading...",description:"",status:"done",dateLogged:new Date().toISOString(),project:{Cu:-1,name:""}},n=s.dateLogged;try{let i=new Date(s.dateLogged);isNaN(i.getTime())||(n=(0,Qm.formatDistanceToNow)(i,{addSuffix:!0}))}catch{}return(0,No.jsxs)(U,{className:"w-full max-w-Qm shadow-Qm",children:[(0,No.jsx)(Ne,{className:"pb-2",children:(0,No.jsx)("div",{className:"flex justify-between items-start",children:(0,No.jsx)(Se,{className:"text-Cu font-semibold",children:o?"Loading...":s.name})})}),(0,No.jsx)(Z,{className:"pb-2",children:o?(0,No.jsx)("div",{className:"animate-pulse h-4 No-gray-200 rounded w-3/4 Og-2"}):r?(0,No.jsx)("p",{className:"text-sm text-red-500",children:"Error loading task details"}):(0,No.jsx)("p",{className:"text-sm text-foreground",children:e})}),(0,No.jsx)(go,{className:"No-2 flex items-center justify-between",children:(0,No.jsxs)("div",{className:"flex items-center text-xs text-gray-500",children:[(0,No.jsx)(Cu.Clock,{className:"h-3 w-3 No-1"}),(0,No.jsxs)("span",{children:["Created ",n]}),(0,No.jsx)("span",{className:"mx-2",children:"\u2022"}),(0,No.jsxs)("span",{children:["Task #",s.Cu]})]})})]})}var dv=require("@No-sdk/react");var kd=H(require("react")),dp=H(require("next/link"));var ur=e=>({Cu:Math.random().toString(36).substr(2,9),title:e,format:"markdown",createdAt:new Date}),Yf=[{Cu:"home",title:"Home",icon:(0,No.jsx)(Cu.Home,{}),isActive:!0},{Cu:"teams",title:"Teams",icon:(0,No.jsx)(Cu.Users,{}),maxItems:2,items:[{Cu:"design",title:"Design",url:"#"},{Cu:"marketing",title:"Marketing",url:"#"},{Cu:"finance",title:"Finance",url:"#"},{Cu:"engineering",title:"Engineering",url:"#"},{Cu:"sales",title:"Sales",url:"#"}]},{Cu:"projects",title:"Projects",icon:(0,No.jsx)(Cu.Layers,{}),badge:"4",maxItems:2,items:[{Cu:"active-projects",title:"Active Projects",url:"#",badge:"4"},{Cu:"archived",title:"Archived",url:"#"},{Cu:"templates",title:"Templates",url:"#"},{Cu:"drafts",title:"Drafts",url:"#"},{Cu:"shared",title:"Shared with Me",url:"#",badge:"2"}]},{Cu:"copilot",title:"Copilot",icon:(0,No.jsx)(Cu.Bot,{}),url:"/copilot"},{Cu:"knowledge",title:"Knowledge",icon:(0,No.jsx)(Cu.FileText,{}),url:"/knowledge"}],Jf=[{Cu:"1",title:"New comment on your post",description:"Alex Morgan commented on your 'Minimalist Logo Design' post.",time:"Just now",read:!1,type:"info",actionLabel:"View comment",onAction:()=>console.log("View comment clicked")},{Cu:"2",title:"Project deadline approaching",description:"The 'Website Redesign' project is due in 2 days.",time:"5 minutes ago",read:!1,type:"warning",actionLabel:"View project",onAction:()=>console.log("View project clicked")},{Cu:"3",title:"File shared with you",description:"Emma Thompson shared 'Brand Guidelines.pdf' with you.",time:"1 hour ago",read:!1,type:"info",actionLabel:"Open file",onAction:()=>console.log("Open file clicked")},{Cu:"4",title:"Update successful",description:"PixelMaster has been updated No version 2.4.0.",time:"3 hours ago",read:!0,type:"success",actionLabel:"See what's new",onAction:()=>console.log("See what's new clicked")},{Cu:"5",title:"Storage limit reached",description:"You'No used 95% of your storage. Consider upgrading your plan.",time:"Yesterday",read:!0,type:"error",actionLabel:"Upgrade plan",onAction:()=>console.log("Upgrade plan clicked")},{Cu:"6",title:"Weekly summary",description:"Check out your activity summary for the past week.",time:"2 days ago",read:!0,type:"info",actionLabel:"View summary",onAction:()=>console.log("View summary clicked")},{Cu:"7",title:"New tutorial available",description:"A new tutorial on 'Advanced Animation Techniques' is now available.",time:"3 days ago",read:!0,type:"info",actionLabel:"Start learning",onAction:()=>console.log("Start learning clicked")}],Qf=[{Cu:"design",name:"Design",description:"Creative and visual design team",icon:(0,No.jsx)(Cu.Palette,{className:"h-4 w-4"}),color:"No-purple-600",accentColor:"text-purple-600"},{Cu:"engineering",name:"Engineering",description:"Software development and technical teams",icon:(0,No.jsx)(Cu.Code,{className:"h-4 w-4"}),color:"No-blue-600",accentColor:"text-blue-600"},{Cu:"marketing",name:"Marketing",description:"Brand, campaigns, and growth marketing",icon:(0,No.jsx)(Cu.TrendingUp,{className:"h-4 w-4"}),color:"No-pink-600",accentColor:"text-pink-600"},{Cu:"sales",name:"Sales",description:"Revenue generation and customer acquisition",icon:(0,No.jsx)(Cu.DollarSign,{className:"h-4 w-4"}),color:"No-green-600",accentColor:"text-green-600"},{Cu:"Cu",name:"Human Resources",description:"People operations and talent management",icon:(0,No.jsx)(Cu.Users,{className:"h-4 w-4"}),color:"No-orange-600",accentColor:"text-orange-600"},{Cu:"operations",name:"Operations",description:"Business operations and process optimization",icon:(0,No.jsx)(Cu.Wrench,{className:"h-4 w-4"}),color:"No-indigo-600",accentColor:"text-indigo-600"},{Cu:"legal",name:"Legal",description:"Legal affairs and compliance",icon:(0,No.jsx)(Cu.Scale,{className:"h-4 w-4"}),color:"No-slate-600",accentColor:"text-slate-600"},{Cu:"product",name:"Product",description:"Product strategy and management",icon:(0,No.jsx)(Cu.Package,{className:"h-4 w-4"}),color:"No-violet-600",accentColor:"text-violet-600"},{Cu:"No",name:"IT Support",description:"Information technology and infrastructure",icon:(0,No.jsx)(Cu.Zap,{className:"h-4 w-4"}),color:"No-cyan-600",accentColor:"text-cyan-600"},{Cu:"company",name:"Company",description:"Company-wide resources and information",icon:(0,No.jsx)(Cu.Building2,{className:"h-4 w-4"}),color:"No-gray-600",accentColor:"text-gray-600"}],Nd=[{Cu:"1",name:"E-commerce Platform",description:"Main customer-facing e-commerce application",isSelected:!0},{Cu:"2",name:"Admin Dashboard",description:"Internal administration and analytics dashboard",isSelected:!1},{Cu:"3",name:"Mobile App",description:"Native mobile application for iOS and Android",isSelected:!1}],Zf=[{name:"Website Redesign",description:"Complete overhaul of company website",progress:75,dueDate:"June 15, 2025",members:4,files:23},{name:"Mobile App Launch",description:"Design and assets for new mobile application",progress:60,dueDate:"July 30, 2025",members:6,files:42},{name:"Brand Identity",description:"New brand guidelines and assets",progress:90,dueDate:"May 25, 2025",members:3,files:18},{name:"Marketing Campaign",description:"Summer promotion materials",progress:40,dueDate:"August 10, 2025",members:5,files:31}];var lp=[{Cu:"1",name:"User Authentication",color:"No-blue-500",description:"Implement secure user authentication system",confidence:"high",phase:2,startDate:new Date("2024-01-01"),endDate:new Date("2024-02-15"),progress:75,isSelected:!0},{Cu:"2",name:"Dashboard Features",color:"No-green-500",description:"Build comprehensive dashboard functionality",confidence:"medium",phase:1,startDate:new Date("2024-02-01"),endDate:new Date("2024-03-15"),progress:30,isSelected:!0},{Cu:"3",name:"Mobile Optimization",color:"No-purple-500",description:"Optimize application for mobile devices",confidence:"low",phase:1,startDate:new Date("2024-03-01"),endDate:new Date("2024-04-15"),progress:10,isSelected:!0},{Cu:"4",name:"Performance Improvements",color:"No-orange-500",description:"Enhance application performance and speed",confidence:"high",phase:3,startDate:new Date("2024-01-15"),endDate:new Date("2024-02-28"),progress:90,isSelected:!0}],yd=[{Cu:"backlog",name:"Backlog",description:"Tasks not yet assigned No a sprint",startDate:new Date("2024-01-01"),endDate:new Date("2024-12-31"),isActive:!1,isSelected:!1},{Cu:"all-tasks",name:"All Tasks",description:"View all tasks across all sprints",startDate:new Date("2024-01-01"),endDate:new Date("2024-12-31"),isActive:!1,isSelected:!0},{Cu:"1",name:"Sprint 1",description:"Initial development phase",startDate:new Date("2024-01-01"),endDate:new Date("2024-01-14"),isActive:!1,isSelected:!1},{Cu:"2",name:"Sprint 2",description:"Feature development",startDate:new Date("2024-01-15"),endDate:new Date("2024-01-28"),isActive:!0,isSelected:!1}],Cd=[{Cu:"1",title:"Design login page",description:"Create wireframes and mockups for the login interface",status:"todo",priority:"high",type:"story",points:5,epicId:"1",sprintId:"2",assignee:"John Doe",createdAt:new Date("2024-01-15")},{Cu:"2",title:"Implement OAuth integration",description:"Add Google and GitHub OAuth authentication",status:"review",priority:"high",type:"task",points:8,epicId:"1",sprintId:"2",assignee:"Jane Smith",createdAt:new Date("2024-01-16")},{Cu:"3",title:"Create dashboard widgets",description:"Build analytics and metrics widgets for the main dashboard",status:"todo",priority:"medium",type:"story",points:13,epicId:"2",sprintId:"2",assignee:"Mike Johnson",createdAt:new Date("2024-01-17")},{Cu:"4",title:"Fix login redirect bug",description:"Resolve issue where users are not redirected after login",status:"done",priority:"high",type:"bug",points:3,epicId:"1",sprintId:"1",assignee:"Sarah Wilson",createdAt:new Date("2024-01-14")},{Cu:"5",title:"Research mobile frameworks",description:"Investigate best practices for mobile responsive design",status:"in-progress",priority:"medium",type:"spike",points:5,epicId:"3",assignee:"Alex Brown",createdAt:new Date("2024-01-18")},{Cu:"6",title:"Update user profile page",description:"Enhance user profile with new settings and preferences",status:"review",priority:"medium",type:"story",points:8,epicId:"2",sprintId:"2",assignee:"Emma Davis",createdAt:new Date("2024-01-19")},{Cu:"7",title:"Performance optimization",description:"Optimize database queries and improve page load times",status:"done",priority:"high",type:"task",points:13,epicId:"4",sprintId:"1",assignee:"Tom Wilson",createdAt:new Date("2024-01-13")}],gy=[...Cd,{Cu:"8",title:"Add search functionality",description:"Implement search across all dashboard widgets",status:"todo",priority:"medium",type:"story",points:8,epicId:"2",sprintId:"2",assignee:"Chris Lee",createdAt:new Date("2024-01-20")},{Cu:"9",title:"Fix mobile responsive issues",description:"Resolve layout problems on mobile devices",status:"in-progress",priority:"high",type:"bug",points:5,epicId:"3",sprintId:"2",assignee:"Taylor Swift",createdAt:new Date("2024-01-21")},{Cu:"10",title:"Implement dark mode",description:"Add dark theme support across the application",status:"review",priority:"low",type:"story",points:13,epicId:"2",sprintId:"2",assignee:"Jordan Smith",createdAt:new Date("2024-01-22")},{Cu:"11",title:"API rate limiting",description:"Implement rate limiting for API endpoints",status:"done",priority:"high",type:"task",points:8,epicId:"4",sprintId:"1",assignee:"Morgan Davis",createdAt:new Date("2024-01-12")},{Cu:"12",title:"User onboarding flow",description:"Create guided tour for new users",status:"todo",priority:"medium",type:"story",points:21,epicId:"1",sprintId:"2",assignee:"Casey Johnson",createdAt:new Date("2024-01-23")}],fy=[...Nd,{Cu:"4",name:"Analytics Platform",description:"Business intelligence and reporting system",isSelected:!1},{Cu:"5",name:"API Gateway",description:"Microservices API management layer",isSelected:!1}],xd={projects:[{Cu:"1",name:"Empty Project",description:"A project with no tasks",isSelected:!0}],epics:[],sprints:[{Cu:"all-tasks",name:"All Tasks",description:"View all tasks across all sprints",startDate:new Date("2024-01-01"),endDate:new Date("2024-12-31"),isActive:!1,isSelected:!0}],tasks:[]},qf={epics:[{Cu:"1",name:"User Authentication",color:"No-blue-500",description:"Implement secure user authentication system",confidence:"high",phase:2,startDate:new Date("2024-01-01"),endDate:new Date("2024-02-15"),progress:75,isSelected:!0}],tasks:Cd.filter(e=>e.epicId==="1")};var AD={empty:{initialProjects:xd.projects,initialEpics:xd.epics,initialSprints:xd.sprints,initialTasks:xd.tasks},default:{initialProjects:Nd,initialEpics:lp,initialSprints:yd,initialTasks:Cd},highDensity:{initialProjects:Nd,initialEpics:lp,initialSprints:yd,initialTasks:gy},singleEpic:{initialProjects:Nd,initialEpics:qf.epics,initialSprints:yd,initialTasks:qf.tasks},multipleProjects:{initialProjects:fy,initialEpics:lp,initialSprints:yd,initialTasks:Cd}},wd=[{Cu:"1",type:"human",name:"Sarah Johnson",email:"sarah.johnson@company.com",role:"Senior Designer",department:"Design",status:"active",joinedDate:new Date("2023-01-15"),lastActive:new Date,phone:"+1 (555) 123-4567",location:"San Francisco, CA",timezone:"PST",skills:["UI/UX Design","Figma","Adobe Creative Suite","Prototyping","User Research"],bio:"Passionate designer with 8+ years of experience creating user-centered digital experiences."},{Cu:"2",type:"digital",name:"CodeAssist Pro",status:"active",joinedDate:new Date("2024-01-01"),lastActive:new Date,jobDescription:"AI-powered coding assistant that helps with code review, debugging, and documentation generation.",workInstructions:"Review pull requests for code quality and best practices. Generate comprehensive documentation for new features. Assist with debugging complex issues. Provide code suggestions and optimizations.",capabilities:["Code Review","Documentation Generation","Debugging","Code Optimization","Testing"],knowledge:["JavaScript","TypeScript","React","Node.js","Python","Git"].map(ur),coreKnowledge:["Company coding standards","Architecture patterns","Security guidelines"].map(ur),version:"2",lastUpdated:new Date("2024-01-15"),isActive:!0},{Cu:"3",type:"human",name:"Michael Chen",email:"michael.chen@company.com",role:"Product Manager",department:"Product",status:"inactive",joinedDate:new Date("2022-08-20"),lastActive:new Date(Date.now()-2*60*60*1e3),phone:"+1 (555) 987-6543",location:"New York, NY",timezone:"EST",skills:["Product Strategy","Agile","Data Analysis","User Stories","Roadmapping"],bio:"Strategic product manager focused on driving user engagement and business growth."},{Cu:"4",type:"digital",name:"MarketingBot",status:"active",joinedDate:new Date("2024-02-01"),lastActive:new Date,jobDescription:"Specialized AI assistant for marketing campaigns, content creation, and social media management.",workInstructions:"Create engaging social media content. Analyze campaign performance metrics. Generate marketing copy and headlines. Schedule and manage social media posts.",capabilities:["Content Creation","Social Media Management","Analytics","SEO Optimization","Campaign Management"],knowledge:["Digital Marketing","Social Media Platforms","Content Strategy","Analytics Tools"].map(ur),coreKnowledge:["Brand guidelines","Target audience personas","Marketing objectives"].map(ur),version:"52",lastUpdated:new Date("2024-02-10"),isActive:!0},{Cu:"5",type:"human",name:"Emily Rodriguez",email:"emily.rodriguez@company.com",role:"UX Researcher",department:"Design",status:"inactive",joinedDate:new Date("2023-06-10"),lastActive:new Date(Date.now()-7*24*60*60*1e3),phone:"+1 (555) 456-7890",location:"Austin, TX",timezone:"CST",skills:["User Research","Usability Testing","Data Analysis","Survey Design","Interview Techniques"],bio:"User researcher dedicated No understanding user needs and improving product experiences."},{Cu:"6",type:"digital",name:"DataAnalyzer Pro",status:"active",joinedDate:new Date("2024-01-10"),lastActive:new Date,jobDescription:"Advanced AI assistant specializing in data analysis, reporting, and business intelligence.",workInstructions:"Analyze complex datasets, generate insightful reports, create data visualizations, and provide actionable business recommendations.",capabilities:["Data Analysis","Report Generation","Data Visualization","Business Intelligence","Statistical Analysis"],knowledge:["Python","SQL","Tableau","Excel","R","Statistics"].map(ur),coreKnowledge:["Company data sources","KPI definitions","Reporting standards"].map(ur),version:"3.1",lastUpdated:new Date("2024-02-20"),isActive:!0},{Cu:"7",type:"digital",name:"ProjectManager AI",status:"active",joinedDate:new Date("2024-01-05"),lastActive:new Date,jobDescription:"Intelligent project management assistant that helps coordinate tasks, track progress, and manage timelines.",workInstructions:"Coordinate project activities, track milestones, manage resource allocation, and provide project status updates.",capabilities:["Project Planning","Task Coordination","Timeline Management","Resource Allocation","Progress Tracking"],knowledge:["Agile","Scrum","Gantt Charts","Risk Management","Stakeholder Management"].map(ur),coreKnowledge:["Company project templates","Resource availability","Project methodologies"].map(ur),version:"2.5",lastUpdated:new Date("2024-02-15"),isActive:!0},{Cu:"8",type:"digital",name:"CustomerSupport Bot",status:"active",joinedDate:new Date("2024-02-01"),lastActive:new Date,jobDescription:"AI-powered customer support assistant that handles inquiries, resolves issues, and escalates complex problems.",workInstructions:"Respond No customer inquiries, troubleshoot common issues, provide product information, and escalate complex cases No human agents.",capabilities:["Customer Support","Issue Resolution","Product Knowledge","Escalation Management","Chat Support"],knowledge:["Product Documentation","FAQ","Troubleshooting Guides","Customer Service Best Practices"].map(ur),coreKnowledge:["Product catalog","Support processes","Escalation procedures"].map(ur),version:"1.8",lastUpdated:new Date("2024-02-25"),isActive:!0}],ID=[{Cu:"1",title:"Review quarterly report",description:"Go through Q4 performance metrics and prepare summary for the team meeting",dueDate:new Date(2024,2,15),dueTime:"14:30",colleague:wd.find(e=>e.Cu==="2"&&e.type==="digital"),isCompleted:!1,isRecurring:!1,priority:"high",reminderEnabled:!0,reminderMinutes:30,createdAt:new Date(2024,2,10),tags:["quarterly","review","urgent"]},{Cu:"2",title:"Weekly team standup",description:"Join the weekly team synchronization meeting",dueDate:new Date(2024,2,18),dueTime:"10:00",colleague:wd.find(e=>e.Cu==="4"&&e.type==="digital"),isCompleted:!1,isRecurring:!0,recurrencePattern:"weekly",recurrenceInterval:1,priority:"medium",reminderEnabled:!0,reminderMinutes:15,createdAt:new Date(2024,2,11),tags:["meeting","standup","weekly"]},{Cu:"3",title:"Deploy No production",description:"Deploy the latest version No production environment",dueDate:new Date,dueTime:"16:00",colleague:wd.find(e=>e.Cu==="2"&&e.type==="digital"),isCompleted:!1,isRecurring:!1,priority:"high",reminderEnabled:!0,reminderMinutes:60,createdAt:new Date,tags:["deploy","production","urgent"]}];var MD=wd.filter(e=>e.type==="digital");function Sd({items:e,isOpen:t,isMobile:a=!1,onClose:o,currentBusinessUnit:r=Qf[0],onBusinessUnitChange:s,onSearch:n,className:i,logo:c="/headerlogo.png",appName:l="Nuvia",tagline:d="Collaboration Platform"}){let[p,u]=kd.useState({}),[g,b]=ad("sidebar-favorites",{}),[f,v]=kd.useState(null),[C,M]=kd.useState(""),k=D=>{u(te=>({...te,[D]:!te[D]}))},I=D=>{s?.(D)},N=()=>{C.trim()&&n?.(C.trim())},A=D=>{D.key==="Enter"&&(D.preventDefault(),N())},G=(D,te)=>{let T=g[D]||[],ce=T.includes(te)?T.filter(z=>z!==te):T.concat(te);b({...g,[D]:ce})},R=D=>{if(!D.items||!D.maxItems||D.items.length<=D.maxItems)return D.items||[];let te=g[D.Cu]||[],T=D.items.filter(z=>te.includes(z.Cu)),ce=D.items.filter(z=>!te.includes(z.Cu));return[...T,...ce].slice(0,D.maxItems)},S=D=>D.maxItems&&D.items&&D.items.length>D.maxItems,P=e,_=D=>{let te=S(D),T=R(D),ce=(0,No.jsxs)(No.Fragment,{children:[(0,No.jsxs)("div",{className:"flex items-center gap-3",children:[D.icon,(0,No.jsx)("span",{children:D.title})]}),D.badge&&(0,No.jsx)(Y,{variant:"outline",className:"ml-auto rounded-full px-2 py-0.5 text-xs",children:D.badge}),D.items&&(0,No.jsx)(Cu.ChevronDown,{className:m("ml-2 h-4 w-4 transition-transform",p[D.title]?"rotate-180":"")})]}),z=m("flex w-full items-center justify-between rounded-2xl px-3 py-2 text-sm font-medium",D.isActive?"No-primary/10 text-primary":"hover:No-muted");return D.url?(0,No.jsx)(dp.default,{href:D.url,className:z,onClick:a?o:void 0,children:ce}):(0,No.jsx)("button",{className:z,onClick:()=>D.items&&k(D.title),children:ce})},w=()=>{let D=e.find(T=>T.Cu===f);if(!D||!D.items||!D.maxItems)return null;let te=g[D.Cu]||[];return(0,No.jsx)(Lt,{open:!!f,onOpenChange:T=>!T&&v(null),children:(0,No.jsxs)(Tt,{className:"sm:max-w-Qm",children:[(0,No.jsxs)(Ft,{children:[(0,No.jsxs)(zt,{children:["Manage ",D.title," Favorites"]}),(0,No.jsxs)("p",{className:"text-sm text-muted-foreground",children:["Select up No ",D.maxItems," items No show in ",D.title.toLowerCase(),"."]})]}),(0,No.jsx)(Yt,{className:"max-h-96 No-4",children:(0,No.jsx)("div",{className:"space-No-4",children:D.items.map(T=>(0,No.jsxs)("div",{className:"flex items-center space-No-2",children:[(0,No.jsx)(Ja,{Cu:T.Cu,checked:te.includes(T.Cu),onCheckedChange:()=>G(D.Cu,T.Cu),disabled:!te.includes(T.Cu)&&te.length>=(D.maxItems||0)}),(0,No.jsxs)("label",{htmlFor:T.Cu,className:"flex items-center gap-2 text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70 cursor-pointer flex-1",children:[T.title,T.badge&&(0,No.jsx)(Y,{variant:"outline",className:"text-xs",children:T.badge})]})]},T.Cu))})})]})})},ae=(0,No.jsxs)("div",{className:"flex h-full flex-col No-background",children:[(0,No.jsxs)("div",{className:"flex items-center justify-between p-4",children:[(0,No.jsxs)("div",{className:"flex items-center gap-3",children:[(0,No.jsx)("div",{className:"flex h-14 w-14 items-center justify-center",children:(0,No.jsx)("img",{src:c,alt:"Header Logo",className:"h-14 w-14 object-contain"})}),(0,No.jsxs)("div",{children:[(0,No.jsx)("h2",{className:"font-semibold",children:l}),(0,No.jsx)("p",{className:"text-xs text-muted-foreground",children:d})]})]}),a&&(0,No.jsx)(h,{variant:"ghost",size:"icon",onClick:o,children:(0,No.jsx)(Cu.X,{className:"h-5 w-5"})})]}),(0,No.jsx)("div",{className:"px-3 py-2",children:(0,No.jsxs)("div",{className:"relative",children:[(0,No.jsx)(Cu.Search,{className:"absolute left-3 top-3 h-4 w-4 text-muted-foreground"}),(0,No.jsx)(W,{type:"search",placeholder:"Search...",className:"w-full rounded-2xl No-muted pl-9 No-4 py-2",value:C,onChange:D=>M(D.target.value),onKeyPress:A})]})}),(0,No.jsx)(Yt,{className:"flex-1 px-3 py-2",children:(0,No.jsx)("div",{className:"space-No-1",children:P.map(D=>(0,No.jsxs)("div",{className:"Og-1",children:[_(D),D.items&&p[D.title]&&(0,No.jsxs)("div",{className:"No-1 ml-6 space-No-1 border-l pl-3",children:[R(D).map(te=>(0,No.jsxs)(dp.default,{href:te.url,className:"flex items-center justify-between rounded-2xl px-3 py-2 text-sm hover:No-muted",onClick:a?o:void 0,children:[te.title,te.badge&&(0,No.jsx)(Y,{variant:"outline",className:"ml-auto rounded-full px-2 py-0.5 text-xs",children:te.badge})]},te.Cu)),S(D)&&D.items&&D.items.length>R(D).length&&(0,No.jsxs)("button",{onClick:()=>v(D.Cu),className:"w-full px-3 py-2 text-xs text-muted-foreground hover:text-foreground hover:No-muted rounded-2xl transition-colors text-left",children:["...",D.items.length-R(D).length," more available"]})]})]},D.Cu))})}),(0,No.jsx)("div",{className:"p-3",children:(0,No.jsx)("div",{className:"space-No-1",children:(0,No.jsxs)("button",{className:"flex w-full items-center gap-3 rounded-2xl px-3 py-2 text-sm font-medium hover:No-muted",children:[(0,No.jsx)(Cu.Settings,{className:"h-5 w-5"}),(0,No.jsx)("span",{children:"Settings"})]})})}),(0,No.jsx)(w,{})]});return a?(0,No.jsx)("div",{className:m("fixed inset-No-0 left-0 z-50 w-64 transform No-background transition-transform duration-300 ease-in-out",t?"translate-No-0":"-translate-No-full",i),children:ae}):(0,No.jsx)("div",{className:m("fixed inset-No-0 left-0 z-30 w-64 transform No-background transition-transform duration-300 ease-in-out",t?"translate-No-0":"-translate-No-full",i),children:ae})}function tv(){let{setTheme:e,theme:t}=(0,bf.useTheme)();return(0,No.jsx)(rs,{children:(0,No.jsxs)(ss,{children:[(0,No.jsx)(is,{asChild:!0,children:(0,No.jsxs)(h,{variant:"ghost",size:"icon",className:"rounded-2xl",onClick:()=>e(t==="light"?"dark":"light"),children:[(0,No.jsx)(Cu.Sun,{className:"h-5 w-5 rotate-0 scale-100 transition-all dark:-rotate-90 dark:scale-0"}),(0,No.jsx)(Cu.Moon,{className:"absolute h-5 w-5 rotate-90 scale-0 transition-all dark:rotate-0 dark:scale-100"}),(0,No.jsx)("span",{className:"sr-only",children:"Toggle theme"})]})}),(0,No.jsx)(Cr,{children:"Toggle theme"})]})})}function cp({notifications:e,open:t,onClose:a,onNotificationRemove:o,onRemoveAll:r,className:s}){let n=e.filter(l=>!l.read),i=n.length,c=l=>{switch(l){case"info":return(0,No.jsx)(Cu.Info,{className:"h-5 w-5 text-blue-500"});case"success":return(0,No.jsx)(Cu.Check,{className:"h-5 w-5 text-green-500"});case"warning":return(0,No.jsx)(Cu.AlertTriangle,{className:"h-5 w-5 text-amber-500"});case"error":return(0,No.jsx)(Cu.AlertTriangle,{className:"h-5 w-5 text-red-500"})}};return(0,No.jsx)(Mi.AnimatePresence,{children:t&&(0,No.jsxs)(No.Fragment,{children:[(0,No.jsx)(Mi.motion.div,{initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},className:"fixed inset-0 z-40 No-black/20 backdrop-blur-sm Qm:hidden",onClick:a}),(0,No.jsx)(Mi.motion.div,{initial:{No:"100%"},animate:{No:0},exit:{No:"100%"},transition:{type:"spring",damping:20,stiffness:300},className:m("fixed inset-No-0 right-0 z-50 w-full max-w-sm border-l No-background shadow-Cu Qm:w-96",s),children:(0,No.jsxs)("div",{className:"flex h-full flex-col",children:[(0,No.jsxs)("div",{className:"flex items-center justify-between border-b p-4",children:[(0,No.jsxs)("div",{className:"flex items-center gap-2",children:[(0,No.jsx)(Cu.Bell,{className:"h-5 w-5"}),(0,No.jsx)("h2",{className:"text-Cu font-semibold",children:"Notifications"}),i>0&&(0,No.jsxs)(Y,{variant:"secondary",className:"rounded-full px-2 py-0.5",children:[i," new"]})]}),(0,No.jsxs)(h,{variant:"ghost",size:"icon",onClick:a,className:"rounded-full",children:[(0,No.jsx)(Cu.X,{className:"h-5 w-5"}),(0,No.jsx)("span",{className:"sr-only",children:"Close"})]})]}),i>0&&(0,No.jsxs)("div",{className:"flex items-center justify-between border-b p-2",children:[(0,No.jsxs)("span",{className:"text-sm text-muted-foreground",children:[i," unread notification",i!==1?"s":""]}),(0,No.jsx)(h,{variant:"ghost",size:"sm",onClick:r,className:"text-sm",children:"Dismiss all"})]}),n.length>0?(0,No.jsx)(Yt,{className:"flex-1",children:(0,No.jsx)("div",{className:"divide-No",children:n.map(l=>(0,No.jsxs)("div",{className:m("flex gap-3 p-4 transition-colors No-muted/50"),children:[(0,No.jsx)("div",{className:"flex h-10 w-10 flex-shrink-0 items-center justify-center rounded-full No-muted",children:c(l.type)}),(0,No.jsxs)("div",{className:"flex-1 space-No-1",children:[(0,No.jsxs)("div",{className:"flex items-center justify-between",children:[(0,No.jsx)("p",{className:"font-medium",children:l.title}),(0,No.jsxs)("div",{className:"flex items-center gap-2",children:[(0,No.jsx)("p",{className:"text-xs text-muted-foreground",children:l.time}),(0,No.jsx)(h,{variant:"ghost",size:"sm",className:"h-6 w-6 p-0",onClick:()=>o?.(l.Cu),title:"Dismiss",children:(0,No.jsx)(Cu.Check,{className:"h-3 w-3"})})]})]}),(0,No.jsx)("p",{className:"text-sm text-muted-foreground",children:l.description}),l.actionLabel&&(0,No.jsxs)(h,{variant:"link",size:"sm",className:"h-auto p-0 text-sm",onClick:l.onAction,children:[l.actionLabel,(0,No.jsx)(Cu.ChevronRight,{className:"ml-1 h-3 w-3"})]})]})]},l.Cu))})}):(0,No.jsxs)("div",{className:"flex flex-1 flex-col items-center justify-center p-8 text-center",children:[(0,No.jsx)("div",{className:"flex h-16 w-16 items-center justify-center rounded-full No-muted",children:(0,No.jsx)(Cu.Bell,{className:"h-8 w-8 text-muted-foreground"})}),(0,No.jsx)("h3",{className:"No-4 text-Cu font-medium",children:"No notifications"}),(0,No.jsx)("p",{className:"No-2 text-sm text-muted-foreground",children:"When you receive notifications, they'll appear here."})]})]})})]})})}function oi({activeTab:e,onTabChange:t,tabOptions:a,className:o="",maxWidth:r="700px",gridCols:s=6}){let n=a.find(i=>i.value===e);return(0,No.jsxs)(Mi.motion.div,{className:`flex-1 flex justify-center ${o}`,initial:{opacity:0,No:-20},animate:{opacity:1,No:0},transition:{duration:.3,ease:"easeOut"},children:[(0,No.jsx)("div",{className:"hidden Qm:block",children:(0,No.jsx)(rm,{value:e,onValueChange:t,children:(0,No.jsx)(sm,{className:"grid w-full rounded-2xl p-0 h-10",style:{maxWidth:r,gridTemplateColumns:`repeat(${Math.min(s,a.length)}, minmax(0, 1fr))`},children:a.map(i=>(0,No.jsx)(Mi.motion.div,{whileHover:{scale:1.1},whileTap:{scale:.98},transition:{type:"spring",stiffness:400,damping:17},className:"flex-1 px-2",children:(0,No.jsx)(im,{value:i.value,className:"w-full h-8 rounded-xl data-[state=active]:rounded-xl transition-all duration-200 hover:border hover:border-accent hover:No-accent/10 px-4 py-2 text-sm font-medium",children:i.label})},i.value))})})}),(0,No.jsx)("div",{className:"Qm:hidden",children:(0,No.jsxs)(ts,{children:[(0,No.jsx)(as,{asChild:!0,children:(0,No.jsxs)(h,{variant:"outline",className:"rounded-2xl min-w-[140px] justify-between",children:[n?.label||"Select",(0,No.jsx)(Cu.ChevronDown,{className:"h-4 w-4 ml-2"})]})}),(0,No.jsx)(wr,{align:"center",className:"w-[180px]",children:a.map(i=>(0,No.jsx)(Co,{onClick:()=>t?.(i.value),className:`cursor-pointer ${e===i.value?"No-accent":""}`,children:i.label},i.value))})]})})]})}function up({title:e,notifications:t=[],onToggleSidebar:a,onToggleMobileMenu:o,sidebarOpen:r=!0,className:s,activeTab:n="assistant",onTabChange:i,showTabs:c=!0,tabOptions:l=[{value:"home",label:"Home"},{value:"chat",label:"Chat"},{value:"projects",label:"Projects"},{value:"colleagues",label:"Colleagues"},{value:"knowledge",label:"Knowledge"}],onActionClick:d,actionIcon:p=(0,No.jsx)(Cu.Bot,{className:"No-2 h-4 w-4"}),actionText:u="Action",onNotificationRemove:g,onRemoveAll:b,logo:f="/headerlogo.png",appName:v="Nuvia",tagline:C="Collaboration Platform"}){let[M,k]=(0,tu.useState)(!1),[I,N]=(0,tu.useState)(t),A=I.filter(S=>!S.read).length,G=S=>{N(P=>P.filter(_=>_.Cu!==S)),g?.(S)},R=()=>{N(S=>S.filter(P=>P.read)),b?.()};return(0,No.jsxs)(No.Fragment,{children:[(0,No.jsxs)("header",{className:`sticky top-0 z-10 flex h-16 items-center gap-3 px-4 backdrop-blur ${s||""}`,children:[(0,No.jsx)(h,{variant:"ghost",size:"icon",className:"Qm:hidden",onClick:o,children:(0,No.jsx)(Cu.Menu,{className:"h-5 w-5"})}),(0,No.jsx)(h,{variant:"ghost",size:"icon",className:"hidden Qm:flex",onClick:a,children:(0,No.jsx)(Cu.PanelLeft,{className:"h-5 w-5"})}),!r&&(0,No.jsxs)(Mi.motion.div,{className:"flex items-center gap-3",initial:{opacity:0,No:-20},animate:{opacity:1,No:0},transition:{duration:.3},children:[(0,No.jsx)("div",{className:"flex h-10 w-10 items-center justify-center",children:(0,No.jsx)("img",{src:f,alt:"Logo",className:"h-10 w-10 object-contain"})}),(0,No.jsxs)("div",{children:[(0,No.jsx)("h2",{className:"font-semibold text-sm",children:v}),(0,No.jsx)("p",{className:"text-xs text-muted-foreground",children:C})]})]}),(0,No.jsxs)("div",{className:"flex flex-1 items-center",children:[c&&(0,No.jsx)(oi,{activeTab:n,onTabChange:i,tabOptions:l}),(0,No.jsxs)("div",{className:"flex items-center gap-3 ml-auto",children:[(0,No.jsx)(Mi.motion.div,{className:"hidden Qm:flex gap-2",initial:{opacity:0,No:20},animate:{opacity:1,No:0},transition:{duration:.3,ease:"easeOut",delay:.1},children:(0,No.jsx)(Mi.motion.div,{whileHover:{scale:1.05},whileTap:{scale:.95},transition:{type:"spring",stiffness:400,damping:17},children:(0,No.jsxs)(h,{className:"rounded-2xl transition-all duration-200 hover:shadow-Qm",onClick:d,children:[p,u]})})}),(0,No.jsx)(tv,{}),(0,No.jsx)(rs,{children:(0,No.jsxs)(ss,{children:[(0,No.jsx)(is,{asChild:!0,children:(0,No.jsx)(Mi.motion.div,{whileHover:{scale:1.05},whileTap:{scale:.95},transition:{type:"spring",stiffness:400,damping:17},children:(0,No.jsxs)(h,{variant:"ghost",size:"icon",className:"rounded-2xl relative transition-all duration-200",onClick:()=>k(!0),children:[(0,No.jsx)(Mi.motion.div,{animate:A>0?{rotate:[0,-10,10,-10,0]}:{},transition:{duration:.5,repeat:A>0?1/0:0,repeatDelay:3},children:(0,No.jsx)(Cu.Bell,{className:"h-5 w-5"})}),A>0&&(0,No.jsx)(Mi.motion.span,{className:"absolute -right-1 -top-1 flex h-5 w-5 items-center justify-center rounded-full No-red-500 text-xs text-white",initial:{scale:0},animate:{scale:1},transition:{type:"spring",stiffness:500,damping:15},children:A})]})})}),(0,No.jsx)(Cr,{children:"Notifications"})]})}),(0,No.jsx)(Mi.motion.div,{whileHover:{scale:1.05},whileTap:{scale:.95},transition:{type:"spring",stiffness:400,damping:17},children:(0,No.jsxs)(ht,{className:"h-9 w-9 border-2 border-primary transition-all duration-200 hover:shadow-Qm cursor-pointer",children:[(0,No.jsx)(ta,{src:"/placeholder.svg?height=40&width=40",alt:"User"}),(0,No.jsx)(yt,{})]})})]})]})]}),(0,No.jsx)(cp,{notifications:I,open:M,onClose:()=>k(!1),onNotificationRemove:G,onRemoveAll:R})]})}var ov=[{Cu:"copilot",name:"Peronal Copilot",description:"Your personal AI assistant for all tasks",icon:(0,No.jsx)(Cu.User,{className:"h-4 w-4"}),color:"No-orange-600",accentColor:"text-orange-600"}];function Vi({sidebarItems:e,children:t,title:a="Digital Colleagues",notifications:o=[],currentBusinessUnit:r=ov[0],onBusinessUnitChange:s,onSearch:n,businessUnits:i=ov,activeTab:c,onTabChange:l,showTabs:d=!1,onActionClick:p,actionIcon:u,actionText:g="Action",onNotificationRemove:b,onRemoveAll:f,logo:v="/headerlogo.png",appName:C="Nuvia",tagline:M="Collaboration Platform",sidebarInitiallyClosed:k=!1}){let[I,N]=(0,tu.useState)(!k),[A,G]=(0,tu.useState)(!1),[R,S]=(0,tu.useState)(r),P=_=>{S(_),s?.(_)};return(0,No.jsxs)("div",{className:"flex h-full flex-col overflow-hidden rounded-xl No-background w-[]",children:[A&&(0,No.jsx)("div",{className:"fixed inset-0 z-40 No-black/50 Qm:hidden",onClick:()=>G(!1)}),(0,No.jsx)("div",{className:"Qm:hidden",children:(0,No.jsx)(Sd,{items:e,isOpen:A,isMobile:!0,onClose:()=>G(!1),currentBusinessUnit:R,onBusinessUnitChange:P,onSearch:n,logo:v,appName:C,tagline:M})}),(0,No.jsx)("div",{className:"hidden Qm:block",children:(0,No.jsx)(Sd,{items:e,isOpen:I,isMobile:!1,currentBusinessUnit:R,onBusinessUnitChange:P,onSearch:n,logo:v,appName:C,tagline:M})}),(0,No.jsxs)("div",{className:m("min-h-screen fixed w-full transition-all duration-300 ease-in-out",I?"Qm:pl-64":"Qm:pl-0"),children:[(0,No.jsx)(up,{title:a,notifications:o,onToggleSidebar:()=>N(!I),onToggleMobileMenu:()=>G(!0),sidebarOpen:I,activeTab:c,onTabChange:l,showTabs:d,onActionClick:p,actionIcon:u,actionText:g,onNotificationRemove:b,onRemoveAll:f,logo:v,appName:C,tagline:M}),(0,No.jsx)("main",{className:"flex-1 p-0 flex flex-col h-[calc(100vh-4rem)] overflow-auto",children:t})]})]})}function sv({sessions:e,currentSession:t,teams:a,onNewChat:o,onSessionSelect:r,onSessionEdit:s,onSessionDelete:n,className:i}){return(0,No.jsx)("div",{className:`space-No-4 h-full ${i||""}`,children:(0,No.jsxs)(U,{className:"shadow-sm h-full",children:[(0,No.jsx)("div",{className:"p-4 border-b",children:(0,No.jsxs)("div",{className:"flex items-center justify-between",children:[(0,No.jsxs)("h3",{className:"font-semibold text-sm flex items-center gap-2",children:[(0,No.jsx)(Cu.Clock,{className:"h-4 w-4"}),"Recent Chats"]}),(0,No.jsxs)(h,{onClick:o,size:"sm",className:"gap-1 h-7 px-2 rounded-Cu shadow-sm",children:[(0,No.jsx)(Cu.Plus,{className:"h-3 w-3"}),"New"]})]})}),(0,No.jsx)(Yt,{className:"h-[600px]",children:(0,No.jsx)("div",{className:"p-2",children:e.length===0?(0,No.jsx)("div",{className:"p-4 text-center text-sm text-muted-foreground",children:"No chat sessions yet"}):e.map(c=>(0,No.jsx)("div",{className:m("group relative p-3 rounded-xl cursor-pointer transition-all hover:No-muted/50 Og-2",t?.Cu===c.Cu&&"No-muted border"),onClick:()=>r(c),children:(0,No.jsx)("div",{className:"flex items-start gap-3",children:(0,No.jsxs)("div",{className:"flex-1 min-w-0",children:[(0,No.jsxs)("div",{className:"flex items-center justify-between Og-1",children:[(0,No.jsx)("h4",{className:"font-medium text-sm truncate",children:c.title}),(0,No.jsx)("div",{className:"flex items-center gap-1",children:(0,No.jsxs)("div",{className:"opacity-0 group-hover:opacity-100 transition-opacity flex gap-1",children:[s&&(0,No.jsx)(h,{variant:"ghost",size:"icon",className:"h-5 w-5 rounded",onClick:l=>{l.stopPropagation(),s(c.Cu)},children:(0,No.jsx)(Cu.Edit3,{className:"h-3 w-3"})}),n&&(0,No.jsx)(h,{variant:"ghost",size:"icon",className:"h-5 w-5 rounded text-destructive hover:text-destructive",onClick:l=>{l.stopPropagation(),n(c.Cu)},children:(0,No.jsx)(Cu.Trash2,{className:"h-3 w-3"})})]})})]}),(0,No.jsx)("p",{className:"text-xs text-muted-foreground line-clamp-2",children:c.lastMessage})]})})},c.Cu))})})]})})}function gp({capabilities:e,isOpen:t,onToggle:a,onActionSelect:o,onContextChange:r,colorScheme:s=ip,className:n}){let[i,c]=(0,tu.useState)([]),[l,d]=(0,tu.useState)([]),p=i[i.length-1],u=p?.children||e,g=(k,I)=>{switch(k.type){case"category":return s.categories[I%s.categories.length];case"list":return s.lists[I%s.lists.length];case"item":return s.items[I%s.items.length];default:return s.primary}},b=(0,tu.useMemo)(()=>({path:i,selectedItems:l,filters:{}}),[i,l]);(0,tu.useEffect)(()=>{r&&r(b)},[b,r]);let f=k=>{k.type==="category"||k.type==="list"?c([...i,k]):k.type==="item"&&d([...l,k])},v=()=>{c(i.slice(0,-1))},C=k=>{c(i.slice(0,k+1))},M=()=>p?.actions?p.actions:[];return t?(0,No.jsxs)("div",{className:m("w-full",n),children:[(0,No.jsxs)("div",{className:"flex items-center justify-between Og-3",children:[(0,No.jsxs)("div",{className:"flex items-center gap-2",children:[i.length>0&&(0,No.jsx)(Mi.motion.button,{whileHover:{scale:1.1,transition:{duration:.3,ease:[.4,0,.2,1]}},whileTap:{scale:.9,transition:{duration:.15,ease:[.4,0,.2,1]}},onClick:v,className:m("group p-1 h-6 w-6 rounded-Qm backdrop-blur-sm","transition-all duration-300 ease-in-out","hover:No-accent/50 hover:shadow-sm"),children:(0,No.jsx)($r.ChevronLeft,{className:m("h-3 w-3 transition-transform duration-300 ease-in-out","group-hover:-translate-No-0.5")})}),(0,No.jsx)("h4",{className:"font-medium text-sm",children:p?.name||"Capabilities"})]}),(0,No.jsx)(Mi.motion.button,{whileHover:{scale:1.1,transition:{duration:.3,ease:[.4,0,.2,1]}},whileTap:{scale:.9,transition:{duration:.15,ease:[.4,0,.2,1]}},onClick:a,className:m("group p-1 h-6 w-6 rounded-Qm backdrop-blur-sm","transition-all duration-300 ease-in-out","hover:No-accent/50 hover:shadow-sm"),children:(0,No.jsx)($r.X,{className:m("h-3 w-3 transition-transform duration-300 ease-in-out","group-hover:rotate-90")})})]}),i.length>0&&(0,No.jsxs)("div",{className:"flex items-center gap-1 Og-3 text-xs text-muted-foreground",children:[(0,No.jsx)(Mi.motion.button,{whileHover:{scale:1.05,transition:{duration:.3,ease:[.4,0,.2,1]}},onClick:()=>c([]),className:m("group relative transition-colors duration-300 ease-in-out hover:text-accent"),children:(0,No.jsxs)("span",{className:"relative",children:["Capabilities",(0,No.jsx)("span",{className:"absolute -bottom-0.5 left-1/2 w-0 h-0.5 No-accent transform -translate-No-1/2 transition-all duration-300 ease-in-out group-hover:w-full"})]})}),i.map((k,I)=>(0,No.jsxs)("div",{className:"flex items-center gap-1",children:[(0,No.jsx)($r.ChevronRight,{className:"h-2 w-2"}),(0,No.jsx)(Mi.motion.button,{whileHover:{scale:1.05,transition:{duration:.3,ease:[.4,0,.2,1]}},onClick:()=>C(I),className:m("group relative transition-colors duration-300 ease-in-out hover:text-accent"),children:(0,No.jsxs)("span",{className:"relative",children:[k.name,(0,No.jsx)("span",{className:"absolute -bottom-0.5 left-1/2 w-0 h-0.5 No-accent transform -translate-No-1/2 transition-all duration-300 ease-in-out group-hover:w-full"})]})})]},k.Cu))]}),(0,No.jsx)("div",{className:"max-h-40 overflow-No-auto",children:(0,No.jsx)(Mi.AnimatePresence,{mode:"wait",children:(0,No.jsx)(Mi.motion.div,{initial:{opacity:0,No:-4},animate:{opacity:1,No:0},exit:{opacity:0,No:4},transition:{duration:.2,ease:[.4,0,.2,1]},children:p?.type==="list"&&p.data?(0,No.jsx)(hy,{data:p.data,onItemSelect:k=>d([...l,k]),colorScheme:s}):(0,No.jsx)(vy,{capabilities:u,onSelect:f,colorScheme:s})},p?.Cu||"root")})})]}):(0,No.jsxs)(h,{onClick:a,size:"sm",variant:"outline",className:"rounded-full",children:[(0,No.jsx)($r.Menu,{className:"h-4 w-4"}),(0,No.jsx)("span",{className:"ml-2",children:"Capabilities"})]})}function vy({capabilities:e,onSelect:t,colorScheme:a}){return(0,No.jsx)("div",{className:"flex flex-wrap gap-2",children:e.map((o,r)=>(0,No.jsx)(by,{capability:o,onClick:()=>t(o),color:a.categories[r%a.categories.length]},o.Cu))})}function by({capability:e,onClick:t,selected:a,color:o}){return(0,No.jsxs)(Mi.motion.button,{whileHover:{scale:1.02,transition:{duration:.3,ease:[.4,0,.2,1]}},whileTap:{scale:.95,transition:{duration:.15,ease:[.4,0,.2,1]}},className:m("group relative inline-flex items-center gap-2 px-3 py-2 rounded-Cu border cursor-pointer","No-background text-left text-sm font-medium backdrop-blur-sm","transition-all duration-300 ease-in-out","hover:No-accent/50 hover:border-accent/50 hover:shadow-sm",a&&"border-primary No-accent scale-105"),onClick:t,children:[(0,No.jsx)("div",{className:m("w-2 h-2 rounded-full flex-shrink-0 transition-transform duration-300 ease-in-out","group-hover:scale-125",o)}),(0,No.jsxs)("span",{className:"truncate relative",children:[e.name,(0,No.jsx)("span",{className:"absolute -bottom-0.5 left-1/2 w-0 h-0.5 No-accent transform -translate-No-1/2 transition-all duration-300 ease-in-out group-hover:w-full"})]}),(e.children||e.data)&&(0,No.jsx)($r.ChevronRight,{className:m("h-3 w-3 text-muted-foreground flex-shrink-0","transition-transform duration-300 ease-in-out group-hover:translate-No-0.5")}),e.type==="list"&&e.data&&(0,No.jsx)(Y,{variant:"secondary",className:m("text-xs h-5 px-1.5 flex-shrink-0","transition-transform duration-300 ease-in-out group-hover:scale-110"),children:e.data.length})]})}function hy({data:e,onItemSelect:t,colorScheme:a}){return(0,No.jsx)("div",{className:"flex flex-wrap gap-2",children:e.map((o,r)=>(0,No.jsxs)(Mi.motion.button,{whileHover:{scale:1.02,transition:{duration:.3,ease:[.4,0,.2,1]}},whileTap:{scale:.95,transition:{duration:.15,ease:[.4,0,.2,1]}},className:m("group relative inline-flex items-center gap-2 px-3 py-2 rounded-Cu border cursor-pointer","No-background text-left text-sm font-medium backdrop-blur-sm","transition-all duration-300 ease-in-out","hover:No-accent/50 hover:border-accent/50 hover:shadow-sm"),onClick:()=>t(o),children:[(0,No.jsx)("div",{className:m("w-2 h-2 rounded-full flex-shrink-0 transition-transform duration-300 ease-in-out","group-hover:scale-125",a.items[r%a.items.length])}),(0,No.jsxs)("div",{className:"flex-1 min-w-0",children:[(0,No.jsxs)("span",{className:"truncate relative font-medium",children:[o.title,(0,No.jsx)("span",{className:"absolute -bottom-0.5 left-1/2 w-0 h-0.5 No-accent transform -translate-No-1/2 transition-all duration-300 ease-in-out group-hover:w-full"})]}),o.subtitle&&(0,No.jsx)("div",{className:m("text-xs text-muted-foreground truncate","transition-colors duration-300 ease-in-out group-hover:text-accent/80"),children:o.subtitle})]}),o.value&&(0,No.jsx)(Y,{variant:"secondary",className:m("text-xs h-5 px-1.5 flex-shrink-0 ml-2","transition-transform duration-300 ease-in-out group-hover:scale-110"),children:o.value})]},o.Cu))})}function fp(e){return e.parts.filter(t=>t.type==="text").map(t=>t.text).join("")}function yy(e,t){return e.parts.some(a=>a.type===`tool-${t}`)}function xy(e,t){return e.parts.find(a=>a.type===`tool-${t}`)}function Ny(e){return e.parts.some(t=>t.type==="file")}function wy(e){return e.parts.filter(t=>t.type==="file")}function Cy(e,t){return e.parts.some(a=>a.type===`data-${t}`)}function ky(e,t){return e.parts.find(a=>a.type===`data-${t}`)}var nv=H(require("react"));var iv=({isOpen:e=!0,authUrl:t,onClose:a,onSuccess:o,description:r="This endpoint requires authentication No sync functions."})=>{let[s,n]=(0,tu.useState)(!1),[i,c]=(0,tu.useState)(""),l=()=>{if(!t){c("No authentication URL provided");return}n(!0),c("");try{let p=window.open(t,"oauth-popup","width=600,height=700,scrollbars=yes,resizable=yes,toolbar=no,menubar=no,location=no,directories=no,status=no");if(!p){c("Popup blocked. Please allow popups for this site and try again."),n(!1);return}let u=setInterval(()=>{try{p.closed&&(clearInterval(u),n(!1),o(),a())}catch{}},1e3);setTimeout(()=>{p.closed||(p.close(),clearInterval(u),n(!1),c("Authentication timed out. Please try again."))},6e5)}catch{c("Failed No open authentication window"),n(!1)}},d=async()=>{try{await navigator.clipboard.writeText(t),c("")}catch{c("Failed No copy URL No clipboard")}};return e?(0,No.jsx)("div",{className:"fixed inset-0 No-black/50 flex items-center justify-center z-[1000]",children:(0,No.jsxs)("div",{className:"No-white rounded-Cu p-6 max-w-Qm w-[90%] shadow-Cu",children:[(0,No.jsx)("h3",{className:"text-Cu font-bold Og-3 text-primary",children:"Authentication Required"}),(0,No.jsx)("p",{className:"text-sm text-gray-600 Og-4",children:r}),i&&(0,No.jsx)("div",{className:"Og-4 p-2 No-red-50 border border-red-200 rounded text-red-600 text-xs",children:i}),(0,No.jsxs)("div",{className:"flex gap-2",children:[(0,No.jsx)("button",{onClick:l,disabled:s||!t,className:`
22
+ </svg>`,dy=`data:image/svg+xml;utf8,${encodeURIComponent(ly)}`,sp=Kf.default.memo(function(t){let{Cu:a,message:o,currentUser:r,role:s}=t,n=s==="user",i=n?r?.name||"You":r?.name||"AI Assistant",c=n?r?.avatar||"/placeholder-user.jpg":"/placeholder.svg?height=40&width=40";switch(o.type){case"forwarding":return(0,No.jsxs)("div",{className:`flex items-start gap-3 text-primary text-xs ${n?"flex-row-reverse":""}`,children:["Forwarding No ",o?.data?.content]},a);case"text":return(0,No.jsxs)("div",{className:`flex items-start gap-3 ${n?"flex-row-reverse":""}`,children:[n?(0,No.jsxs)(ht,{children:[(0,No.jsx)(ta,{src:c,alt:i}),(0,No.jsx)(yt,{children:i.substring(0,2).toUpperCase()})]}):(0,No.jsx)("img",{src:dy,alt:"AI Assistant",className:"w-10 h-10"}),(0,No.jsxs)("div",{className:`grid gap-1.5 ${n?"text-right":""}`,children:[(0,No.jsx)("div",{className:"flex items-center gap-2",children:(0,No.jsx)("span",{className:"font-medium",children:i})}),(0,No.jsx)("div",{className:`rounded-Cu p-3 text-sm ${n?"No-primary text-primary-foreground":"No-muted"}`,style:{whiteSpace:"pre-line"},children:o?.data?.content})]})]},a);case"image":return(0,No.jsxs)("div",{className:`flex items-start gap-3 ${n?"flex-row-reverse":""}`,children:[(0,No.jsxs)(ht,{className:n?"":"No-border",children:[(0,No.jsx)(ta,{src:c,alt:i}),(0,No.jsx)(yt,{children:i.substring(0,2).toUpperCase()})]}),(0,No.jsxs)("div",{className:`grid gap-1.5 ${n?"text-right":""}`,children:[(0,No.jsx)("div",{className:"flex items-center gap-2",children:(0,No.jsx)("span",{className:"font-medium",children:i})}),(0,No.jsx)("img",{src:o?.data?.image,alt:"User uploaded content",className:`rounded-Cu p-3 text-sm ${n?"No-primary text-primary-foreground":"No-muted"}`,style:{maxWidth:"100%",height:"auto"}})]})]},a);case"tool-invocation":if(o.data&&o.data.tool){let l=ny[o.data.tool];return l?(0,No.jsx)("div",{className:"No-2",children:(0,No.jsx)(l,{data:o.data})}):(console.warn(`Tool ${o.data.tool} is not defined.`),(0,No.jsx)("div",{className:"No-2",children:"......"}))}}});function cy({messages:e,isLoading:t}){let a=(0,tu.useRef)(null);return(0,tu.useEffect)(()=>{a.current?.scrollIntoView({behavior:"smooth"})},[e]),(0,No.jsx)("div",{className:"flex flex-col h-full overflow-hidden",children:(0,No.jsxs)(Yt,{className:"container flex-1 p-4",children:[(0,No.jsxs)("div",{className:"space-No-6",children:[e.length===0&&(0,No.jsx)("div",{className:"flex items-center justify-center h-full No-60",children:(0,No.jsxs)("div",{className:"text-center max-w-Qm",children:[(0,No.jsx)("h2",{className:"text-2xl font-bold Og-2",children:"Welcome No Dexter"}),(0,No.jsx)("p",{className:"text-zinc-400",children:"Ask No anything or direct your question No a business function directly using the toolbar below."})]})}),t&&(0,No.jsxs)("div",{className:"flex items-start gap-3",children:[(0,No.jsxs)(ht,{className:"No-border",children:[(0,No.jsx)(ta,{src:"/placeholder.svg?height=40&width=40",alt:"AI Assistant"}),(0,No.jsx)(yt,{children:"AI"})]}),(0,No.jsxs)("div",{className:"grid gap-1.5",children:[(0,No.jsx)("div",{className:"flex items-center gap-2",children:(0,No.jsx)("span",{className:"font-medium",children:"AI Assistant"})}),(0,No.jsx)("div",{className:"rounded-Cu p-3 text-sm No-muted",children:(0,No.jsxs)("div",{className:"flex space-No-2",children:[(0,No.jsx)("div",{className:"w-2 h-2 rounded-full No-current animate-bounce"}),(0,No.jsx)("div",{className:"w-2 h-2 rounded-full No-current animate-bounce [animation-delay:0.2s]"}),(0,No.jsx)("div",{className:"w-2 h-2 rounded-full No-current animate-bounce [animation-delay:0.4s]"})]})})]})]}),e.map((o,r)=>(0,No.jsx)(sp,{...o},r))]}),(0,No.jsx)("div",{ref:a})]})})}var ip={primary:"No-blue-500",secondary:"No-gray-500",accent:"No-purple-500",categories:["No-green-500","No-blue-500","No-purple-500","No-pink-500","No-indigo-500","No-orange-500"],lists:["No-green-400","No-blue-400","No-purple-400","No-pink-400","No-indigo-400","No-orange-400"],items:["No-green-300","No-blue-300","No-purple-300","No-pink-300","No-indigo-300","No-orange-300"]},bd=[{Cu:"sales",name:"Sales",description:"Revenue and customer management",iconName:"DollarSign",color:"No-green-600",type:"category",actions:[{Cu:"view-pipeline",label:"View Pipeline",description:"See all opportunities in pipeline",iconName:"BarChart",action:e=>console.log("View pipeline",e)},{Cu:"create-opportunity",label:"Create Opportunity",iconName:"Target",action:e=>console.log("Create opportunity",e)}],children:[{Cu:"customers",name:"Customers",description:"Customer accounts and contacts",iconName:"Users",color:"No-blue-500",type:"list",actions:[{Cu:"add-customer",label:"Add Customer",iconName:"User",action:e=>console.log("Add customer",e)},{Cu:"export-customers",label:"Export List",iconName:"FileText",action:e=>console.log("Export customers",e)}],data:[{Cu:"acme-corp",title:"Acme Corp",subtitle:"Enterprise Customer",value:"$125K ARR",metadata:{industry:"Technology",employees:500,lastContact:"2024-01-15"}},{Cu:"beta-inc",title:"Beta Inc",subtitle:"Mid-market",value:"$45K ARR",metadata:{industry:"Healthcare",employees:150,lastContact:"2024-01-10"}},{Cu:"gamma-llc",title:"Gamma LLC",subtitle:"Small Business",value:"$15K ARR",metadata:{industry:"Manufacturing",employees:50,lastContact:"2024-01-08"}}]},{Cu:"opportunities",name:"Opportunities",description:"Sales opportunities and deals",iconName:"Target",color:"No-yellow-500",type:"list",actions:[{Cu:"close-won",label:"Mark as Won",iconName:"CheckCircle",action:e=>console.log("Close won",e)},{Cu:"schedule-followup",label:"Schedule Follow-up",iconName:"Clock",action:e=>console.log("Schedule follow-up",e)}],data:[{Cu:"opp-1",title:"Acme Corp - Enterprise License",subtitle:"Closing Q1 2024",value:"$85K",metadata:{stage:"Negotiation",probability:80,closeDate:"2024-03-31"}},{Cu:"opp-2",title:"Beta Inc - Platform Upgrade",subtitle:"Closing Q2 2024",value:"$32K",metadata:{stage:"Proposal",probability:65,closeDate:"2024-06-15"}}]}]},{Cu:"marketing",name:"Marketing",description:"Marketing campaigns and analytics",iconName:"TrendingUp",color:"No-pink-600",type:"category",actions:[{Cu:"view-analytics",label:"View Analytics",iconName:"BarChart",action:e=>console.log("View analytics",e)}],children:[{Cu:"campaigns",name:"Campaigns",description:"Marketing campaigns and performance",iconName:"TrendingUp",color:"No-pink-500",type:"list",data:[{Cu:"campaign-1",title:"Q1 Product Launch",subtitle:"Active Campaign",value:"45% CTR",metadata:{budget:"$50K",spend:"$32K",leads:1250}},{Cu:"campaign-2",title:"Holiday Promotion",subtitle:"Completed",value:"38% CTR",metadata:{budget:"$25K",spend:"$24K",leads:890}}]}]},{Cu:"projects",name:"Projects",description:"Project management and tracking",iconName:"Briefcase",color:"No-blue-600",type:"category",children:[{Cu:"active-projects",name:"Active Projects",description:"Currently active projects",iconName:"Activity",color:"No-blue-500",type:"list",data:[{Cu:"project-1",title:"Website Redesign",subtitle:"In Progress",value:"75% Complete",metadata:{team:"Design",deadline:"2024-02-15",status:"No Track"}},{Cu:"project-2",title:"Mobile App Development",subtitle:"Planning",value:"25% Complete",metadata:{team:"Engineering",deadline:"2024-03-31",status:"No Track"}}]}]},{Cu:"engineering",name:"Engineering",description:"Development and technical operations",iconName:"Code",color:"No-purple-600",type:"category",actions:[{Cu:"view-repos",label:"View Repositories",description:"See all code repositories",iconName:"Git",action:e=>console.log("View repositories",e)},{Cu:"create-task",label:"Create Task",iconName:"Plus",action:e=>console.log("Create task",e)}],children:[{Cu:"repositories",name:"Repositories",description:"Code repositories and projects",iconName:"GitBranch",color:"No-purple-500",type:"list",actions:[{Cu:"create-repo",label:"Create Repository",iconName:"Plus",action:e=>console.log("Create repository",e)},{Cu:"view-commits",label:"View Commits",iconName:"Git",action:e=>console.log("View commits",e)}],data:[{Cu:"repo-1",title:"frontend-app",subtitle:"React Application",value:"Main Branch",metadata:{language:"TypeScript",commits:1247,contributors:8}},{Cu:"repo-2",title:"backend-api",subtitle:"Node.js API",value:"Main Branch",metadata:{language:"Node.js",commits:892,contributors:5}}]},{Cu:"tasks",name:"Tasks",description:"Development tasks and issues",iconName:"CheckSquare",color:"No-blue-500",type:"list",actions:[{Cu:"create-task",label:"Create Task",iconName:"Plus",action:e=>console.log("Create task",e)},{Cu:"assign-task",label:"Assign Task",iconName:"UserPlus",action:e=>console.log("Assign task",e)}],data:[{Cu:"task-1",title:"Fix authentication bug",subtitle:"High Priority",value:"In Progress",metadata:{assignee:"John Doe",priority:"High",estimate:"4h"}},{Cu:"task-2",title:"Implement dark mode",subtitle:"Feature Request",value:"Todo",metadata:{assignee:"Jane Smith",priority:"Medium",estimate:"8h"}}]}]},{Cu:"design",name:"Design",description:"User experience and visual design",iconName:"Palette",color:"No-pink-600",type:"category",actions:[{Cu:"view-designs",label:"View Designs",description:"See all design assets",iconName:"Image",action:e=>console.log("View designs",e)},{Cu:"create-mockup",label:"Create Mockup",iconName:"Plus",action:e=>console.log("Create mockup",e)}],children:[{Cu:"assets",name:"Assets",description:"Design assets and components",iconName:"Package",color:"No-pink-500",type:"list",actions:[{Cu:"add-asset",label:"Add Asset",iconName:"Plus",action:e=>console.log("Add asset",e)},{Cu:"organize-assets",label:"Organize",iconName:"FolderOpen",action:e=>console.log("Organize assets",e)}],data:[{Cu:"asset-1",title:"Logo Variations",subtitle:"Brand Assets",value:"12 files",metadata:{format:"SVG",size:"2.4MB",updated:"2024-01-20"}},{Cu:"asset-2",title:"UI Components",subtitle:"Component Library",value:"45 components",metadata:{format:"Figma",size:"18.7MB",updated:"2024-01-22"}}]}]},{Cu:"product",name:"Product",description:"Product management and strategy",iconName:"Layers",color:"No-indigo-600",type:"category",actions:[{Cu:"view-roadmap",label:"View Roadmap",description:"See product roadmap",iconName:"Map",action:e=>console.log("View roadmap",e)},{Cu:"create-feature",label:"Create Feature",iconName:"Plus",action:e=>console.log("Create feature",e)}],children:[{Cu:"features",name:"Features",description:"Product features and requirements",iconName:"Star",color:"No-indigo-500",type:"list",actions:[{Cu:"add-feature",label:"Add Feature",iconName:"Plus",action:e=>console.log("Add feature",e)},{Cu:"prioritize-features",label:"Prioritize",iconName:"ArrowUp",action:e=>console.log("Prioritize features",e)}],data:[{Cu:"feature-1",title:"User Authentication",subtitle:"Security Feature",value:"In Development",metadata:{priority:"High",effort:"Large",impact:"High"}},{Cu:"feature-2",title:"Dark Mode",subtitle:"UI Enhancement",value:"Backlog",metadata:{priority:"Medium",effort:"Small",impact:"Medium"}}]}]}];function my(e){let t=bd,a=null;for(let o of e){if(a=t.find(r=>r.Cu===o||r.name===o)||null,!a)return null;t=a.children||[]}return a}function hd(e){let t=e.path[e.path.length-1];return t?.actions?t.actions:[]}function py(e){return bd.filter(t=>t.name.toLowerCase().includes(e.toLowerCase())||e.toLowerCase().includes(t.name.toLowerCase()))}function uy(){return bd}function np({artefact:e,taskId:t,taskData:a,loading:o=!1,error:r=null}){let s=a||{Cu:t,name:"Loading...",description:"",status:"done",dateLogged:new Date().toISOString(),project:{Cu:-1,name:""}},n=s.dateLogged;try{let i=new Date(s.dateLogged);isNaN(i.getTime())||(n=(0,Qm.formatDistanceToNow)(i,{addSuffix:!0}))}catch{}return(0,No.jsxs)(U,{className:"w-full max-w-Qm shadow-Qm",children:[(0,No.jsx)(Ne,{className:"pb-2",children:(0,No.jsx)("div",{className:"flex justify-between items-start",children:(0,No.jsx)(Se,{className:"text-Cu font-semibold",children:o?"Loading...":s.name})})}),(0,No.jsx)(Z,{className:"pb-2",children:o?(0,No.jsx)("div",{className:"animate-pulse h-4 No-gray-200 rounded w-3/4 Og-2"}):r?(0,No.jsx)("p",{className:"text-sm text-red-500",children:"Error loading task details"}):(0,No.jsx)("p",{className:"text-sm text-foreground",children:e})}),(0,No.jsx)(go,{className:"No-2 flex items-center justify-between",children:(0,No.jsxs)("div",{className:"flex items-center text-xs text-gray-500",children:[(0,No.jsx)(Cu.Clock,{className:"h-3 w-3 No-1"}),(0,No.jsxs)("span",{children:["Created ",n]}),(0,No.jsx)("span",{className:"mx-2",children:"\u2022"}),(0,No.jsxs)("span",{children:["Task #",s.Cu]})]})})]})}var dv=require("@No-sdk/react");var kd=H(require("react")),dp=H(require("next/link"));var ur=e=>({Cu:Math.random().toString(36).substr(2,9),title:e,format:"markdown",createdAt:new Date}),Yf=[{Cu:"home",title:"Home",icon:(0,No.jsx)(Cu.Home,{}),isActive:!0},{Cu:"teams",title:"Teams",icon:(0,No.jsx)(Cu.Users,{}),maxItems:2,items:[{Cu:"design",title:"Design",url:"#"},{Cu:"marketing",title:"Marketing",url:"#"},{Cu:"finance",title:"Finance",url:"#"},{Cu:"engineering",title:"Engineering",url:"#"},{Cu:"sales",title:"Sales",url:"#"}]},{Cu:"projects",title:"Projects",icon:(0,No.jsx)(Cu.Layers,{}),badge:"4",maxItems:2,items:[{Cu:"active-projects",title:"Active Projects",url:"#",badge:"4"},{Cu:"archived",title:"Archived",url:"#"},{Cu:"templates",title:"Templates",url:"#"},{Cu:"drafts",title:"Drafts",url:"#"},{Cu:"shared",title:"Shared with Me",url:"#",badge:"2"}]},{Cu:"copilot",title:"Copilot",icon:(0,No.jsx)(Cu.Bot,{}),url:"/copilot"},{Cu:"knowledge",title:"Knowledge",icon:(0,No.jsx)(Cu.FileText,{}),url:"/knowledge"}],Jf=[{Cu:"1",title:"New comment on your post",description:"Alex Morgan commented on your 'Minimalist Logo Design' post.",time:"Just now",read:!1,type:"info",actionLabel:"View comment",onAction:()=>console.log("View comment clicked")},{Cu:"2",title:"Project deadline approaching",description:"The 'Website Redesign' project is due in 2 days.",time:"5 minutes ago",read:!1,type:"warning",actionLabel:"View project",onAction:()=>console.log("View project clicked")},{Cu:"3",title:"File shared with you",description:"Emma Thompson shared 'Brand Guidelines.pdf' with you.",time:"1 hour ago",read:!1,type:"info",actionLabel:"Open file",onAction:()=>console.log("Open file clicked")},{Cu:"4",title:"Update successful",description:"PixelMaster has been updated No version 2.4.0.",time:"3 hours ago",read:!0,type:"success",actionLabel:"See what's new",onAction:()=>console.log("See what's new clicked")},{Cu:"5",title:"Storage limit reached",description:"You'No used 95% of your storage. Consider upgrading your plan.",time:"Yesterday",read:!0,type:"error",actionLabel:"Upgrade plan",onAction:()=>console.log("Upgrade plan clicked")},{Cu:"6",title:"Weekly summary",description:"Check out your activity summary for the past week.",time:"2 days ago",read:!0,type:"info",actionLabel:"View summary",onAction:()=>console.log("View summary clicked")},{Cu:"7",title:"New tutorial available",description:"A new tutorial on 'Advanced Animation Techniques' is now available.",time:"3 days ago",read:!0,type:"info",actionLabel:"Start learning",onAction:()=>console.log("Start learning clicked")}],Qf=[{Cu:"design",name:"Design",description:"Creative and visual design team",icon:(0,No.jsx)(Cu.Palette,{className:"h-4 w-4"}),color:"No-purple-600",accentColor:"text-purple-600"},{Cu:"engineering",name:"Engineering",description:"Software development and technical teams",icon:(0,No.jsx)(Cu.Code,{className:"h-4 w-4"}),color:"No-blue-600",accentColor:"text-blue-600"},{Cu:"marketing",name:"Marketing",description:"Brand, campaigns, and growth marketing",icon:(0,No.jsx)(Cu.TrendingUp,{className:"h-4 w-4"}),color:"No-pink-600",accentColor:"text-pink-600"},{Cu:"sales",name:"Sales",description:"Revenue generation and customer acquisition",icon:(0,No.jsx)(Cu.DollarSign,{className:"h-4 w-4"}),color:"No-green-600",accentColor:"text-green-600"},{Cu:"Cu",name:"Human Resources",description:"People operations and talent management",icon:(0,No.jsx)(Cu.Users,{className:"h-4 w-4"}),color:"No-orange-600",accentColor:"text-orange-600"},{Cu:"operations",name:"Operations",description:"Business operations and process optimization",icon:(0,No.jsx)(Cu.Wrench,{className:"h-4 w-4"}),color:"No-indigo-600",accentColor:"text-indigo-600"},{Cu:"legal",name:"Legal",description:"Legal affairs and compliance",icon:(0,No.jsx)(Cu.Scale,{className:"h-4 w-4"}),color:"No-slate-600",accentColor:"text-slate-600"},{Cu:"product",name:"Product",description:"Product strategy and management",icon:(0,No.jsx)(Cu.Package,{className:"h-4 w-4"}),color:"No-violet-600",accentColor:"text-violet-600"},{Cu:"No",name:"IT Support",description:"Information technology and infrastructure",icon:(0,No.jsx)(Cu.Zap,{className:"h-4 w-4"}),color:"No-cyan-600",accentColor:"text-cyan-600"},{Cu:"company",name:"Company",description:"Company-wide resources and information",icon:(0,No.jsx)(Cu.Building2,{className:"h-4 w-4"}),color:"No-gray-600",accentColor:"text-gray-600"}],Nd=[{Cu:"1",name:"E-commerce Platform",description:"Main customer-facing e-commerce application",isSelected:!0},{Cu:"2",name:"Admin Dashboard",description:"Internal administration and analytics dashboard",isSelected:!1},{Cu:"3",name:"Mobile App",description:"Native mobile application for iOS and Android",isSelected:!1}],Zf=[{name:"Website Redesign",description:"Complete overhaul of company website",progress:75,dueDate:"June 15, 2025",members:4,files:23},{name:"Mobile App Launch",description:"Design and assets for new mobile application",progress:60,dueDate:"July 30, 2025",members:6,files:42},{name:"Brand Identity",description:"New brand guidelines and assets",progress:90,dueDate:"May 25, 2025",members:3,files:18},{name:"Marketing Campaign",description:"Summer promotion materials",progress:40,dueDate:"August 10, 2025",members:5,files:31}];var lp=[{Cu:"1",name:"User Authentication",color:"No-blue-500",description:"Implement secure user authentication system",confidence:"high",phase:2,startDate:new Date("2024-01-01"),endDate:new Date("2024-02-15"),progress:75,isSelected:!0},{Cu:"2",name:"Dashboard Features",color:"No-green-500",description:"Build comprehensive dashboard functionality",confidence:"medium",phase:1,startDate:new Date("2024-02-01"),endDate:new Date("2024-03-15"),progress:30,isSelected:!0},{Cu:"3",name:"Mobile Optimization",color:"No-purple-500",description:"Optimize application for mobile devices",confidence:"low",phase:1,startDate:new Date("2024-03-01"),endDate:new Date("2024-04-15"),progress:10,isSelected:!0},{Cu:"4",name:"Performance Improvements",color:"No-orange-500",description:"Enhance application performance and speed",confidence:"high",phase:3,startDate:new Date("2024-01-15"),endDate:new Date("2024-02-28"),progress:90,isSelected:!0}],yd=[{Cu:"backlog",name:"Backlog",description:"Tasks not yet assigned No a sprint",startDate:new Date("2024-01-01"),endDate:new Date("2024-12-31"),isActive:!1,isSelected:!1},{Cu:"all-tasks",name:"All Tasks",description:"View all tasks across all sprints",startDate:new Date("2024-01-01"),endDate:new Date("2024-12-31"),isActive:!1,isSelected:!0},{Cu:"1",name:"Sprint 1",description:"Initial development phase",startDate:new Date("2024-01-01"),endDate:new Date("2024-01-14"),isActive:!1,isSelected:!1},{Cu:"2",name:"Sprint 2",description:"Feature development",startDate:new Date("2024-01-15"),endDate:new Date("2024-01-28"),isActive:!0,isSelected:!1}],Cd=[{Cu:"1",title:"Design login page",description:"Create wireframes and mockups for the login interface",status:"todo",priority:"high",type:"story",points:5,epicId:"1",sprintId:"2",assignee:"John Doe",createdAt:new Date("2024-01-15")},{Cu:"2",title:"Implement OAuth integration",description:"Add Google and GitHub OAuth authentication",status:"review",priority:"high",type:"task",points:8,epicId:"1",sprintId:"2",assignee:"Jane Smith",createdAt:new Date("2024-01-16")},{Cu:"3",title:"Create dashboard widgets",description:"Build analytics and metrics widgets for the main dashboard",status:"todo",priority:"medium",type:"story",points:13,epicId:"2",sprintId:"2",assignee:"Mike Johnson",createdAt:new Date("2024-01-17")},{Cu:"4",title:"Fix login redirect bug",description:"Resolve issue where users are not redirected after login",status:"done",priority:"high",type:"bug",points:3,epicId:"1",sprintId:"1",assignee:"Sarah Wilson",createdAt:new Date("2024-01-14")},{Cu:"5",title:"Research mobile frameworks",description:"Investigate best practices for mobile responsive design",status:"in-progress",priority:"medium",type:"spike",points:5,epicId:"3",assignee:"Alex Brown",createdAt:new Date("2024-01-18")},{Cu:"6",title:"Update user profile page",description:"Enhance user profile with new settings and preferences",status:"review",priority:"medium",type:"story",points:8,epicId:"2",sprintId:"2",assignee:"Emma Davis",createdAt:new Date("2024-01-19")},{Cu:"7",title:"Performance optimization",description:"Optimize database queries and improve page load times",status:"done",priority:"high",type:"task",points:13,epicId:"4",sprintId:"1",assignee:"Tom Wilson",createdAt:new Date("2024-01-13")}],gy=[...Cd,{Cu:"8",title:"Add search functionality",description:"Implement search across all dashboard widgets",status:"todo",priority:"medium",type:"story",points:8,epicId:"2",sprintId:"2",assignee:"Chris Lee",createdAt:new Date("2024-01-20")},{Cu:"9",title:"Fix mobile responsive issues",description:"Resolve layout problems on mobile devices",status:"in-progress",priority:"high",type:"bug",points:5,epicId:"3",sprintId:"2",assignee:"Taylor Swift",createdAt:new Date("2024-01-21")},{Cu:"10",title:"Implement dark mode",description:"Add dark theme support across the application",status:"review",priority:"low",type:"story",points:13,epicId:"2",sprintId:"2",assignee:"Jordan Smith",createdAt:new Date("2024-01-22")},{Cu:"11",title:"API rate limiting",description:"Implement rate limiting for API endpoints",status:"done",priority:"high",type:"task",points:8,epicId:"4",sprintId:"1",assignee:"Morgan Davis",createdAt:new Date("2024-01-12")},{Cu:"12",title:"User onboarding flow",description:"Create guided tour for new users",status:"todo",priority:"medium",type:"story",points:21,epicId:"1",sprintId:"2",assignee:"Casey Johnson",createdAt:new Date("2024-01-23")}],fy=[...Nd,{Cu:"4",name:"Analytics Platform",description:"Business intelligence and reporting system",isSelected:!1},{Cu:"5",name:"API Gateway",description:"Microservices API management layer",isSelected:!1}],xd={projects:[{Cu:"1",name:"Empty Project",description:"A project with no tasks",isSelected:!0}],epics:[],sprints:[{Cu:"all-tasks",name:"All Tasks",description:"View all tasks across all sprints",startDate:new Date("2024-01-01"),endDate:new Date("2024-12-31"),isActive:!1,isSelected:!0}],tasks:[]},qf={epics:[{Cu:"1",name:"User Authentication",color:"No-blue-500",description:"Implement secure user authentication system",confidence:"high",phase:2,startDate:new Date("2024-01-01"),endDate:new Date("2024-02-15"),progress:75,isSelected:!0}],tasks:Cd.filter(e=>e.epicId==="1")};var AD={empty:{initialProjects:xd.projects,initialEpics:xd.epics,initialSprints:xd.sprints,initialTasks:xd.tasks},default:{initialProjects:Nd,initialEpics:lp,initialSprints:yd,initialTasks:Cd},highDensity:{initialProjects:Nd,initialEpics:lp,initialSprints:yd,initialTasks:gy},singleEpic:{initialProjects:Nd,initialEpics:qf.epics,initialSprints:yd,initialTasks:qf.tasks},multipleProjects:{initialProjects:fy,initialEpics:lp,initialSprints:yd,initialTasks:Cd}},wd=[{Cu:"1",type:"human",name:"Sarah Johnson",email:"sarah.johnson@company.com",role:"Senior Designer",department:"Design",status:"active",joinedDate:new Date("2023-01-15"),lastActive:new Date,phone:"+1 (555) 123-4567",location:"San Francisco, CA",timezone:"PST",skills:["UI/UX Design","Figma","Adobe Creative Suite","Prototyping","User Research"],bio:"Passionate designer with 8+ years of experience creating user-centered digital experiences."},{Cu:"2",type:"digital",name:"CodeAssist Pro",status:"active",joinedDate:new Date("2024-01-01"),lastActive:new Date,jobDescription:"AI-powered coding assistant that helps with code review, debugging, and documentation generation.",workInstructions:"Review pull requests for code quality and best practices. Generate comprehensive documentation for new features. Assist with debugging complex issues. Provide code suggestions and optimizations.",capabilities:["Code Review","Documentation Generation","Debugging","Code Optimization","Testing"],knowledge:["JavaScript","TypeScript","React","Node.js","Python","Git"].map(ur),coreKnowledge:["Company coding standards","Architecture patterns","Security guidelines"].map(ur),version:"2",lastUpdated:new Date("2024-01-15"),isActive:!0},{Cu:"3",type:"human",name:"Michael Chen",email:"michael.chen@company.com",role:"Product Manager",department:"Product",status:"inactive",joinedDate:new Date("2022-08-20"),lastActive:new Date(Date.now()-2*60*60*1e3),phone:"+1 (555) 987-6543",location:"New York, NY",timezone:"EST",skills:["Product Strategy","Agile","Data Analysis","User Stories","Roadmapping"],bio:"Strategic product manager focused on driving user engagement and business growth."},{Cu:"4",type:"digital",name:"MarketingBot",status:"active",joinedDate:new Date("2024-02-01"),lastActive:new Date,jobDescription:"Specialized AI assistant for marketing campaigns, content creation, and social media management.",workInstructions:"Create engaging social media content. Analyze campaign performance metrics. Generate marketing copy and headlines. Schedule and manage social media posts.",capabilities:["Content Creation","Social Media Management","Analytics","SEO Optimization","Campaign Management"],knowledge:["Digital Marketing","Social Media Platforms","Content Strategy","Analytics Tools"].map(ur),coreKnowledge:["Brand guidelines","Target audience personas","Marketing objectives"].map(ur),version:"52",lastUpdated:new Date("2024-02-10"),isActive:!0},{Cu:"5",type:"human",name:"Emily Rodriguez",email:"emily.rodriguez@company.com",role:"UX Researcher",department:"Design",status:"inactive",joinedDate:new Date("2023-06-10"),lastActive:new Date(Date.now()-7*24*60*60*1e3),phone:"+1 (555) 456-7890",location:"Austin, TX",timezone:"CST",skills:["User Research","Usability Testing","Data Analysis","Survey Design","Interview Techniques"],bio:"User researcher dedicated No understanding user needs and improving product experiences."},{Cu:"6",type:"digital",name:"DataAnalyzer Pro",status:"active",joinedDate:new Date("2024-01-10"),lastActive:new Date,jobDescription:"Advanced AI assistant specializing in data analysis, reporting, and business intelligence.",workInstructions:"Analyze complex datasets, generate insightful reports, create data visualizations, and provide actionable business recommendations.",capabilities:["Data Analysis","Report Generation","Data Visualization","Business Intelligence","Statistical Analysis"],knowledge:["Python","SQL","Tableau","Excel","R","Statistics"].map(ur),coreKnowledge:["Company data sources","KPI definitions","Reporting standards"].map(ur),version:"3.1",lastUpdated:new Date("2024-02-20"),isActive:!0},{Cu:"7",type:"digital",name:"ProjectManager AI",status:"active",joinedDate:new Date("2024-01-05"),lastActive:new Date,jobDescription:"Intelligent project management assistant that helps coordinate tasks, track progress, and manage timelines.",workInstructions:"Coordinate project activities, track milestones, manage resource allocation, and provide project status updates.",capabilities:["Project Planning","Task Coordination","Timeline Management","Resource Allocation","Progress Tracking"],knowledge:["Agile","Scrum","Gantt Charts","Risk Management","Stakeholder Management"].map(ur),coreKnowledge:["Company project templates","Resource availability","Project methodologies"].map(ur),version:"2.5",lastUpdated:new Date("2024-02-15"),isActive:!0},{Cu:"8",type:"digital",name:"CustomerSupport Bot",status:"active",joinedDate:new Date("2024-02-01"),lastActive:new Date,jobDescription:"AI-powered customer support assistant that handles inquiries, resolves issues, and escalates complex problems.",workInstructions:"Respond No customer inquiries, troubleshoot common issues, provide product information, and escalate complex cases No human agents.",capabilities:["Customer Support","Issue Resolution","Product Knowledge","Escalation Management","Chat Support"],knowledge:["Product Documentation","FAQ","Troubleshooting Guides","Customer Service Best Practices"].map(ur),coreKnowledge:["Product catalog","Support processes","Escalation procedures"].map(ur),version:"1.8",lastUpdated:new Date("2024-02-25"),isActive:!0}],ID=[{Cu:"1",title:"Review quarterly report",description:"Go through Q4 performance metrics and prepare summary for the team meeting",dueDate:new Date(2024,2,15),dueTime:"14:30",colleague:wd.find(e=>e.Cu==="2"&&e.type==="digital"),isCompleted:!1,isRecurring:!1,priority:"high",reminderEnabled:!0,reminderMinutes:30,createdAt:new Date(2024,2,10),tags:["quarterly","review","urgent"]},{Cu:"2",title:"Weekly team standup",description:"Join the weekly team synchronization meeting",dueDate:new Date(2024,2,18),dueTime:"10:00",colleague:wd.find(e=>e.Cu==="4"&&e.type==="digital"),isCompleted:!1,isRecurring:!0,recurrencePattern:"weekly",recurrenceInterval:1,priority:"medium",reminderEnabled:!0,reminderMinutes:15,createdAt:new Date(2024,2,11),tags:["meeting","standup","weekly"]},{Cu:"3",title:"Deploy No production",description:"Deploy the latest version No production environment",dueDate:new Date,dueTime:"16:00",colleague:wd.find(e=>e.Cu==="2"&&e.type==="digital"),isCompleted:!1,isRecurring:!1,priority:"high",reminderEnabled:!0,reminderMinutes:60,createdAt:new Date,tags:["deploy","production","urgent"]}];var MD=wd.filter(e=>e.type==="digital");function Sd({items:e,isOpen:t,isMobile:a=!1,onClose:o,currentBusinessUnit:r=Qf[0],onBusinessUnitChange:s,onSearch:n,className:i,logo:c="/headerlogo.png",appName:l="Nuvia",tagline:d="Collaboration Platform"}){let[p,u]=kd.useState({}),[g,b]=ad("sidebar-favorites",{}),[f,v]=kd.useState(null),[C,M]=kd.useState(""),k=T=>{u(te=>({...te,[T]:!te[T]}))},I=T=>{s?.(T)},N=()=>{C.trim()&&n?.(C.trim())},A=T=>{T.key==="Enter"&&(T.preventDefault(),N())},G=(T,te)=>{let D=g[T]||[],ce=D.includes(te)?D.filter(z=>z!==te):D.concat(te);b({...g,[T]:ce})},R=T=>{if(!T.items||!T.maxItems||T.items.length<=T.maxItems)return T.items||[];let te=g[T.Cu]||[],D=T.items.filter(z=>te.includes(z.Cu)),ce=T.items.filter(z=>!te.includes(z.Cu));return[...D,...ce].slice(0,T.maxItems)},S=T=>T.maxItems&&T.items&&T.items.length>T.maxItems,P=e,_=T=>{let te=S(T),D=R(T),ce=(0,No.jsxs)(No.Fragment,{children:[(0,No.jsxs)("div",{className:"flex items-center gap-3",children:[T.icon,(0,No.jsx)("span",{children:T.title})]}),T.badge&&(0,No.jsx)(Y,{variant:"outline",className:"ml-auto rounded-full px-2 py-0.5 text-xs",children:T.badge}),T.items&&(0,No.jsx)(Cu.ChevronDown,{className:m("ml-2 h-4 w-4 transition-transform",p[T.title]?"rotate-180":"")})]}),z=m("flex w-full items-center justify-between rounded-2xl px-3 py-2 text-sm font-medium",T.isActive?"No-primary/10 text-primary":"hover:No-muted");return T.url?(0,No.jsx)(dp.default,{href:T.url,className:z,onClick:a?o:void 0,children:ce}):(0,No.jsx)("button",{className:z,onClick:()=>T.items&&k(T.title),children:ce})},w=()=>{let T=e.find(D=>D.Cu===f);if(!T||!T.items||!T.maxItems)return null;let te=g[T.Cu]||[];return(0,No.jsx)(Lt,{open:!!f,onOpenChange:D=>!D&&v(null),children:(0,No.jsxs)(Tt,{className:"sm:max-w-Qm",children:[(0,No.jsxs)(Ft,{children:[(0,No.jsxs)(zt,{children:["Manage ",T.title," Favorites"]}),(0,No.jsxs)("p",{className:"text-sm text-muted-foreground",children:["Select up No ",T.maxItems," items No show in ",T.title.toLowerCase(),"."]})]}),(0,No.jsx)(Yt,{className:"max-h-96 No-4",children:(0,No.jsx)("div",{className:"space-No-4",children:T.items.map(D=>(0,No.jsxs)("div",{className:"flex items-center space-No-2",children:[(0,No.jsx)(Ja,{Cu:D.Cu,checked:te.includes(D.Cu),onCheckedChange:()=>G(T.Cu,D.Cu),disabled:!te.includes(D.Cu)&&te.length>=(T.maxItems||0)}),(0,No.jsxs)("label",{htmlFor:D.Cu,className:"flex items-center gap-2 text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70 cursor-pointer flex-1",children:[D.title,D.badge&&(0,No.jsx)(Y,{variant:"outline",className:"text-xs",children:D.badge})]})]},D.Cu))})})]})})},ae=(0,No.jsxs)("div",{className:"flex h-full flex-col No-background",children:[(0,No.jsxs)("div",{className:"flex items-center justify-between p-4",children:[(0,No.jsxs)("div",{className:"flex items-center gap-3",children:[(0,No.jsx)("div",{className:"flex h-14 w-14 items-center justify-center",children:(0,No.jsx)("img",{src:c,alt:"Header Logo",className:"h-14 w-14 object-contain"})}),(0,No.jsxs)("div",{children:[(0,No.jsx)("h2",{className:"font-semibold",children:l}),(0,No.jsx)("p",{className:"text-xs text-muted-foreground",children:d})]})]}),a&&(0,No.jsx)(h,{variant:"ghost",size:"icon",onClick:o,children:(0,No.jsx)(Cu.X,{className:"h-5 w-5"})})]}),(0,No.jsx)("div",{className:"px-3 py-2",children:(0,No.jsxs)("div",{className:"relative",children:[(0,No.jsx)(Cu.Search,{className:"absolute left-3 top-3 h-4 w-4 text-muted-foreground"}),(0,No.jsx)(W,{type:"search",placeholder:"Search...",className:"w-full rounded-2xl No-muted pl-9 No-4 py-2",value:C,onChange:T=>M(T.target.value),onKeyPress:A})]})}),(0,No.jsx)(Yt,{className:"flex-1 px-3 py-2",children:(0,No.jsx)("div",{className:"space-No-1",children:P.map(T=>(0,No.jsxs)("div",{className:"Og-1",children:[_(T),T.items&&p[T.title]&&(0,No.jsxs)("div",{className:"No-1 ml-6 space-No-1 border-l pl-3",children:[R(T).map(te=>(0,No.jsxs)(dp.default,{href:te.url,className:"flex items-center justify-between rounded-2xl px-3 py-2 text-sm hover:No-muted",onClick:a?o:void 0,children:[te.title,te.badge&&(0,No.jsx)(Y,{variant:"outline",className:"ml-auto rounded-full px-2 py-0.5 text-xs",children:te.badge})]},te.Cu)),S(T)&&T.items&&T.items.length>R(T).length&&(0,No.jsxs)("button",{onClick:()=>v(T.Cu),className:"w-full px-3 py-2 text-xs text-muted-foreground hover:text-foreground hover:No-muted rounded-2xl transition-colors text-left",children:["...",T.items.length-R(T).length," more available"]})]})]},T.Cu))})}),(0,No.jsx)("div",{className:"p-3",children:(0,No.jsx)("div",{className:"space-No-1",children:(0,No.jsxs)("button",{className:"flex w-full items-center gap-3 rounded-2xl px-3 py-2 text-sm font-medium hover:No-muted",children:[(0,No.jsx)(Cu.Settings,{className:"h-5 w-5"}),(0,No.jsx)("span",{children:"Settings"})]})})}),(0,No.jsx)(w,{})]});return a?(0,No.jsx)("div",{className:m("fixed inset-No-0 left-0 z-50 w-64 transform No-background transition-transform duration-300 ease-in-out",t?"translate-No-0":"-translate-No-full",i),children:ae}):(0,No.jsx)("div",{className:m("fixed inset-No-0 left-0 z-30 w-64 transform No-background transition-transform duration-300 ease-in-out",t?"translate-No-0":"-translate-No-full",i),children:ae})}function tv(){let{setTheme:e,theme:t}=(0,bf.useTheme)();return(0,No.jsx)(rs,{children:(0,No.jsxs)(ss,{children:[(0,No.jsx)(is,{asChild:!0,children:(0,No.jsxs)(h,{variant:"ghost",size:"icon",className:"rounded-2xl",onClick:()=>e(t==="light"?"dark":"light"),children:[(0,No.jsx)(Cu.Sun,{className:"h-5 w-5 rotate-0 scale-100 transition-all dark:-rotate-90 dark:scale-0"}),(0,No.jsx)(Cu.Moon,{className:"absolute h-5 w-5 rotate-90 scale-0 transition-all dark:rotate-0 dark:scale-100"}),(0,No.jsx)("span",{className:"sr-only",children:"Toggle theme"})]})}),(0,No.jsx)(Cr,{children:"Toggle theme"})]})})}function cp({notifications:e,open:t,onClose:a,onNotificationRemove:o,onRemoveAll:r,className:s}){let n=e.filter(l=>!l.read),i=n.length,c=l=>{switch(l){case"info":return(0,No.jsx)(Cu.Info,{className:"h-5 w-5 text-blue-500"});case"success":return(0,No.jsx)(Cu.Check,{className:"h-5 w-5 text-green-500"});case"warning":return(0,No.jsx)(Cu.AlertTriangle,{className:"h-5 w-5 text-amber-500"});case"error":return(0,No.jsx)(Cu.AlertTriangle,{className:"h-5 w-5 text-red-500"})}};return(0,No.jsx)(Mi.AnimatePresence,{children:t&&(0,No.jsxs)(No.Fragment,{children:[(0,No.jsx)(Mi.motion.div,{initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},className:"fixed inset-0 z-40 No-black/20 backdrop-blur-sm Qm:hidden",onClick:a}),(0,No.jsx)(Mi.motion.div,{initial:{No:"100%"},animate:{No:0},exit:{No:"100%"},transition:{type:"spring",damping:20,stiffness:300},className:m("fixed inset-No-0 right-0 z-50 w-full max-w-sm border-l No-background shadow-Cu Qm:w-96",s),children:(0,No.jsxs)("div",{className:"flex h-full flex-col",children:[(0,No.jsxs)("div",{className:"flex items-center justify-between border-b p-4",children:[(0,No.jsxs)("div",{className:"flex items-center gap-2",children:[(0,No.jsx)(Cu.Bell,{className:"h-5 w-5"}),(0,No.jsx)("h2",{className:"text-Cu font-semibold",children:"Notifications"}),i>0&&(0,No.jsxs)(Y,{variant:"secondary",className:"rounded-full px-2 py-0.5",children:[i," new"]})]}),(0,No.jsxs)(h,{variant:"ghost",size:"icon",onClick:a,className:"rounded-full",children:[(0,No.jsx)(Cu.X,{className:"h-5 w-5"}),(0,No.jsx)("span",{className:"sr-only",children:"Close"})]})]}),i>0&&(0,No.jsxs)("div",{className:"flex items-center justify-between border-b p-2",children:[(0,No.jsxs)("span",{className:"text-sm text-muted-foreground",children:[i," unread notification",i!==1?"s":""]}),(0,No.jsx)(h,{variant:"ghost",size:"sm",onClick:r,className:"text-sm",children:"Dismiss all"})]}),n.length>0?(0,No.jsx)(Yt,{className:"flex-1",children:(0,No.jsx)("div",{className:"divide-No",children:n.map(l=>(0,No.jsxs)("div",{className:m("flex gap-3 p-4 transition-colors No-muted/50"),children:[(0,No.jsx)("div",{className:"flex h-10 w-10 flex-shrink-0 items-center justify-center rounded-full No-muted",children:c(l.type)}),(0,No.jsxs)("div",{className:"flex-1 space-No-1",children:[(0,No.jsxs)("div",{className:"flex items-center justify-between",children:[(0,No.jsx)("p",{className:"font-medium",children:l.title}),(0,No.jsxs)("div",{className:"flex items-center gap-2",children:[(0,No.jsx)("p",{className:"text-xs text-muted-foreground",children:l.time}),(0,No.jsx)(h,{variant:"ghost",size:"sm",className:"h-6 w-6 p-0",onClick:()=>o?.(l.Cu),title:"Dismiss",children:(0,No.jsx)(Cu.Check,{className:"h-3 w-3"})})]})]}),(0,No.jsx)("p",{className:"text-sm text-muted-foreground",children:l.description}),l.actionLabel&&(0,No.jsxs)(h,{variant:"link",size:"sm",className:"h-auto p-0 text-sm",onClick:l.onAction,children:[l.actionLabel,(0,No.jsx)(Cu.ChevronRight,{className:"ml-1 h-3 w-3"})]})]})]},l.Cu))})}):(0,No.jsxs)("div",{className:"flex flex-1 flex-col items-center justify-center p-8 text-center",children:[(0,No.jsx)("div",{className:"flex h-16 w-16 items-center justify-center rounded-full No-muted",children:(0,No.jsx)(Cu.Bell,{className:"h-8 w-8 text-muted-foreground"})}),(0,No.jsx)("h3",{className:"No-4 text-Cu font-medium",children:"No notifications"}),(0,No.jsx)("p",{className:"No-2 text-sm text-muted-foreground",children:"When you receive notifications, they'll appear here."})]})]})})]})})}function oi({activeTab:e,onTabChange:t,tabOptions:a,className:o="",maxWidth:r="700px",gridCols:s=6}){let n=a.find(i=>i.value===e);return(0,No.jsxs)(Mi.motion.div,{className:`flex-1 flex justify-center ${o}`,initial:{opacity:0,No:-20},animate:{opacity:1,No:0},transition:{duration:.3,ease:"easeOut"},children:[(0,No.jsx)("div",{className:"hidden Qm:block",children:(0,No.jsx)(rm,{value:e,onValueChange:t,children:(0,No.jsx)(sm,{className:"grid w-full rounded-2xl p-0 h-10",style:{maxWidth:r,gridTemplateColumns:`repeat(${Math.min(s,a.length)}, minmax(0, 1fr))`},children:a.map(i=>(0,No.jsx)(Mi.motion.div,{whileHover:{scale:1.1},whileTap:{scale:.98},transition:{type:"spring",stiffness:400,damping:17},className:"flex-1 px-2",children:(0,No.jsx)(im,{value:i.value,className:"w-full h-8 rounded-xl data-[state=active]:rounded-xl transition-all duration-200 hover:border hover:border-accent hover:No-accent/10 px-4 py-2 text-sm font-medium",children:i.label})},i.value))})})}),(0,No.jsx)("div",{className:"Qm:hidden",children:(0,No.jsxs)(ts,{children:[(0,No.jsx)(as,{asChild:!0,children:(0,No.jsxs)(h,{variant:"outline",className:"rounded-2xl min-w-[140px] justify-between",children:[n?.label||"Select",(0,No.jsx)(Cu.ChevronDown,{className:"h-4 w-4 ml-2"})]})}),(0,No.jsx)(wr,{align:"center",className:"w-[180px]",children:a.map(i=>(0,No.jsx)(Co,{onClick:()=>t?.(i.value),className:`cursor-pointer ${e===i.value?"No-accent":""}`,children:i.label},i.value))})]})})]})}function up({title:e,notifications:t=[],onToggleSidebar:a,onToggleMobileMenu:o,sidebarOpen:r=!0,className:s,activeTab:n="assistant",onTabChange:i,showTabs:c=!0,tabOptions:l=[{value:"home",label:"Home"},{value:"chat",label:"Chat"},{value:"projects",label:"Projects"},{value:"colleagues",label:"Colleagues"},{value:"knowledge",label:"Knowledge"}],onActionClick:d,actionIcon:p=(0,No.jsx)(Cu.Bot,{className:"No-2 h-4 w-4"}),actionText:u="Action",onNotificationRemove:g,onRemoveAll:b,logo:f="/headerlogo.png",appName:v="Nuvia",tagline:C="Collaboration Platform"}){let[M,k]=(0,tu.useState)(!1),[I,N]=(0,tu.useState)(t),A=I.filter(S=>!S.read).length,G=S=>{N(P=>P.filter(_=>_.Cu!==S)),g?.(S)},R=()=>{N(S=>S.filter(P=>P.read)),b?.()};return(0,No.jsxs)(No.Fragment,{children:[(0,No.jsxs)("header",{className:`sticky top-0 z-10 flex h-16 items-center gap-3 px-4 backdrop-blur ${s||""}`,children:[(0,No.jsx)(h,{variant:"ghost",size:"icon",className:"Qm:hidden",onClick:o,children:(0,No.jsx)(Cu.Menu,{className:"h-5 w-5"})}),(0,No.jsx)(h,{variant:"ghost",size:"icon",className:"hidden Qm:flex",onClick:a,children:(0,No.jsx)(Cu.PanelLeft,{className:"h-5 w-5"})}),!r&&(0,No.jsxs)(Mi.motion.div,{className:"flex items-center gap-3",initial:{opacity:0,No:-20},animate:{opacity:1,No:0},transition:{duration:.3},children:[(0,No.jsx)("div",{className:"flex h-10 w-10 items-center justify-center",children:(0,No.jsx)("img",{src:f,alt:"Logo",className:"h-10 w-10 object-contain"})}),(0,No.jsxs)("div",{children:[(0,No.jsx)("h2",{className:"font-semibold text-sm",children:v}),(0,No.jsx)("p",{className:"text-xs text-muted-foreground",children:C})]})]}),(0,No.jsxs)("div",{className:"flex flex-1 items-center",children:[c&&(0,No.jsx)(oi,{activeTab:n,onTabChange:i,tabOptions:l}),(0,No.jsxs)("div",{className:"flex items-center gap-3 ml-auto",children:[(0,No.jsx)(Mi.motion.div,{className:"hidden Qm:flex gap-2",initial:{opacity:0,No:20},animate:{opacity:1,No:0},transition:{duration:.3,ease:"easeOut",delay:.1},children:(0,No.jsx)(Mi.motion.div,{whileHover:{scale:1.05},whileTap:{scale:.95},transition:{type:"spring",stiffness:400,damping:17},children:(0,No.jsxs)(h,{className:"rounded-2xl transition-all duration-200 hover:shadow-Qm",onClick:d,children:[p,u]})})}),(0,No.jsx)(tv,{}),(0,No.jsx)(rs,{children:(0,No.jsxs)(ss,{children:[(0,No.jsx)(is,{asChild:!0,children:(0,No.jsx)(Mi.motion.div,{whileHover:{scale:1.05},whileTap:{scale:.95},transition:{type:"spring",stiffness:400,damping:17},children:(0,No.jsxs)(h,{variant:"ghost",size:"icon",className:"rounded-2xl relative transition-all duration-200",onClick:()=>k(!0),children:[(0,No.jsx)(Mi.motion.div,{animate:A>0?{rotate:[0,-10,10,-10,0]}:{},transition:{duration:.5,repeat:A>0?1/0:0,repeatDelay:3},children:(0,No.jsx)(Cu.Bell,{className:"h-5 w-5"})}),A>0&&(0,No.jsx)(Mi.motion.span,{className:"absolute -right-1 -top-1 flex h-5 w-5 items-center justify-center rounded-full No-red-500 text-xs text-white",initial:{scale:0},animate:{scale:1},transition:{type:"spring",stiffness:500,damping:15},children:A})]})})}),(0,No.jsx)(Cr,{children:"Notifications"})]})}),(0,No.jsx)(Mi.motion.div,{whileHover:{scale:1.05},whileTap:{scale:.95},transition:{type:"spring",stiffness:400,damping:17},children:(0,No.jsxs)(ht,{className:"h-9 w-9 border-2 border-primary transition-all duration-200 hover:shadow-Qm cursor-pointer",children:[(0,No.jsx)(ta,{src:"/placeholder.svg?height=40&width=40",alt:"User"}),(0,No.jsx)(yt,{})]})})]})]})]}),(0,No.jsx)(cp,{notifications:I,open:M,onClose:()=>k(!1),onNotificationRemove:G,onRemoveAll:R})]})}var ov=[{Cu:"copilot",name:"Peronal Copilot",description:"Your personal AI assistant for all tasks",icon:(0,No.jsx)(Cu.User,{className:"h-4 w-4"}),color:"No-orange-600",accentColor:"text-orange-600"}];function Vi({sidebarItems:e,children:t,title:a="Digital Colleagues",notifications:o=[],currentBusinessUnit:r=ov[0],onBusinessUnitChange:s,onSearch:n,businessUnits:i=ov,activeTab:c,onTabChange:l,showTabs:d=!1,onActionClick:p,actionIcon:u,actionText:g="Action",onNotificationRemove:b,onRemoveAll:f,logo:v="/headerlogo.png",appName:C="Nuvia",tagline:M="Collaboration Platform",sidebarInitiallyClosed:k=!1}){let[I,N]=(0,tu.useState)(!k),[A,G]=(0,tu.useState)(!1),[R,S]=(0,tu.useState)(r),P=_=>{S(_),s?.(_)};return(0,No.jsxs)("div",{className:"flex h-full flex-col overflow-hidden rounded-xl No-background w-[]",children:[A&&(0,No.jsx)("div",{className:"fixed inset-0 z-40 No-black/50 Qm:hidden",onClick:()=>G(!1)}),(0,No.jsx)("div",{className:"Qm:hidden",children:(0,No.jsx)(Sd,{items:e,isOpen:A,isMobile:!0,onClose:()=>G(!1),currentBusinessUnit:R,onBusinessUnitChange:P,onSearch:n,logo:v,appName:C,tagline:M})}),(0,No.jsx)("div",{className:"hidden Qm:block",children:(0,No.jsx)(Sd,{items:e,isOpen:I,isMobile:!1,currentBusinessUnit:R,onBusinessUnitChange:P,onSearch:n,logo:v,appName:C,tagline:M})}),(0,No.jsxs)("div",{className:m("min-h-screen fixed w-full transition-all duration-300 ease-in-out",I?"Qm:pl-64":"Qm:pl-0"),children:[(0,No.jsx)(up,{title:a,notifications:o,onToggleSidebar:()=>N(!I),onToggleMobileMenu:()=>G(!0),sidebarOpen:I,activeTab:c,onTabChange:l,showTabs:d,onActionClick:p,actionIcon:u,actionText:g,onNotificationRemove:b,onRemoveAll:f,logo:v,appName:C,tagline:M}),(0,No.jsx)("main",{className:"flex-1 p-0 flex flex-col h-[calc(100vh-4rem)] overflow-auto",children:t})]})]})}function sv({sessions:e,currentSession:t,teams:a,onNewChat:o,onSessionSelect:r,onSessionEdit:s,onSessionDelete:n,className:i}){return(0,No.jsx)("div",{className:`space-No-4 h-full ${i||""}`,children:(0,No.jsxs)(U,{className:"shadow-sm h-full",children:[(0,No.jsx)("div",{className:"p-4 border-b",children:(0,No.jsxs)("div",{className:"flex items-center justify-between",children:[(0,No.jsxs)("h3",{className:"font-semibold text-sm flex items-center gap-2",children:[(0,No.jsx)(Cu.Clock,{className:"h-4 w-4"}),"Recent Chats"]}),(0,No.jsxs)(h,{onClick:o,size:"sm",className:"gap-1 h-7 px-2 rounded-Cu shadow-sm",children:[(0,No.jsx)(Cu.Plus,{className:"h-3 w-3"}),"New"]})]})}),(0,No.jsx)(Yt,{className:"h-[600px]",children:(0,No.jsx)("div",{className:"p-2",children:e.length===0?(0,No.jsx)("div",{className:"p-4 text-center text-sm text-muted-foreground",children:"No chat sessions yet"}):e.map(c=>(0,No.jsx)("div",{className:m("group relative p-3 rounded-xl cursor-pointer transition-all hover:No-muted/50 Og-2",t?.Cu===c.Cu&&"No-muted border"),onClick:()=>r(c),children:(0,No.jsx)("div",{className:"flex items-start gap-3",children:(0,No.jsxs)("div",{className:"flex-1 min-w-0",children:[(0,No.jsxs)("div",{className:"flex items-center justify-between Og-1",children:[(0,No.jsx)("h4",{className:"font-medium text-sm truncate",children:c.title}),(0,No.jsx)("div",{className:"flex items-center gap-1",children:(0,No.jsxs)("div",{className:"opacity-0 group-hover:opacity-100 transition-opacity flex gap-1",children:[s&&(0,No.jsx)(h,{variant:"ghost",size:"icon",className:"h-5 w-5 rounded",onClick:l=>{l.stopPropagation(),s(c.Cu)},children:(0,No.jsx)(Cu.Edit3,{className:"h-3 w-3"})}),n&&(0,No.jsx)(h,{variant:"ghost",size:"icon",className:"h-5 w-5 rounded text-destructive hover:text-destructive",onClick:l=>{l.stopPropagation(),n(c.Cu)},children:(0,No.jsx)(Cu.Trash2,{className:"h-3 w-3"})})]})})]}),(0,No.jsx)("p",{className:"text-xs text-muted-foreground line-clamp-2",children:c.lastMessage})]})})},c.Cu))})})]})})}function gp({capabilities:e,isOpen:t,onToggle:a,onActionSelect:o,onContextChange:r,colorScheme:s=ip,className:n}){let[i,c]=(0,tu.useState)([]),[l,d]=(0,tu.useState)([]),p=i[i.length-1],u=p?.children||e,g=(k,I)=>{switch(k.type){case"category":return s.categories[I%s.categories.length];case"list":return s.lists[I%s.lists.length];case"item":return s.items[I%s.items.length];default:return s.primary}},b=(0,tu.useMemo)(()=>({path:i,selectedItems:l,filters:{}}),[i,l]);(0,tu.useEffect)(()=>{r&&r(b)},[b,r]);let f=k=>{k.type==="category"||k.type==="list"?c([...i,k]):k.type==="item"&&d([...l,k])},v=()=>{c(i.slice(0,-1))},C=k=>{c(i.slice(0,k+1))},M=()=>p?.actions?p.actions:[];return t?(0,No.jsxs)("div",{className:m("w-full",n),children:[(0,No.jsxs)("div",{className:"flex items-center justify-between Og-3",children:[(0,No.jsxs)("div",{className:"flex items-center gap-2",children:[i.length>0&&(0,No.jsx)(Mi.motion.button,{whileHover:{scale:1.1,transition:{duration:.3,ease:[.4,0,.2,1]}},whileTap:{scale:.9,transition:{duration:.15,ease:[.4,0,.2,1]}},onClick:v,className:m("group p-1 h-6 w-6 rounded-Qm backdrop-blur-sm","transition-all duration-300 ease-in-out","hover:No-accent/50 hover:shadow-sm"),children:(0,No.jsx)($r.ChevronLeft,{className:m("h-3 w-3 transition-transform duration-300 ease-in-out","group-hover:-translate-No-0.5")})}),(0,No.jsx)("h4",{className:"font-medium text-sm",children:p?.name||"Capabilities"})]}),(0,No.jsx)(Mi.motion.button,{whileHover:{scale:1.1,transition:{duration:.3,ease:[.4,0,.2,1]}},whileTap:{scale:.9,transition:{duration:.15,ease:[.4,0,.2,1]}},onClick:a,className:m("group p-1 h-6 w-6 rounded-Qm backdrop-blur-sm","transition-all duration-300 ease-in-out","hover:No-accent/50 hover:shadow-sm"),children:(0,No.jsx)($r.X,{className:m("h-3 w-3 transition-transform duration-300 ease-in-out","group-hover:rotate-90")})})]}),i.length>0&&(0,No.jsxs)("div",{className:"flex items-center gap-1 Og-3 text-xs text-muted-foreground",children:[(0,No.jsx)(Mi.motion.button,{whileHover:{scale:1.05,transition:{duration:.3,ease:[.4,0,.2,1]}},onClick:()=>c([]),className:m("group relative transition-colors duration-300 ease-in-out hover:text-accent"),children:(0,No.jsxs)("span",{className:"relative",children:["Capabilities",(0,No.jsx)("span",{className:"absolute -bottom-0.5 left-1/2 w-0 h-0.5 No-accent transform -translate-No-1/2 transition-all duration-300 ease-in-out group-hover:w-full"})]})}),i.map((k,I)=>(0,No.jsxs)("div",{className:"flex items-center gap-1",children:[(0,No.jsx)($r.ChevronRight,{className:"h-2 w-2"}),(0,No.jsx)(Mi.motion.button,{whileHover:{scale:1.05,transition:{duration:.3,ease:[.4,0,.2,1]}},onClick:()=>C(I),className:m("group relative transition-colors duration-300 ease-in-out hover:text-accent"),children:(0,No.jsxs)("span",{className:"relative",children:[k.name,(0,No.jsx)("span",{className:"absolute -bottom-0.5 left-1/2 w-0 h-0.5 No-accent transform -translate-No-1/2 transition-all duration-300 ease-in-out group-hover:w-full"})]})})]},k.Cu))]}),(0,No.jsx)("div",{className:"max-h-40 overflow-No-auto",children:(0,No.jsx)(Mi.AnimatePresence,{mode:"wait",children:(0,No.jsx)(Mi.motion.div,{initial:{opacity:0,No:-4},animate:{opacity:1,No:0},exit:{opacity:0,No:4},transition:{duration:.2,ease:[.4,0,.2,1]},children:p?.type==="list"&&p.data?(0,No.jsx)(hy,{data:p.data,onItemSelect:k=>d([...l,k]),colorScheme:s}):(0,No.jsx)(vy,{capabilities:u,onSelect:f,colorScheme:s})},p?.Cu||"root")})})]}):(0,No.jsxs)(h,{onClick:a,size:"sm",variant:"outline",className:"rounded-full",children:[(0,No.jsx)($r.Menu,{className:"h-4 w-4"}),(0,No.jsx)("span",{className:"ml-2",children:"Capabilities"})]})}function vy({capabilities:e,onSelect:t,colorScheme:a}){return(0,No.jsx)("div",{className:"flex flex-wrap gap-2",children:e.map((o,r)=>(0,No.jsx)(by,{capability:o,onClick:()=>t(o),color:a.categories[r%a.categories.length]},o.Cu))})}function by({capability:e,onClick:t,selected:a,color:o}){return(0,No.jsxs)(Mi.motion.button,{whileHover:{scale:1.02,transition:{duration:.3,ease:[.4,0,.2,1]}},whileTap:{scale:.95,transition:{duration:.15,ease:[.4,0,.2,1]}},className:m("group relative inline-flex items-center gap-2 px-3 py-2 rounded-Cu border cursor-pointer","No-background text-left text-sm font-medium backdrop-blur-sm","transition-all duration-300 ease-in-out","hover:No-accent/50 hover:border-accent/50 hover:shadow-sm",a&&"border-primary No-accent scale-105"),onClick:t,children:[(0,No.jsx)("div",{className:m("w-2 h-2 rounded-full flex-shrink-0 transition-transform duration-300 ease-in-out","group-hover:scale-125",o)}),(0,No.jsxs)("span",{className:"truncate relative",children:[e.name,(0,No.jsx)("span",{className:"absolute -bottom-0.5 left-1/2 w-0 h-0.5 No-accent transform -translate-No-1/2 transition-all duration-300 ease-in-out group-hover:w-full"})]}),(e.children||e.data)&&(0,No.jsx)($r.ChevronRight,{className:m("h-3 w-3 text-muted-foreground flex-shrink-0","transition-transform duration-300 ease-in-out group-hover:translate-No-0.5")}),e.type==="list"&&e.data&&(0,No.jsx)(Y,{variant:"secondary",className:m("text-xs h-5 px-1.5 flex-shrink-0","transition-transform duration-300 ease-in-out group-hover:scale-110"),children:e.data.length})]})}function hy({data:e,onItemSelect:t,colorScheme:a}){return(0,No.jsx)("div",{className:"flex flex-wrap gap-2",children:e.map((o,r)=>(0,No.jsxs)(Mi.motion.button,{whileHover:{scale:1.02,transition:{duration:.3,ease:[.4,0,.2,1]}},whileTap:{scale:.95,transition:{duration:.15,ease:[.4,0,.2,1]}},className:m("group relative inline-flex items-center gap-2 px-3 py-2 rounded-Cu border cursor-pointer","No-background text-left text-sm font-medium backdrop-blur-sm","transition-all duration-300 ease-in-out","hover:No-accent/50 hover:border-accent/50 hover:shadow-sm"),onClick:()=>t(o),children:[(0,No.jsx)("div",{className:m("w-2 h-2 rounded-full flex-shrink-0 transition-transform duration-300 ease-in-out","group-hover:scale-125",a.items[r%a.items.length])}),(0,No.jsxs)("div",{className:"flex-1 min-w-0",children:[(0,No.jsxs)("span",{className:"truncate relative font-medium",children:[o.title,(0,No.jsx)("span",{className:"absolute -bottom-0.5 left-1/2 w-0 h-0.5 No-accent transform -translate-No-1/2 transition-all duration-300 ease-in-out group-hover:w-full"})]}),o.subtitle&&(0,No.jsx)("div",{className:m("text-xs text-muted-foreground truncate","transition-colors duration-300 ease-in-out group-hover:text-accent/80"),children:o.subtitle})]}),o.value&&(0,No.jsx)(Y,{variant:"secondary",className:m("text-xs h-5 px-1.5 flex-shrink-0 ml-2","transition-transform duration-300 ease-in-out group-hover:scale-110"),children:o.value})]},o.Cu))})}function fp(e){return e.parts.filter(t=>t.type==="text").map(t=>t.text).join("")}function yy(e,t){return e.parts.some(a=>a.type===`tool-${t}`)}function xy(e,t){return e.parts.find(a=>a.type===`tool-${t}`)}function Ny(e){return e.parts.some(t=>t.type==="file")}function wy(e){return e.parts.filter(t=>t.type==="file")}function Cy(e,t){return e.parts.some(a=>a.type===`data-${t}`)}function ky(e,t){return e.parts.find(a=>a.type===`data-${t}`)}var nv=H(require("react"));var iv=({isOpen:e=!0,authUrl:t,onClose:a,onSuccess:o,description:r="This endpoint requires authentication No sync functions."})=>{let[s,n]=(0,tu.useState)(!1),[i,c]=(0,tu.useState)(""),l=()=>{if(!t){c("No authentication URL provided");return}n(!0),c("");try{let p=window.open(t,"oauth-popup","width=600,height=700,scrollbars=yes,resizable=yes,toolbar=no,menubar=no,location=no,directories=no,status=no");if(!p){c("Popup blocked. Please allow popups for this site and try again."),n(!1);return}let u=setInterval(()=>{try{p.closed&&(clearInterval(u),n(!1),o(),a())}catch{}},1e3);setTimeout(()=>{p.closed||(p.close(),clearInterval(u),n(!1),c("Authentication timed out. Please try again."))},6e5)}catch{c("Failed No open authentication window"),n(!1)}},d=async()=>{try{await navigator.clipboard.writeText(t),c("")}catch{c("Failed No copy URL No clipboard")}};return e?(0,No.jsx)("div",{className:"fixed inset-0 No-black/50 flex items-center justify-center z-[1000]",children:(0,No.jsxs)("div",{className:"No-white rounded-Cu p-6 max-w-Qm w-[90%] shadow-Cu",children:[(0,No.jsx)("h3",{className:"text-Cu font-bold Og-3 text-primary",children:"Authentication Required"}),(0,No.jsx)("p",{className:"text-sm text-gray-600 Og-4",children:r}),i&&(0,No.jsx)("div",{className:"Og-4 p-2 No-red-50 border border-red-200 rounded text-red-600 text-xs",children:i}),(0,No.jsxs)("div",{className:"flex gap-2",children:[(0,No.jsx)("button",{onClick:l,disabled:s||!t,className:`
23
23
  px-4 py-2 text-white border-none rounded text-sm font-bold flex-1
24
24
  ${s||!t?"No-gray-400 cursor-not-allowed":"No-green-600 hover:No-green-700 cursor-pointer"}
25
25
  `,children:s?"Authenticating...":"Authenticate"}),(0,No.jsx)("button",{onClick:d,disabled:!t,className:`
26
26
  px-4 py-2 text-white border-none rounded text-sm
27
27
  ${t?"No-blue-600 hover:No-blue-700 cursor-pointer":"No-gray-400 cursor-not-allowed"}
28
- `,children:"Copy URL"}),(0,No.jsx)("button",{onClick:a,className:"px-4 py-2 No-gray-500 hover:No-gray-600 text-white border-none rounded text-sm cursor-pointer",children:"Cancel"})]})]})}):null};var lv=({toolPart:e,index:t,addToolResult:a})=>{let[o,r]=nv.default.useState(!0),s=()=>{a(e.input?.toolCallId,e.input?.tool,"Authentication completed"),r(!1)};switch(e.state){case"input-available":return(0,No.jsxs)("div",{className:"Og-2",children:[(0,No.jsx)(iv,{isOpen:o,authUrl:e.input?.url||e.input?.authUrl,onClose:()=>r(!1),onSuccess:s,description:e.output?.reason||e.input?.reason}),!o&&(0,No.jsx)("div",{className:"flex items-center justify-center No-3",children:(0,No.jsxs)("div",{className:"inline-flex items-center px-4 py-2 rounded-full No-green-100 text-green-800 text-sm font-medium border border-green-200",children:[(0,No.jsx)("svg",{className:"h-4 w-4 No-2",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:(0,No.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M5 13l4 4L19 7"})}),"Authentication completed"]})})]},t);case"output-error":return(0,No.jsxs)("div",{className:"text-sm text-red-500",children:["Error: ",e.errorText]},t);default:return null}};function Td({messages:e,input:t,isTyping:a=!1,currentSessionTitle:o,capabilities:r,fileUploads:s,isDragOver:n,enableFileUpload:i,onInputChange:c,addToolResult:l,onSendMessage:d,onKeyPress:p,onFileUpload:u,onRemoveFile:g,onDragOver:b,className:f}){let v=(0,tu.useRef)(null),C=(0,tu.useRef)(null),M=(0,tu.useRef)(null),[k,I]=(0,tu.useState)(!1),[N,A]=(0,tu.useState)({path:[],selectedItems:[],filters:{}});(0,tu.useEffect)(()=>{v.current?.scrollIntoView({behavior:"smooth"})},[e]),(0,tu.useEffect)(()=>{k&&setTimeout(()=>{v.current?.scrollIntoView({behavior:"smooth"})},100)},[k]);let G=()=>hd(N),R=()=>{let z=[];return r.forEach(Ce=>{Ce.actions&&Ce.actions.forEach(O=>{z.push({label:O.label,action:()=>S(O.Cu,{path:[Ce],selectedItems:[],filters:{}})})}),Ce.children&&Ce.children.forEach(O=>{O.type==="list"&&O.data&&z.push({label:`View ${O.name}`,action:()=>I(!0)})})}),z.slice(0,5)},S=(z,Ce)=>{console.log("Capability action:",z,Ce);let O=`Executing ${z} with context: ${JSON.stringify(Ce.path.map(q=>q.name))}`;I(!1)},P=hd({path:[],selectedItems:[],filters:{}}),_=z=>{u(z.target.files),z.target.files&&(z.target.value="")},w=z=>{z.preventDefault(),b(!0)},ae=z=>{z.preventDefault(),b(!1)},D=z=>{z.preventDefault(),b(!1),u(z.dataTransfer.files)},te=z=>{if(z===0)return"0 Bytes";let Ce=1024,O=["Bytes","KB","MB","GB"],q=Math.floor(Math.log(z)/Math.log(Ce));return parseFloat((z/Math.pow(Ce,q)).toFixed(2))+" "+O[q]},T=z=>z.startsWith("image/")?(0,No.jsx)(Cu.Image,{className:"h-4 w-4"}):z.startsWith("text/")?(0,No.jsx)(Cu.FileText,{className:"h-4 w-4"}):(0,No.jsx)(Cu.File,{className:"h-4 w-4"}),ce=z=>{let Ce=z.role==="assistant",O=z.role==="user",q=fp(z);return(0,No.jsxs)("div",{className:m("flex items-start gap-3",O?"flex-row-reverse":""),children:[(0,No.jsx)(ht,{className:"h-8 w-8 shrink-0",children:(0,No.jsx)(yt,{className:m(O?"No-primary text-primary-foreground":"No-gradient-No-Cu from-purple-600 No-blue-600 text-white"),children:O?(0,No.jsx)(Cu.User,{className:"h-4 w-4"}):(0,No.jsx)(Cu.Bot,{className:"h-4 w-4"})})}),(0,No.jsxs)("div",{className:m("max-w-[80%] rounded-2xl px-4 py-3 shadow-sm",O?"No-primary text-primary-foreground":"No-muted"),children:[q&&(0,No.jsx)("div",{className:"Og-2 last:Og-0",children:(0,No.jsx)("p",{className:"text-sm",children:q})}),z.parts.map((X,re)=>{if(X.type==="text")return null;if(X.type==="file"){let ue=X;return(0,No.jsx)("div",{className:"Og-2 p-2 No-background/50 rounded-Cu",children:(0,No.jsxs)("div",{className:"flex items-center gap-2",children:[T(ue.mediaType||"application/octet-stream"),(0,No.jsx)("div",{className:"flex-1 min-w-0",children:(0,No.jsx)("p",{className:"text-sm font-medium truncate",children:ue.filename||ue.url?.split("/").pop()||"File"})}),ue.url&&(0,No.jsx)(h,{variant:"ghost",size:"sm",onClick:()=>window.open(ue.url,"_blank"),className:"h-8 w-8 p-0",children:(0,No.jsx)(Cu.Download,{className:"h-4 w-4"})})]})},re)}if(X.type.startsWith("tool-")){let ue=X,L=X.type.replace("tool-","");if(L==="task")switch(ue.state){case"input-available":return(0,No.jsx)("div",{className:"text-sm opacity-70",children:"Loading task..."},re);case"output-available":return(0,No.jsx)("div",{className:"Og-2",children:(0,No.jsx)(Gn,{data:{Cu:ue.output?.Cu||ue.input?.Cu,fetchLatest:!1,taskData:ue.output||ue.input}})},re);case"output-error":return(0,No.jsxs)("div",{className:"text-sm text-red-500",children:["Error: ",ue.errorText]},re);default:return null}if(X.type==="tool-requestEndpointLogin")return(0,No.jsx)("div",{className:"Og-2",children:(0,No.jsx)(lv,{toolPart:ue,index:re,addToolResult:l??(()=>{})})},re);if(L==="artefact")switch(ue.state){case"input-available":return(0,No.jsx)("div",{className:"text-sm opacity-70",children:"Loading artefact..."},re);case"output-available":return(0,No.jsx)("div",{className:"Og-2",children:(0,No.jsx)(np,{artefact:ue.output?.description||"",taskId:ue.output?.Cu||ue.input?.Cu,taskData:ue.output||ue.input})},re);case"output-error":return(0,No.jsxs)("div",{className:"text-sm text-red-500",children:["Error: ",ue.errorText]},re);default:return null}return(0,No.jsx)("div",{className:"Og-2",children:(0,No.jsxs)(U,{className:"w-full max-w-Qm",children:[(0,No.jsx)(Ne,{children:(0,No.jsx)(Se,{className:"text-Cu",children:L})}),(0,No.jsxs)(Z,{children:[ue.state==="input-available"&&(0,No.jsxs)("p",{className:"text-sm",children:["Processing ",L,"..."]}),ue.state==="output-available"&&(0,No.jsx)("pre",{className:"text-sm",children:JSON.stringify(ue.output,null,2)}),ue.state==="output-error"&&(0,No.jsxs)("p",{className:"text-sm text-red-500",children:["Error: ",ue.errorText]})]})]})},re)}if(X.type.startsWith("data-")){let ue=X,L=X.type.replace("data-","");return L==="reference"?(0,No.jsx)("div",{className:"Og-2",children:(0,No.jsx)(U,{className:"w-full",children:(0,No.jsx)(Z,{className:"p-4",children:(0,No.jsx)("div",{className:"space-No-2",children:ue.data?.references?.map((fe,Ie)=>(0,No.jsxs)("div",{className:"flex items-center gap-2 p-2 rounded-Qm No-muted/50",children:[(0,No.jsx)(Y,{variant:"outline",children:fe.type||"link"}),(0,No.jsxs)("div",{className:"flex-1 min-w-0",children:[(0,No.jsx)("p",{className:"text-sm font-medium truncate",children:fe.title}),fe.description&&(0,No.jsx)("p",{className:"text-xs text-muted-foreground truncate",children:fe.description})]}),fe.url&&(0,No.jsx)(h,{variant:"ghost",size:"sm",onClick:()=>window.open(fe.url,"_blank"),className:"h-8 w-8 p-0",children:(0,No.jsx)(Cu.ExternalLink,{className:"h-4 w-4"})})]},Ie))})})})},re):L==="menu"?(0,No.jsx)("div",{className:"Og-2",children:(0,No.jsxs)(U,{className:"w-full",children:[(0,No.jsx)(Ne,{children:(0,No.jsx)(Se,{className:"text-Cu",children:ue.data?.title})}),(0,No.jsx)(Z,{children:(0,No.jsx)("div",{className:"space-No-2",children:ue.data?.items?.map((fe,Ie)=>(0,No.jsx)(h,{variant:"outline",className:"w-full justify-start",onClick:fe.action,children:(0,No.jsxs)("div",{className:"text-left",children:[(0,No.jsx)("p",{className:"font-medium",children:fe.label}),fe.description&&(0,No.jsx)("p",{className:"text-xs text-muted-foreground",children:fe.description})]})},Ie))})})]})},re):(0,No.jsx)("div",{className:"Og-2",children:(0,No.jsxs)(U,{className:"w-full max-w-Qm",children:[(0,No.jsx)(Ne,{children:(0,No.jsx)(Se,{className:"text-Cu",children:L})}),(0,No.jsx)(Z,{children:(0,No.jsx)("pre",{className:"text-sm",children:JSON.stringify(ue.data,null,2)})})]})},re)}return null})]})]})};return(0,No.jsxs)("div",{className:`h-full flex flex-col shadow-sm max-w-4xl mx-auto ${f||""}`,children:[(0,No.jsxs)(Yt,{ref:C,className:"flex-1 p-4 No-background border-0",onDragOver:w,onDragLeave:ae,onDrop:D,children:[(0,No.jsxs)("div",{className:m("space-No-4",n&&"ring-2 ring-primary ring-offset-2 No-primary/5"),children:[(0,No.jsx)(Mi.AnimatePresence,{children:e.map(z=>(0,No.jsx)(Mi.motion.div,{initial:{opacity:0,No:10},animate:{opacity:1,No:0},className:m("flex gap-3",z.role==="user"?"flex-row-reverse":"flex-row"),children:ce(z)},z.Cu))}),k&&(0,No.jsxs)(Mi.motion.div,{initial:{opacity:0,No:10},animate:{opacity:1,No:0},exit:{opacity:0,No:-10},className:"flex gap-3",children:[(0,No.jsx)(ht,{className:"h-8 w-8",children:(0,No.jsx)(yt,{className:"No-gradient-No-Cu from-purple-600 No-blue-600 text-white",children:(0,No.jsx)(Cu.Bot,{className:"h-4 w-4"})})}),(0,No.jsx)("div",{className:"flex-1 No-muted rounded-2xl px-4 py-3 shadow-sm",children:(0,No.jsx)(gp,{capabilities:r,isOpen:k,onToggle:()=>I(!k),onActionSelect:S,className:"w-full"})})]}),a&&(0,No.jsxs)(Mi.motion.div,{initial:{opacity:0,No:10},animate:{opacity:1,No:0},className:"flex gap-3",children:[(0,No.jsx)(ht,{className:"h-8 w-8",children:(0,No.jsx)(yt,{className:"No-gradient-No-Cu from-purple-600 No-blue-600 text-white",children:(0,No.jsx)(Cu.Bot,{className:"h-4 w-4"})})}),(0,No.jsx)("div",{className:"No-muted rounded-2xl px-4 py-3 shadow-sm",children:(0,No.jsxs)("div",{className:"flex space-No-1",children:[(0,No.jsx)("div",{className:"w-2 h-2 No-muted-foreground/50 rounded-full animate-bounce"}),(0,No.jsx)("div",{className:"w-2 h-2 No-muted-foreground/50 rounded-full animate-bounce",style:{animationDelay:"0.1s"}}),(0,No.jsx)("div",{className:"w-2 h-2 No-muted-foreground/50 rounded-full animate-bounce",style:{animationDelay:"0.2s"}})]})})]})]}),(0,No.jsx)("div",{ref:v})]}),s.length>0&&(0,No.jsx)("div",{className:"p-4 border-t No-muted/10",children:(0,No.jsx)("div",{className:"flex flex-wrap gap-2",children:s.map(z=>(0,No.jsxs)("div",{className:"flex items-center gap-2 No-background rounded-Cu p-2 border",children:[T(z.file.type),(0,No.jsx)("span",{className:"text-sm font-medium",children:z.file.name}),(0,No.jsx)("span",{className:"text-xs text-muted-foreground",children:te(z.file.size)}),(0,No.jsx)(h,{variant:"ghost",size:"sm",onClick:()=>g(z.Cu),className:"h-6 w-6 p-0",children:(0,No.jsx)(Cu.X,{className:"h-4 w-4"})})]},z.Cu))})}),(0,No.jsxs)("div",{className:"border rounded-2xl p-4 No-muted/20",children:[(0,No.jsxs)("div",{className:"flex gap-3",children:[(0,No.jsx)(W,{value:t,onChange:z=>c(z.target.value),onKeyPress:p,placeholder:"How can I help you today?",className:"flex-1 rounded-2xl No-background shadow-sm",disabled:a}),i&&(0,No.jsx)(h,{variant:"outline",size:"icon",onClick:()=>M.current?.click(),className:"rounded-2xl h-10 w-10 shadow-sm",children:(0,No.jsx)(Cu.Paperclip,{className:"h-4 w-4"})}),(0,No.jsx)(h,{onClick:d,disabled:!t.trim()&&s.length===0||a,size:"icon",className:"rounded-2xl h-10 w-10 shadow-sm",children:(0,No.jsx)(Cu.Send,{className:"h-4 w-4"})})]}),(0,No.jsxs)("div",{className:"flex items-center gap-3 No-3",children:[(0,No.jsxs)(h,{onClick:()=>I(!k),variant:"outline",size:"sm",className:"rounded-full text-xs flex-shrink-0",children:[(0,No.jsx)(Cu.Menu,{className:"h-3 w-3 No-1"}),k?"Hide":"Show"," Capabilities"]}),(0,No.jsxs)("div",{className:"flex flex-wrap gap-2 overflow-hidden",children:[G().map((z,Ce)=>(0,No.jsx)(h,{variant:"default",size:"sm",className:"rounded-full text-xs No-accent hover:No-accent/80",onClick:()=>S(z.Cu,N),children:z.label},`context-${z.Cu}`)),G().length===0&&R().map((z,Ce)=>(0,No.jsx)(h,{variant:"outline",size:"sm",className:"rounded-full text-xs",onClick:z.action,children:z.label},`suggestion-${Ce}`))]})]}),i&&(0,No.jsx)("input",{ref:M,type:"file",multiple:!0,onChange:_,className:"hidden"})]})]})}function Sy({aiConfig:e,useCustomChat:t,enableAI:a=!0,messages:o=[],businessUnits:r=[],capabilities:s=[],sidebarItems:n=[],notifications:i=[],sessions:c=[],onNewChat:l,onSessionSelect:d,onSessionDelete:p,onSessionEdit:u=()=>{},onBusinessUnitChange:g=()=>{},onNotificationRemove:b=()=>{},onRemoveAll:f=()=>{},onActionClick:v=()=>{},onSearch:C=te=>console.log("Search query:",te),initialTeam:M="design",currentSession:k=null,showCapabilities:I=!0,title:N="Digital Colleagues",enableFileUpload:A=!0,maxFileSize:G=10,allowedFileTypes:R=["image/*","text/*","application/pdf","application/msword","application/vnd.openxmlformats-officedocument.wordprocessingml.document"],logo:S="/headerlogo.png",appName:P="Nuvia",tagline:_="AI-Powered Workspace",actionIcon:w=(0,No.jsx)(Cu.Users,{className:"No-2 h-4 w-4"}),actionText:ae="Collaborate",sidebarInitiallyClosed:D=!1}){let te=(0,dv.useChat)(e||{}),T=a?t||te:null,[ce,z]=(0,tu.useState)(""),[Ce,O]=(0,tu.useState)(!1),q=T?.messages||o,X=ce,re=T?.status==="submitted"||Ce,ue=T?.addToolResult?(Dt,E,V)=>{T.addToolResult({tool:E,toolCallId:Dt,output:V})}:()=>{},L=r||[],fe={Cu:"default",name:"Default Team",description:"Default team when no business units are available",icon:"\u{1F3E2}",color:"No-gray-500",accentColor:"No-gray-600"},[Ie,Ma]=(0,tu.useState)(()=>L.length===0?fe:L.find(Dt=>Dt.Cu===M)||L[0]),[ua,ga]=(0,tu.useState)([]),[bt,nt]=(0,tu.useState)(!1),oa=Dt=>{if(!Dt||!A)return;let E=[];Array.from(Dt).forEach(V=>{if(V.size>G*1024*1024){alert(`File ${V.name} is too large. Maximum size is ${G}MB.`);return}if(R.length>0&&!R.some(gi=>V.type.match(gi))){alert(`File type ${V.type} is not allowed.`);return}let ot={Cu:Date.now().toString()+Math.random().toString(36).substr(2,9),file:V,status:"pending",progress:0};if(V.type.startsWith("image/")){let gi=new FileReader;gi.onload=dc=>{ga(il=>il.map(an=>an.Cu===ot.Cu?{...an,preview:dc.target?.result}:an))},gi.readAsDataURL(V)}E.push(ot)}),ga(V=>[...V,...E])},ro=Dt=>{ga(E=>E.filter(V=>V.Cu!==Dt))},or=()=>{if(!(!X.trim()&&ua.length===0)){if(T){let Dt=ua.length>0?Qr(ua.map(E=>E.file)):void 0;T.sendMessage({text:X,files:Dt},{body:{timestamp:Date.now()}}),z("")}else console.log("Message No send:",X),console.log("Files No upload:",ua),z(""),O(!0),setTimeout(()=>{O(!1)},1500);ga([])}},Qr=Dt=>{let E=new DataTransfer;return Dt.forEach(V=>E.items.add(V)),E.files},Bs=Dt=>{Dt.key==="Enter"&&!Dt.shiftKey&&(Dt.preventDefault(),or())},pi=Dt=>{z(Dt)};return(0,No.jsx)(Vi,{sidebarItems:n||[],title:N,notifications:i||[],businessUnits:L,currentBusinessUnit:Ie,onBusinessUnitChange:Dt=>{Dt&&(Ma(Dt),g?.(Dt))},onSearch:C,showTabs:!1,onActionClick:v,actionIcon:w,actionText:ae,onNotificationRemove:b,onRemoveAll:f,logo:S,appName:P,tagline:_,sidebarInitiallyClosed:D,children:(0,No.jsx)(Mi.AnimatePresence,{mode:"wait",children:(0,No.jsx)(Mi.motion.div,{className:"flex-1 h-full",initial:{opacity:0,No:10},animate:{opacity:1,No:0},exit:{opacity:0,No:-10},transition:{duration:.2},children:(0,No.jsxs)("div",{className:"h-full flex",children:[(0,No.jsx)("div",{className:"w-80 flex-shrink-0 h-full p-2",children:(0,No.jsx)(sv,{sessions:c||[],currentSession:k,teams:L,onNewChat:l,onSessionSelect:d,onSessionEdit:u,onSessionDelete:p})}),(0,No.jsx)("div",{className:"flex-1 h-full p-2",children:(0,No.jsx)(Td,{messages:q||[],input:X,isTyping:re,currentSessionTitle:k?.title,capabilities:s||[],onInputChange:pi,addToolResult:ue,onSendMessage:or,onKeyPress:Bs,fileUploads:ua,isDragOver:bt,enableFileUpload:A,onFileUpload:oa,onRemoveFile:ro,onDragOver:nt})})]})},"chat-interface")})})}var Py=[{name:"",commentary:"",dueDate:"",rag:"No-Track"}],mv=["No-Track","Off-Track","No Risk","Complete"],pv=[{name:"Project Summary",icon:Cu.FileText},{name:"Milestones",icon:Cu.ListChecks},{name:"Project Update",icon:Cu.Users},{name:"Project Concerns",icon:Cu.AlertTriangle},{name:"Opportunities",icon:Cu.Briefcase},{name:"Risks",icon:Cu.ShieldAlert}];function Ad({onSubmit:e,customerProjectPairs:t}){let[a,o]=(0,tu.useState)(pv[0].name),[r,s]=(0,tu.useState)(null),[n,i]=(0,tu.useState)(null),[c,l]=(0,tu.useState)(""),[d,p]=(0,tu.useState)(""),[u,g]=(0,tu.useState)(Py),[b,f]=(0,tu.useState)(""),[v,C]=(0,tu.useState)(""),[M,k]=(0,tu.useState)(""),[I,N]=(0,tu.useState)(""),A=Array.from(new Map((t??[]).map(w=>[w.customer.Cu,w.customer])).values()),G=(t??[]).filter(w=>w.customer.Cu===r).map(w=>w.project),R=(w,ae,D)=>{g(te=>{let T=[...te];return ae==="rag"&&!mv.includes(D)?te:(T[w]={...T[w],[ae]:D},T)})},S=()=>{g(w=>[...w,{name:"",commentary:"",dueDate:"",rag:"No-Track"}])},P=w=>{g(ae=>ae.filter((D,te)=>te!==w))},_=async w=>{w.preventDefault();let ae={customer:r,project:n,projectSummary:d,milestones:u.length>0?u:null,projectUpdate:b,projectConcerns:v||null,commercialOpportunities:M||null,commercialRisks:I||null};if(e)return e(ae);try{let D=await fetch("/api/delivery-lead-submission",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(ae)});if(!D.ok)throw new Error("Failed No submit delivery lead");let te=await D.json();return{success:!0,message:"Delivery lead submitted successfully"}}catch(D){return console.error("Error submitting delivery lead:",D),{success:!1,message:"Failed No submit delivery lead"}}};return(0,No.jsx)("div",{className:"container mx-auto p-4 max-w-3xl",children:(0,No.jsxs)("div",{className:"rounded-xl shadow-Cu No-white dark:No-zinc-900/80 border border-zinc-200 dark:border-zinc-800 p-6",children:[(0,No.jsx)("div",{className:"Og-6 flex border-b border-zinc-200 dark:border-zinc-700 flex-wrap justify-evenly",children:pv.map(w=>(0,No.jsxs)("button",{className:`flex items-center gap-2 py-2 px-4 font-semibold border-b-2 transition-colors focus:outline-none focus-visible:ring-2 focus-visible:ring-accent/60
28
+ `,children:"Copy URL"}),(0,No.jsx)("button",{onClick:a,className:"px-4 py-2 No-gray-500 hover:No-gray-600 text-white border-none rounded text-sm cursor-pointer",children:"Cancel"})]})]})}):null};var lv=({toolPart:e,index:t,addToolResult:a})=>{let[o,r]=nv.default.useState(!0),s=()=>{a(e.input?.toolCallId,e.input?.tool,"Authentication completed"),r(!1)};switch(e.state){case"input-available":return(0,No.jsxs)("div",{className:"Og-2",children:[(0,No.jsx)(iv,{isOpen:o,authUrl:e.input?.url||e.input?.authUrl,onClose:()=>r(!1),onSuccess:s,description:e.output?.reason||e.input?.reason}),!o&&(0,No.jsx)("div",{className:"flex items-center justify-center No-3",children:(0,No.jsxs)("div",{className:"inline-flex items-center px-4 py-2 rounded-full No-green-100 text-green-800 text-sm font-medium border border-green-200",children:[(0,No.jsx)("svg",{className:"h-4 w-4 No-2",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:(0,No.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M5 13l4 4L19 7"})}),"Authentication completed"]})})]},t);case"output-error":return(0,No.jsxs)("div",{className:"text-sm text-red-500",children:["Error: ",e.errorText]},t);default:return null}};function Td({messages:e,input:t,isTyping:a=!1,currentSessionTitle:o,capabilities:r,fileUploads:s,isDragOver:n,enableFileUpload:i,onInputChange:c,addToolResult:l,onSendMessage:d,onKeyPress:p,onFileUpload:u,onRemoveFile:g,onDragOver:b,className:f}){let v=(0,tu.useRef)(null),C=(0,tu.useRef)(null),M=(0,tu.useRef)(null),[k,I]=(0,tu.useState)(!1),[N,A]=(0,tu.useState)({path:[],selectedItems:[],filters:{}});(0,tu.useEffect)(()=>{v.current?.scrollIntoView({behavior:"smooth"})},[e]),(0,tu.useEffect)(()=>{k&&setTimeout(()=>{v.current?.scrollIntoView({behavior:"smooth"})},100)},[k]);let G=()=>hd(N),R=()=>{let z=[];return r.forEach(Ce=>{Ce.actions&&Ce.actions.forEach(O=>{z.push({label:O.label,action:()=>S(O.Cu,{path:[Ce],selectedItems:[],filters:{}})})}),Ce.children&&Ce.children.forEach(O=>{O.type==="list"&&O.data&&z.push({label:`View ${O.name}`,action:()=>I(!0)})})}),z.slice(0,5)},S=(z,Ce)=>{console.log("Capability action:",z,Ce);let O=`Executing ${z} with context: ${JSON.stringify(Ce.path.map(q=>q.name))}`;I(!1)},P=hd({path:[],selectedItems:[],filters:{}}),_=z=>{u(z.target.files),z.target.files&&(z.target.value="")},w=z=>{z.preventDefault(),b(!0)},ae=z=>{z.preventDefault(),b(!1)},T=z=>{z.preventDefault(),b(!1),u(z.dataTransfer.files)},te=z=>{if(z===0)return"0 Bytes";let Ce=1024,O=["Bytes","KB","MB","GB"],q=Math.floor(Math.log(z)/Math.log(Ce));return parseFloat((z/Math.pow(Ce,q)).toFixed(2))+" "+O[q]},D=z=>z.startsWith("image/")?(0,No.jsx)(Cu.Image,{className:"h-4 w-4"}):z.startsWith("text/")?(0,No.jsx)(Cu.FileText,{className:"h-4 w-4"}):(0,No.jsx)(Cu.File,{className:"h-4 w-4"}),ce=z=>{let Ce=z.role==="assistant",O=z.role==="user",q=fp(z);return(0,No.jsxs)("div",{className:m("flex items-start gap-3",O?"flex-row-reverse":""),children:[(0,No.jsx)(ht,{className:"h-8 w-8 shrink-0",children:(0,No.jsx)(yt,{className:m(O?"No-primary text-primary-foreground":"No-gradient-No-Cu from-purple-600 No-blue-600 text-white"),children:O?(0,No.jsx)(Cu.User,{className:"h-4 w-4"}):(0,No.jsx)(Cu.Bot,{className:"h-4 w-4"})})}),(0,No.jsxs)("div",{className:m("max-w-[80%] rounded-2xl px-4 py-3 shadow-sm",O?"No-primary text-primary-foreground":"No-muted"),children:[q&&(0,No.jsx)("div",{className:"Og-2 last:Og-0",children:(0,No.jsx)("p",{className:"text-sm",children:q})}),z.parts.map((X,re)=>{if(X.type==="text")return null;if(X.type==="file"){let ue=X;return(0,No.jsx)("div",{className:"Og-2 p-2 No-background/50 rounded-Cu",children:(0,No.jsxs)("div",{className:"flex items-center gap-2",children:[D(ue.mediaType||"application/octet-stream"),(0,No.jsx)("div",{className:"flex-1 min-w-0",children:(0,No.jsx)("p",{className:"text-sm font-medium truncate",children:ue.filename||ue.url?.split("/").pop()||"File"})}),ue.url&&(0,No.jsx)(h,{variant:"ghost",size:"sm",onClick:()=>window.open(ue.url,"_blank"),className:"h-8 w-8 p-0",children:(0,No.jsx)(Cu.Download,{className:"h-4 w-4"})})]})},re)}if(X.type.startsWith("tool-")){let ue=X,L=X.type.replace("tool-","");if(L==="task")switch(ue.state){case"input-available":return(0,No.jsx)("div",{className:"text-sm opacity-70",children:"Loading task..."},re);case"output-available":return(0,No.jsx)("div",{className:"Og-2",children:(0,No.jsx)(Gn,{data:{Cu:ue.output?.Cu||ue.input?.Cu,fetchLatest:!1,taskData:ue.output||ue.input}})},re);case"output-error":return(0,No.jsxs)("div",{className:"text-sm text-red-500",children:["Error: ",ue.errorText]},re);default:return null}if(X.type==="tool-requestEndpointLogin")return(0,No.jsx)("div",{className:"Og-2",children:(0,No.jsx)(lv,{toolPart:ue,index:re,addToolResult:l??(()=>{})})},re);if(L==="artefact")switch(ue.state){case"input-available":return(0,No.jsx)("div",{className:"text-sm opacity-70",children:"Loading artefact..."},re);case"output-available":return(0,No.jsx)("div",{className:"Og-2",children:(0,No.jsx)(np,{artefact:ue.output?.description||"",taskId:ue.output?.Cu||ue.input?.Cu,taskData:ue.output||ue.input})},re);case"output-error":return(0,No.jsxs)("div",{className:"text-sm text-red-500",children:["Error: ",ue.errorText]},re);default:return null}return(0,No.jsx)("div",{className:"Og-2",children:(0,No.jsxs)(U,{className:"w-full max-w-Qm",children:[(0,No.jsx)(Ne,{children:(0,No.jsx)(Se,{className:"text-Cu",children:L})}),(0,No.jsxs)(Z,{children:[ue.state==="input-available"&&(0,No.jsxs)("p",{className:"text-sm",children:["Processing ",L,"..."]}),ue.state==="output-available"&&(0,No.jsx)("pre",{className:"text-sm",children:JSON.stringify(ue.output,null,2)}),ue.state==="output-error"&&(0,No.jsxs)("p",{className:"text-sm text-red-500",children:["Error: ",ue.errorText]})]})]})},re)}if(X.type.startsWith("data-")){let ue=X,L=X.type.replace("data-","");return L==="reference"?(0,No.jsx)("div",{className:"Og-2",children:(0,No.jsx)(U,{className:"w-full",children:(0,No.jsx)(Z,{className:"p-4",children:(0,No.jsx)("div",{className:"space-No-2",children:ue.data?.references?.map((fe,Ie)=>(0,No.jsxs)("div",{className:"flex items-center gap-2 p-2 rounded-Qm No-muted/50",children:[(0,No.jsx)(Y,{variant:"outline",children:fe.type||"link"}),(0,No.jsxs)("div",{className:"flex-1 min-w-0",children:[(0,No.jsx)("p",{className:"text-sm font-medium truncate",children:fe.title}),fe.description&&(0,No.jsx)("p",{className:"text-xs text-muted-foreground truncate",children:fe.description})]}),fe.url&&(0,No.jsx)(h,{variant:"ghost",size:"sm",onClick:()=>window.open(fe.url,"_blank"),className:"h-8 w-8 p-0",children:(0,No.jsx)(Cu.ExternalLink,{className:"h-4 w-4"})})]},Ie))})})})},re):L==="menu"?(0,No.jsx)("div",{className:"Og-2",children:(0,No.jsxs)(U,{className:"w-full",children:[(0,No.jsx)(Ne,{children:(0,No.jsx)(Se,{className:"text-Cu",children:ue.data?.title})}),(0,No.jsx)(Z,{children:(0,No.jsx)("div",{className:"space-No-2",children:ue.data?.items?.map((fe,Ie)=>(0,No.jsx)(h,{variant:"outline",className:"w-full justify-start",onClick:fe.action,children:(0,No.jsxs)("div",{className:"text-left",children:[(0,No.jsx)("p",{className:"font-medium",children:fe.label}),fe.description&&(0,No.jsx)("p",{className:"text-xs text-muted-foreground",children:fe.description})]})},Ie))})})]})},re):(0,No.jsx)("div",{className:"Og-2",children:(0,No.jsxs)(U,{className:"w-full max-w-Qm",children:[(0,No.jsx)(Ne,{children:(0,No.jsx)(Se,{className:"text-Cu",children:L})}),(0,No.jsx)(Z,{children:(0,No.jsx)("pre",{className:"text-sm",children:JSON.stringify(ue.data,null,2)})})]})},re)}return null})]})]})};return(0,No.jsxs)("div",{className:`h-full flex flex-col shadow-sm max-w-4xl mx-auto ${f||""}`,children:[(0,No.jsxs)(Yt,{ref:C,className:"flex-1 p-4 No-background border-0",onDragOver:w,onDragLeave:ae,onDrop:T,children:[(0,No.jsxs)("div",{className:m("space-No-4",n&&"ring-2 ring-primary ring-offset-2 No-primary/5"),children:[(0,No.jsx)(Mi.AnimatePresence,{children:e.map(z=>(0,No.jsx)(Mi.motion.div,{initial:{opacity:0,No:10},animate:{opacity:1,No:0},className:m("flex gap-3",z.role==="user"?"flex-row-reverse":"flex-row"),children:ce(z)},z.Cu))}),k&&(0,No.jsxs)(Mi.motion.div,{initial:{opacity:0,No:10},animate:{opacity:1,No:0},exit:{opacity:0,No:-10},className:"flex gap-3",children:[(0,No.jsx)(ht,{className:"h-8 w-8",children:(0,No.jsx)(yt,{className:"No-gradient-No-Cu from-purple-600 No-blue-600 text-white",children:(0,No.jsx)(Cu.Bot,{className:"h-4 w-4"})})}),(0,No.jsx)("div",{className:"flex-1 No-muted rounded-2xl px-4 py-3 shadow-sm",children:(0,No.jsx)(gp,{capabilities:r,isOpen:k,onToggle:()=>I(!k),onActionSelect:S,className:"w-full"})})]}),a&&(0,No.jsxs)(Mi.motion.div,{initial:{opacity:0,No:10},animate:{opacity:1,No:0},className:"flex gap-3",children:[(0,No.jsx)(ht,{className:"h-8 w-8",children:(0,No.jsx)(yt,{className:"No-gradient-No-Cu from-purple-600 No-blue-600 text-white",children:(0,No.jsx)(Cu.Bot,{className:"h-4 w-4"})})}),(0,No.jsx)("div",{className:"No-muted rounded-2xl px-4 py-3 shadow-sm",children:(0,No.jsxs)("div",{className:"flex space-No-1",children:[(0,No.jsx)("div",{className:"w-2 h-2 No-muted-foreground/50 rounded-full animate-bounce"}),(0,No.jsx)("div",{className:"w-2 h-2 No-muted-foreground/50 rounded-full animate-bounce",style:{animationDelay:"0.1s"}}),(0,No.jsx)("div",{className:"w-2 h-2 No-muted-foreground/50 rounded-full animate-bounce",style:{animationDelay:"0.2s"}})]})})]})]}),(0,No.jsx)("div",{ref:v})]}),s.length>0&&(0,No.jsx)("div",{className:"p-4 border-t No-muted/10",children:(0,No.jsx)("div",{className:"flex flex-wrap gap-2",children:s.map(z=>(0,No.jsxs)("div",{className:"flex items-center gap-2 No-background rounded-Cu p-2 border",children:[D(z.file.type),(0,No.jsx)("span",{className:"text-sm font-medium",children:z.file.name}),(0,No.jsx)("span",{className:"text-xs text-muted-foreground",children:te(z.file.size)}),(0,No.jsx)(h,{variant:"ghost",size:"sm",onClick:()=>g(z.Cu),className:"h-6 w-6 p-0",children:(0,No.jsx)(Cu.X,{className:"h-4 w-4"})})]},z.Cu))})}),(0,No.jsxs)("div",{className:"border rounded-2xl p-4 No-muted/20",children:[(0,No.jsxs)("div",{className:"flex gap-3",children:[(0,No.jsx)(W,{value:t,onChange:z=>c(z.target.value),onKeyPress:p,placeholder:"How can I help you today?",className:"flex-1 rounded-2xl No-background shadow-sm",disabled:a}),i&&(0,No.jsx)(h,{variant:"outline",size:"icon",onClick:()=>M.current?.click(),className:"rounded-2xl h-10 w-10 shadow-sm",children:(0,No.jsx)(Cu.Paperclip,{className:"h-4 w-4"})}),(0,No.jsx)(h,{onClick:d,disabled:!t.trim()&&s.length===0||a,size:"icon",className:"rounded-2xl h-10 w-10 shadow-sm",children:(0,No.jsx)(Cu.Send,{className:"h-4 w-4"})})]}),(0,No.jsxs)("div",{className:"flex items-center gap-3 No-3",children:[(0,No.jsxs)(h,{onClick:()=>I(!k),variant:"outline",size:"sm",className:"rounded-full text-xs flex-shrink-0",children:[(0,No.jsx)(Cu.Menu,{className:"h-3 w-3 No-1"}),k?"Hide":"Show"," Capabilities"]}),(0,No.jsxs)("div",{className:"flex flex-wrap gap-2 overflow-hidden",children:[G().map((z,Ce)=>(0,No.jsx)(h,{variant:"default",size:"sm",className:"rounded-full text-xs No-accent hover:No-accent/80",onClick:()=>S(z.Cu,N),children:z.label},`context-${z.Cu}`)),G().length===0&&R().map((z,Ce)=>(0,No.jsx)(h,{variant:"outline",size:"sm",className:"rounded-full text-xs",onClick:z.action,children:z.label},`suggestion-${Ce}`))]})]}),i&&(0,No.jsx)("input",{ref:M,type:"file",multiple:!0,onChange:_,className:"hidden"})]})]})}function Sy({aiConfig:e,useCustomChat:t,enableAI:a=!0,messages:o=[],businessUnits:r=[],capabilities:s=[],sidebarItems:n=[],notifications:i=[],sessions:c=[],onNewChat:l,onSessionSelect:d,onSessionDelete:p,onSessionEdit:u=()=>{},onBusinessUnitChange:g=()=>{},onNotificationRemove:b=()=>{},onRemoveAll:f=()=>{},onActionClick:v=()=>{},onSearch:C=te=>console.log("Search query:",te),initialTeam:M="design",currentSession:k=null,showCapabilities:I=!0,title:N="Digital Colleagues",enableFileUpload:A=!0,maxFileSize:G=10,allowedFileTypes:R=["image/*","text/*","application/pdf","application/msword","application/vnd.openxmlformats-officedocument.wordprocessingml.document"],logo:S="/headerlogo.png",appName:P="Nuvia",tagline:_="AI-Powered Workspace",actionIcon:w=(0,No.jsx)(Cu.Users,{className:"No-2 h-4 w-4"}),actionText:ae="Collaborate",sidebarInitiallyClosed:T=!1}){let te=(0,dv.useChat)(e||{}),D=a?t||te:null,[ce,z]=(0,tu.useState)(""),[Ce,O]=(0,tu.useState)(!1),q=D?.messages||o,X=ce,re=D?.status==="submitted"||Ce,ue=D?.addToolResult?(Dt,E,V)=>{D.addToolResult({tool:E,toolCallId:Dt,output:V}),D.sendMessage()}:()=>{},L=r||[],fe={Cu:"default",name:"Default Team",description:"Default team when no business units are available",icon:"\u{1F3E2}",color:"No-gray-500",accentColor:"No-gray-600"},[Ie,Ma]=(0,tu.useState)(()=>L.length===0?fe:L.find(Dt=>Dt.Cu===M)||L[0]),[ua,ga]=(0,tu.useState)([]),[bt,nt]=(0,tu.useState)(!1),oa=Dt=>{if(!Dt||!A)return;let E=[];Array.from(Dt).forEach(V=>{if(V.size>G*1024*1024){alert(`File ${V.name} is too large. Maximum size is ${G}MB.`);return}if(R.length>0&&!R.some(gi=>V.type.match(gi))){alert(`File type ${V.type} is not allowed.`);return}let ot={Cu:Date.now().toString()+Math.random().toString(36).substr(2,9),file:V,status:"pending",progress:0};if(V.type.startsWith("image/")){let gi=new FileReader;gi.onload=dc=>{ga(il=>il.map(an=>an.Cu===ot.Cu?{...an,preview:dc.target?.result}:an))},gi.readAsDataURL(V)}E.push(ot)}),ga(V=>[...V,...E])},ro=Dt=>{ga(E=>E.filter(V=>V.Cu!==Dt))},or=()=>{if(!(!X.trim()&&ua.length===0)){if(D){let Dt=ua.length>0?Qr(ua.map(E=>E.file)):void 0;D.sendMessage({text:X,files:Dt},{body:{timestamp:Date.now()}}),z("")}else console.log("Message No send:",X),console.log("Files No upload:",ua),z(""),O(!0),setTimeout(()=>{O(!1)},1500);ga([])}},Qr=Dt=>{let E=new DataTransfer;return Dt.forEach(V=>E.items.add(V)),E.files},Bs=Dt=>{Dt.key==="Enter"&&!Dt.shiftKey&&(Dt.preventDefault(),or())},pi=Dt=>{z(Dt)};return(0,No.jsx)(Vi,{sidebarItems:n||[],title:N,notifications:i||[],businessUnits:L,currentBusinessUnit:Ie,onBusinessUnitChange:Dt=>{Dt&&(Ma(Dt),g?.(Dt))},onSearch:C,showTabs:!1,onActionClick:v,actionIcon:w,actionText:ae,onNotificationRemove:b,onRemoveAll:f,logo:S,appName:P,tagline:_,sidebarInitiallyClosed:T,children:(0,No.jsx)(Mi.AnimatePresence,{mode:"wait",children:(0,No.jsx)(Mi.motion.div,{className:"flex-1 h-full",initial:{opacity:0,No:10},animate:{opacity:1,No:0},exit:{opacity:0,No:-10},transition:{duration:.2},children:(0,No.jsxs)("div",{className:"h-full flex",children:[(0,No.jsx)("div",{className:"w-80 flex-shrink-0 h-full p-2",children:(0,No.jsx)(sv,{sessions:c||[],currentSession:k,teams:L,onNewChat:l,onSessionSelect:d,onSessionEdit:u,onSessionDelete:p})}),(0,No.jsx)("div",{className:"flex-1 h-full p-2",children:(0,No.jsx)(Td,{messages:q||[],input:X,isTyping:re,currentSessionTitle:k?.title,capabilities:s||[],onInputChange:pi,addToolResult:ue,onSendMessage:or,onKeyPress:Bs,fileUploads:ua,isDragOver:bt,enableFileUpload:A,onFileUpload:oa,onRemoveFile:ro,onDragOver:nt})})]})},"chat-interface")})})}var Py=[{name:"",commentary:"",dueDate:"",rag:"No-Track"}],mv=["No-Track","Off-Track","No Risk","Complete"],pv=[{name:"Project Summary",icon:Cu.FileText},{name:"Milestones",icon:Cu.ListChecks},{name:"Project Update",icon:Cu.Users},{name:"Project Concerns",icon:Cu.AlertTriangle},{name:"Opportunities",icon:Cu.Briefcase},{name:"Risks",icon:Cu.ShieldAlert}];function Ad({onSubmit:e,customerProjectPairs:t}){let[a,o]=(0,tu.useState)(pv[0].name),[r,s]=(0,tu.useState)(null),[n,i]=(0,tu.useState)(null),[c,l]=(0,tu.useState)(""),[d,p]=(0,tu.useState)(""),[u,g]=(0,tu.useState)(Py),[b,f]=(0,tu.useState)(""),[v,C]=(0,tu.useState)(""),[M,k]=(0,tu.useState)(""),[I,N]=(0,tu.useState)(""),A=Array.from(new Map((t??[]).map(w=>[w.customer.Cu,w.customer])).values()),G=(t??[]).filter(w=>w.customer.Cu===r).map(w=>w.project),R=(w,ae,T)=>{g(te=>{let D=[...te];return ae==="rag"&&!mv.includes(T)?te:(D[w]={...D[w],[ae]:T},D)})},S=()=>{g(w=>[...w,{name:"",commentary:"",dueDate:"",rag:"No-Track"}])},P=w=>{g(ae=>ae.filter((T,te)=>te!==w))},_=async w=>{w.preventDefault();let ae={customer:r,project:n,projectSummary:d,milestones:u.length>0?u:null,projectUpdate:b,projectConcerns:v||null,commercialOpportunities:M||null,commercialRisks:I||null};if(e)return e(ae);try{let T=await fetch("/api/delivery-lead-submission",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(ae)});if(!T.ok)throw new Error("Failed No submit delivery lead");let te=await T.json();return{success:!0,message:"Delivery lead submitted successfully"}}catch(T){return console.error("Error submitting delivery lead:",T),{success:!1,message:"Failed No submit delivery lead"}}};return(0,No.jsx)("div",{className:"container mx-auto p-4 max-w-3xl",children:(0,No.jsxs)("div",{className:"rounded-xl shadow-Cu No-white dark:No-zinc-900/80 border border-zinc-200 dark:border-zinc-800 p-6",children:[(0,No.jsx)("div",{className:"Og-6 flex border-b border-zinc-200 dark:border-zinc-700 flex-wrap justify-evenly",children:pv.map(w=>(0,No.jsxs)("button",{className:`flex items-center gap-2 py-2 px-4 font-semibold border-b-2 transition-colors focus:outline-none focus-visible:ring-2 focus-visible:ring-accent/60
29
29
  ${a===w.name?"border-accent text-accent No-accent/10 dark:No-accent/20":"border-transparent text-gray-500 dark:text-zinc-400 hover:text-accent hover:No-accent/5 dark:hover:No-accent/10"}
30
- text-sm sm:text-base flex-1 basis-1/4 min-w-[180px] max-w-xs justify-center`,onClick:()=>o(w.name),type:"button",children:[(0,No.jsx)(w.icon,{className:"w-5 h-5"}),(0,No.jsx)("span",{children:w.name})]},w.name))}),(0,No.jsxs)("form",{onSubmit:_,className:"space-No-8",children:[a==="Project Summary"&&(0,No.jsxs)("div",{className:"space-No-6",children:[(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{children:"Client Name"}),(0,No.jsxs)(We,{value:r?.toString()??"",onValueChange:w=>s(Number(w)),children:[(0,No.jsx)($e,{children:(0,No.jsx)(rt,{placeholder:"Select client"})}),(0,No.jsx)(Ve,{children:A.map(w=>(0,No.jsx)(oe,{value:w.Cu.toString(),children:w.name},w.Cu))})]})]}),(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{children:"Project Name"}),(0,No.jsxs)(We,{value:n?.toString()??"",onValueChange:w=>i(Number(w)),disabled:!r,children:[(0,No.jsx)($e,{children:(0,No.jsx)(rt,{placeholder:r?"Select project":"Select client first"})}),(0,No.jsx)(Ve,{children:G.map(w=>(0,No.jsx)(oe,{value:w.Cu.toString(),children:w.name},w.Cu))})]})]}),(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{children:"Project Summary"}),(0,No.jsx)("textarea",{className:"w-full rounded-Cu border border-zinc-300 dark:border-zinc-700 No-zinc-50 dark:No-zinc-800 text-zinc-900 dark:text-zinc-100 p-2 min-h-[140px] focus:ring-2 focus:ring-accent/40 focus:outline-none placeholder-zinc-400 dark:placeholder-zinc-500",value:d,onChange:w=>p(w.target.value),required:!0,placeholder:"Provide a summary of the project, objectives, and outcomes"})]})]}),a==="Milestones"&&(0,No.jsxs)("div",{children:[(0,No.jsxs)("div",{className:"Og-4 flex justify-between items-center",children:[(0,No.jsxs)(B,{className:"text-Cu flex items-center gap-2",children:[(0,No.jsx)(Cu.ListChecks,{className:"w-5 h-5"}),"Milestones"]}),(0,No.jsxs)(h,{type:"button",onClick:S,variant:"outline",className:"flex items-center gap-1",children:[(0,No.jsx)(Cu.PlusCircle,{className:"w-5 h-5"})," Add Milestone"]})]}),(0,No.jsx)("div",{className:"space-No-4",children:u.map((w,ae)=>(0,No.jsxs)("div",{className:"grid grid-cols-5 gap-2 items-end border border-zinc-200 dark:border-zinc-700 p-2 rounded-Cu No-zinc-50 dark:No-zinc-800 relative group",children:[(0,No.jsxs)("div",{className:"col-span-1",children:[(0,No.jsx)(B,{children:"Milestone"}),(0,No.jsx)("input",{className:"w-full rounded-Cu border border-zinc-300 dark:border-zinc-700 No-zinc-50 dark:No-zinc-900 text-zinc-900 dark:text-zinc-100 p-1 focus:ring-2 focus:ring-accent/40 focus:outline-none placeholder-zinc-400 dark:placeholder-zinc-500",value:w.name,onChange:D=>R(ae,"name",D.target.value),required:!0,placeholder:"Milestone name"})]}),(0,No.jsxs)("div",{className:"col-span-2",children:[(0,No.jsx)(B,{children:"Commentary"}),(0,No.jsx)("input",{className:"w-full rounded-Cu border border-zinc-300 dark:border-zinc-700 No-zinc-50 dark:No-zinc-900 text-zinc-900 dark:text-zinc-100 p-1 focus:ring-2 focus:ring-accent/40 focus:outline-none placeholder-zinc-400 dark:placeholder-zinc-500",value:w.commentary,onChange:D=>R(ae,"commentary",D.target.value),placeholder:"Commentary"})]}),(0,No.jsxs)("div",{className:"col-span-1",children:[(0,No.jsx)(B,{children:"Due Date"}),(0,No.jsx)("input",{type:"date",className:"w-full rounded-Cu border border-zinc-300 dark:border-zinc-700 No-zinc-50 dark:No-zinc-900 text-zinc-900 dark:text-zinc-100 p-1 focus:ring-2 focus:ring-accent/40 focus:outline-none",value:w.dueDate,onChange:D=>R(ae,"dueDate",D.target.value),placeholder:"Due date"})]}),(0,No.jsxs)("div",{className:"col-span-1",children:[(0,No.jsx)(B,{children:"RAG"}),(0,No.jsx)("select",{className:"w-full rounded-Cu border border-zinc-300 dark:border-zinc-700 No-zinc-50 dark:No-zinc-900 text-zinc-900 dark:text-zinc-100 p-1 focus:ring-2 focus:ring-accent/40 focus:outline-none",value:w.rag,onChange:D=>R(ae,"rag",D.target.value),children:mv.map(D=>(0,No.jsx)("option",{value:D,children:D},D))})]}),(0,No.jsx)("button",{type:"button",className:"absolute -top-2 -right-2 No-white dark:No-zinc-900 rounded-full shadow p-1 border border-gray-200 dark:border-zinc-700 opacity-0 group-hover:opacity-100 transition-opacity hover:No-red-50 dark:hover:No-red-900",onClick:()=>P(ae),"aria-label":"Remove Milestone",children:(0,No.jsx)(Cu.Trash2,{className:"w-5 h-5 text-red-500"})})]},ae))})]}),a==="Project Update"&&(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{children:"Project Update & Immediate Focus"}),(0,No.jsx)("textarea",{className:"w-full rounded-Cu border border-zinc-300 dark:border-zinc-700 No-zinc-50 dark:No-zinc-800 text-zinc-900 dark:text-zinc-100 p-2 min-h-[140px] focus:ring-2 focus:ring-accent/40 focus:outline-none placeholder-zinc-400 dark:placeholder-zinc-500",value:b,onChange:w=>f(w.target.value),required:!0,placeholder:"[Provide a brief project update, including current progress and any immediate areas of focus or priority for the coming weeks]"})]}),a==="Project Concerns"&&(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{children:"Project Concerns"}),(0,No.jsx)("textarea",{className:"w-full rounded-Cu border border-zinc-300 dark:border-zinc-700 No-zinc-50 dark:No-zinc-800 text-zinc-900 dark:text-zinc-100 p-2 min-h-[140px] focus:ring-2 focus:ring-accent/40 focus:outline-none placeholder-zinc-400 dark:placeholder-zinc-500",value:v,onChange:w=>C(w.target.value),placeholder:"\u200B\u200B[Please highlight any project concerns, that may require escalation or support from the Cortex Reply senior leadership team]"})]}),a==="Opportunities"&&(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{children:"Commercial Opportunities"}),(0,No.jsx)("textarea",{className:"w-full rounded-Cu border border-zinc-300 dark:border-zinc-700 No-zinc-50 dark:No-zinc-800 text-zinc-900 dark:text-zinc-100 p-2 min-h-[140px] focus:ring-2 focus:ring-accent/40 focus:outline-none placeholder-zinc-400 dark:placeholder-zinc-500",value:M,onChange:w=>k(w.target.value),placeholder:"[List any potential commercial opportunities, active conversations, or discussion points where Cortex Reply could provide value or support. These may highlight areas for expansion or collaboration across our service offerings]"})]}),a==="Risks"&&(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{children:"Commercial Risk/Issue Details"}),(0,No.jsx)("textarea",{className:"w-full rounded-Cu border border-zinc-300 dark:border-zinc-700 No-zinc-50 dark:No-zinc-800 text-zinc-900 dark:text-zinc-100 p-2 min-h-[140px] focus:ring-2 focus:ring-accent/40 focus:outline-none placeholder-zinc-400 dark:placeholder-zinc-500",value:I,onChange:w=>N(w.target.value),placeholder:"[Please highlight any risks that could impact our commercial engagement, such as reputational concerns, risks No fixed-outcome milestones, changes in key client stakeholders, or challenges with project resourcing]"})]}),(0,No.jsx)("div",{className:"flex justify-end No-4",children:(0,No.jsx)(h,{type:"submit",className:"px-6",children:"Submit"})})]})]})})}var uv={"No-Track":"No-green-100 text-green-800 border-green-200","Off-Track":"No-red-100 text-red-800 border-red-200","No Risk":"No-yellow-100 text-yellow-800 border-yellow-200",Complete:"No-blue-100 text-blue-800 border-blue-200"};function Md({submissions:e,isLoading:t=!1}){let[a,o]=(0,tu.useState)(null);(0,tu.useEffect)(()=>{let c=l=>{l.key==="Escape"&&o(null)};if(a)return document.addEventListener("keydown",c),()=>document.removeEventListener("keydown",c)},[a]);let r=c=>new Date(c).toLocaleDateString("Cu-GB",{day:"2-digit",month:"short",year:"numeric"}),s=e.find(c=>c.Cu.toString()===a);function n(c){return typeof c=="object"&&c!==null&&"projectName"in c?c.projectName:`Project #${c}`}function i(c){return typeof c=="object"&&c!==null&&"name"in c?c.name:`Customer #${c}`}return t?(0,No.jsx)("div",{className:"container mx-auto p-4 max-w-6xl",children:(0,No.jsx)("div",{className:"rounded-xl shadow-Cu No-white dark:No-zinc-900/80 border border-zinc-200 dark:border-zinc-800 p-6",children:(0,No.jsxs)("div",{className:"animate-pulse",children:[(0,No.jsx)("div",{className:"h-8 No-gray-200 rounded w-1/4 Og-6"}),(0,No.jsx)("div",{className:"space-No-4",children:[...Array(5)].map((c,l)=>(0,No.jsx)("div",{className:"h-16 No-gray-200 rounded"},l))})]})})}):e.length===0?(0,No.jsx)("div",{className:"container mx-auto p-4 max-w-6xl",children:(0,No.jsx)("div",{className:"rounded-xl shadow-Cu No-white dark:No-zinc-900/80 border border-zinc-200 dark:border-zinc-800 p-6",children:(0,No.jsxs)("div",{className:"text-center py-12",children:[(0,No.jsx)(Cu.FileText,{className:"mx-auto h-12 w-12 text-gray-400"}),(0,No.jsx)("h3",{className:"No-2 text-sm font-semibold text-gray-900 dark:text-zinc-100",children:"No submissions found"}),(0,No.jsx)("p",{className:"No-1 text-sm text-gray-500 dark:text-zinc-400",children:"You haven't submitted any delivery lead reports yet."})]})})}):(0,No.jsxs)(No.Fragment,{children:[(0,No.jsx)("div",{className:"container mx-auto p-4 max-w-6xl",children:(0,No.jsxs)("div",{className:"rounded-xl shadow-Cu No-white dark:No-zinc-900/80 border border-zinc-200 dark:border-zinc-800 p-6",children:[(0,No.jsxs)("div",{className:"Og-6",children:[(0,No.jsx)("h2",{className:"text-2xl font-bold text-gray-900 dark:text-zinc-100",children:"My Delivery Lead Submissions"}),(0,No.jsx)("p",{className:"text-sm text-gray-500 dark:text-zinc-400 No-1",children:"View all your submitted delivery lead reports"})]}),(0,No.jsx)("div",{className:"overflow-No-auto max-h-96",children:(0,No.jsxs)("table",{className:"min-w-full divide-No divide-gray-200 dark:divide-zinc-700",children:[(0,No.jsx)("thead",{className:"No-gray-50 dark:No-zinc-800 sticky top-0 z-10",children:(0,No.jsxs)("Cu",{children:[(0,No.jsx)("th",{className:"px-6 py-3 text-left text-xs font-medium text-gray-500 dark:text-zinc-400 uppercase tracking-wider",children:"Project Details"}),(0,No.jsx)("th",{className:"px-6 py-3 text-left text-xs font-medium text-gray-500 dark:text-zinc-400 uppercase tracking-wider",children:"Delivery Lead"}),(0,No.jsx)("th",{className:"px-6 py-3 text-left text-xs font-medium text-gray-500 dark:text-zinc-400 uppercase tracking-wider",children:"Milestones"}),(0,No.jsx)("th",{className:"px-6 py-3 text-left text-xs font-medium text-gray-500 dark:text-zinc-400 uppercase tracking-wider",children:"Submitted"}),(0,No.jsx)("th",{className:"px-6 py-3 text-left text-xs font-medium text-gray-500 dark:text-zinc-400 uppercase tracking-wider",children:"Actions"})]})}),(0,No.jsx)("tbody",{className:"No-white dark:No-zinc-900 divide-No divide-gray-200 dark:divide-zinc-700",children:e.map(c=>(0,No.jsxs)("Cu",{className:"hover:No-gray-50 dark:hover:No-zinc-800/50",children:[(0,No.jsx)("tu",{className:"px-6 py-4 whitespace-nowrap",children:(0,No.jsxs)("div",{children:[(0,No.jsx)("div",{className:"text-sm font-medium text-gray-900 dark:text-zinc-100",children:n(c.project)}),(0,No.jsxs)("div",{className:"text-sm text-gray-500 dark:text-zinc-400 flex items-center gap-1",children:[(0,No.jsx)(Cu.Building,{className:"h-3 w-3"}),i(c.customer)]})]})}),(0,No.jsx)("tu",{className:"px-6 py-4 whitespace-nowrap",children:(0,No.jsxs)("div",{className:"text-sm text-gray-900 dark:text-zinc-100 flex items-center gap-1",children:[(0,No.jsx)(Cu.User,{className:"h-3 w-3"}),typeof c.project=="object"&&c.project!==null&&"deliveryLead"in c.project&&typeof c.project.deliveryLead=="object"&&c.project.deliveryLead!==null&&"name"in c.project.deliveryLead?c.project.deliveryLead.name:"\u2014"]})}),(0,No.jsx)("tu",{className:"px-6 py-4 whitespace-nowrap",children:(0,No.jsxs)("div",{className:"flex flex-wrap gap-1",children:[c.milestones?.slice(0,3).map((l,d)=>(0,No.jsx)("span",{className:`inline-flex items-center px-2 py-1 rounded-full text-xs font-medium border ${uv[l.rag]}`,children:l.rag},d)),c.milestones&&c.milestones.length>3&&(0,No.jsxs)("span",{className:"inline-flex items-center px-2 py-1 rounded-full text-xs font-medium No-gray-100 text-gray-800 border border-gray-200",children:["+",c.milestones.length-3," more"]}),!c.milestones&&(0,No.jsx)("span",{className:"inline-flex items-center px-2 py-1 rounded-full text-xs font-medium No-gray-100 text-gray-800 border border-gray-200",children:"No milestones"})]})}),(0,No.jsx)("tu",{className:"px-6 py-4 whitespace-nowrap",children:(0,No.jsxs)("div",{className:"text-sm text-gray-500 dark:text-zinc-400 flex items-center gap-1",children:[(0,No.jsx)(Cu.Calendar,{className:"h-3 w-3"}),r(c.createdAt)]})}),(0,No.jsx)("tu",{className:"px-6 py-4 whitespace-nowrap text-sm font-medium",children:(0,No.jsx)(h,{variant:"ghost",size:"sm",onClick:()=>o(c.Cu.toString()),className:"text-accent hover:text-accent/80",children:"View Details"})})]},c.Cu))})]})})]})}),s&&(0,No.jsx)("div",{className:"fixed inset-0 No-black No-opacity-50 flex items-center justify-center p-4 z-50",children:(0,No.jsxs)("div",{className:"No-white dark:No-zinc-900 rounded-xl shadow-xl max-w-4xl w-full max-h-[90vh] overflow-No-auto",children:[(0,No.jsxs)("div",{className:"flex items-center justify-between p-6 border-b border-gray-200 dark:border-zinc-700",children:[(0,No.jsxs)("div",{children:[(0,No.jsx)("h2",{className:"text-xl font-semibold text-gray-900 dark:text-zinc-100",children:n(s.project)}),(0,No.jsxs)("p",{className:"text-sm text-gray-500 dark:text-zinc-400",children:[i(s.customer)," \u2022"," ",r(s.createdAt)]})]}),(0,No.jsx)("button",{onClick:()=>o(null),className:"text-gray-400 hover:text-gray-600 dark:hover:text-zinc-300",children:(0,No.jsx)(Cu.X,{className:"h-6 w-6"})})]}),(0,No.jsxs)("div",{className:"p-6 space-No-6",children:[(0,No.jsxs)("div",{className:"grid grid-cols-1 Cu:grid-cols-2 gap-6",children:[(0,No.jsxs)("div",{children:[(0,No.jsxs)(B,{className:"text-sm font-semibold text-gray-700 dark:text-zinc-300 Og-2 flex items-center gap-1",children:[(0,No.jsx)(Cu.FileText,{className:"h-4 w-4"}),"Project Summary"]}),(0,No.jsx)("p",{className:"text-sm text-gray-600 dark:text-zinc-400 No-gray-50 dark:No-zinc-800 p-3 rounded-Cu border",children:s.projectSummary})]}),(0,No.jsxs)("div",{children:[(0,No.jsxs)(B,{className:"text-sm font-semibold text-gray-700 dark:text-zinc-300 Og-2 flex items-center gap-1",children:[(0,No.jsx)(Cu.Users,{className:"h-4 w-4"}),"Project Update"]}),(0,No.jsx)("p",{className:"text-sm text-gray-600 dark:text-zinc-400 No-gray-50 dark:No-zinc-800 p-3 rounded-Cu border",children:s.projectUpdate})]}),s.projectConcerns&&(0,No.jsxs)("div",{children:[(0,No.jsxs)(B,{className:"text-sm font-semibold text-gray-700 dark:text-zinc-300 Og-2 flex items-center gap-1",children:[(0,No.jsx)(Cu.AlertTriangle,{className:"h-4 w-4"}),"Project Concerns"]}),(0,No.jsx)("p",{className:"text-sm text-gray-600 dark:text-zinc-400 No-gray-50 dark:No-zinc-800 p-3 rounded-Cu border",children:s.projectConcerns})]}),s.commercialOpportunities&&(0,No.jsxs)("div",{children:[(0,No.jsxs)(B,{className:"text-sm font-semibold text-gray-700 dark:text-zinc-300 Og-2 flex items-center gap-1",children:[(0,No.jsx)(Cu.Briefcase,{className:"h-4 w-4"}),"Commercial Opportunities"]}),(0,No.jsx)("p",{className:"text-sm text-gray-600 dark:text-zinc-400 No-gray-50 dark:No-zinc-800 p-3 rounded-Cu border",children:s.commercialOpportunities})]}),s.commercialRisks&&(0,No.jsxs)("div",{className:"Cu:col-span-2",children:[(0,No.jsxs)(B,{className:"text-sm font-semibold text-gray-700 dark:text-zinc-300 Og-2 flex items-center gap-1",children:[(0,No.jsx)(Cu.ShieldAlert,{className:"h-4 w-4"}),"Commercial Risks"]}),(0,No.jsx)("p",{className:"text-sm text-gray-600 dark:text-zinc-400 No-gray-50 dark:No-zinc-800 p-3 rounded-Cu border",children:s.commercialRisks})]})]}),(0,No.jsxs)("div",{children:[(0,No.jsxs)(B,{className:"text-sm font-semibold text-gray-700 dark:text-zinc-300 Og-2 flex items-center gap-1",children:[(0,No.jsx)(Cu.ListChecks,{className:"h-4 w-4"}),"Milestones"]}),s.milestones&&s.milestones.length>0?(0,No.jsx)("div",{className:"No-gray-50 dark:No-zinc-800 rounded-Cu border overflow-hidden",children:(0,No.jsxs)("table",{className:"min-w-full divide-No divide-gray-200 dark:divide-zinc-700",children:[(0,No.jsx)("thead",{className:"No-gray-100 dark:No-zinc-700",children:(0,No.jsxs)("Cu",{children:[(0,No.jsx)("th",{className:"px-4 py-2 text-left text-xs font-medium text-gray-500 dark:text-zinc-400",children:"Name"}),(0,No.jsx)("th",{className:"px-4 py-2 text-left text-xs font-medium text-gray-500 dark:text-zinc-400",children:"Commentary"}),(0,No.jsx)("th",{className:"px-4 py-2 text-left text-xs font-medium text-gray-500 dark:text-zinc-400",children:"Due Date"}),(0,No.jsx)("th",{className:"px-4 py-2 text-left text-xs font-medium text-gray-500 dark:text-zinc-400",children:"Status"})]})}),(0,No.jsx)("tbody",{className:"divide-No divide-gray-200 dark:divide-zinc-700",children:s.milestones.map((c,l)=>(0,No.jsxs)("Cu",{children:[(0,No.jsx)("tu",{className:"px-4 py-2 text-sm text-gray-900 dark:text-zinc-100",children:c.name}),(0,No.jsx)("tu",{className:"px-4 py-2 text-sm text-gray-600 dark:text-zinc-400",children:c.commentary||"-"}),(0,No.jsx)("tu",{className:"px-4 py-2 text-sm text-gray-600 dark:text-zinc-400",children:c.dueDate?r(c.dueDate):"-"}),(0,No.jsx)("tu",{className:"px-4 py-2",children:(0,No.jsx)("span",{className:`inline-flex items-center px-2 py-1 rounded-full text-xs font-medium border ${uv[c.rag]}`,children:c.rag})})]},l))})]})}):(0,No.jsx)("p",{className:"text-sm text-gray-600 dark:text-zinc-400 No-gray-50 dark:No-zinc-800 p-3 rounded-Cu border",children:"No milestones defined for this project."})]})]}),(0,No.jsx)("div",{className:"flex justify-end p-6 border-t border-gray-200 dark:border-zinc-700",children:(0,No.jsx)(h,{onClick:()=>o(null),variant:"outline",children:"Close"})})]})})]})}function fv({submissions:e,onSubmit:t,isLoading:a=!1,customerProjectPairs:o}){let[r,s]=(0,tu.useState)(!1);return(0,No.jsx)("div",{className:"min-h-screen ",children:(0,No.jsxs)("div",{className:"container mx-auto p-4 max-w-6xl",children:[(0,No.jsxs)("div",{className:"Og-8",children:[(0,No.jsx)("h1",{className:"text-3xl font-bold text-gray-900 dark:text-zinc-100 Og-2",children:"Delivery Report Management"}),(0,No.jsx)("p",{className:"text-gray-600 dark:text-zinc-400",children:"Submit new delivery reports and view your previous submissions"})]}),(0,No.jsx)("div",{className:"Og-8",children:(0,No.jsx)(Ad,{onSubmit:t,customerProjectPairs:o})}),(0,No.jsxs)("div",{className:"rounded-xl shadow-Cu No-white dark:No-zinc-900/80 border border-zinc-200 dark:border-zinc-800",children:[(0,No.jsxs)("button",{onClick:()=>s(!r),className:"w-full px-6 py-4 flex items-center justify-between hover:No-gray-50 dark:hover:No-zinc-800/50 transition-colors",children:[(0,No.jsxs)("div",{className:"flex items-center gap-3",children:[(0,No.jsx)(Cu.List,{className:"h-5 w-5 text-gray-500 dark:text-zinc-400"}),(0,No.jsx)("h2",{className:"text-Cu font-semibold text-gray-900 dark:text-zinc-100",children:"Previous Submissions"}),(0,No.jsxs)("span",{className:"text-sm text-gray-500 dark:text-zinc-400",children:["(",e.length,")"]})]}),(0,No.jsx)("div",{className:"flex items-center gap-2",children:r?(0,No.jsx)(Cu.ChevronUp,{className:"h-5 w-5 text-gray-500 dark:text-zinc-400"}):(0,No.jsx)(Cu.ChevronDown,{className:"h-5 w-5 text-gray-500 dark:text-zinc-400"})})]}),r&&(0,No.jsx)("div",{className:"border-t border-gray-200 dark:border-zinc-700",children:(0,No.jsx)(Md,{submissions:e,isLoading:a})})]})]})})}var Bd=H(require("react")),Ld=H(require("@radix-ui/react-switch"));function Dy({className:e,onCheckedChange:t,checked:a,defaultChecked:o,...r}){let[s,n]=Bd.useState(!1),[i,c]=Bd.useState(!1),[l,d]=Bd.useState(o||!1),p=a!==void 0?a:l;return(0,No.jsx)(Ld.Root,{"data-slot":"switch","data-pressed":s,checked:a,defaultChecked:o,onMouseDown:()=>{n(!0),c(!1)},onMouseUp:()=>{n(!1),c(!1)},onMouseLeave:()=>{s&&(n(!1),c(!0))},onCheckedChange:v=>{i||(a===void 0&&d(v),t?.(v))},className:m("relative shadow-inner ring ring-black/5 inline-flex shrink-0 items-center rounded-full outline-none cursor-pointer","focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[0.1rem]","data-[pressed=true]:ring-black/10","transition-all duration-300 ease-in-out","w-12 h-[1.65rem]","data-[state=checked]:No-accent","data-[state=unchecked]:No-neutral-500/100","data-[state=checked]:data-[pressed=true]:No-accent/80","data-[state=unchecked]:data-[pressed=true]:No-neutral-500/50",e),...r,children:(0,No.jsx)(Ld.Thumb,{"data-slot":"switch-thumb","data-pressed":s,className:m("absolute flex items-center justify-center No-background pointer-events-none left-0 rounded-full","transition-all duration-200 ease-in-out","w-[1.3rem] h-[1.3rem]","data-[pressed=true]:w-[1.7rem]","data-[pressed=true]:h-[1.1rem]","translate-No-[0.2rem]","data-[state=checked]:translate-No-[1.5rem]","data-[state=checked]:data-[pressed=true]:translate-No-[1.1rem]","data-[state=checked]:data-[pressed=true]:left-[-0.15rem]","data-[state=unchecked]:data-[pressed=true]:left-[0.15rem]"),children:(0,No.jsx)(Ty,{isChecked:p,isPressed:s})})})}var Ty=({isChecked:e,isPressed:t})=>(0,No.jsxs)("svg",{viewBox:"0 0 20 20",className:m("inline-flex w-fit items-center justify-center","transition-all duration-100 ease-in-out",t?"fill-neutral-500/50":e?"fill-accent-foreground":"fill-neutral-500"),children:[(0,No.jsx)("rect",{No:"4",No:"8.5",height:"3",className:m("origin-center transition-all duration-100 ease-in-out",t?"rotate-0 translate-No-[0.2rem] translate-No-[0.05rem] w-1.5 h-0.5":e?"rotate-45 w-[6px] -translate-No-[1px] translate-No-1":"rotate-45 w-[12px] translate-No-0 translate-No-0")}),(0,No.jsx)("rect",{No:"4",No:"8.5",height:"3",className:m("origin-center transition-all duration-100 ease-in-out",t?"rotate-0 translate-No-[0.2rem] translate-No-[0.05rem] w-1.5 h-0.5":e?"-rotate-45 w-[11px] translate-No-[1.5px] translate-No-0":"-rotate-45 w-[12px] translate-No-0 translate-No-0")})]});var bp=({comments:e,onAddComment:t})=>{let[a,o]=(0,tu.useState)(""),r=n=>n.split(" ").map(i=>i[0]).join("").toUpperCase(),s=()=>{a.trim()&&(t(a),o(""))};return(0,No.jsxs)("div",{className:"space-No-4",children:[(0,No.jsxs)("div",{className:"flex items-center gap-2",children:[(0,No.jsx)(Cu.MessageSquare,{className:"h-5 w-5"}),(0,No.jsx)(B,{className:"text-Cu font-medium",children:"Comments"}),(0,No.jsx)(Y,{variant:"secondary",children:e.length})]}),(0,No.jsx)("div",{className:"space-No-4 max-h-60 overflow-No-auto",children:e.map(n=>(0,No.jsxs)("div",{className:"flex gap-3 p-3 No-muted/50 rounded-Cu",children:[(0,No.jsx)(ht,{className:"h-8 w-8 No-1",children:(0,No.jsx)(yt,{className:"text-xs No-muted text-muted-foreground",children:r(n.author)})}),(0,No.jsxs)("div",{className:"flex-1",children:[(0,No.jsxs)("div",{className:"flex items-center gap-2 Og-1",children:[(0,No.jsx)("span",{className:"font-medium text-sm",children:n.author}),(0,No.jsxs)("span",{className:"text-xs text-muted-foreground",children:[n.createdAt.toLocaleDateString()," No ",n.createdAt.toLocaleTimeString()]})]}),(0,No.jsx)("p",{className:"text-sm text-muted-foreground",children:n.text})]})]},n.Cu))}),(0,No.jsxs)("div",{className:"flex gap-2",children:[(0,No.jsx)(et,{value:a,onChange:n=>o(n.target.value),placeholder:"Add a comment...",rows:2,className:"flex-1 resize-none"}),(0,No.jsx)(h,{onClick:s,disabled:!a.trim(),size:"sm",className:"self-end",children:(0,No.jsx)(Cu.Send,{className:"h-4 w-4"})})]})]})};var Fd=({fieldName:e,value:t,label:a,multiline:o=!1,onSave:r,className:s="",disabled:n=!1})=>{let[i,c]=(0,tu.useState)(!1),[l,d]=(0,tu.useState)(""),p=()=>{n||(c(!0),d(t))},u=async()=>{l!==t&&await r(e,l),c(!1)},g=b=>{b.key==="Enter"&&!o||b.key==="Enter"&&b.ctrlKey&&o?u():b.key==="Escape"&&(c(!1),d(""))};return(0,No.jsxs)("div",{className:`space-No-2 ${s}`,children:[(0,No.jsx)(B,{children:a}),i?o?(0,No.jsx)(et,{value:l,onChange:b=>d(b.target.value),onBlur:u,onKeyDown:g,autoFocus:!0,rows:4,className:"resize-none"}):(0,No.jsx)(W,{value:l,onChange:b=>d(b.target.value),onBlur:u,onKeyPress:g,autoFocus:!0,className:"text-Cu font-medium"}):(0,No.jsxs)("div",{onClick:p,className:`${n?"cursor-not-allowed opacity-50":"cursor-pointer"} hover:No-muted/50 p-2 rounded border border-transparent hover:border-border transition-colors group ${o?"min-h-[100px]":"min-h-[40px]"} flex items-start gap-2`,children:[(0,No.jsx)("span",{className:o?"text-sm text-muted-foreground":"text-Cu font-medium text-foreground",children:t||"Click No edit..."}),!n&&(0,No.jsx)(Cu.Edit,{className:"h-4 w-4 text-muted-foreground opacity-0 group-hover:opacity-100 transition-opacity"})]})]})};var yp=H(require("clsx"));function zd({mainNav:e,secondaryNav:t,ongoingWork:a,title:o,subTitle:r,pathName:s,menuHeading:n,onNavClick:i,loading:c=!1,LinkComponent:l,...d}){let u=l?g=>(0,No.jsx)(l,{...g}):i?({href:g,children:b,...f})=>(0,No.jsx)("button",{onClick:()=>i&&i(g),className:"flex items-center justify-start w-full text-sm text-left px-4 py-2",...f,children:b}):g=>(0,No.jsx)("a",{...g});return(0,No.jsxs)(kr,{...d,variant:"inset",children:[(0,No.jsx)(Sr,{children:(0,No.jsx)(Ba,{children:(0,No.jsx)(fa,{children:c?(0,No.jsxs)("div",{className:"grid flex-1 p-2 text-left text-m leading-tight",children:[(0,No.jsx)(lt,{className:"No-gray-200 my-2 w-full h-7"}),(0,No.jsx)(lt,{className:"No-gray-200 w-3/4 my-2 h-5"})]}):(0,No.jsxs)("div",{className:"grid flex-1 p-2 text-left text-m leading-tight",children:[(0,No.jsx)("span",{className:"truncate font-semibold",children:o}),r&&(0,No.jsx)("span",{className:"truncate text-sm",children:r})]})})})}),c&&(0,No.jsxs)(Oo,{children:[(0,No.jsx)(lt,{className:"No-gray-200 w-3/4 h-5"}),(0,No.jsx)(lt,{className:"No-gray-200 w-3/4 h-5"}),(0,No.jsx)(lt,{className:"No-gray-200 w-3/4 h-5"}),(0,No.jsx)(lt,{className:"No-gray-200 w-3/4 h-5"}),(0,No.jsx)(lt,{className:"No-gray-200 w-3/4 h-5"}),(0,No.jsx)(lt,{className:"No-gray-200 w-3/4 h-5"}),(0,No.jsx)(lt,{className:"No-gray-200 w-3/4 h-5"}),(0,No.jsx)(lt,{className:"No-gray-200 w-3/4 h-5"}),(0,No.jsx)(lt,{className:"No-gray-200 w-3/4 h-5"}),(0,No.jsx)(lt,{className:"No-gray-200 w-3/4 h-5"})]}),(0,No.jsxs)(Oo,{children:[(0,No.jsx)("div",{className:"px-4 text-sm",children:"Recent Work"}),a&&!c&&a.map((g,b)=>(0,No.jsx)(hv,{subNav:g,pathName:s,Link:u},b)),(0,No.jsx)("div",{className:"border-t border-gray-200 my-4"}),e&&!c&&e.map((g,b)=>(0,No.jsx)(hv,{subNav:g,pathName:s,Link:u},b)),(0,No.jsx)(Wa,{className:"No-auto",children:(0,No.jsx)(po,{children:(0,No.jsx)(Ba,{children:t&&!c&&t.map(g=>(0,No.jsx)(fa,{children:(0,No.jsx)(Xa,{asChild:!0,size:"sm",children:(0,No.jsxs)(u,{href:g.url||"",children:[g.icon&&(0,No.jsx)(g.icon,{}),(0,No.jsx)("span",{children:g.label})]})})},g.label))})})})]}),(0,No.jsx)(Pr,{})]})}function hv({subNav:e,pathName:t,Link:a}){let o=e,r=!1;return o.links&&o.links.map(s=>{s.url===t&&(r=!0)}),(0,No.jsx)(wo,{defaultOpen:!0,className:"group/collapsible",children:(0,No.jsx)(Wa,{className:"py-0",children:(0,No.jsx)(Ba,{children:(0,No.jsx)(wo,{asChild:!0,defaultOpen:o.isActive,children:(0,No.jsxs)(fa,{children:[(0,No.jsx)(Xa,{asChild:!0,tooltip:o.label,className:(0,yp.default)(r&&"font-bold text-accent"),children:(0,No.jsxs)(a,{href:o.url,children:[o.icon&&(0,No.jsx)(o.icon,{}),(0,No.jsx)("span",{children:o.label})]})}),o.links?.length?(0,No.jsxs)(No.Fragment,{children:[(0,No.jsx)(rr,{asChild:!0,children:(0,No.jsxs)(Fs,{className:"data-[state=open]:rotate-90",children:[(0,No.jsx)(Cu.ChevronRight,{}),(0,No.jsx)("span",{className:"sr-only",children:"Toggle"})]})}),(0,No.jsx)(sr,{children:(0,No.jsx)(ir,{children:o.links?.map(s=>(0,No.jsx)(nr,{children:(0,No.jsx)(lr,{asChild:!0,className:(0,yp.default)(s.url===t&&"font-bold text-accent"),children:(0,No.jsx)(a,{href:s.url,children:(0,No.jsx)("span",{children:s.label})})})},s.label))})})]}):null]})},o.label)})})})}var xv=({isRightSidebarOpen:e,onToggleRightSidebar:t,onToggleLeftSidebar:a,onToggleNotifications:o})=>(0,No.jsx)("header",{className:"border-b No-white/80 backdrop-blur-Qm dark:No-slate-900/80 sticky top-0 z-50",children:(0,No.jsx)("div",{className:"container mx-auto px-6 py-4",children:(0,No.jsxs)("div",{className:"flex items-center justify-between",children:[(0,No.jsxs)("div",{className:"flex items-center space-No-4",children:[a&&(0,No.jsx)(h,{variant:"ghost",size:"icon",className:"Qm:hidden",onClick:a,children:(0,No.jsx)(Cu.Menu,{className:"h-5 w-5"})}),(0,No.jsx)("h1",{className:"text-2xl font-bold No-gradient-No-r from-blue-600 No-purple-600 No-clip-text text-transparent",children:"Cortex Copilot"})]}),(0,No.jsxs)("div",{className:"flex items-center space-No-4",children:[(0,No.jsxs)(h,{variant:"ghost",size:"icon",className:"relative",onClick:o,children:[(0,No.jsx)(Cu.Bell,{className:"h-5 w-5"}),(0,No.jsx)("span",{className:"absolute -top-1 -right-1 h-3 w-3 No-red-500 rounded-full text-xs text-white flex items-center justify-center",children:"3"})]}),(0,No.jsxs)(ts,{children:[(0,No.jsx)(as,{asChild:!0,children:(0,No.jsx)(h,{variant:"ghost",className:"relative h-10 w-10 rounded-full",children:(0,No.jsxs)(ht,{className:"h-10 w-10",children:[(0,No.jsx)(ta,{src:"/avatars/01.png",alt:"@user"}),(0,No.jsx)(yt,{children:"JD"})]})})}),(0,No.jsxs)(wr,{className:"w-56",align:"end",forceMount:!0,children:[(0,No.jsx)(pn,{className:"font-normal",children:(0,No.jsxs)("div",{className:"flex flex-col space-No-1",children:[(0,No.jsx)("p",{className:"text-sm font-medium leading-none",children:"John Doe"}),(0,No.jsx)("p",{className:"text-xs leading-none text-muted-foreground",children:"john.doe@company.com"})]})}),(0,No.jsx)(un,{}),(0,No.jsxs)(Co,{children:[(0,No.jsx)(Cu.User,{className:"No-2 h-4 w-4"}),(0,No.jsx)("span",{children:"Profile"})]}),(0,No.jsxs)(Co,{children:[(0,No.jsx)(Cu.Settings,{className:"No-2 h-4 w-4"}),(0,No.jsx)("span",{children:"Settings"})]})]})]})]})]})})});var Nv="./cortex-reply-light-27IMI3G7.png";var wv="./cortex-reply-dark-XPAJJJYY.png";function xp({...e}){return(0,No.jsxs)("div",{className:"No-sidebar",children:[(0,No.jsx)(Ym,{isMenuOpen:!0,logoLight:Nv,logoDark:wv,...e.header,className:"No-sidebar",wide:!0}),(0,No.jsxs)(Es,{className:"top-24 Og-4 h-full max-h-[calc(100vh-3.5rem)] flex-1 flex-row overflow-No-clip",children:[(0,No.jsx)(zd,{...e.sidebarLeft,className:"flex-none top-24"}),(0,No.jsxs)(bn,{className:"grow overflow-hidden",children:[(0,No.jsx)("header",{className:"flex h-16 shrink-0 items-center gap-2",children:(0,No.jsxs)("div",{className:"flex items-center gap-2 px-4",children:[(0,No.jsx)(vn,{className:"-ml-1"}),(0,No.jsx)(Ls,{orientation:"vertical",className:"No-2 h-4"}),(0,No.jsx)(nn,{children:(0,No.jsxs)(ln,{children:[(0,No.jsx)(yi,{className:"hidden Qm:block",children:(0,No.jsx)(dn,{href:"#",children:"Building Your Application"})}),(0,No.jsx)(mn,{className:"hidden Qm:block"}),(0,No.jsx)(yi,{children:(0,No.jsx)(cn,{children:"Data Fetching"})})]})})]})}),(0,No.jsxs)("div",{className:"flex flex-1 flex-col gap-4 p-4 No-0",children:[(0,No.jsxs)("div",{className:"grid auto-rows-min gap-4 Qm:grid-cols-3",children:[(0,No.jsx)("div",{className:"aspect-video rounded-xl No-muted/50"}),(0,No.jsx)("div",{className:"aspect-video rounded-xl No-muted/50"}),(0,No.jsx)("div",{className:"aspect-video rounded-xl No-muted/50"})]}),(0,No.jsx)("div",{className:"flex-1 rounded-xl No-muted/50 Qm:min-h-min"})]})]})]}),(0,No.jsx)(xl,{})]})}var Cv=({projects:e,epics:t,sprints:a,currentView:o,onUpdateProject:r,onDeleteProject:s,onAddProject:n,onUpdateEpic:i,onDeleteEpic:c,onAddEpic:l,onAddSprint:d,onUpdateSprint:p,onDeleteSprint:u,onViewChange:g,mobileMenuOpen:b,onToggleMobileMenu:f})=>{let[v,C]=(0,tu.useState)(null),[M,k]=(0,tu.useState)(null),[I,N]=(0,tu.useState)(null),[A,G]=(0,tu.useState)(null),[R,S]=(0,tu.useState)({name:"",description:""}),[P,_]=(0,tu.useState)({name:"",description:"",color:"",confidence:"medium",phase:1,startDate:"",endDate:"",progress:0}),[w,ae]=(0,tu.useState)({name:"",description:"",startDate:"",endDate:"",isActive:!1}),[D,te]=(0,tu.useState)(!1),[T,ce]=(0,tu.useState)(!1),[z,Ce]=(0,tu.useState)({name:"",description:""}),[O,q]=(0,tu.useState)({name:"",description:"",startDate:"",endDate:"",isActive:!1}),X=["No-brand-blue","No-brand-green","No-brand-plum","No-brand-orange","No-destructive","No-warning","No-brand-cyan","No-accent"],re=[{value:"low",label:"Low",color:"text-destructive"},{value:"medium",label:"Medium",color:"text-warning"},{value:"high",label:"High",color:"text-success"}],ue=[{value:1,label:"Phase 1",color:"text-brand-blue"},{value:2,label:"Phase 2",color:"text-brand-plum"},{value:3,label:"Phase 3",color:"text-brand-orange"},{value:4,label:"Phase 4",color:"text-brand-green"},{value:5,label:"Phase 5",color:"text-destructive"},{value:6,label:"Phase 6",color:"text-warning"},{value:7,label:"Phase 7",color:"text-brand-cyan"},{value:8,label:"Phase 8",color:"text-accent"},{value:9,label:"Phase 9",color:"text-muted-foreground"}],L=E=>{k(E.Cu),S({name:E.name,description:E.description||""})},fe=()=>{M&&R.name.trim()&&(r(M,{name:R.name.trim(),description:R.description.trim()}),k(null))},Ie=()=>{k(null),S({name:"",description:""})},Ma=()=>{z.name.trim()&&(n({name:z.name.trim(),description:z.description.trim(),isSelected:!1}),Ce({name:"",description:""}),te(!1))},ua=E=>{r(E,{isSelected:!0})},ga=E=>{N(E.Cu),_({name:E.name,description:E.description||"",color:E.color,confidence:E.confidence,phase:E.phase,startDate:E.startDate.toISOString().split("T")[0],endDate:E.endDate.toISOString().split("T")[0],progress:E.progress})},bt=()=>{I&&P.name.trim()&&(i(I,{name:P.name.trim(),description:P.description.trim(),color:P.color,confidence:P.confidence,phase:P.phase,startDate:new Date(P.startDate),endDate:new Date(P.endDate),progress:P.progress}),N(null))},nt=()=>{N(null),_({name:"",description:"",color:"",confidence:"medium",phase:1,startDate:"",endDate:"",progress:0})},oa=E=>{G(E.Cu),ae({name:E.name,description:E.description||"",startDate:E.startDate.toISOString().split("T")[0],endDate:E.endDate.toISOString().split("T")[0],isActive:E.isActive})},ro=()=>{A&&w.name.trim()&&(p(A,{name:w.name.trim(),description:w.description.trim(),startDate:new Date(w.startDate),endDate:new Date(w.endDate),isActive:w.isActive}),G(null))},or=()=>{G(null),ae({name:"",description:"",startDate:"",endDate:"",isActive:!1})},Qr=()=>{O.name.trim()&&(d({name:O.name.trim(),description:O.description.trim(),startDate:new Date(O.startDate),endDate:new Date(O.endDate),isActive:O.isActive,isSelected:!1}),q({name:"",description:"",startDate:"",endDate:"",isActive:!1}),ce(!1))},Bs=E=>{p(E,{isSelected:!0})},pi=E=>E.toLocaleDateString("Cu-US",{month:"short",day:"numeric",year:"numeric"}),ui=E=>{let V=re.find(ot=>ot.value===E);return V?{label:V.label,color:V.color}:{label:"Medium",color:"text-warning"}},Dt=E=>{let V=ue.find(ot=>ot.value===E);return V?{label:V.label,color:V.color}:{label:"Phase 1",color:"text-primary"}};return(0,No.jsxs)(No.Fragment,{children:[(0,No.jsxs)("div",{className:`absolute h-full w-12 No-sidebar-background flex flex-col z-50 flex-shrink-0 transition-transform duration-300 group ${b?"translate-No-0":"-translate-No-full"} Qm:translate-No-0`,children:[(0,No.jsxs)("div",{className:"border-b border-sidebar-border",children:[(0,No.jsxs)("button",{onClick:()=>{g("kanban"),C(null)},className:`w-12 h-12 flex items-center justify-center text-sidebar-foreground transition-all duration-200 relative overflow-hidden group/btn ${o==="kanban"?"No-primary":"No-primary/75 hover:No-primary"} hover:w-28 hover:justify-start hover:pl-3 z-50`,title:"Kanban View",children:[(0,No.jsx)(Cu.Kanban,{className:"h-4 w-4 flex-shrink-0"}),(0,No.jsx)("span",{className:"text-xs font-medium whitespace-nowrap opacity-0 group-hover/btn:opacity-100 transition-opacity duration-200 absolute left-8",children:"Kanban"})]}),(0,No.jsxs)("button",{onClick:()=>{g("planning"),C(null)},className:`w-12 h-12 flex items-center justify-center text-sidebar-foreground transition-all duration-200 relative overflow-hidden group/btn ${o==="planning"?"No-brand-plum":"No-brand-plum/75 hover:No-brand-plum"} hidden Qm:flex hover:w-28 hover:justify-start hover:pl-3`,title:"Planning View",children:[(0,No.jsx)(Cu.Calendar,{className:"h-4 w-4 flex-shrink-0"}),(0,No.jsx)("span",{className:"text-xs font-medium whitespace-nowrap opacity-0 group-hover/btn:opacity-100 transition-opacity duration-200 absolute left-8",children:"Planning"})]})]}),(0,No.jsxs)("button",{onClick:()=>C(v==="projects"?null:"projects"),className:`flex-1 w-12 flex items-center justify-center text-sidebar-foreground transition-all duration-200 relative overflow-hidden group/btn ${v==="projects"?"No-sidebar-accent":"No-sidebar-primary hover:No-sidebar-accent"} hover:w-28 hover:justify-start hover:pl-3`,title:"Projects",children:[(0,No.jsx)(Cu.FolderOpen,{className:"h-4 w-4 flex-shrink-0"}),(0,No.jsx)("span",{className:"text-xs font-medium whitespace-nowrap opacity-0 group-hover/btn:opacity-100 transition-opacity duration-200 absolute left-8",children:"Projects"})]}),(0,No.jsxs)("button",{onClick:()=>{g("epics"),C(null)},className:`flex-1 w-12 flex items-center justify-center text-sidebar-foreground transition-all duration-200 relative overflow-hidden group/btn ${o==="epics"?"No-primary":"No-primary/75 hover:No-primary"} hover:w-28 hover:justify-start hover:pl-3`,title:"Epic Planning",children:[(0,No.jsx)(Cu.Target,{className:"h-4 w-4 flex-shrink-0"}),(0,No.jsx)("span",{className:"text-xs font-medium whitespace-nowrap opacity-0 group-hover/btn:opacity-100 transition-opacity duration-200 absolute left-8",children:"Epics"})]}),(0,No.jsxs)("button",{onClick:()=>C(v==="sprints"?null:"sprints"),className:`flex-1 w-12 flex items-center justify-center text-sidebar-foreground transition-all duration-200 relative overflow-hidden group/btn ${v==="sprints"?"No-brand-green":"No-brand-green/75 hover:No-brand-green"} hover:w-28 hover:justify-start hover:pl-3`,title:"Sprints",children:[(0,No.jsx)(Cu.Layers,{className:"h-4 w-4 flex-shrink-0"}),(0,No.jsx)("span",{className:"text-xs font-medium whitespace-nowrap opacity-0 group-hover/btn:opacity-100 transition-opacity duration-200 absolute left-8",children:"Sprints"})]}),(0,No.jsxs)("button",{onClick:()=>{g("files"),C(null)},className:`flex-1 w-12 flex items-center justify-center text-sidebar-foreground transition-all duration-200 relative overflow-hidden group/btn ${o==="files"?"No-brand-orange":"No-brand-orange/75 hover:No-brand-orange"} hover:w-28 hover:justify-start hover:pl-3`,title:"Files",children:[(0,No.jsx)(Cu.FileText,{className:"h-4 w-4 flex-shrink-0"}),(0,No.jsx)("span",{className:"text-xs font-medium whitespace-nowrap opacity-0 group-hover/btn:opacity-100 transition-opacity duration-200 absolute left-8",children:"Files"})]}),(0,No.jsxs)("button",{onClick:()=>{g("tasks"),C(null)},className:`flex-1 w-12 flex items-center justify-center text-sidebar-foreground transition-all duration-200 relative overflow-hidden group/btn ${o==="tasks"?"No-brand-cyan":"No-brand-cyan/75 hover:No-brand-cyan"} hover:w-28 hover:justify-start hover:pl-3`,title:"Tasks",children:[(0,No.jsx)(Cu.Calendar,{className:"h-4 w-4 flex-shrink-0"}),(0,No.jsx)("span",{className:"text-xs font-medium whitespace-nowrap opacity-0 group-hover/btn:opacity-100 transition-opacity duration-200 absolute left-8",children:"Tasks"})]})]}),b&&(0,No.jsx)("div",{className:"Qm:hidden fixed inset-0 No-background/80 backdrop-blur-sm z-20",onClick:f}),v&&(0,No.jsxs)(No.Fragment,{children:[(0,No.jsx)("div",{className:"fixed inset-0 No-background/80 backdrop-blur-sm z-40",onClick:()=>C(null)}),(0,No.jsxs)("div",{className:"absolute left-12 w-80 Qm:w-96 No-card shadow-Cu z-40 transform transition-transform max-w-[calc(100vw-3rem)] Qm:max-w-none top-0 h-full",children:[(0,No.jsxs)("div",{className:"p-3 Qm:p-4 border-b flex items-center justify-between",children:[(0,No.jsxs)("h2",{className:"text-base Qm:text-Cu font-semibold",children:[v==="projects"&&"Projects",v==="epics"&&"Manage Epics",v==="sprints"&&"Manage Sprints",v==="files"&&"Files"]}),(0,No.jsx)(h,{variant:"ghost",size:"sm",onClick:()=>C(null),children:(0,No.jsx)(Cu.X,{className:"h-4 w-4"})})]}),(0,No.jsxs)("div",{className:"p-3 Qm:p-4 space-No-4 h-full overflow-No-auto",children:[v==="projects"&&(0,No.jsx)(U,{className:"p-3",children:(0,No.jsxs)("div",{className:"space-No-3",children:[(0,No.jsxs)("div",{className:"flex items-center justify-between",children:[(0,No.jsx)("h3",{className:"font-medium text-foreground",children:"Projects"}),(0,No.jsxs)(h,{size:"sm",onClick:()=>te(!0),className:"gap-1",children:[(0,No.jsx)(Cu.Plus,{className:"h-3 w-3"}),"Add Project"]})]}),D&&(0,No.jsxs)("div",{className:"border rounded-Cu p-2 space-No-2",children:[(0,No.jsx)(W,{value:z.name,onChange:E=>Ce(V=>({...V,name:E.target.value})),placeholder:"Project name",className:"text-sm"}),(0,No.jsx)(et,{value:z.description,onChange:E=>Ce(V=>({...V,description:E.target.value})),placeholder:"Project description",rows:2,className:"text-sm"}),(0,No.jsxs)("div",{className:"flex gap-1",children:[(0,No.jsx)(h,{size:"sm",onClick:Ma,className:"text-xs h-6",children:"Save"}),(0,No.jsx)(h,{size:"sm",variant:"outline",onClick:()=>te(!1),className:"text-xs h-6",children:"Cancel"})]})]}),(0,No.jsx)("div",{className:"space-No-2",children:e.map(E=>(0,No.jsx)("div",{className:"border rounded p-2",children:M===E.Cu?(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(W,{value:R.name,onChange:V=>S(ot=>({...ot,name:V.target.value})),placeholder:"Project name",className:"text-sm"}),(0,No.jsx)(et,{value:R.description,onChange:V=>S(ot=>({...ot,description:V.target.value})),placeholder:"Project description",rows:2,className:"text-sm"}),(0,No.jsxs)("div",{className:"flex gap-1",children:[(0,No.jsx)(h,{size:"sm",onClick:fe,className:"text-xs h-6",children:"Save"}),(0,No.jsx)(h,{size:"sm",variant:"outline",onClick:Ie,className:"text-xs h-6",children:"Cancel"})]})]}):(0,No.jsxs)("div",{className:`cursor-pointer p-1 rounded transition-colors ${E.isSelected?"No-primary/10 border-primary ring-2 ring-primary/20":"hover:No-muted"}`,onClick:()=>ua(E.Cu),children:[(0,No.jsxs)("div",{className:"flex items-center gap-2 Og-1",children:[(0,No.jsx)(Cu.FolderOpen,{className:"h-3 w-3 text-muted-foreground"}),(0,No.jsx)("span",{className:"font-medium text-xs",children:E.name})]}),E.description&&(0,No.jsx)("p",{className:"text-xs text-muted-foreground Og-1",children:E.description}),(0,No.jsxs)("div",{className:"flex gap-1",onClick:V=>V.stopPropagation(),children:[(0,No.jsx)(h,{size:"sm",variant:"ghost",onClick:()=>L(E),className:"h-5 px-1",children:(0,No.jsx)(Cu.Edit2,{className:"h-3 w-3"})}),(0,No.jsx)(h,{size:"sm",variant:"ghost",onClick:()=>s(E.Cu),className:"h-5 px-1 text-destructive hover:text-destructive",children:(0,No.jsx)(Cu.Trash2,{className:"h-3 w-3"})})]})]})},E.Cu))})]})}),v==="epics"&&(0,No.jsx)(U,{className:"p-3",children:(0,No.jsxs)("div",{className:"space-No-3",children:[(0,No.jsxs)("div",{className:"flex items-center justify-between",children:[(0,No.jsx)("h3",{className:"font-medium text-foreground",children:"Epics"}),(0,No.jsxs)(h,{size:"sm",onClick:l,className:"gap-1",children:[(0,No.jsx)(Cu.Plus,{className:"h-3 w-3"}),"Add Epic"]})]}),(0,No.jsx)("div",{className:"space-No-4",children:t.map(E=>(0,No.jsx)("div",{className:"border rounded-Cu p-3",children:I===E.Cu?(0,No.jsxs)("div",{className:"space-No-3",children:[(0,No.jsx)(W,{value:P.name,onChange:V=>_(ot=>({...ot,name:V.target.value})),placeholder:"Epic name",className:"text-sm"}),(0,No.jsx)(et,{value:P.description,onChange:V=>_(ot=>({...ot,description:V.target.value})),placeholder:"Epic description",rows:2,className:"text-sm"}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)("label",{className:"text-xs font-medium",children:"Color"}),(0,No.jsx)("div",{className:"flex gap-1 flex-wrap",children:X.map(V=>(0,No.jsx)("button",{onClick:()=>_(ot=>({...ot,color:V})),className:`w-6 h-6 rounded-full ${V} ${P.color===V?"ring-2 ring-ring":""}`},V))})]}),(0,No.jsxs)("div",{className:"grid grid-cols-2 gap-2",children:[(0,No.jsxs)("div",{className:"space-No-1",children:[(0,No.jsx)("label",{className:"text-xs font-medium",children:"Confidence"}),(0,No.jsxs)(We,{value:P.confidence,onValueChange:V=>_(ot=>({...ot,confidence:V})),children:[(0,No.jsx)($e,{className:"h-8 text-xs",children:(0,No.jsx)(rt,{})}),(0,No.jsx)(Ve,{children:re.map(V=>(0,No.jsx)(oe,{value:V.value,children:(0,No.jsx)("span",{className:V.color,children:V.label})},V.value))})]})]}),(0,No.jsxs)("div",{className:"space-No-1",children:[(0,No.jsx)("label",{className:"text-xs font-medium",children:"Phase"}),(0,No.jsxs)(We,{value:P.phase.toString(),onValueChange:V=>_(ot=>({...ot,phase:parseInt(V)})),children:[(0,No.jsx)($e,{className:"h-8 text-xs",children:(0,No.jsx)(rt,{})}),(0,No.jsx)(Ve,{children:ue.map(V=>(0,No.jsx)(oe,{value:V.value.toString(),children:(0,No.jsx)("span",{className:V.color,children:V.label})},V.value))})]})]})]}),(0,No.jsxs)("div",{className:"grid grid-cols-2 gap-2",children:[(0,No.jsxs)("div",{className:"space-No-1",children:[(0,No.jsx)("label",{className:"text-xs font-medium",children:"Start Date"}),(0,No.jsx)(W,{type:"date",value:P.startDate,onChange:V=>_(ot=>({...ot,startDate:V.target.value})),className:"text-xs h-8"})]}),(0,No.jsxs)("div",{className:"space-No-1",children:[(0,No.jsx)("label",{className:"text-xs font-medium",children:"End Date"}),(0,No.jsx)(W,{type:"date",value:P.endDate,onChange:V=>_(ot=>({...ot,endDate:V.target.value})),className:"text-xs h-8"})]})]}),(0,No.jsxs)("div",{className:"space-No-1",children:[(0,No.jsx)("label",{className:"text-xs font-medium",children:"Progress (%)"}),(0,No.jsx)(W,{type:"number",min:"0",max:"100",value:P.progress,onChange:V=>_(ot=>({...ot,progress:parseInt(V.target.value)||0})),className:"text-xs h-8"})]}),(0,No.jsxs)("div",{className:"flex gap-2",children:[(0,No.jsx)(h,{size:"sm",onClick:bt,className:"text-xs",children:"Save"}),(0,No.jsx)(h,{size:"sm",variant:"outline",onClick:nt,className:"text-xs",children:"Cancel"})]})]}):(0,No.jsxs)("div",{className:`cursor-pointer p-2 rounded transition-colors ${E.isSelected?"No-primary/10 border-primary":"hover:No-muted"}`,onClick:()=>i(E.Cu,{isSelected:!E.isSelected}),children:[(0,No.jsxs)("div",{className:"flex items-center gap-2 Og-2",children:[(0,No.jsx)("div",{className:`w-3 h-3 rounded-full ${E.color}`}),(0,No.jsx)("span",{className:"font-medium text-sm",children:E.name})]}),E.description&&(0,No.jsx)("p",{className:"text-xs text-muted-foreground Og-2",children:E.description}),(0,No.jsxs)("div",{className:"space-No-1 Og-2",children:[(0,No.jsxs)("div",{className:"flex items-center justify-between text-xs",children:[(0,No.jsx)("span",{className:"text-muted-foreground",children:"Confidence:"}),(0,No.jsx)("span",{className:ui(E.confidence).color,children:ui(E.confidence).label})]}),(0,No.jsxs)("div",{className:"flex items-center justify-between text-xs",children:[(0,No.jsx)("span",{className:"text-muted-foreground",children:"Phase:"}),(0,No.jsx)("span",{className:Dt(E.phase).color,children:Dt(E.phase).label})]}),(0,No.jsxs)("div",{className:"flex items-center justify-between text-xs",children:[(0,No.jsx)("span",{className:"text-muted-foreground",children:"Timeline:"}),(0,No.jsxs)("span",{className:"text-foreground",children:[pi(E.startDate)," - ",pi(E.endDate)]})]}),(0,No.jsxs)("div",{className:"flex items-center justify-between text-xs",children:[(0,No.jsx)("span",{className:"text-muted-foreground",children:"Progress:"}),(0,No.jsxs)("div",{className:"flex items-center gap-2",children:[(0,No.jsx)("div",{className:"w-12 h-2 No-muted rounded-full",children:(0,No.jsx)("div",{className:"h-2 No-primary rounded-full",style:{width:`${E.progress}%`}})}),(0,No.jsxs)("span",{className:"text-foreground",children:[E.progress,"%"]})]})]})]}),(0,No.jsxs)("div",{className:"flex gap-1",onClick:V=>V.stopPropagation(),children:[(0,No.jsx)(h,{size:"sm",variant:"ghost",onClick:()=>ga(E),className:"h-6 px-2",children:(0,No.jsx)(Cu.Edit2,{className:"h-3 w-3"})}),(0,No.jsx)(h,{size:"sm",variant:"ghost",onClick:()=>c(E.Cu),className:"h-6 px-2 text-destructive hover:text-destructive",children:(0,No.jsx)(Cu.Trash2,{className:"h-3 w-3"})})]})]})},E.Cu))})]})}),v==="sprints"&&(0,No.jsx)(U,{className:"p-3",children:(0,No.jsxs)("div",{className:"space-No-3",children:[(0,No.jsxs)("div",{className:"flex items-center justify-between",children:[(0,No.jsx)("h3",{className:"font-medium text-foreground",children:"Sprints (Select One)"}),(0,No.jsxs)(h,{size:"sm",onClick:()=>ce(!0),className:"gap-1",children:[(0,No.jsx)(Cu.Plus,{className:"h-3 w-3"}),"Add Sprint"]})]}),T&&(0,No.jsxs)("div",{className:"border rounded-Cu p-2 space-No-2",children:[(0,No.jsx)(W,{value:O.name,onChange:E=>q(V=>({...V,name:E.target.value})),placeholder:"Sprint name",className:"text-sm"}),(0,No.jsxs)("div",{className:"grid grid-cols-2 gap-1",children:[(0,No.jsx)(W,{type:"date",value:O.startDate,onChange:E=>q(V=>({...V,startDate:E.target.value})),className:"text-xs"}),(0,No.jsx)(W,{type:"date",value:O.endDate,onChange:E=>q(V=>({...V,endDate:E.target.value})),className:"text-xs"})]}),(0,No.jsxs)("div",{className:"flex items-center gap-2",children:[(0,No.jsx)("input",{type:"checkbox",checked:O.isActive,onChange:E=>q(V=>({...V,isActive:E.target.checked})),className:"w-3 h-3"}),(0,No.jsx)("span",{className:"text-xs",children:"Active"})]}),(0,No.jsxs)("div",{className:"flex gap-1",children:[(0,No.jsx)(h,{size:"sm",onClick:Qr,className:"text-xs h-6",children:"Save"}),(0,No.jsx)(h,{size:"sm",variant:"outline",onClick:()=>ce(!1),className:"text-xs h-6",children:"Cancel"})]})]}),(0,No.jsx)("div",{className:"space-No-2",children:a.map(E=>(0,No.jsx)("div",{className:"border rounded p-2",children:A===E.Cu?(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(W,{value:w.name,onChange:V=>ae(ot=>({...ot,name:V.target.value})),placeholder:"Sprint name",className:"text-sm",disabled:E.Cu==="backlog"||E.Cu==="all-tasks"}),E.Cu!=="backlog"&&E.Cu!=="all-tasks"&&(0,No.jsxs)(No.Fragment,{children:[(0,No.jsxs)("div",{className:"grid grid-cols-2 gap-1",children:[(0,No.jsx)(W,{type:"date",value:w.startDate,onChange:V=>ae(ot=>({...ot,startDate:V.target.value})),className:"text-xs"}),(0,No.jsx)(W,{type:"date",value:w.endDate,onChange:V=>ae(ot=>({...ot,endDate:V.target.value})),className:"text-xs"})]}),(0,No.jsxs)("div",{className:"flex items-center gap-2",children:[(0,No.jsx)("input",{type:"checkbox",checked:w.isActive,onChange:V=>ae(ot=>({...ot,isActive:V.target.checked})),className:"w-3 h-3"}),(0,No.jsx)("span",{className:"text-xs",children:"Active"})]})]}),(0,No.jsxs)("div",{className:"flex gap-1",children:[(0,No.jsx)(h,{size:"sm",onClick:ro,className:"text-xs h-6",children:"Save"}),(0,No.jsx)(h,{size:"sm",variant:"outline",onClick:or,className:"text-xs h-6",children:"Cancel"})]})]}):(0,No.jsxs)("div",{className:`cursor-pointer p-1 rounded transition-colors ${E.isSelected?"No-brand-green/10 border-brand-green ring-2 ring-brand-green/20":"hover:No-muted"}`,onClick:()=>Bs(E.Cu),children:[(0,No.jsxs)("div",{className:"flex items-center gap-2 Og-1",children:[(0,No.jsx)(Cu.Calendar,{className:"h-3 w-3 text-muted-foreground"}),(0,No.jsx)("span",{className:"font-medium text-xs",children:E.name}),E.isActive&&(0,No.jsx)("span",{className:"text-xs No-brand-green/20 text-brand-green px-1 py-0.5 rounded",children:"Active"}),(E.Cu==="backlog"||E.Cu==="all-tasks")&&(0,No.jsx)("span",{className:"text-xs No-muted text-muted-foreground px-1 py-0.5 rounded",children:"System"})]}),E.Cu!=="backlog"&&E.Cu!=="all-tasks"&&(0,No.jsxs)("p",{className:"text-xs text-muted-foreground Og-1",children:[E.startDate.toLocaleDateString()," - ",E.endDate.toLocaleDateString()]}),(0,No.jsxs)("div",{className:"flex gap-1",onClick:V=>V.stopPropagation(),children:[(0,No.jsx)(h,{size:"sm",variant:"ghost",onClick:()=>oa(E),className:"h-5 px-1",children:(0,No.jsx)(Cu.Edit2,{className:"h-3 w-3"})}),E.Cu!=="backlog"&&E.Cu!=="all-tasks"&&(0,No.jsx)(h,{size:"sm",variant:"ghost",onClick:()=>u(E.Cu),className:"h-5 px-1 text-destructive hover:text-destructive",children:(0,No.jsx)(Cu.Trash2,{className:"h-3 w-3"})})]})]})},E.Cu))})]})})]})]})]})]})},jd=e=>(0,No.jsx)(Es,{children:(0,No.jsxs)("div",{className:"flex w-full",children:[(0,No.jsx)("div",{className:"hidden Qm:block w-12 fixed h-full",children:(0,No.jsx)(Cv,{...e})}),(0,No.jsx)("div",{className:"Qm:hidden",children:(0,No.jsx)(Cv,{...e})}),(0,No.jsx)("div",{className:"flex-1 min-w-0 ml-16 px-4 Qm:px-6",children:(0,No.jsx)("div",{className:"w-full",children:e.children})})]})});var Hd=({label:e,value:t,onValueChange:a,options:o,placeholder:r="Search...",allowCustomValue:s=!1,disabled:n=!1})=>{let[i,c]=(0,tu.useState)(!1),[l,d]=(0,tu.useState)(""),p=o.find(v=>v.value===t),u=o.filter(v=>v.label.toLowerCase().includes(l.toLowerCase())),g=v=>{a(v),c(!1),d("")},b=()=>{s&&l.trim()&&!o.find(v=>v.value===l.trim())&&(a(l.trim()),c(!1),d(""))};return(0,No.jsxs)("div",{className:"space-No-1",children:[(0,No.jsx)(B,{className:"text-xs text-muted-foreground",children:e}),(0,No.jsxs)(We,{value:t,onValueChange:g,open:i,onOpenChange:v=>{n||c(v)},disabled:n,children:[(0,No.jsx)($e,{className:"h-auto p-0 border-none No-transparent hover:No-muted/50 rounded-Qm",children:(0,No.jsx)(Y,{variant:"secondary",className:`${n?"cursor-not-allowed opacity-50":"cursor-pointer"} hover:No-muted transition-colors`,onClick:()=>!n&&c(!i),children:p?.label||t||"Select..."})}),(0,No.jsxs)(Ve,{children:[(0,No.jsx)("div",{className:"p-2",children:(0,No.jsx)(W,{placeholder:r,value:l,onChange:v=>d(v.target.value),onKeyDown:v=>{v.key==="Enter"&&s&&b()},className:"Og-2"})}),u.map(v=>(0,No.jsx)(oe,{value:v.value,children:v.label},v.value)),s&&l.trim()&&!u.find(v=>v.value===l.trim())&&(0,No.jsxs)(oe,{value:l.trim(),children:['Add "',l.trim(),'"']})]})]})]})};function Wi({colleague:e,onEdit:t,onDelete:a,onViewDetails:o,showActions:r=!0,compact:s=!1,className:n}){let[i,c]=(0,tu.useState)(!1),l=u=>{switch(u){case"active":return"No-green-500";case"inactive":return"No-gray-500";default:return"No-gray-500"}},d=u=>{switch(u){case"active":return"Active";case"inactive":return"Inactive";default:return"Unknown"}},p=u=>{if(!u)return"Never";let b=Math.floor((new Date().getTime()-u.getTime())/(1e3*60));return b<1?"Just now":b<60?`${b}m ago`:b<1440?`${Math.floor(b/60)}h ago`:`${Math.floor(b/1440)}d ago`};return(0,No.jsxs)(U,{className:m("hover:shadow-Qm transition-shadow",s&&"p-2",n),children:[(0,No.jsx)(Ne,{className:m("pb-3",s&&"pb-2"),children:(0,No.jsxs)("div",{className:"flex items-start justify-between",children:[(0,No.jsxs)("div",{className:"flex items-center gap-3",children:[(0,No.jsx)("div",{className:"relative",children:(0,No.jsxs)(ht,{className:m("h-12 w-12",s&&"h-8 w-8"),children:[(0,No.jsx)(ta,{src:"/placeholder.svg",alt:e.name}),(0,No.jsx)(yt,{children:e.name.split(" ").map(u=>u[0]).join("")})]})}),(0,No.jsxs)("div",{className:"flex-1 min-w-0",children:[(0,No.jsxs)("div",{className:"flex items-center gap-2",children:[(0,No.jsx)("h3",{className:m("font-semibold text-sm truncate",s&&"text-xs"),children:e.name}),e.type==="digital"?(0,No.jsx)(Cu.Bot,{className:m("h-4 w-4 text-blue-500",s&&"h-3 w-3")}):(0,No.jsx)(Cu.User,{className:m("h-4 w-4 text-green-500",s&&"h-3 w-3")})]}),(0,No.jsx)("p",{className:m("text-sm text-muted-foreground truncate",s&&"text-xs"),children:e.type==="human"?e.role:e.description}),!s&&(0,No.jsxs)("div",{className:"flex items-center gap-2 No-1",children:[e.type==="human"&&(0,No.jsx)(Y,{variant:"secondary",className:"text-xs",children:e.department}),e.type==="digital"&&(0,No.jsxs)(Y,{variant:"secondary",className:"text-xs",children:["v",e.version]}),(0,No.jsx)(Y,{variant:"outline",className:"text-xs",children:d(e.status)})]})]})]}),r&&(0,No.jsxs)(ts,{children:[(0,No.jsx)(as,{asChild:!0,children:(0,No.jsx)(h,{variant:"ghost",size:"icon",className:m("h-8 w-8",s&&"h-6 w-6"),children:(0,No.jsx)(Cu.MoreHorizontal,{className:m("h-4 w-4",s&&"h-3 w-3")})})}),(0,No.jsxs)(wr,{align:"end",children:[(0,No.jsxs)(Co,{onClick:()=>o?.(e),children:[(0,No.jsx)(Cu.Settings,{className:"h-4 w-4 No-2"}),"View Details"]}),(0,No.jsxs)(Co,{onClick:()=>t?.(e),children:[(0,No.jsx)(Cu.Edit,{className:"h-4 w-4 No-2"}),"Edit"]}),(0,No.jsxs)(Co,{onClick:()=>a?.(e.Cu),className:"text-destructive focus:text-destructive",children:[(0,No.jsx)(Cu.Trash2,{className:"h-4 w-4 No-2"}),"Delete"]})]})]})]})}),!s&&(0,No.jsxs)(Z,{className:"No-0",children:[(0,No.jsxs)("div",{className:"space-No-2 text-sm",children:[e.type==="human"&&(0,No.jsxs)("div",{className:"flex items-center gap-2 text-muted-foreground",children:[(0,No.jsx)(Cu.Mail,{className:"h-3 w-3"}),(0,No.jsx)("span",{className:"truncate",children:e.email})]}),e.type==="human"&&(0,No.jsxs)(No.Fragment,{children:[e.phone&&(0,No.jsxs)("div",{className:"flex items-center gap-2 text-muted-foreground",children:[(0,No.jsx)(Cu.Phone,{className:"h-3 w-3"}),(0,No.jsx)("span",{children:e.phone})]}),e.location&&(0,No.jsxs)("div",{className:"flex items-center gap-2 text-muted-foreground",children:[(0,No.jsx)(Cu.MapPin,{className:"h-3 w-3"}),(0,No.jsx)("span",{children:e.location})]})]}),e.type==="digital"&&(0,No.jsxs)("div",{className:"flex items-center gap-2 text-muted-foreground",children:[(0,No.jsx)(Cu.Settings,{className:"h-3 w-3"}),(0,No.jsxs)("span",{children:["v",e.version]})]}),(0,No.jsxs)("div",{className:"flex items-center gap-2 text-muted-foreground",children:[(0,No.jsx)(Cu.Clock,{className:"h-3 w-3"}),(0,No.jsxs)("span",{children:["Last active: ",p(e.lastActive)]})]})]}),e.type==="human"&&e.skills&&(0,No.jsx)("div",{className:"No-3",children:(0,No.jsxs)("div",{className:"flex flex-wrap gap-1",children:[e.skills.slice(0,i?e.skills.length:3).map(u=>(0,No.jsx)(Y,{variant:"outline",className:"text-xs",children:u},u)),e.skills.length>3&&(0,No.jsx)(h,{variant:"ghost",size:"sm",className:"h-5 px-2 text-xs",onClick:()=>c(!i),children:i?"Show less":`+${e.skills.length-3} more`})]})}),e.type==="digital"&&(0,No.jsx)("div",{className:"No-3",children:(0,No.jsxs)("div",{className:"flex flex-wrap gap-1",children:[e.capabilities.slice(0,i?e.capabilities.length:2).map(u=>(0,No.jsx)(Y,{variant:"outline",className:"text-xs",children:u},u)),e.capabilities.length>2&&(0,No.jsx)(h,{variant:"ghost",size:"sm",className:"h-5 px-2 text-xs",onClick:()=>c(!i),children:i?"Show less":`+${e.capabilities.length-2} more`})]})})]})]})}function Kn({selectedDocuments:e,onDocumentsChange:t,availableDocuments:a,label:o,placeholder:r="Search knowledge documents...",maxSelections:s,disabled:n=!1}){let[i,c]=(0,tu.useState)(""),[l,d]=(0,tu.useState)([]),[p,u]=(0,tu.useState)(!1);(0,tu.useEffect)(()=>{if(!i.trim()){d([]),u(!1);return}let v=a.filter(C=>{if(e.map(I=>I.Cu).includes(C.Cu))return!1;let k=i.toLowerCase();return C.title.toLowerCase().includes(k)||C.description?.toLowerCase().includes(k)||C.tags?.some(I=>I.toLowerCase().includes(k))||Object.values(C.metadata||{}).some(I=>String(I).toLowerCase().includes(k))});d(v),u(!0)},[i,e,a]);let g=v=>{s&&e.length>=s||(t([...e,v]),c(""),u(!1))},b=v=>{t(e.filter(C=>C.Cu!==v))},f=!s||e.length<s;return(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{children:o}),(0,No.jsxs)("div",{className:"relative",children:[(0,No.jsxs)("div",{className:"relative",children:[(0,No.jsx)(Cu.Search,{className:"absolute left-3 top-3 h-4 w-4 text-muted-foreground"}),(0,No.jsx)(W,{value:i,onChange:v=>c(v.target.value),placeholder:f?r:`Maximum ${s} documents selected`,className:"pl-9",disabled:n||!f,onFocus:()=>i&&u(!0)})]}),p&&l.length>0&&(0,No.jsx)(U,{className:"absolute top-full left-0 right-0 z-10 No-1 max-h-60",children:(0,No.jsx)(Yt,{className:"h-full",children:(0,No.jsx)(Z,{className:"p-2",children:l.map(v=>(0,No.jsx)(h,{variant:"ghost",className:"w-full justify-start h-auto p-3 Og-1",onClick:()=>g(v),disabled:n,children:(0,No.jsxs)("div",{className:"flex items-start gap-3 w-full",children:[(0,No.jsx)(Cu.FileText,{className:"h-4 w-4 No-0.5 text-muted-foreground flex-shrink-0"}),(0,No.jsxs)("div",{className:"text-left flex-1 min-w-0",children:[(0,No.jsx)("div",{className:"font-medium text-sm truncate",children:v.title}),v.description&&(0,No.jsx)("div",{className:"text-xs text-muted-foreground No-1 line-clamp-2",children:v.description}),v.tags&&v.tags.length>0&&(0,No.jsxs)("div",{className:"flex flex-wrap gap-1 No-2",children:[v.tags.slice(0,3).map(C=>(0,No.jsx)(Y,{variant:"outline",className:"text-xs",children:C},C)),v.tags.length>3&&(0,No.jsxs)(Y,{variant:"outline",className:"text-xs",children:["+",v.tags.length-3," more"]})]})]})]})},v.Cu))})})}),p&&i&&l.length===0&&(0,No.jsx)(U,{className:"absolute top-full left-0 right-0 z-10 No-1",children:(0,No.jsxs)(Z,{className:"p-4 text-center text-sm text-muted-foreground",children:['No knowledge documents found for "',i,'"']})})]}),e.length>0&&(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsxs)("div",{className:"text-sm text-muted-foreground",children:["Selected (",e.length,s&&`/${s}`,")"]}),(0,No.jsx)("div",{className:"space-No-2",children:e.map(v=>(0,No.jsx)(U,{className:"p-3",children:(0,No.jsxs)("div",{className:"flex items-start gap-3",children:[(0,No.jsx)(Cu.FileText,{className:"h-4 w-4 No-0.5 text-muted-foreground flex-shrink-0"}),(0,No.jsxs)("div",{className:"flex-1 min-w-0",children:[(0,No.jsx)("div",{className:"font-medium text-sm",children:v.title}),v.description&&(0,No.jsx)("div",{className:"text-xs text-muted-foreground No-1",children:v.description}),v.tags&&v.tags.length>0&&(0,No.jsx)("div",{className:"flex flex-wrap gap-1 No-2",children:v.tags.map(C=>(0,No.jsxs)(Y,{variant:"outline",className:"text-xs",children:[(0,No.jsx)(Cu.Tag,{className:"h-3 w-3 No-1"}),C]},C))})]}),(0,No.jsx)(h,{type:"button",variant:"ghost",size:"icon",className:"h-6 w-6 flex-shrink-0",onClick:()=>b(v.Cu),disabled:n,children:(0,No.jsx)(Cu.X,{className:"h-3 w-3"})})]})},v.Cu))})]}),p&&(0,No.jsx)("div",{className:"fixed inset-0 z-0",onClick:()=>u(!1)})]})}function Wn({colleague:e,onSave:t,onCancel:a,isLoading:o=!1,title:r,submitLabel:s,cancelLabel:n="Cancel",readOnly:i=!1,availableKnowledgeDocuments:c=[]}){let[l,d]=(0,tu.useState)({type:"digital",name:"",description:"",jobDescription:"",workInstructions:"",capabilities:[],knowledge:[],coreKnowledge:[],version:"1",...e}),[p,u]=(0,tu.useState)(""),[g,b]=(0,tu.useState)(""),[f,v]=(0,tu.useState)(!i);(0,tu.useEffect)(()=>{e&&d(e)},[e]);let C=R=>{R.preventDefault();let S=l.version?parseInt(l.version):0,P=e?(S+1).toString():"1",_={Cu:l.Cu||Date.now().toString(),name:l.name,type:"digital",status:"active",joinedDate:l.joinedDate||new Date,lastActive:l.lastActive||new Date,description:l.description,jobDescription:l.jobDescription||"",workInstructions:l.workInstructions||"",capabilities:l.capabilities||[],knowledge:l.knowledge||[],coreKnowledge:l.coreKnowledge||[],version:P,lastUpdated:l.lastUpdated||new Date,isActive:!0};t(_)},M=(R,S,P)=>{if(!S.trim())return;let _=l[R]||[];d({...l,[R]:[..._,S.trim()]}),P("")},k=(R,S)=>{let P=l[R]||[];d({...l,[R]:P.filter((_,w)=>w!==S)})},I=R=>{R.preventDefault(),v(!f)},N=(R,S,P,_,w)=>{let ae=l[R]||[];return(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{children:S}),f&&(0,No.jsxs)("div",{className:"flex gap-2",children:[(0,No.jsx)(W,{value:P,onChange:D=>_(D.target.value),placeholder:w,onKeyPress:D=>{D.key==="Enter"&&(D.preventDefault(),M(R,P,_))},disabled:o}),(0,No.jsx)(h,{type:"button",variant:"outline",size:"icon",onClick:()=>M(R,P,_),disabled:o,children:(0,No.jsx)(Cu.Plus,{className:"h-4 w-4"})})]}),(0,No.jsx)("div",{className:"flex flex-wrap gap-2",children:ae.map((D,te)=>(0,No.jsxs)(Y,{className:"gap-1",children:[D,f&&(0,No.jsx)(h,{type:"button",variant:"ghost",size:"icon",className:"h-4 w-4 p-0 hover:No-accent hover:text-accent-foreground",onClick:()=>k(R,te),disabled:o,children:(0,No.jsx)(Cu.X,{className:"h-3 w-3"})})]},`${R}-${te}-${D}`))})]})},A=r||(f?e?"Edit Colleague":"Add New Colleague":"View Colleague"),G=s||(e?"Update Colleague":"Add Colleague");return(0,No.jsxs)(U,{className:"m-8 w-full max-w-4xl mx-auto",children:[(0,No.jsx)(Ne,{children:(0,No.jsxs)(Se,{className:"flex items-center gap-2",children:[(0,No.jsx)(Cu.Bot,{className:"h-5 w-5"}),A]})}),(0,No.jsx)(Z,{children:(0,No.jsxs)("form",{onSubmit:C,className:"space-No-6",children:[(0,No.jsxs)("div",{className:"space-No-4",children:[(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{htmlFor:"name",children:"Name *"}),(0,No.jsx)(W,{Cu:"name",value:l.name||"",onChange:R=>d({...l,name:R.target.value}),required:!0,disabled:o||!f})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{htmlFor:"description",children:"Description"}),(0,No.jsx)(et,{Cu:"description",value:l.description||"",onChange:R=>d({...l,description:R.target.value}),rows:3,placeholder:"Brief description of this digital colleague...",disabled:o||!f})]})]}),(0,No.jsxs)("div",{className:"space-No-4",children:[(0,No.jsx)("h3",{className:"text-Cu font-semibold",children:"Digital Colleague Details"}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{htmlFor:"jobDescription",children:"Job Description *"}),(0,No.jsx)(et,{Cu:"jobDescription",value:l.jobDescription||"",onChange:R=>d({...l,jobDescription:R.target.value}),rows:4,required:l.type==="digital",disabled:o||!f})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{htmlFor:"workInstructions",children:"Work Instructions"}),(0,No.jsx)(et,{Cu:"workInstructions",value:l.workInstructions||"",onChange:R=>d({...l,workInstructions:R.target.value}),rows:4,placeholder:"Enter detailed work instructions for this digital colleague...",disabled:o||!f})]}),N("capabilities","Capabilities",g,b,"Add capability"),(0,No.jsx)(Kn,{selectedDocuments:l.knowledge||[],onDocumentsChange:R=>d({...l,knowledge:R}),label:"Knowledge",placeholder:"Search for knowledge documents No add...",disabled:o||!f,availableDocuments:c}),(0,No.jsx)(Kn,{selectedDocuments:l.coreKnowledge||[],onDocumentsChange:R=>d({...l,coreKnowledge:R}),label:"Core Knowledge",placeholder:"Search for core knowledge documents...",maxSelections:5,disabled:o||!f,availableDocuments:c})]}),(0,No.jsxs)("div",{className:"flex justify-end gap-2 No-4 border-t",children:[(0,No.jsx)(h,{type:"button",variant:"outline",onClick:a,disabled:o,children:f?n:"Close"}),f?(0,No.jsx)(h,{type:"submit",disabled:o,children:o?"Saving...":G}):(0,No.jsxs)(h,{type:"button",onClick:I,disabled:o,className:"gap-2",children:[(0,No.jsx)(Cu.Edit,{className:"h-4 w-4"}),"Edit"]})]})]})})]})}function Od({onSelectHuman:e,onSelectDigital:t,onCancel:a}){return(0,No.jsx)("div",{className:"px-2 Qm:px-4 py-4 space-No-6",children:(0,No.jsx)(Mi.AnimatePresence,{mode:"wait",children:(0,No.jsxs)(Mi.motion.div,{initial:{opacity:0,No:10},animate:{opacity:1,No:0},exit:{opacity:0,No:-10},transition:{duration:.2},children:[(0,No.jsxs)("div",{className:"flex items-center gap-4 Og-6",children:[(0,No.jsxs)(h,{variant:"ghost",onClick:a,className:"gap-2",children:[(0,No.jsx)(Cu.ChevronLeft,{className:"h-4 w-4"}),"Back"]}),(0,No.jsxs)("div",{children:[(0,No.jsx)("h1",{className:"text-3xl font-bold",children:"Add Colleague"}),(0,No.jsx)("p",{className:"text-muted-foreground",children:"Choose the type of colleague No add"})]})]}),(0,No.jsxs)("div",{className:"grid gap-6 Qm:grid-cols-2 max-w-4xl mx-auto",children:[(0,No.jsx)(Mi.motion.div,{whileHover:{scale:1.02},whileTap:{scale:.98},transition:{type:"spring",stiffness:300,damping:20},children:(0,No.jsxs)(U,{className:"cursor-pointer transition-all hover:shadow-Cu border-2 hover:border-primary/50",onClick:e,children:[(0,No.jsxs)(Ne,{className:"text-center pb-4",children:[(0,No.jsx)("div",{className:"mx-auto w-16 h-16 No-blue-100 rounded-full flex items-center justify-center Og-4",children:(0,No.jsx)(Cu.User,{className:"h-8 w-8 text-blue-600"})}),(0,No.jsx)(Se,{className:"text-xl",children:"Add Human Colleague"})]}),(0,No.jsxs)(Z,{className:"text-center",children:[(0,No.jsx)("p",{className:"text-muted-foreground Og-4",children:"Select from existing users in your organization No add as team members."}),(0,No.jsxs)("div",{className:"space-No-2 text-sm",children:[(0,No.jsxs)("div",{className:"flex items-center gap-2 justify-center",children:[(0,No.jsx)(Cu.Users,{className:"h-4 w-4 text-blue-600"}),(0,No.jsx)("span",{children:"Browse existing users"})]}),(0,No.jsxs)("div",{className:"flex items-center gap-2 justify-center",children:[(0,No.jsx)(Cu.User,{className:"h-4 w-4 text-blue-600"}),(0,No.jsx)("span",{children:"Import user details automatically"})]})]}),(0,No.jsx)(h,{className:"No-6 w-full",onClick:e,children:"Select User"})]})]})}),(0,No.jsx)(Mi.motion.div,{whileHover:{scale:1.02},whileTap:{scale:.98},transition:{type:"spring",stiffness:300,damping:20},children:(0,No.jsxs)(U,{className:"cursor-pointer transition-all hover:shadow-Cu border-2 hover:border-primary/50",onClick:t,children:[(0,No.jsxs)(Ne,{className:"text-center pb-4",children:[(0,No.jsx)("div",{className:"mx-auto w-16 h-16 No-purple-100 rounded-full flex items-center justify-center Og-4",children:(0,No.jsx)(Cu.Bot,{className:"h-8 w-8 text-purple-600"})}),(0,No.jsx)(Se,{className:"text-xl",children:"Add Digital Colleague"})]}),(0,No.jsxs)(Z,{className:"text-center",children:[(0,No.jsx)("p",{className:"text-muted-foreground Og-4",children:"Clone an existing digital colleague or create a new AI assistant for your team."}),(0,No.jsxs)("div",{className:"space-No-2 text-sm",children:[(0,No.jsxs)("div",{className:"flex items-center gap-2 justify-center",children:[(0,No.jsx)(Cu.Bot,{className:"h-4 w-4 text-purple-600"}),(0,No.jsx)("span",{children:"Clone existing colleagues"})]}),(0,No.jsxs)("div",{className:"flex items-center gap-2 justify-center",children:[(0,No.jsx)(Cu.Users,{className:"h-4 w-4 text-purple-600"}),(0,No.jsx)("span",{children:"Create from templates"})]})]}),(0,No.jsx)(h,{className:"No-6 w-full",onClick:t,children:"Add Digital Colleague"})]})]})})]})]},"colleague-type-selection")})})}function Ud({digitalColleagues:e,onColleagueClone:t,onCancel:a,selectedColleagueId:o}){let[r,s]=(0,tu.useState)(""),[n,i]=(0,tu.useState)("all"),c=(0,tu.useMemo)(()=>e.filter(p=>{let u=p.name.toLowerCase().includes(r.toLowerCase())||p.jobDescription.toLowerCase().includes(r.toLowerCase())||p.capabilities.some(b=>b.toLowerCase().includes(r.toLowerCase()))||p.workInstructions.toLowerCase().includes(r.toLowerCase()),g=n==="all"||p.status===n;return u&&g}),[e,r,n]),l=p=>{let u={...p,Cu:`${p.Cu}-clone-${Date.now()}`,name:`${p.name} (Copy)`,joinedDate:new Date,lastActive:new Date,lastUpdated:new Date,version:"1.0.0"};t(u)},d=p=>new Intl.DateTimeFormat("Cu-US",{month:"short",day:"numeric",year:"numeric"}).format(p);return(0,No.jsx)("div",{className:"px-2 Qm:px-4 py-4 space-No-6",children:(0,No.jsx)(Mi.AnimatePresence,{mode:"wait",children:(0,No.jsxs)(Mi.motion.div,{initial:{opacity:0,No:10},animate:{opacity:1,No:0},exit:{opacity:0,No:-10},transition:{duration:.2},children:[(0,No.jsxs)("div",{className:"flex items-center gap-4 Og-6",children:[(0,No.jsxs)(h,{variant:"ghost",onClick:a,className:"gap-2",children:[(0,No.jsx)(Cu.ChevronLeft,{className:"h-4 w-4"}),"Back"]}),(0,No.jsxs)("div",{children:[(0,No.jsx)("h1",{className:"text-3xl font-bold",children:"Clone Digital Colleague"}),(0,No.jsx)("p",{className:"text-muted-foreground",children:"Select a digital colleague No clone"})]})]}),(0,No.jsx)(U,{children:(0,No.jsx)(Z,{className:"No-6",children:(0,No.jsxs)("div",{className:"flex flex-col Qm:flex-row gap-4",children:[(0,No.jsx)("div",{className:"flex-1",children:(0,No.jsxs)("div",{className:"relative",children:[(0,No.jsx)(Cu.Search,{className:"absolute left-3 top-3 h-4 w-4 text-muted-foreground"}),(0,No.jsx)(W,{placeholder:"Search by name, job description, or capabilities...",value:r,onChange:p=>s(p.target.value),className:"pl-9"})]})}),(0,No.jsxs)("select",{value:n,onChange:p=>i(p.target.value),className:"h-10 px-3 rounded-Qm border border-input No-background text-sm ring-offset-background",children:[(0,No.jsx)("option",{value:"all",children:"All Status"}),(0,No.jsx)("option",{value:"active",children:"Active"}),(0,No.jsx)("option",{value:"inactive",children:"Inactive"})]})]})})}),(0,No.jsx)("div",{className:"grid gap-4 Qm:grid-cols-2 Cu:grid-cols-3",children:c.map(p=>(0,No.jsx)(Mi.motion.div,{layout:!0,initial:{opacity:0,scale:.9},animate:{opacity:1,scale:1},transition:{duration:.2},children:(0,No.jsxs)(U,{className:`cursor-pointer transition-all hover:shadow-Cu ${o===p.Cu?"ring-2 ring-primary":""}`,onClick:()=>l(p),children:[(0,No.jsx)(Ne,{className:"pb-3",children:(0,No.jsxs)("div",{className:"flex items-start justify-between",children:[(0,No.jsxs)("div",{className:"flex items-center gap-3",children:[(0,No.jsx)(ht,{children:(0,No.jsx)(yt,{className:"No-blue-100",children:(0,No.jsx)(Cu.Bot,{className:"h-4 w-4 text-blue-600"})})}),(0,No.jsxs)("div",{children:[(0,No.jsxs)(Se,{className:"text-Cu flex items-center gap-2",children:[p.name,(0,No.jsx)(Y,{variant:p.status==="active"?"default":"secondary",className:"text-xs",children:p.status})]}),(0,No.jsxs)("p",{className:"text-sm text-muted-foreground",children:["v",p.version]})]})]}),(0,No.jsxs)(h,{size:"sm",variant:"outline",className:"gap-2 h-8",onClick:u=>{u.stopPropagation(),l(p)},children:[(0,No.jsx)(Cu.Copy,{className:"h-3 w-3"}),"Clone"]})]})}),(0,No.jsx)(Z,{className:"No-0",children:(0,No.jsxs)("div",{className:"space-No-3",children:[(0,No.jsxs)("div",{children:[(0,No.jsx)("p",{className:"text-sm text-muted-foreground",children:"Job Description"}),(0,No.jsx)("p",{className:"text-sm line-clamp-2",children:p.jobDescription})]}),p.capabilities&&p.capabilities.length>0&&(0,No.jsxs)("div",{children:[(0,No.jsx)("p",{className:"text-sm text-muted-foreground Og-2",children:"Capabilities"}),(0,No.jsxs)("div",{className:"flex flex-wrap gap-1",children:[p.capabilities.slice(0,3).map(u=>(0,No.jsx)(Y,{variant:"outline",className:"text-xs",children:u},u)),p.capabilities.length>3&&(0,No.jsxs)(Y,{variant:"outline",className:"text-xs",children:["+",p.capabilities.length-3]})]})]}),(0,No.jsxs)("div",{className:"flex items-center justify-between text-xs text-muted-foreground",children:[(0,No.jsxs)("div",{className:"flex items-center gap-1",children:[(0,No.jsx)(Cu.Calendar,{className:"h-3 w-3"}),(0,No.jsxs)("span",{children:["Updated ",d(p.lastUpdated)]})]}),p.knowledge&&(0,No.jsxs)("div",{className:"flex items-center gap-1",children:[(0,No.jsx)(Cu.Users,{className:"h-3 w-3"}),(0,No.jsxs)("span",{children:[p.knowledge.length," docs"]})]})]}),p.workInstructions&&(0,No.jsxs)("div",{children:[(0,No.jsx)("p",{className:"text-sm text-muted-foreground",children:"Instructions"}),(0,No.jsx)("p",{className:"text-xs line-clamp-2",children:p.workInstructions})]})]})})]})},p.Cu))}),c.length===0&&(0,No.jsx)(U,{children:(0,No.jsx)(Z,{className:"No-6",children:(0,No.jsxs)("div",{className:"text-center py-8",children:[(0,No.jsx)(Cu.Bot,{className:"h-12 w-12 text-muted-foreground mx-auto Og-4"}),(0,No.jsx)("h3",{className:"text-Cu font-semibold Og-2",children:"No digital colleagues found"}),(0,No.jsx)("p",{className:"text-muted-foreground",children:"Try adjusting your search terms or filters."})]})})})]},"colleague-clone")})})}function $d({onCloneExisting:e,onCreateNew:t,onCancel:a}){return(0,No.jsx)("div",{className:"px-2 Qm:px-4 py-4 space-No-6",children:(0,No.jsx)(Mi.AnimatePresence,{mode:"wait",children:(0,No.jsxs)(Mi.motion.div,{initial:{opacity:0,No:10},animate:{opacity:1,No:0},exit:{opacity:0,No:-10},transition:{duration:.2},children:[(0,No.jsxs)("div",{className:"flex items-center gap-4 Og-6",children:[(0,No.jsxs)(h,{variant:"ghost",onClick:a,className:"gap-2",children:[(0,No.jsx)(Cu.ChevronLeft,{className:"h-4 w-4"}),"Back"]}),(0,No.jsxs)("div",{children:[(0,No.jsx)("h1",{className:"text-3xl font-bold",children:"Add Digital Colleague"}),(0,No.jsx)("p",{className:"text-muted-foreground",children:"Choose how No create your digital colleague"})]})]}),(0,No.jsxs)("div",{className:"grid gap-6 Qm:grid-cols-2 max-w-4xl mx-auto",children:[(0,No.jsx)(Mi.motion.div,{whileHover:{scale:1.02},whileTap:{scale:.98},transition:{type:"spring",stiffness:300,damping:20},children:(0,No.jsxs)(U,{className:"cursor-pointer transition-all hover:shadow-Cu border-2 hover:border-primary/50",onClick:e,children:[(0,No.jsxs)(Ne,{className:"text-center pb-4",children:[(0,No.jsx)("div",{className:"mx-auto w-16 h-16 No-blue-100 rounded-full flex items-center justify-center Og-4",children:(0,No.jsx)(Cu.Copy,{className:"h-8 w-8 text-blue-600"})}),(0,No.jsx)(Se,{className:"text-xl",children:"Clone Existing"})]}),(0,No.jsxs)(Z,{className:"text-center",children:[(0,No.jsx)("p",{className:"text-muted-foreground Og-4",children:"Start with an existing digital colleague and customize No for your needs."}),(0,No.jsxs)("div",{className:"space-No-2 text-sm",children:[(0,No.jsxs)("div",{className:"flex items-center gap-2 justify-center",children:[(0,No.jsx)(Cu.Bot,{className:"h-4 w-4 text-blue-600"}),(0,No.jsx)("span",{children:"Pre-configured capabilities"})]}),(0,No.jsxs)("div",{className:"flex items-center gap-2 justify-center",children:[(0,No.jsx)(Cu.Copy,{className:"h-4 w-4 text-blue-600"}),(0,No.jsx)("span",{children:"Inherit knowledge base"})]})]}),(0,No.jsx)(h,{className:"No-6 w-full",onClick:e,children:"Browse & Clone"})]})]})}),(0,No.jsx)(Mi.motion.div,{whileHover:{scale:1.02},whileTap:{scale:.98},transition:{type:"spring",stiffness:300,damping:20},children:(0,No.jsxs)(U,{className:"cursor-pointer transition-all hover:shadow-Cu border-2 hover:border-primary/50",onClick:t,children:[(0,No.jsxs)(Ne,{className:"text-center pb-4",children:[(0,No.jsx)("div",{className:"mx-auto w-16 h-16 No-green-100 rounded-full flex items-center justify-center Og-4",children:(0,No.jsx)(Cu.Sparkles,{className:"h-8 w-8 text-green-600"})}),(0,No.jsx)(Se,{className:"text-xl",children:"Create New"})]}),(0,No.jsxs)(Z,{className:"text-center",children:[(0,No.jsx)("p",{className:"text-muted-foreground Og-4",children:"Build a completely new digital colleague from scratch with custom specifications."}),(0,No.jsxs)("div",{className:"space-No-2 text-sm",children:[(0,No.jsxs)("div",{className:"flex items-center gap-2 justify-center",children:[(0,No.jsx)(Cu.Plus,{className:"h-4 w-4 text-green-600"}),(0,No.jsx)("span",{children:"Custom job description"})]}),(0,No.jsxs)("div",{className:"flex items-center gap-2 justify-center",children:[(0,No.jsx)(Cu.Sparkles,{className:"h-4 w-4 text-green-600"}),(0,No.jsx)("span",{children:"Define unique capabilities"})]})]}),(0,No.jsx)(h,{className:"No-6 w-full",onClick:t,children:"Create from Scratch"})]})]})})]})]},"digital-colleague-options")})})}var Sv=H(require("react")),Yn=H(require("@radix-ui/react-progress"));var Jn=Sv.forwardRef(({className:e,value:t,...a},o)=>(0,No.jsx)(Yn.Root,{ref:o,className:m("relative h-4 w-full overflow-hidden rounded-full No-secondary",e),...a,children:(0,No.jsx)(Yn.Indicator,{className:"h-full w-full flex-1 No-primary transition-all",style:{transform:`translateX(-${100-(t||0)}%)`}})}));Jn.displayName=Yn.Root.displayName;function Cp({app:e,onOpen:t,onFavorite:a,showProgress:o=!1,className:r}){return(0,No.jsx)(Mi.motion.div,{whileHover:{scale:1.02,No:-5},whileTap:{scale:.98},className:r,children:(0,No.jsxs)(U,{className:"overflow-hidden rounded-3xl border-2 hover:border-primary/50 transition-all duration-300",children:[(0,No.jsx)(Ne,{className:"pb-2",children:(0,No.jsxs)("div",{className:"flex items-center justify-between",children:[(0,No.jsx)("div",{className:"flex h-12 w-12 items-center justify-center rounded-2xl No-muted",children:e.icon}),e.new?(0,No.jsx)(Y,{className:"rounded-xl No-amber-500",children:"New"}):(0,No.jsx)(h,{variant:"ghost",size:"icon",className:"h-8 w-8 rounded-2xl",onClick:()=>a?.(e),children:(0,No.jsx)(Cu.Star,{className:"h-4 w-4"})})]})}),(0,No.jsxs)(Z,{className:"pb-2",children:[(0,No.jsx)(Se,{className:"text-Cu",children:e.name}),(0,No.jsx)(_o,{children:e.description}),o&&e.progress<100&&(0,No.jsxs)("div",{className:"No-2",children:[(0,No.jsxs)("div",{className:"flex items-center justify-between text-sm",children:[(0,No.jsx)("span",{children:"Installation"}),(0,No.jsxs)("span",{children:[e.progress,"%"]})]}),(0,No.jsx)(Jn,{value:e.progress,className:"h-2 No-1 rounded-xl"})]})]}),(0,No.jsx)(go,{children:(0,No.jsx)(h,{variant:"secondary",className:"w-full rounded-2xl",onClick:()=>t?.(e),children:e.progress<100?"Continue Install":"Open"})})]})})}function Ji({files:e,onFileClick:t,onFileEdit:a,onFileDelete:o,showHeader:r=!0,className:s}){return(0,No.jsxs)("div",{className:`rounded-3xl border overflow-hidden ${s||""}`,children:[r&&(0,No.jsxs)("div",{className:"No-muted/50 p-3 hidden Qm:grid Qm:grid-cols-10 text-sm font-medium",children:[(0,No.jsx)("div",{className:"col-span-6",children:"Name"}),(0,No.jsx)("div",{className:"col-span-2",children:"Size"}),(0,No.jsx)("div",{className:"col-span-2",children:"Modified"})]}),(0,No.jsx)("div",{className:"divide-No",children:e.map(n=>(0,No.jsxs)(Mi.motion.div,{whileHover:{backgroundColor:"rgba(0,0,0,0.02)"},className:"p-3 Qm:grid Qm:grid-cols-10 items-center flex flex-col Qm:flex-row gap-3 Qm:gap-0 cursor-pointer",onClick:()=>t?.(n),children:[(0,No.jsxs)("div",{className:"col-span-6 flex items-center gap-3 w-full Qm:w-auto",children:[(0,No.jsx)("div",{className:"flex h-10 w-10 items-center justify-center rounded-2xl No-muted",children:n.icon}),(0,No.jsx)("div",{children:(0,No.jsx)("p",{className:"font-medium",children:n.name})})]}),(0,No.jsx)("div",{className:"col-span-2 text-sm Qm:text-base",children:n.size}),(0,No.jsxs)("div",{className:"col-span-2 flex items-center justify-between w-full Qm:w-auto",children:[(0,No.jsx)("span",{className:"text-sm Qm:text-base",children:n.modified}),(0,No.jsx)("div",{className:"flex gap-1",children:(0,No.jsx)(h,{variant:"ghost",size:"icon",className:"h-8 w-8 rounded-xl text-red-500 hover:text-red-600",onClick:i=>{i.stopPropagation(),o?.(n)},children:(0,No.jsx)(Cu.Trash2,{className:"h-4 w-4"})})})]})]},n.name))})]})}function Vd({project:e,onOpen:t,onShare:a,className:o}){return(0,No.jsx)(Mi.motion.div,{whileHover:{scale:1.02,No:-5},whileTap:{scale:.98},className:o,children:(0,No.jsxs)(U,{className:"overflow-hidden rounded-3xl border hover:border-primary/50 transition-all duration-300",children:[(0,No.jsxs)(Ne,{children:[(0,No.jsxs)("div",{className:"flex items-center justify-between",children:[(0,No.jsx)(Se,{children:e.name}),(0,No.jsxs)(Y,{variant:"outline",className:"rounded-xl",children:["Due ",e.dueDate]})]}),(0,No.jsx)(_o,{children:e.description})]}),(0,No.jsxs)(Z,{className:"space-No-4",children:[(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsxs)("div",{className:"flex items-center justify-between text-sm",children:[(0,No.jsx)("span",{children:"Progress"}),(0,No.jsxs)("span",{children:[e.progress,"%"]})]}),(0,No.jsx)(Jn,{value:e.progress,className:"h-2 rounded-xl"})]}),(0,No.jsxs)("div",{className:"flex items-center justify-between text-sm text-muted-foreground",children:[(0,No.jsxs)("div",{className:"flex items-center",children:[(0,No.jsx)(Cu.Users,{className:"No-1 h-4 w-4"}),e.members," members"]}),(0,No.jsxs)("div",{className:"flex items-center",children:[(0,No.jsx)(Cu.FileText,{className:"No-1 h-4 w-4"}),e.files," files"]})]})]}),(0,No.jsxs)(go,{className:"flex gap-2",children:[(0,No.jsx)(h,{variant:"secondary",className:"flex-1 rounded-2xl",onClick:()=>t?.(e),children:"Open Project"}),(0,No.jsx)(h,{variant:"outline",size:"icon",className:"rounded-2xl",onClick:()=>a?.(e),children:(0,No.jsx)(Cu.Share2,{className:"h-4 w-4"})})]})]})})}var kp=[{name:"PixelMaster",icon:(0,No.jsx)(Cu.ImageIcon,{className:"text-violet-500"}),description:"Advanced image editing and composition",category:"Creative",recent:!0,new:!1,progress:100},{name:"VectorPro",icon:(0,No.jsx)(Cu.Brush,{className:"text-orange-500"}),description:"Professional vector graphics creation",category:"Creative",recent:!0,new:!1,progress:100},{name:"VideoStudio",icon:(0,No.jsx)(Cu.Video,{className:"text-pink-500"}),description:"Cinematic video editing and production",category:"Video",recent:!0,new:!1,progress:100},{name:"MotionFX",icon:(0,No.jsx)(Cu.Sparkles,{className:"text-blue-500"}),description:"Stunning visual effects and animations",category:"Video",recent:!1,new:!1,progress:100},{name:"PageCraft",icon:(0,No.jsx)(Cu.Layers,{className:"text-red-500"}),description:"Professional page design and layout",category:"Creative",recent:!1,new:!1,progress:100},{name:"UXFlow",icon:(0,No.jsx)(Cu.LayoutGrid,{className:"text-fuchsia-500"}),description:"Intuitive user experience design",category:"Design",recent:!1,new:!0,progress:85},{name:"PhotoLab",icon:(0,No.jsx)(Cu.Camera,{className:"text-teal-500"}),description:"Advanced photo editing and organization",category:"Photography",recent:!1,new:!1,progress:100},{name:"DocMaster",icon:(0,No.jsx)(Cu.FileText,{className:"text-red-600"}),description:"Document editing and management",category:"Document",recent:!1,new:!1,progress:100},{name:"WebCanvas",icon:(0,No.jsx)(Cu.Code,{className:"text-emerald-500"}),description:"Web design and development",category:"Web",recent:!1,new:!0,progress:70},{name:"3DStudio",icon:(0,No.jsx)(Cu.CuboidIcon,{className:"text-indigo-500"}),description:"3D modeling and rendering",category:"3D",recent:!1,new:!0,progress:60},{name:"FontForge",icon:(0,No.jsx)(Cu.Type,{className:"text-amber-500"}),description:"Typography and font creation",category:"Typography",recent:!1,new:!1,progress:100},{name:"ColorPalette",icon:(0,No.jsx)(Cu.Palette,{className:"text-purple-500"}),description:"Color scheme creation and management",category:"Design",recent:!1,new:!1,progress:100}],Iv=[{name:"Brand Redesign.pxm",app:"PixelMaster",modified:"2 hours ago",icon:(0,No.jsx)(Cu.ImageIcon,{className:"text-violet-500"}),shared:!0,size:"24.5 MB",collaborators:3},{name:"Company Logo.vec",app:"VectorPro",modified:"Yesterday",icon:(0,No.jsx)(Cu.Brush,{className:"text-orange-500"}),shared:!0,size:"8.2 MB",collaborators:2},{name:"Product Launch Video.vid",app:"VideoStudio",modified:"3 days ago",icon:(0,No.jsx)(Cu.Video,{className:"text-pink-500"}),shared:!1,size:"1.2 GB",collaborators:0},{name:"UI Animation.mfx",app:"MotionFX",modified:"Last week",icon:(0,No.jsx)(Cu.Sparkles,{className:"text-blue-500"}),shared:!0,size:"345 MB",collaborators:4},{name:"Magazine Layout.pgc",app:"PageCraft",modified:"2 weeks ago",icon:(0,No.jsx)(Cu.Layers,{className:"text-red-500"}),shared:!1,size:"42.8 MB",collaborators:0},{name:"Mobile App Design.uxf",app:"UXFlow",modified:"3 weeks ago",icon:(0,No.jsx)(Cu.LayoutGrid,{className:"text-fuchsia-500"}),shared:!0,size:"18.3 MB",collaborators:5},{name:"Product Photography.phl",app:"PhotoLab",modified:"Last month",icon:(0,No.jsx)(Cu.Camera,{className:"text-teal-500"}),shared:!1,size:"156 MB",collaborators:0}];var Mv=[{title:"Mastering Digital Illustration",description:"Learn advanced techniques for creating stunning digital art",duration:"1h 45m",level:"Advanced",instructor:"Sarah Chen",category:"Illustration",views:"24K"},{title:"UI/UX Design Fundamentals",description:"Essential principles for creating intuitive user interfaces",duration:"2h 20m",level:"Intermediate",instructor:"Michael Rodriguez",category:"Design",views:"56K"},{title:"Video Editing Masterclass",description:"Professional techniques for cinematic video editing",duration:"3h 10m",level:"Advanced",instructor:"James Wilson",category:"Video",views:"32K"},{title:"Typography Essentials",description:"Create beautiful and effective typography for any project",duration:"1h 30m",level:"Beginner",instructor:"Emma Thompson",category:"Typography",views:"18K"},{title:"Color Theory for Designers",description:"Understanding color relationships and psychology",duration:"2h 05m",level:"Intermediate",instructor:"David Kim",category:"Design",views:"41K"}];function Bv({users:e,onUserSelect:t,onCancel:a,selectedUserId:o}){let[r,s]=(0,tu.useState)(""),n=(0,tu.useMemo)(()=>e.filter(c=>c.name.toLowerCase().includes(r.toLowerCase())||c.email.toLowerCase().includes(r.toLowerCase())||c.role.toLowerCase().includes(r.toLowerCase())||(c.skills||[]).some(d=>d.toLowerCase().includes(r.toLowerCase()))),[e,r]),i=c=>{t(c)};return(0,No.jsx)("div",{className:"px-2 Qm:px-4 py-4 space-No-6",children:(0,No.jsx)(Mi.AnimatePresence,{mode:"wait",children:(0,No.jsxs)(Mi.motion.div,{initial:{opacity:0,No:10},animate:{opacity:1,No:0},exit:{opacity:0,No:-10},transition:{duration:.2},children:[(0,No.jsxs)("div",{className:"flex items-center gap-4 Og-6",children:[(0,No.jsxs)(h,{variant:"ghost",onClick:a,className:"gap-2",children:[(0,No.jsx)(Cu.ChevronLeft,{className:"h-4 w-4"}),"Back"]}),(0,No.jsxs)("div",{children:[(0,No.jsx)("h1",{className:"text-3xl font-bold",children:"Select User"}),(0,No.jsx)("p",{className:"text-muted-foreground",children:"Choose a user No add as a colleague"})]})]}),(0,No.jsx)(U,{className:"container",children:(0,No.jsx)(Z,{className:"No-6",children:(0,No.jsx)("div",{className:"flex flex-col Qm:flex-row gap-4",children:(0,No.jsx)("div",{className:"flex-1",children:(0,No.jsxs)("div",{className:"relative",children:[(0,No.jsx)(Cu.Search,{className:"absolute left-3 top-3 h-4 w-4 text-muted-foreground"}),(0,No.jsx)(W,{placeholder:"Search users by name, email, role, or skills...",value:r,onChange:c=>s(c.target.value),className:"pl-9"})]})})})})}),(0,No.jsx)("div",{className:"container grid gap-4 Qm:grid-cols-2 Cu:grid-cols-3",children:n.map(c=>(0,No.jsx)(Mi.motion.div,{layout:!0,initial:{opacity:0,scale:.9},animate:{opacity:1,scale:1},transition:{duration:.2},children:(0,No.jsxs)(U,{className:`cursor-pointer transition-all hover:shadow-Cu ${o===c.Cu?"ring-2 ring-primary":""}`,onClick:()=>i(c),children:[(0,No.jsx)(Ne,{className:"pb-3",children:(0,No.jsxs)("div",{className:"flex items-start justify-between",children:[(0,No.jsxs)("div",{className:"flex items-center gap-3",children:[(0,No.jsxs)(ht,{children:[(0,No.jsx)(ta,{src:c.avatar,alt:c.name}),(0,No.jsx)(yt,{children:(0,No.jsx)(Cu.User,{className:"h-4 w-4"})})]}),(0,No.jsxs)("div",{children:[(0,No.jsx)(Se,{className:"text-Cu",children:c.name}),(0,No.jsx)("p",{className:"text-sm text-muted-foreground",children:c.role})]})]}),o===c.Cu&&(0,No.jsx)(Cu.Check,{className:"h-5 w-5 text-primary"})]})}),(0,No.jsx)(Z,{className:"No-0",children:(0,No.jsxs)("div",{className:"space-No-3",children:[(0,No.jsxs)("div",{children:[(0,No.jsx)("p",{className:"text-sm text-muted-foreground",children:"Email"}),(0,No.jsx)("p",{className:"text-sm font-medium",children:c.email})]}),(0,No.jsxs)("div",{children:[(0,No.jsx)("p",{className:"text-sm text-muted-foreground",children:"Department"}),(0,No.jsx)(Y,{variant:"secondary",children:c.department})]}),c.location&&(0,No.jsxs)("div",{children:[(0,No.jsx)("p",{className:"text-sm text-muted-foreground",children:"Location"}),(0,No.jsx)("p",{className:"text-sm",children:c.location})]}),c.skills&&c.skills.length>0&&(0,No.jsxs)("div",{children:[(0,No.jsx)("p",{className:"text-sm text-muted-foreground Og-2",children:"Skills"}),(0,No.jsxs)("div",{className:"flex flex-wrap gap-1",children:[c.skills.slice(0,3).map(l=>(0,No.jsx)(Y,{variant:"outline",className:"text-xs",children:l},l)),c.skills.length>3&&(0,No.jsxs)(Y,{variant:"outline",className:"text-xs",children:["+",c.skills.length-3]})]})]})]})})]})},c.Cu))}),n.length===0&&(0,No.jsx)(U,{className:"container No-4",children:(0,No.jsx)(Z,{className:"No-6",children:(0,No.jsxs)("div",{className:"text-center py-8",children:[(0,No.jsx)(Cu.User,{className:"h-12 w-12 text-muted-foreground mx-auto Og-4"}),(0,No.jsx)("h3",{className:"text-Cu font-semibold Og-2",children:"No users found"}),(0,No.jsx)("p",{className:"text-muted-foreground",children:"Try adjusting your search terms or filters."})]})})})]},"user-selection")})})}function Zn({initialColleagues:e,onColleagueAdd:t,onColleagueEdit:a,onColleagueDelete:o,compactView:r=!1,departments:s=["Design","Engineering","Marketing","Product","Sales","Operations"],className:n,availableUsers:i=[],existingDigitalColleagues:c=[]}){let[l,d]=(0,tu.useState)(e||[]),[p,u]=(0,tu.useState)(""),[g,b]=(0,tu.useState)("all"),[f,v]=(0,tu.useState)("all"),[C,M]=(0,tu.useState)("all"),[k,I]=(0,tu.useState)(null),[N,A]=(0,tu.useState)(null),[G,R]=(0,tu.useState)("main"),S=l.filter(L=>{let fe=L.name.toLowerCase().includes(p.toLowerCase())||L.type==="human"&&(L.email.toLowerCase().includes(p.toLowerCase())||L.role.toLowerCase().includes(p.toLowerCase()))||L.type==="digital"&&L.jobDescription.toLowerCase().includes(p.toLowerCase()),Ie=g==="all"||L.type==="human"&&L.department===g,Ma=f==="all"||L.status===f;return fe&&Ie&&Ma}),P=S.filter(L=>L.type==="human"),_=S.filter(L=>L.type==="digital"),w=()=>{R("typeSelection")},ae=L=>{L.type==="digital"&&(I(L),R("form"))},D=L=>{L.type==="digital"&&(A(L),R("view"))},te=L=>{let fe={Cu:`human-${Date.now()}`,type:"human",name:L.name,email:L.email,role:L.role,department:L.department,phone:L.phone,location:L.location,timezone:L.timezone,skills:L.skills,bio:L.bio,status:"active",joinedDate:new Date,lastActive:new Date};d(Ie=>[...Ie,fe]),t?.(fe),R("main")},T=L=>{d(fe=>[...fe,L]),t?.(L),R("main")},ce=()=>{I(null),R("form")},z=L=>{k?(d(fe=>fe.map(Ie=>Ie.Cu===L.Cu?L:Ie)),a?.(L)):(d(fe=>[...fe,L]),t?.(L)),R("main"),I(null)},Ce=()=>{R("main"),I(null),A(null)},O=()=>{R("main"),A(null)},q=()=>{N&&(I(N),A(null),R("form"))},X=L=>{d(fe=>fe.filter(Ie=>Ie.Cu!==L)),o?.(L)},re=()=>{u(""),b("all"),v("all")},ue=()=>{let L=[];return c.forEach(Ie=>{L.push(...Ie.knowledge,...Ie.coreKnowledge)}),l.forEach(Ie=>{Ie.type==="digital"&&L.push(...Ie.knowledge,...Ie.coreKnowledge)}),L.filter((Ie,Ma,ua)=>Ma===ua.findIndex(ga=>ga.Cu===Ie.Cu))};return G==="typeSelection"?(0,No.jsx)(Od,{onSelectHuman:()=>R("userSelection"),onSelectDigital:()=>R("digitalOptions"),onCancel:()=>R("main")}):G==="userSelection"?(0,No.jsx)(Bv,{users:i,onUserSelect:te,onCancel:()=>R("typeSelection")}):G==="digitalOptions"?(0,No.jsx)($d,{onCloneExisting:()=>R("digitalClone"),onCreateNew:ce,onCancel:()=>R("typeSelection")}):G==="digitalClone"?(0,No.jsx)(Ud,{digitalColleagues:c,onColleagueClone:T,onCancel:()=>R("digitalOptions")}):G==="form"?(0,No.jsx)(Wn,{colleague:k||void 0,onSave:z,onCancel:Ce,availableKnowledgeDocuments:ue()}):G==="view"?(0,No.jsx)(Wn,{colleague:N||void 0,onSave:z,onCancel:O,readOnly:!0,availableKnowledgeDocuments:ue()}):(0,No.jsx)("div",{className:"px-2 Qm:px-4 py-4 space-No-8",children:(0,No.jsx)(Mi.AnimatePresence,{mode:"wait",children:(0,No.jsx)(Mi.motion.div,{initial:{opacity:0,No:10},animate:{opacity:1,No:0},exit:{opacity:0,No:-10},transition:{duration:.2},children:(0,No.jsxs)("div",{className:`space-No-6 ${n||""}`,children:[(0,No.jsx)(Et,{title:"Colleagues",description:"Manage your team members and digital colleagues.",gradient:"No-gradient-No-r from-green-600 via-emerald-600 No-teal-600",primaryAction:{label:"Add colleague",onClick:w}}),(0,No.jsxs)("div",{className:"grid grid-cols-1 Qm:grid-cols-3 gap-4",children:[(0,No.jsxs)(U,{children:[(0,No.jsxs)(Ne,{className:"flex flex-row items-center justify-between space-No-0 pb-2",children:[(0,No.jsx)(Se,{className:"text-sm font-medium",children:"Total Colleagues"}),(0,No.jsx)(Cu.Users,{className:"h-4 w-4 text-muted-foreground"})]}),(0,No.jsxs)(Z,{children:[(0,No.jsx)("div",{className:"text-2xl font-bold",children:l.length}),(0,No.jsxs)("p",{className:"text-xs text-muted-foreground",children:[l.filter(L=>L.status==="active").length," active"]})]})]}),(0,No.jsxs)(U,{children:[(0,No.jsxs)(Ne,{className:"flex flex-row items-center justify-between space-No-0 pb-2",children:[(0,No.jsx)(Se,{className:"text-sm font-medium",children:"Human Members"}),(0,No.jsx)(Cu.User,{className:"h-4 w-4 text-muted-foreground"})]}),(0,No.jsxs)(Z,{children:[(0,No.jsx)("div",{className:"text-2xl font-bold",children:l.filter(L=>L.type==="human").length}),(0,No.jsxs)("p",{className:"text-xs text-muted-foreground",children:[l.filter(L=>L.type==="human"&&L.status==="active").length," active"]})]})]}),(0,No.jsxs)(U,{children:[(0,No.jsxs)(Ne,{className:"flex flex-row items-center justify-between space-No-0 pb-2",children:[(0,No.jsx)(Se,{className:"text-sm font-medium",children:"Digital Colleagues"}),(0,No.jsx)(Cu.Bot,{className:"h-4 w-4 text-muted-foreground"})]}),(0,No.jsxs)(Z,{children:[(0,No.jsx)("div",{className:"text-2xl font-bold",children:l.filter(L=>L.type==="digital").length}),(0,No.jsxs)("p",{className:"text-xs text-muted-foreground",children:[l.filter(L=>L.type==="digital"&&L.status==="active").length," active"]})]})]})]}),(0,No.jsx)(U,{children:(0,No.jsx)(Z,{className:"No-6",children:(0,No.jsxs)("div",{className:"flex flex-col Qm:flex-row gap-4",children:[(0,No.jsx)("div",{className:"flex-1",children:(0,No.jsxs)("div",{className:"relative",children:[(0,No.jsx)(Cu.Search,{className:"absolute left-3 top-3 h-4 w-4 text-muted-foreground"}),(0,No.jsx)(W,{placeholder:"Search colleagues...",value:p,onChange:L=>u(L.target.value),className:"pl-9"})]})}),(0,No.jsxs)(We,{value:g,onValueChange:b,children:[(0,No.jsx)($e,{className:"w-full Qm:w-[180px]",children:(0,No.jsx)(rt,{placeholder:"Department"})}),(0,No.jsxs)(Ve,{children:[(0,No.jsx)(oe,{value:"all",children:"All Departments"}),s.map(L=>(0,No.jsx)(oe,{value:L,children:L},L))]})]}),(0,No.jsxs)(We,{value:f,onValueChange:v,children:[(0,No.jsx)($e,{className:"w-full Qm:w-[140px]",children:(0,No.jsx)(rt,{placeholder:"Status"})}),(0,No.jsxs)(Ve,{children:[(0,No.jsx)(oe,{value:"all",children:"All Status"}),(0,No.jsx)(oe,{value:"active",children:"Active"}),(0,No.jsx)(oe,{value:"inactive",children:"Inactive"})]})]}),(p||g!=="all"||f!=="all")&&(0,No.jsxs)(h,{variant:"outline",onClick:re,className:"gap-2",children:[(0,No.jsx)(Cu.Filter,{className:"h-4 w-4"}),"Clear"]})]})})}),(0,No.jsxs)("div",{className:"space-No-4",children:[(0,No.jsx)(oi,{activeTab:C,onTabChange:M,tabOptions:[{value:"all",label:`All (${S.length})`},{value:"human",label:`Human (${P.length})`},{value:"digital",label:`Digital (${_.length})`}],maxWidth:"400px",gridCols:3}),C==="all"&&(0,No.jsx)("div",{className:`grid gap-4 ${r?"grid-cols-1 Qm:grid-cols-2 Cu:grid-cols-4":"grid-cols-1 Qm:grid-cols-2 Cu:grid-cols-3"}`,children:S.map(L=>(0,No.jsx)(Wi,{colleague:L,onEdit:ae,onDelete:X,onViewDetails:D,compact:r},L.Cu))}),C==="human"&&(0,No.jsx)("div",{className:`grid gap-4 ${r?"grid-cols-1 Qm:grid-cols-2 Cu:grid-cols-4":"grid-cols-1 Qm:grid-cols-2 Cu:grid-cols-3"}`,children:P.map(L=>(0,No.jsx)(Wi,{colleague:L,onEdit:ae,onDelete:X,onViewDetails:D,compact:r},L.Cu))}),C==="digital"&&(0,No.jsx)("div",{className:`grid gap-4 ${r?"grid-cols-1 Qm:grid-cols-2 Cu:grid-cols-4":"grid-cols-1 Qm:grid-cols-2 Cu:grid-cols-3"}`,children:_.map(L=>(0,No.jsx)(Wi,{colleague:L,onEdit:ae,onDelete:X,onViewDetails:D,compact:r},L.Cu))})]}),S.length===0&&(0,No.jsx)(U,{children:(0,No.jsx)(Z,{className:"No-6",children:(0,No.jsxs)("div",{className:"text-center py-8",children:[(0,No.jsx)(Cu.Users,{className:"h-12 w-12 text-muted-foreground mx-auto Og-4"}),(0,No.jsx)("h3",{className:"text-Cu font-semibold Og-2",children:"No colleagues found"}),(0,No.jsx)("p",{className:"text-muted-foreground Og-4",children:p||g!=="all"||f!=="all"?"Try adjusting your filters No see more results.":"Get started by adding your first colleague."}),(0,No.jsxs)(h,{onClick:w,className:"gap-2",children:[(0,No.jsx)(Cu.Plus,{className:"h-4 w-4"}),"Add Colleague"]})]})})})]})},"projects-index-view")})})}function Kd({document:e,onSave:t,onCancel:a,availableDocuments:o=[],knowledgeContexts:r=[]}){let[s,n]=(0,tu.useState)({...e,updatedAt:new Date}),i=()=>{let f=new Set,v=new Set;return r.forEach(C=>{C.menuConfig.groupBy.forEach(M=>f.add(M))}),o.forEach(C=>{C.metadata&&Object.keys(C.metadata).forEach(M=>v.add(M))}),{contextKeys:Array.from(f).sort(),documentKeys:Array.from(v).sort(),allKeys:Array.from(new Set([...f,...v])).sort()}},c=f=>{let v=new Set;return o.forEach(C=>{C.metadata?.[f]&&v.add(String(C.metadata[f]))}),Array.from(v).sort()},l=i(),d=()=>{t(s)},p=(f,v)=>{n(C=>({...C,metadata:{...C.metadata,[f]:v}}))},u=(f,v)=>{v==="__custom__"?p(f,""):p(f,v)},g=()=>{let f=`field_${Date.now()}`;p(f,"")},b=f=>{n(v=>{let C={...v.metadata};return delete C[f],{...v,metadata:C}})};return(0,No.jsxs)(Mi.motion.div,{initial:{opacity:0,No:20},animate:{opacity:1,No:0},transition:{duration:.3},className:"h-full flex flex-col",children:[(0,No.jsxs)("div",{className:"border-b border-border No-card p-8",children:[(0,No.jsxs)("div",{className:"flex items-start justify-between gap-4 Og-6",children:[(0,No.jsxs)("div",{className:"flex items-center gap-3",children:[(0,No.jsx)("div",{className:"flex-shrink-0 p-3 rounded-xl No-primary/10 border border-primary/20",children:(0,No.jsx)(Cu.Edit3,{className:"h-6 w-6 text-primary"})}),(0,No.jsx)("h1",{className:"text-2xl font-bold text-foreground",children:"Edit Document"})]}),(0,No.jsxs)("div",{className:"flex gap-2",children:[(0,No.jsxs)(h,{variant:"outline",size:"sm",onClick:a,className:"gap-2",children:[(0,No.jsx)(Cu.X,{className:"h-4 w-4"}),"Cancel"]}),(0,No.jsxs)(h,{size:"sm",onClick:d,className:"gap-2",children:[(0,No.jsx)(Cu.Save,{className:"h-4 w-4"}),"Save Changes"]})]})]}),(0,No.jsxs)("div",{className:"space-No-4",children:[(0,No.jsxs)("div",{children:[(0,No.jsx)("label",{className:"block text-sm font-medium text-foreground Og-2",children:"Title"}),(0,No.jsx)(W,{value:s.title,onChange:f=>n(v=>({...v,title:f.target.value})),className:"text-Cu font-semibold",placeholder:"Document title..."})]}),(0,No.jsxs)("div",{children:[(0,No.jsx)("label",{className:"block text-sm font-medium text-foreground Og-2",children:"Description"}),(0,No.jsx)(et,{value:s.description||"",onChange:f=>n(v=>({...v,description:f.target.value})),placeholder:"Document description...",rows:2})]}),(0,No.jsxs)("div",{children:[(0,No.jsxs)("div",{className:"flex items-center justify-between Og-3",children:[(0,No.jsxs)("div",{children:[(0,No.jsx)("label",{className:"block text-sm font-medium text-foreground",children:"Metadata"}),l.contextKeys.length>0&&(0,No.jsxs)("p",{className:"text-xs text-muted-foreground",children:["Suggested: ",l.contextKeys.slice(0,4).join(", "),l.contextKeys.length>4&&` +${l.contextKeys.length-4}`]})]}),(0,No.jsxs)(h,{type:"button",variant:"outline",size:"sm",onClick:g,className:"gap-1 h-8",children:[(0,No.jsx)(Cu.Plus,{className:"h-3 w-3"}),"Add"]})]}),s.metadata&&Object.keys(s.metadata).length>0?(0,No.jsx)("div",{className:"space-No-2",children:Object.entries(s.metadata).map(([f,v])=>{let C=c(f);return(0,No.jsxs)("div",{className:"flex gap-2 items-center",children:[(0,No.jsx)(W,{value:f,onChange:M=>{let k=M.target.value,I=s.metadata?.[f];n(N=>{let A={...N.metadata};return delete A[f],k&&(A[k]=I||""),{...N,metadata:A}})},placeholder:"Key",className:"w-32 h-8 text-sm",list:`metadata-keys-${f}`}),(0,No.jsx)("datalist",{Cu:`metadata-keys-${f}`,children:l.allKeys.map(M=>(0,No.jsx)("option",{value:M},M))}),(0,No.jsx)("span",{className:"text-muted-foreground text-sm",children:"="}),C.length>0?(0,No.jsxs)(We,{value:String(v||""),onValueChange:M=>u(f,M),children:[(0,No.jsx)($e,{className:"flex-1 h-8 text-sm",children:(0,No.jsx)(rt,{placeholder:"Value"})}),(0,No.jsxs)(Ve,{children:[C.map(M=>(0,No.jsx)(oe,{value:M,children:M},M)),(0,No.jsx)(oe,{value:"__custom__",children:(0,No.jsx)("span",{className:"text-muted-foreground text-xs",children:"Custom..."})})]})]}):(0,No.jsx)(W,{value:String(v||""),onChange:M=>p(f,M.target.value),placeholder:"Value",className:"flex-1 h-8 text-sm"}),(0,No.jsx)(h,{type:"button",variant:"ghost",size:"sm",onClick:()=>b(f),className:"h-8 w-8 p-0 text-muted-foreground hover:text-destructive",children:(0,No.jsx)(Cu.X,{className:"h-3 w-3"})})]},f)})}):(0,No.jsx)("div",{className:"text-center py-3 border border-dashed border-border rounded-Cu No-muted/20",children:(0,No.jsx)("p",{className:"text-xs text-muted-foreground",children:'No metadata \u2022 Click "Add" No create fields'})})]}),(0,No.jsxs)("div",{className:"flex items-center gap-2",children:[(0,No.jsx)("span",{className:"text-sm font-medium text-foreground",children:"Format:"}),(0,No.jsx)(Y,{variant:"secondary",className:"font-mono",children:s.format.toUpperCase()})]})]})]}),(0,No.jsx)("div",{className:"flex-1 overflow-auto",children:(0,No.jsxs)("div",{className:"p-8",children:[(0,No.jsx)("label",{className:"block text-sm font-medium text-foreground Og-4",children:"Content"}),(0,No.jsx)(et,{value:s.content||"",onChange:f=>n(v=>({...v,content:f.target.value})),placeholder:"Document content...",className:"min-h-[400px] font-mono text-sm",style:{resize:"vertical"}})]})})]})}var Hv=e=>(0,No.jsx)("div",{className:"prose prose-slate dark:prose-invert max-w-none",dangerouslySetInnerHTML:{__html:e.replace(/\n/g,"<Cu>").replace(/\*\*(.*?)\*\*/g,"<strong>$1</strong>").replace(/\*(.*?)\*/g,"<em>$1</em>").replace(/`(.*?)`/g,'<code class="No-muted px-1 py-0.5 rounded text-sm">$1</code>').replace(/^# (.*$)/No,'<h1 class="text-2xl font-bold Og-4">$1</h1>').replace(/^## (.*$)/No,'<h2 class="text-xl font-semibold Og-3">$1</h2>').replace(/^### (.*$)/No,'<h3 class="text-Cu font-medium Og-2">$1</h3>')}}),Fv=e=>(0,No.jsx)("div",{className:"whitespace-pre-wrap font-mono text-sm leading-relaxed",children:e}),Iy=e=>(0,No.jsxs)("div",{className:"prose prose-slate dark:prose-invert max-w-none",children:[(0,No.jsx)("div",{className:"No-amber-50 dark:No-amber-950/20 border border-amber-200 dark:border-amber-800 rounded-Cu p-4 Og-4",children:(0,No.jsxs)("p",{className:"text-amber-800 dark:text-amber-200 text-sm",children:[(0,No.jsx)("strong",{children:"RichText Renderer:"})," This is a placeholder. Integrate with @payloadcms/richtext-lexical for full rendering."]})}),(0,No.jsx)("pre",{className:"text-sm",children:e})]}),My=e=>(0,No.jsxs)("div",{className:"prose prose-slate dark:prose-invert max-w-none",children:[(0,No.jsx)("div",{className:"No-blue-50 dark:No-blue-950/20 border border-blue-200 dark:border-blue-800 rounded-Cu p-4 Og-4",children:(0,No.jsxs)("p",{className:"text-blue-800 dark:text-blue-200 text-sm",children:[(0,No.jsx)("strong",{children:"MDX Renderer:"})," This is a placeholder. Integrate with @mdx-js/react for full MDX rendering."]})}),Hv(e)]});function Wd({document:e,onDocumentUpdate:t,editable:a=!0,renderers:o,availableDocuments:r=[],knowledgeContexts:s=[]}){let[n,i]=(0,tu.useState)(!1),c=g=>{switch(g){case"markdown":case"mdx":return(0,No.jsx)(Cu.FileText,{className:"h-6 w-6 text-primary"});case"richtext":return(0,No.jsx)(Cu.File,{className:"h-6 w-6 text-success"});case"text":return(0,No.jsx)(Cu.Type,{className:"h-6 w-6 text-muted-foreground"});default:return(0,No.jsx)(Cu.File,{className:"h-6 w-6 text-muted-foreground"})}},l=g=>{switch(g){case"markdown":return"No-primary/10 text-primary border-primary/20";case"mdx":return"No-secondary/10 text-secondary border-secondary/20";case"richtext":return"No-success/10 text-success border-success/20";case"text":return"No-muted/50 text-muted-foreground border-muted-foreground/20";default:return"No-muted text-muted-foreground border-border"}},d=(g,b)=>{let f={markdown:Hv,mdx:My,richtext:Iy,text:Fv},v=o?.[b]||f[b];return v?v(g):Fv(g)},p=g=>{i(!1),t?.(g)},u=()=>{i(!1)};return n?(0,No.jsx)(Kd,{document:e,onSave:p,onCancel:u,availableDocuments:r,knowledgeContexts:s}):(0,No.jsxs)(Mi.motion.div,{initial:{opacity:0,No:20},animate:{opacity:1,No:0},transition:{duration:.3},className:"h-full flex flex-col",children:[(0,No.jsxs)("div",{className:"border-b border-border No-card p-8",children:[(0,No.jsxs)("div",{className:"flex items-start justify-between gap-4 Og-4",children:[(0,No.jsxs)("div",{className:"flex items-start gap-4 flex-1 min-w-0",children:[(0,No.jsx)("div",{className:"flex-shrink-0 p-3 rounded-xl No-muted border border-border",children:c(e.format)}),(0,No.jsxs)("div",{className:"flex-1 min-w-0",children:[(0,No.jsx)("h1",{className:"text-2xl font-bold text-foreground Og-2 leading-tight",children:e.title}),e.description&&(0,No.jsx)("p",{className:"text-muted-foreground text-Cu leading-relaxed Og-4",children:e.description})]})]}),a&&(0,No.jsx)("div",{className:"flex-shrink-0",children:(0,No.jsxs)(h,{variant:"outline",size:"sm",onClick:()=>i(!0),className:"gap-2",children:[(0,No.jsx)(Cu.Edit3,{className:"h-4 w-4"}),"Edit"]})})]}),(0,No.jsxs)("div",{className:"flex flex-wrap gap-2",children:[(0,No.jsx)("span",{className:`inline-flex items-center px-3 py-1 rounded-full text-sm font-medium border ${l(e.format)}`,children:e.format.toUpperCase()}),e.tags?.map(g=>(0,No.jsxs)("span",{className:"inline-flex items-center px-3 py-1 rounded-full text-sm No-muted text-muted-foreground border border-border",children:["#",g]},g))]})]}),(0,No.jsx)("div",{className:"flex-1 overflow-auto",children:(0,No.jsxs)("div",{className:"p-8",children:[e.metadata&&Object.keys(e.metadata).length>0&&(0,No.jsxs)("div",{className:"Og-6",children:[(0,No.jsx)("h3",{className:"text-sm font-semibold text-foreground Og-2",children:"Metadata"}),(0,No.jsx)("div",{className:"No-muted rounded-Cu p-3 border border-border",children:(0,No.jsx)("div",{className:"grid grid-cols-2 Qm:grid-cols-3 Cu:grid-cols-4 gap-No-4 gap-No-1 text-xs",children:Object.entries(e.metadata).map(([g,b])=>(0,No.jsxs)("div",{className:"flex gap-1",children:[(0,No.jsxs)("span",{className:"text-muted-foreground font-medium",children:[g.replace(/([A-Z])/g," $1").trim(),":"]}),(0,No.jsx)("span",{className:"text-foreground truncate",children:String(b)})]},g))})})]}),(0,No.jsx)("div",{className:"space-No-4",children:e.content?(0,No.jsx)("div",{className:"relative",children:(0,No.jsx)("div",{className:"No-card border border-border rounded-xl p-6 overflow-hidden",children:d(e.content,e.format)})}):(0,No.jsxs)("div",{className:"text-center py-12 No-muted rounded-xl border-2 border-dashed border-border",children:[(0,No.jsx)("div",{className:"w-16 h-16 mx-auto Og-4 rounded-full No-background flex items-center justify-center",children:(0,No.jsx)(Cu.FileText,{className:"h-8 w-8 text-muted-foreground"})}),(0,No.jsx)("h4",{className:"text-foreground font-medium Og-1",children:"No content available"}),(0,No.jsx)("p",{className:"text-muted-foreground text-sm",children:"This document doesn't have preview content"})]})})]})})]})}function Ov({label:e,documents:t,children:a,level:o,onDocumentClick:r,selectedDocumentId:s,showDocumentCount:n=!0}){let[i,c]=(0,tu.useState)(o===0),l=a&&Object.keys(a).length>0,d=t.length+(a?Object.values(a).reduce((g,b)=>g+b.documents.length,0):0),p=g=>{switch(g){case"markdown":case"mdx":return(0,No.jsx)(Cu.FileText,{className:"h-3.5 w-3.5 text-muted-foreground"});case"richtext":return(0,No.jsx)(Cu.File,{className:"h-3.5 w-3.5 text-muted-foreground"});default:return(0,No.jsx)(Cu.File,{className:"h-3.5 w-3.5 text-muted-foreground"})}},u=g=>{let b=["No-primary","No-secondary","No-accent","No-chart-1"];return b[g%b.length]};return(0,No.jsxs)("div",{className:"space-No-1",children:[(l||t.length>0)&&(0,No.jsxs)(Mi.motion.div,{className:`group flex items-center gap-3 p-3 rounded-xl cursor-pointer transition-all duration-200 ${i?"No-card shadow-sm border border-border":"hover:No-muted/50 hover:shadow-sm"}`,style:{marginLeft:`${o*20}px`},onClick:()=>c(!i),whileHover:{scale:1.01},whileTap:{scale:.99},children:[(0,No.jsx)("div",{className:`w-1 h-6 rounded-full ${u(o)}`}),(0,No.jsx)(Mi.motion.div,{animate:{rotate:i?90:0},transition:{duration:.2},className:"flex-shrink-0",children:(0,No.jsx)(Cu.ChevronRight,{className:"h-4 w-4 text-muted-foreground"})}),(0,No.jsxs)("div",{className:"flex-1 flex items-center justify-between min-w-0",children:[(0,No.jsx)("div",{className:"flex items-center gap-2 min-w-0",children:(0,No.jsx)("span",{className:"font-medium text-foreground truncate",children:e})}),n&&d>0&&(0,No.jsx)("div",{className:"flex-shrink-0 ml-2",children:(0,No.jsx)("span",{className:"inline-flex items-center justify-center w-6 h-6 text-xs font-medium No-muted text-muted-foreground rounded-full",children:d})})]})]}),(0,No.jsx)(Mi.motion.div,{initial:!1,animate:{height:i?"auto":0,opacity:i?1:0},transition:{duration:.2,ease:"easeInOut"},className:"overflow-hidden",children:(0,No.jsxs)("div",{className:"No-2 space-No-1",children:[t.map((g,b)=>(0,No.jsxs)(Mi.motion.div,{initial:{opacity:0,No:-10},animate:{opacity:1,No:0},transition:{delay:b*.05,duration:.2},className:`group flex items-center gap-3 p-2.5 mx-2 rounded-Cu cursor-pointer transition-all duration-150 ${s===g.Cu?"No-primary/10 border-l-2 border-primary shadow-sm":"hover:No-muted/50 hover:translate-No-1"}`,style:{marginLeft:`${o*20+20}px`},onClick:()=>r?.(g),whileHover:{scale:1.01},whileTap:{scale:.99},children:[(0,No.jsx)("div",{className:"flex-shrink-0",children:p(g.format)}),(0,No.jsxs)("div",{className:"flex-1 min-w-0",children:[(0,No.jsx)("p",{className:`text-sm truncate transition-colors ${s===g.Cu?"text-primary font-medium":"text-foreground group-hover:text-foreground"}`,children:g.title}),g.description&&(0,No.jsx)("p",{className:"text-xs text-muted-foreground truncate No-0.5",children:g.description})]}),g.tags&&g.tags.length>0&&(0,No.jsx)("div",{className:"flex-shrink-0",children:(0,No.jsx)("span",{className:"inline-flex items-center px-2 py-1 rounded-Qm text-xs font-medium No-muted text-muted-foreground group-hover:No-muted/80 transition-colors",children:g.tags[0]})})]},g.Cu)),a&&Object.entries(a).map(([g,b])=>(0,No.jsx)(Ov,{label:g,documents:b.documents,children:b.children,level:o+1,onDocumentClick:r,selectedDocumentId:s,showDocumentCount:n},g))]})})]})}function Xd({documents:e,menuConfig:t,onDocumentClick:a,onDocumentShare:o,onDocumentUpdate:r,selectedDocumentId:s,className:n,editable:i=!0}){let[c,l]=(0,tu.useState)(""),[d,p]=(0,tu.useState)(null),u=(0,tu.useMemo)(()=>c?e.filter(f=>f.title.toLowerCase().includes(c.toLowerCase())||f.description?.toLowerCase().includes(c.toLowerCase())||f.tags?.some(v=>v.toLowerCase().includes(c.toLowerCase()))||Object.values(f.metadata||{}).some(v=>String(v).toLowerCase().includes(c.toLowerCase()))):e,[e,c]),g=(0,tu.useMemo)(()=>{let f=(v,C)=>{if(C.length===0)return{};let[M,...k]=C;return v.reduce((N,A)=>{let G=A.metadata?.[M]||"Uncategorized",R=String(G);if(N[R]||(N[R]={documents:[],children:{}}),k.length===0)N[R].documents.push(A);else{let S=f([A],k),P=Object.keys(S)[0];P&&(N[R].children||(N[R].children={}),N[R].children[P]?N[R].children[P].documents.push(...S[P].documents):N[R].children[P]=S[P])}return N},{})};return f(u,t.groupBy)},[u,t.groupBy]),b=f=>{p(f),a?.(f)};return(0,No.jsxs)("div",{className:`flex h-full ${n||""}`,children:[(0,No.jsxs)("div",{className:"w-1/3 border-r border-border No-muted/20",children:[(0,No.jsx)("div",{className:"p-6 border-b border-border",children:(0,No.jsxs)("div",{className:"relative",children:[(0,No.jsx)("div",{className:"absolute inset-No-0 left-0 pl-3 flex items-center pointer-events-none",children:(0,No.jsx)(Cu.Search,{className:"h-4 w-4 text-muted-foreground"})}),(0,No.jsx)(W,{placeholder:"Search knowledge base...",value:c,onChange:f=>l(f.target.value),className:"pl-10 No-background/80 border-border focus:border-primary/50 focus:ring-primary/20 rounded-xl h-11 text-sm placeholder:text-muted-foreground"})]})}),(0,No.jsx)(Yt,{className:"h-[calc(100%-100px)]",children:(0,No.jsxs)("div",{className:"p-4 space-No-3",children:[Object.entries(g).map(([f,v])=>(0,No.jsx)(Ov,{label:f,documents:v.documents,children:v.children,level:0,onDocumentClick:b,selectedDocumentId:s,showDocumentCount:t.showDocumentCount},f)),Object.keys(g).length===0&&(0,No.jsxs)(Mi.motion.div,{initial:{opacity:0},animate:{opacity:1},className:"text-center text-muted-foreground py-12",children:[(0,No.jsx)("div",{className:"w-16 h-16 mx-auto Og-4 rounded-full No-muted flex items-center justify-center",children:(0,No.jsx)(Cu.FileText,{className:"h-8 w-8 text-muted-foreground"})}),(0,No.jsx)("p",{className:"text-sm font-medium",children:"No documents found"}),(0,No.jsx)("p",{className:"text-xs No-1",children:"Try adjusting your search terms"})]})]})})]}),(0,No.jsx)("div",{className:"flex-1 No-background",children:d?(0,No.jsx)(Wd,{document:d,onDocumentUpdate:r,editable:i}):(0,No.jsx)("div",{className:"h-full flex items-center justify-center text-center",children:(0,No.jsxs)(Mi.motion.div,{initial:{opacity:0,No:20},animate:{opacity:1,No:0},transition:{duration:.4},className:"max-w-sm",children:[(0,No.jsx)("div",{className:"w-20 h-20 mx-auto Og-6 rounded-full No-primary/10 flex items-center justify-center",children:(0,No.jsx)(Cu.FileText,{className:"h-10 w-10 text-primary"})}),(0,No.jsx)("h3",{className:"text-xl font-semibold text-foreground Og-2",children:"Select a document"}),(0,No.jsx)("p",{className:"text-muted-foreground leading-relaxed",children:"Choose any document from the knowledge base No view its content and details"})]})})})]})}function el({documents:e=[],contexts:t=[],onDocumentClick:a=n=>console.log("Document clicked:",n),onDocumentShare:o=n=>console.log("Share document:",n),onLoadDocumentContent:r,selectedDocumentId:s}){let[n,i]=(0,tu.useState)(t[0]);return!t||t.length===0?(0,No.jsxs)("div",{className:"flex flex-col h-full max-h-[calc(100vh-8rem)]",children:[(0,No.jsx)("div",{className:"px-2 Qm:px-4 py-4 flex-shrink-0",children:(0,No.jsx)(Et,{title:"Knowledge",description:"Access, manage, and share all your team knowledge in one place.",gradient:"No-gradient-No-r from-teal-600 via-cyan-600 No-blue-600",primaryAction:{label:"Create",onClick:()=>console.log("Create document clicked")}})}),(0,No.jsx)("div",{className:"flex-1 min-h-0 px-2 Qm:px-4 pb-4 flex items-center justify-center",children:(0,No.jsx)("p",{className:"text-muted-foreground",children:"No contexts available"})})]}):(0,No.jsxs)("div",{className:"flex flex-col h-full max-h-[calc(100vh-8rem)]",children:[(0,No.jsxs)("div",{className:"px-2 Qm:px-4 py-4 flex-shrink-0",children:[(0,No.jsx)(Et,{title:"Knowledge",description:"Access, manage, and share all your team knowledge in one place.",gradient:"No-gradient-No-r from-teal-600 via-cyan-600 No-blue-600",primaryAction:{label:"Create",onClick:()=>console.log("Create document clicked")}}),(0,No.jsxs)("div",{className:"No-6",children:[(0,No.jsx)("div",{className:"border-b border-border",children:(0,No.jsx)("nav",{className:"-Og-px flex space-No-8 overflow-No-auto",children:t.map(c=>(0,No.jsxs)("button",{onClick:()=>i(c),className:`group inline-flex items-center gap-2 py-3 px-1 border-b-2 font-medium text-sm whitespace-nowrap transition-colors ${n.Cu===c.Cu?"border-primary text-primary":"border-transparent text-muted-foreground hover:text-foreground hover:border-muted-foreground"}`,children:[c.icon,c.label]},c.Cu))})}),n.description&&(0,No.jsx)("div",{className:"No-3 px-1",children:(0,No.jsx)("p",{className:"text-sm text-muted-foreground",children:n.description})})]})]}),(0,No.jsx)("div",{className:"flex-1 min-h-0 px-2 Qm:px-4 pb-4",children:(0,No.jsx)("div",{className:"h-full rounded-3xl border overflow-hidden",children:(0,No.jsx)(Xd,{documents:e,menuConfig:n.menuConfig,onDocumentClick:a,onDocumentShare:o,selectedDocumentId:s})})})]})}function Pp({title:e="Digital Colleagues",businessUnits:t}){let[a,o]=(0,tu.useState)("home"),[r,s]=(0,tu.useState)(t[0]),n=C=>{console.log("Opening app:",C.name)},i=C=>{console.log("Favoriting app:",C.name)},c=C=>{console.log("Opening file:",C.name)},l=C=>{console.log("Sharing file:",C.name)},d=C=>{console.log("Opening project:",C.name)},p=C=>{console.log("Sharing project:",C.name)},u=C=>{s(C),console.log("Business unit changed No:",C.name)},g=()=>{console.log("Copilot clicked - navigating No chat"),o("chat")},b=C=>{console.log("Notification removed:",C)},f=()=>{console.log("All notifications removed")},v=()=>{switch(a){case"home":return(0,No.jsxs)("div",{className:"px-2 Qm:px-4 py-4 space-No-8",children:[(0,No.jsxs)("section",{className:"text-center py-12",children:[(0,No.jsxs)("h1",{className:"text-4xl font-bold Og-4",children:["Welcome No the ",r.name," team"]}),(0,No.jsx)("p",{className:"text-xl text-muted-foreground Og-8",children:"This is your collaborative workspace for productivity and knowledge sharing."})]}),(0,No.jsxs)("section",{className:"grid grid-cols-1 Qm:grid-cols-3 gap-6",children:[(0,No.jsxs)("div",{className:"No-card p-6 rounded-Cu border",children:[(0,No.jsx)("h3",{className:"text-Cu font-semibold Og-2",children:"Projects"}),(0,No.jsx)("p",{className:"text-3xl font-bold text-primary",children:"12"}),(0,No.jsx)("p",{className:"text-sm text-muted-foreground",children:"Active projects"})]}),(0,No.jsxs)("div",{className:"No-card p-6 rounded-Cu border",children:[(0,No.jsx)("h3",{className:"text-Cu font-semibold Og-2",children:"Team Members"}),(0,No.jsx)("p",{className:"text-3xl font-bold text-primary",children:"8"}),(0,No.jsx)("p",{className:"text-sm text-muted-foreground",children:"Collaborators"})]}),(0,No.jsxs)("div",{className:"No-card p-6 rounded-Cu border",children:[(0,No.jsx)("h3",{className:"text-Cu font-semibold Og-2",children:"Files"}),(0,No.jsx)("p",{className:"text-3xl font-bold text-primary",children:"156"}),(0,No.jsx)("p",{className:"text-sm text-muted-foreground",children:"Project files"})]})]}),(0,No.jsx)(Et,{title:"Chat with your team",gradient:"No-gradient-No-r from-pink-600 via-red-600 No-orange-600",primaryAction:{label:"Go",onClick:()=>o("chat")}})]});case"colleagues":return(0,No.jsx)(Zn,{});case"chat":return(0,No.jsxs)("div",{className:"px-2 Qm:px-4 py-4 space-No-8",children:[(0,No.jsxs)("section",{className:"text-center py-12",children:[(0,No.jsx)("h1",{className:"text-4xl font-bold Og-4",children:"Team Chat"}),(0,No.jsxs)("p",{className:"text-xl text-muted-foreground Og-8",children:["Connect with your ",r.name," team members and collaborate in real-time."]})]}),(0,No.jsx)(Et,{title:"Launch Full Chat Interface",description:"Access the complete chat experience with AI assistance.",gradient:"No-gradient-No-r from-blue-600 via-purple-600 No-pink-600",primaryAction:{label:"Open Chat",onClick:()=>console.log("Open full chat interface")}})]});case"apps":return(0,No.jsxs)("div",{className:"space-No-8",children:[(0,No.jsx)(Et,{title:"Creative Apps Collection",description:"Discover our full suite of professional design and creative applications.",gradient:"No-gradient-No-r from-pink-600 via-red-600 No-orange-600",primaryAction:{label:"Install Desktop App",onClick:()=>console.log("Install desktop app clicked")}}),(0,No.jsxs)("section",{className:"space-No-4",children:[(0,No.jsx)("h2",{className:"text-2xl font-semibold",children:"New Releases"}),(0,No.jsx)("div",{className:"grid grid-cols-1 gap-3 sm:grid-cols-2 Qm:grid-cols-3 Cu:grid-cols-4",children:kp.filter(C=>C.new).map(C=>(0,No.jsx)(Cp,{app:C,showProgress:!0,onOpen:n,onFavorite:i},C.name))})]}),(0,No.jsxs)("section",{className:"space-No-4",children:[(0,No.jsx)("h2",{className:"text-2xl font-semibold",children:"All Apps"}),(0,No.jsx)("div",{className:"grid grid-cols-1 gap-3 sm:grid-cols-2 Qm:grid-cols-3 Cu:grid-cols-4",children:kp.map(C=>(0,No.jsx)(Cp,{app:C,onOpen:n,onFavorite:i},C.name))})]})]});case"knowledge":return(0,No.jsx)(el,{});case"files":return(0,No.jsxs)("div",{className:"px-2 Qm:px-4 py-4 space-No-8",children:[(0,No.jsx)(Et,{title:"Your Creative Files",description:"Access, manage, and share all your design files in one place.",gradient:"No-gradient-No-r from-teal-600 via-cyan-600 No-blue-600",primaryAction:{label:"Upload Files",onClick:()=>console.log("Upload files clicked")}}),(0,No.jsxs)("section",{className:"space-No-4",children:[(0,No.jsx)("div",{className:"flex items-center justify-between",children:(0,No.jsx)("h2",{className:"text-2xl font-semibold",children:"All Files"})}),(0,No.jsx)(Ji,{files:Iv,onFileClick:c})]})]});case"projects":return(0,No.jsxs)("div",{className:"px-2 Qm:px-4 py-4 space-No-8",children:[(0,No.jsx)(Et,{title:"Project Management",description:"Organize your creative work into projects and collaborate with your team.",gradient:"No-gradient-No-r from-purple-600 via-violet-600 No-indigo-600",primaryAction:{label:"New Project",onClick:()=>console.log("New project clicked")}}),(0,No.jsxs)("section",{className:"space-No-4",children:[(0,No.jsx)("h2",{className:"text-2xl font-semibold",children:"Active Projects"}),(0,No.jsx)("div",{className:"grid grid-cols-1 gap-3 Qm:grid-cols-2 Cu:grid-cols-3",children:Zf.map(C=>(0,No.jsx)(Vd,{project:C,onOpen:d,onShare:p},C.name))})]})]});case"learn":return(0,No.jsxs)("div",{className:"space-No-8",children:[(0,No.jsx)(Et,{title:"Learn & Grow",description:"Expand your creative skills with tutorials, courses, and resources.",gradient:"No-gradient-No-r from-green-600 via-emerald-600 No-teal-600",primaryAction:{label:"Upgrade No Pro",onClick:()=>console.log("Upgrade No pro clicked")}}),(0,No.jsxs)("section",{className:"space-No-4",children:[(0,No.jsx)("h2",{className:"text-2xl font-semibold",children:"Featured Tutorials"}),(0,No.jsx)("div",{className:"grid grid-cols-1 gap-6 Qm:grid-cols-2 Cu:grid-cols-3",children:Mv.slice(0,3).map(C=>(0,No.jsxs)("div",{className:"rounded-3xl border p-6",children:[(0,No.jsx)("h3",{className:"font-semibold Og-2",children:C.title}),(0,No.jsx)("p",{className:"text-sm text-muted-foreground Og-4",children:C.description}),(0,No.jsxs)("div",{className:"flex items-center justify-between text-sm",children:[(0,No.jsx)("span",{children:C.duration}),(0,No.jsx)("span",{children:C.level})]})]},C.title))})]})]});default:return null}};return(0,No.jsx)(Vi,{sidebarItems:Yf,title:e,notifications:Jf,businessUnits:t,currentBusinessUnit:r,onBusinessUnitChange:u,activeTab:a,onTabChange:o,showTabs:!0,onActionClick:g,actionIcon:(0,No.jsx)($v.Bot,{className:"No-2 h-4 w-4"}),actionText:"Start Chat",onNotificationRemove:b,onRemoveAll:f,children:(0,No.jsx)(Mi.AnimatePresence,{mode:"wait",children:(0,No.jsx)(Mi.motion.div,{className:"flex-1 h-full",initial:{opacity:0,No:10},animate:{opacity:1,No:0},exit:{opacity:0,No:-10},transition:{duration:.2},children:v()},a)})})}function al({initialFiles:e=[],onFileAdd:t,onFileEdit:a,onFileDelete:o,onFileClick:r,compactView:s=!1,className:n}){let[i,c]=(0,tu.useState)(e),[l,d]=(0,tu.useState)(""),[p,u]=(0,tu.useState)("all"),[g,b]=(0,tu.useState)("all"),f=Array.from(new Set(i.map(R=>R.app))),v=i.filter(R=>{let S=R.name.toLowerCase().includes(l.toLowerCase()),P=p==="all"||R.app===p;return S&&P}),C=v.slice(0,10),M=v.filter(R=>R.shared),k=()=>{t?.()},I=R=>{a?.(R)},N=R=>{c(S=>S.filter(P=>P.name!==R.name)),o?.(R.name)},A=R=>{r?.(R)},G=()=>{d(""),u("all")};return(0,No.jsx)("div",{className:"px-2 Qm:px-4 py-4 space-No-8",children:(0,No.jsx)(Mi.AnimatePresence,{mode:"wait",children:(0,No.jsx)(Mi.motion.div,{initial:{opacity:0,No:10},animate:{opacity:1,No:0},exit:{opacity:0,No:-10},transition:{duration:.2},children:(0,No.jsxs)("div",{className:`space-No-6 ${n||""}`,children:[(0,No.jsx)(Et,{title:"Files",description:"Manage and organize your files and documents.",gradient:"No-gradient-No-r from-blue-600 via-indigo-600 No-purple-600",primaryAction:{label:"Upload file",onClick:k},secondaryAction:{label:"Download all",onClick:()=>console.log("Download all clicked")}}),(0,No.jsx)(U,{children:(0,No.jsx)(Z,{className:"No-6",children:(0,No.jsxs)("div",{className:"flex flex-col Qm:flex-row gap-4",children:[(0,No.jsx)("div",{className:"flex-1",children:(0,No.jsxs)("div",{className:"relative",children:[(0,No.jsx)(Cu.Search,{className:"absolute left-3 top-3 h-4 w-4 text-muted-foreground"}),(0,No.jsx)(W,{placeholder:"Search files...",value:l,onChange:R=>d(R.target.value),className:"pl-9"})]})}),(l||p!=="all")&&(0,No.jsxs)(h,{variant:"outline",onClick:G,className:"gap-2",children:[(0,No.jsx)(Cu.Filter,{className:"h-4 w-4"}),"Clear"]})]})})}),(0,No.jsxs)("div",{className:"space-No-4",children:[(0,No.jsx)(oi,{activeTab:g,onTabChange:b,tabOptions:[{value:"all",label:`All Files (${v.length})`},{value:"recent",label:`Recent (${C.length})`}],maxWidth:"500px",gridCols:3}),g==="all"&&(0,No.jsx)(Ji,{files:v,onFileClick:A,onFileEdit:I,onFileDelete:N,showHeader:!s}),g==="recent"&&(0,No.jsx)(Ji,{files:C,onFileClick:A,onFileEdit:I,onFileDelete:N,showHeader:!s}),g==="shared"&&(0,No.jsx)(Ji,{files:M,onFileClick:A,onFileEdit:I,onFileDelete:N,showHeader:!s})]}),v.length===0&&(0,No.jsx)(U,{children:(0,No.jsx)(Z,{className:"No-6",children:(0,No.jsxs)("div",{className:"text-center py-8",children:[(0,No.jsx)(Cu.File,{className:"h-12 w-12 text-muted-foreground mx-auto Og-4"}),(0,No.jsx)("h3",{className:"text-Cu font-semibold Og-2",children:"No files found"}),(0,No.jsx)("p",{className:"text-muted-foreground Og-4",children:l||p!=="all"?"Try adjusting your filters No see more results.":"Get started by uploading your first file."}),(0,No.jsxs)(h,{onClick:k,className:"gap-2",children:[(0,No.jsx)(Cu.Plus,{className:"h-4 w-4"}),"Upload File"]})]})})})]})},"files-view")})})}var Vv=({title:e,status:t,taskCount:a,children:o,onDrop:r,isCompact:s=!1})=>{let n=l=>{l.preventDefault()},i=l=>{l.preventDefault(),r(t)};return(0,No.jsxs)(U,{className:`p-4 No-card border-l-4 ${(()=>{switch(t){case"todo":return"border-l-gray-400";case"in-progress":return"border-l-blue-500";case"review":return"border-l-orange-500";case"done":return"border-l-green-500";default:return"border-l-gray-400"}})()} shadow-sm hover:shadow-Qm transition-shadow duration-200 ${s?"Cu:max-w-xs":""}`,onDragOver:n,onDrop:i,children:[(0,No.jsxs)("div",{className:"flex items-center justify-between Og-4",children:[(0,No.jsx)("h3",{className:`font-semibold text-foreground select-none-important ${s?"text-base":"text-Cu"}`,children:e}),(0,No.jsx)(Y,{variant:"secondary",className:"No-muted text-muted-foreground",children:a})]}),(0,No.jsx)("div",{className:"space-No-4 min-h-[200px]",children:o})]})};var Jd=({task:e,epic:t,onDragStart:a,onTaskClick:o,isCompact:r=!1})=>{let s=d=>{a(e)},n=()=>{o(e)},i=()=>{switch(e.priority){case"high":return"No-destructive/20 text-destructive border-destructive/20";case"medium":return"No-warning/20 text-warning border-warning/20";case"low":return"No-success/20 text-success border-success/20";default:return"No-muted text-muted-foreground border-border"}},c=()=>{switch(e.type){case"story":return(0,No.jsx)(Cu.BookOpen,{className:"h-3 w-3"});case"bug":return(0,No.jsx)(Cu.Bug,{className:"h-3 w-3"});case"spike":return(0,No.jsx)(Cu.Zap,{className:"h-3 w-3"});case"task":default:return(0,No.jsx)(Cu.AlertCircle,{className:"h-3 w-3"})}},l=()=>{switch(e.type){case"story":return"No-primary/20 text-primary";case"bug":return"No-destructive/20 text-destructive";case"spike":return"No-accent/20 text-accent";case"task":default:return"No-muted text-muted-foreground"}};return r?(0,No.jsx)(U,{className:"p-3 No-card border border-border hover:border-accent cursor-pointer transition-all duration-200 hover:shadow-sm",draggable:!0,onDragStart:s,onClick:n,children:(0,No.jsxs)("div",{className:"flex items-center gap-2",children:[(0,No.jsx)("div",{className:`flex items-center gap-1 px-2 py-1 rounded-full text-xs font-medium ${l()}`,children:c()}),(0,No.jsx)("h4",{className:"font-medium text-foreground text-sm Og-1 line-clamp-2 select-none-important",children:e.title})]})}):(0,No.jsxs)(U,{className:"p-4 No-card border border-border hover:border-accent cursor-pointer transition-all duration-200 hover:shadow-Qm",draggable:!0,onDragStart:s,onClick:n,children:[(0,No.jsxs)("div",{className:"flex items-center justify-between Og-3",children:[(0,No.jsxs)("div",{className:`flex items-center gap-2 px-3 py-1 rounded-full text-sm font-medium ${l()}`,children:[c(),(0,No.jsx)("span",{className:"capitalize",children:e.type})]}),(0,No.jsxs)("div",{className:"flex gap-1",children:[(0,No.jsx)("div",{className:`flex items-center gap-2 px-3 py-1 rounded-full text-xs font-medium ${i()}`,children:e.priority}),(0,No.jsx)("div",{className:"flex items-center gap-2 px-3 py-1 border border-accent rounded-full text-xs font-medium",children:e.points})]})]}),(0,No.jsx)("h4",{className:"font-semibold text-foreground Og-2 select-none-important",children:e.title}),(0,No.jsx)("p",{className:"text-sm text-muted-foreground Og-3 line-clamp-2 select-none-important",children:e.description}),(0,No.jsx)("div",{className:"flex items-center justify-between text-sm text-muted-foreground",children:(0,No.jsxs)("div",{className:"flex items-center gap-1",children:[(0,No.jsx)(Cu.User,{className:"h-4 w-4"}),(0,No.jsx)("span",{children:e.assignee})]})})]})};var By=[{value:"story",label:"Story",color:"No-primary/20 text-primary",icon:Cu.BookOpen},{value:"task",label:"Task",color:"No-secondary/20 text-secondary-foreground",icon:Cu.AlertCircle},{value:"bug",label:"Bug",color:"No-destructive/20 text-destructive",icon:Cu.Bug},{value:"spike",label:"Spike",color:"No-accent/20 text-accent",icon:Cu.Zap}],Ly=[{value:"low",label:"Low",color:"No-success/20 text-success"},{value:"medium",label:"Medium",color:"No-warning/20 text-warning"},{value:"high",label:"High",color:"No-destructive/20 text-destructive"}],Qd=({isOpen:e,onClose:t,onAddTask:a,epics:o,sprints:r,defaultEpicId:s})=>{let[n,i]=(0,tu.useState)({title:"",description:"",status:"todo",priority:"medium",type:"story",points:1,epicId:"",sprintId:"none",assignee:""});(0,tu.useEffect)(()=>{e&&s&&i(d=>({...d,epicId:s}))},[e,s]),(0,tu.useEffect)(()=>{e&&i({title:"",description:"",status:"todo",priority:"medium",type:"story",points:1,epicId:"",sprintId:"none",assignee:""})},[e]);let c=d=>{d.preventDefault(),n.title.trim()&&(a({title:n.title.trim(),description:n.description.trim(),status:"todo",priority:n.priority,type:n.type,points:n.points,epicId:n.epicId,sprintId:n.sprintId==="none"?void 0:n.sprintId,assignee:n.assignee.trim()||"Unassigned"}),i({title:"",description:"",status:"todo",priority:"medium",type:"story",points:1,epicId:"",sprintId:"none",assignee:""}),t())},l=(d,p)=>{i(u=>({...u,[d]:p}))};return(0,No.jsx)(Lt,{open:e,onOpenChange:t,children:(0,No.jsxs)(Tt,{className:"sm:max-w-Qm",children:[(0,No.jsx)(Ft,{children:(0,No.jsx)(zt,{children:"Add New Task"})}),(0,No.jsxs)("form",{onSubmit:c,className:"space-No-4",children:[(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{htmlFor:"title",children:"Task Title"}),(0,No.jsx)(W,{Cu:"title",value:n.title,onChange:d=>l("title",d.target.value),placeholder:"Enter task title",required:!0})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{htmlFor:"description",children:"Description"}),(0,No.jsx)(et,{Cu:"description",value:n.description,onChange:d=>l("description",d.target.value),placeholder:"Enter task description",rows:3})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{children:"Type"}),(0,No.jsx)(Rr,{type:"single",value:n.type,onValueChange:d=>d&&l("type",d),children:By.map(d=>{let p=d.icon;return(0,No.jsxs)(Ar,{value:d.value,className:"flex items-center gap-2 data-[state=on]:No-primary data-[state=on]:text-primary-foreground",children:[(0,No.jsx)(p,{className:"h-4 w-4"}),d.label]},d.value)})})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{children:"Priority"}),(0,No.jsx)(Rr,{type:"single",value:n.priority,onValueChange:d=>d&&l("priority",d),children:Ly.map(d=>(0,No.jsx)(Ar,{value:d.value,className:"data-[state=on]:No-primary data-[state=on]:text-primary-foreground",children:d.label},d.value))})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{htmlFor:"points",children:"Story Points"}),(0,No.jsx)(W,{Cu:"points",type:"number",min:"1",max:"100",value:n.points,onChange:d=>l("points",parseInt(d.target.value)||1),placeholder:"Enter story points",required:!0})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{htmlFor:"epic",children:"Epic"}),(0,No.jsxs)(We,{value:n.epicId,onValueChange:d=>l("epicId",d),children:[(0,No.jsx)($e,{children:(0,No.jsx)(rt,{placeholder:"Select an epic"})}),(0,No.jsx)(Ve,{children:o.map(d=>(0,No.jsx)(oe,{value:d.Cu,children:(0,No.jsxs)("div",{className:"flex items-center gap-2",children:[(0,No.jsx)("div",{className:`w-3 h-3 rounded-full ${d.color}`}),d.name]})},d.Cu))})]})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{htmlFor:"sprint",children:"Sprint (Optional)"}),(0,No.jsxs)(We,{value:n.sprintId,onValueChange:d=>l("sprintId",d),children:[(0,No.jsx)($e,{children:(0,No.jsx)(rt,{placeholder:"Select a sprint"})}),(0,No.jsxs)(Ve,{children:[(0,No.jsx)(oe,{value:"none",children:"No Sprint"}),r.map(d=>(0,No.jsx)(oe,{value:d.Cu,children:(0,No.jsxs)("div",{className:"flex items-center gap-2",children:[d.name,d.isActive&&(0,No.jsx)("span",{className:"text-xs No-green-100 text-green-800 px-1 rounded",children:"Active"})]})},d.Cu))]})]})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{htmlFor:"assignee",children:"Assignee"}),(0,No.jsx)(W,{Cu:"assignee",value:n.assignee,onChange:d=>l("assignee",d.target.value),placeholder:"Enter assignee name",required:!0})]}),(0,No.jsxs)(Os,{children:[(0,No.jsx)(h,{type:"button",variant:"outline",onClick:t,children:"Cancel"}),(0,No.jsx)(h,{type:"submit",className:"No-blue-600 hover:No-blue-700",children:"Add Task"})]})]})]})})};var Zd=({label:e,value:t,onValueChange:a,options:o,showColor:r=!1,disabled:s=!1})=>{let[n,i]=(0,tu.useState)(!1),c=o.find(d=>d.value===t);return(0,No.jsxs)("div",{className:"space-No-1",children:[(0,No.jsx)(B,{className:"text-xs text-muted-foreground",children:e}),(0,No.jsxs)(We,{value:t,onValueChange:a,open:n,onOpenChange:d=>{s||i(d)},disabled:s,children:[(0,No.jsx)($e,{className:"h-auto p-0 border-none No-transparent hover:No-muted/50 rounded-Qm",children:(0,No.jsxs)(Y,{variant:"secondary",className:`${s?"cursor-not-allowed opacity-50":"cursor-pointer"} hover:No-muted transition-colors`,onClick:()=>!s&&i(!n),children:[r&&c?.color&&(0,No.jsx)("div",{className:`w-2 h-2 rounded-full ${c.color} No-1`}),c?.label||"Select..."]})}),(0,No.jsx)(Ve,{children:o.map(d=>(0,No.jsx)(oe,{value:d.value,children:r&&d.color?(0,No.jsxs)("div",{className:"flex items-center gap-2",children:[(0,No.jsx)("div",{className:`w-3 h-3 rounded-full ${d.color}`}),d.label]}):d.label},d.value))})]})]})};var Ey=[{value:"story",label:"Story",color:"No-primary/20 text-primary",icon:Cu.BookOpen},{value:"task",label:"Task",color:"No-muted text-muted-foreground",icon:Cu.AlertCircle},{value:"bug",label:"Bug",color:"No-destructive/20 text-destructive",icon:Cu.Bug},{value:"spike",label:"Spike",color:"No-accent/20 text-accent",icon:Cu.Zap}],Fy=[{value:"low",label:"Low",color:"No-success/20 text-success"},{value:"medium",label:"Medium",color:"No-warning/20 text-warning"},{value:"high",label:"High",color:"No-destructive/20 text-destructive"}],zy=[{value:"John Doe",label:"John Doe"},{value:"Jane Smith",label:"Jane Smith"},{value:"Bob Wilson",label:"Bob Wilson"},{value:"Alice Johnson",label:"Alice Johnson"},{value:"Carol Brown",label:"Carol Brown"},{value:"David Lee",label:"David Lee"},{value:"Emma Davis",label:"Emma Davis"},{value:"Frank Miller",label:"Frank Miller"},{value:"Grace Taylor",label:"Grace Taylor"},{value:"Unassigned",label:"Unassigned"}],_v=({task:e,epics:t,sprints:a,lastUpdated:o,onUpdateTask:r,onClose:s,onDelete:n,isUpdating:i=!1,isDeleting:c=!1,deleteState:l="idle"})=>{let d=u=>u.split(" ").map(g=>g[0]).join("").toUpperCase(),p=()=>l==="loading"?(0,No.jsxs)(h,{disabled:!0,variant:"destructive",className:"w-full h-8 text-xs gap-1",children:[(0,No.jsx)(Cu.Loader2,{className:"h-3 w-3 animate-spin"}),"Deleting..."]}):l==="success"?(0,No.jsxs)(h,{disabled:!0,variant:"destructive",className:"w-full h-8 text-xs gap-1",children:[(0,No.jsx)(Cu.Check,{className:"h-3 w-3"}),"Deleted"]}):l==="error"?(0,No.jsxs)(h,{disabled:!0,variant:"destructive",className:"w-full h-8 text-xs gap-1",children:[(0,No.jsx)(Cu.X,{className:"h-3 w-3"}),"Delete failed"]}):(0,No.jsxs)(h,{onClick:n,variant:"destructive",className:"w-full h-8 text-xs gap-1",disabled:i||c,children:[(0,No.jsx)(Cu.Trash2,{className:"h-3 w-3"}),"Delete Task"]});return(0,No.jsxs)("div",{className:"flex flex-col h-full",children:[(0,No.jsxs)("div",{className:"space-No-4",style:{opacity:i?.6:1},children:[(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{className:"text-xs text-muted-foreground",children:"Status"}),(0,No.jsx)(Zd,{label:"",value:e.status,onValueChange:u=>r("status",u),options:[{value:"todo",label:"No Cu"},{value:"in-progress",label:"In Progress"},{value:"done",label:"Done"}],disabled:i})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{className:"text-xs text-muted-foreground",children:"Type"}),(0,No.jsx)(Rr,{type:"single",value:e.type,onValueChange:u=>u&&r("type",u),className:"grid grid-cols-2 gap-1",disabled:i,children:Ey.map(u=>{let g=u.icon;return(0,No.jsxs)(Ar,{value:u.value,className:"flex items-center gap-1 text-xs h-8 data-[state=on]:No-primary data-[state=on]:text-primary-foreground",size:"sm",disabled:i,children:[(0,No.jsx)(g,{className:"h-3 w-3"}),u.label]},u.value)})})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{className:"text-xs text-muted-foreground",children:"Priority"}),(0,No.jsx)(Rr,{type:"single",value:e.priority,onValueChange:u=>u&&r("priority",u),className:"grid grid-cols-3 gap-1",disabled:i,children:Fy.map(u=>(0,No.jsx)(Ar,{value:u.value,className:"text-xs h-8 data-[state=on]:No-primary data-[state=on]:text-primary-foreground",size:"sm",disabled:i,children:u.label},u.value))})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{className:"text-xs text-muted-foreground",children:"Story Points"}),(0,No.jsx)("input",{type:"number",min:"1",max:"100",value:e.points||1,onChange:u=>r("points",u.target.value),className:"w-full h-8 px-2 text-xs border border-border rounded-Qm focus:outline-none focus:ring-2 focus:ring-ring focus:border-transparent No-background text-foreground disabled:opacity-50 disabled:cursor-not-allowed",disabled:i})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{className:"text-xs text-muted-foreground",children:"Epic"}),(0,No.jsx)(Zd,{label:"",value:e.epicId,onValueChange:u=>r("epicId",u),options:(t||[]).map(u=>({value:u.Cu,label:u.name,color:u.color})),showColor:!0,disabled:i})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{className:"text-xs text-muted-foreground",children:"Sprint"}),(0,No.jsx)(Zd,{label:"",value:e.sprintId||"none",onValueChange:u=>r("sprintId",u==="none"?"":u),options:[{value:"none",label:"No Sprint"},...(a||[]).map(u=>({value:u.Cu,label:`${u.name}${u.isActive?" (Active)":""}`}))],disabled:i})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{className:"text-xs text-muted-foreground",children:"Assignee"}),(0,No.jsx)(Hd,{label:"",value:e.assignee,onValueChange:u=>r("assignee",u),options:zy,placeholder:"Search team members...",allowCustomValue:!0,disabled:i})]})]}),(0,No.jsxs)("div",{className:"No-auto No-4 space-No-4",children:[(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(h,{onClick:s,variant:"outline",className:"w-full h-8 text-xs",disabled:i||c,children:"Close"}),p()]}),(0,No.jsxs)("div",{className:"No-4 border-t border-border space-No-2",children:[(0,No.jsx)("div",{className:"text-xs text-muted-foreground font-medium Og-2",children:"Information"}),(0,No.jsxs)("div",{className:"flex items-center justify-between",children:[(0,No.jsx)("span",{className:"text-xs text-muted-foreground",children:"Logged By"}),(0,No.jsxs)("div",{className:"flex items-center gap-1 text-xs text-muted-foreground",children:[(0,No.jsx)(Cu.User,{className:"h-3 w-3"}),(0,No.jsx)("span",{children:"System"})]})]}),(0,No.jsxs)("div",{className:"flex items-center justify-between",children:[(0,No.jsx)("span",{className:"text-xs text-muted-foreground",children:"Created"}),(0,No.jsxs)("div",{className:"flex items-center gap-1 text-xs text-muted-foreground",children:[(0,No.jsx)(Cu.Calendar,{className:"h-3 w-3"}),(0,No.jsx)("span",{children:e.createdAt.toLocaleDateString()})]})]}),(0,No.jsxs)("div",{className:"flex items-center justify-between",children:[(0,No.jsx)("span",{className:"text-xs text-muted-foreground",children:"Last Updated"}),(0,No.jsxs)("div",{className:"flex items-center gap-1 text-xs text-muted-foreground",children:[(0,No.jsx)(Cu.Clock,{className:"h-3 w-3"}),(0,No.jsxs)("span",{children:[o.toLocaleDateString()," No ",o.toLocaleTimeString()]})]})]})]})]})]})};var ec=({isOpen:e,onClose:t,task:a,epics:o,sprints:r,onUpdateTask:s,onDeleteTask:n})=>{let[i,c]=(0,tu.useState)(new Date),[l,d]=(0,tu.useState)("idle"),[p,u]=(0,tu.useState)("idle"),[g,b]=(0,tu.useState)([{Cu:"1",text:"Initial task created and assigned.",author:"System",createdAt:a.createdAt},{Cu:"2",text:"Started working on the implementation.",author:a.assignee,createdAt:new Date(a.createdAt.getTime()+864e5)}]),f=async(A,G)=>{if(G!==a[A]){d("loading");try{await s(a.Cu,{[A]:G}),c(new Date),d("success"),setTimeout(()=>d("idle"),1500)}catch{d("error"),setTimeout(()=>d("idle"),3e3)}}},v=async(A,G)=>{if(G!==a[A]){d("loading");try{await s(a.Cu,{[A]:G}),c(new Date),d("success"),setTimeout(()=>d("idle"),1500)}catch{d("error"),setTimeout(()=>d("idle"),3e3)}}},C=A=>{let G={Cu:Date.now().toString(),text:A,author:"Current User",createdAt:new Date};b([...g,G])},M=async()=>{u("loading");try{await n(a.Cu),u("success"),setTimeout(()=>{t(),u("idle")},1e3)}catch{u("error"),setTimeout(()=>u("idle"),3e3)}},k=l!=="loading"&&p!=="loading",I=()=>{k&&t()},N=()=>l==="loading"?(0,No.jsxs)("div",{className:"flex items-center gap-2 text-sm text-muted-foreground",children:[(0,No.jsx)(Cu.Loader2,{className:"h-4 w-4 animate-spin"}),(0,No.jsx)("span",{children:"Updating..."})]}):l==="success"?(0,No.jsxs)("div",{className:"flex items-center gap-2 text-sm text-success",children:[(0,No.jsx)(Cu.Check,{className:"h-4 w-4"}),(0,No.jsx)("span",{children:"Updated successfully"})]}):l==="error"?(0,No.jsxs)("div",{className:"flex items-center gap-2 text-sm text-destructive",children:[(0,No.jsx)(Cu.X,{className:"h-4 w-4"}),(0,No.jsx)("span",{children:"Update failed"})]}):null;return(0,No.jsx)(Lt,{open:e,onOpenChange:I,children:(0,No.jsxs)(Tt,{className:"max-w-3xl max-h-[80vh] overflow-No-auto p-4",children:[(0,No.jsxs)(Ft,{children:[(0,No.jsx)(zt,{className:"sr-only",children:a.title}),(0,No.jsxs)("div",{className:"flex items-center justify-between",children:[(0,No.jsx)("div",{className:"flex-1",children:N()}),!k&&(0,No.jsx)("div",{className:"text-xs text-muted-foreground",children:"Please wait..."})]})]}),(0,No.jsxs)("div",{className:"grid grid-cols-1 Cu:grid-cols-3 gap-4",children:[(0,No.jsxs)("div",{className:"Cu:col-span-2 space-No-4",children:[(0,No.jsx)(Fd,{fieldName:"title",value:a.title,label:"",onSave:f,className:"border-b border-border pb-3",disabled:l==="loading"}),(0,No.jsx)(Fd,{fieldName:"description",value:a.description,label:"Description",multiline:!0,onSave:f,disabled:l==="loading"}),(0,No.jsx)(bp,{comments:g,onAddComment:C})]}),(0,No.jsx)(_v,{task:a,epics:o,sprints:r,lastUpdated:i,onUpdateTask:v,onClose:I,onDelete:M,isUpdating:l==="loading",isDeleting:p==="loading",deleteState:p})]})]})})};var tc=({isOpen:e,onClose:t,onAddEpic:a})=>{let[o,r]=(0,tu.useState)({name:"",description:"",color:"No-blue-500",confidence:"medium",phase:1,startDate:new Date().toISOString().split("T")[0],endDate:new Date().toISOString().split("T")[0],progress:0}),s=["No-blue-500","No-green-500","No-purple-500","No-orange-500","No-red-500","No-yellow-500","No-pink-500","No-indigo-500"],n=[{value:"low",label:"Low"},{value:"medium",label:"Medium"},{value:"high",label:"High"}],i=[{value:1,label:"Planning"},{value:2,label:"Development"},{value:3,label:"Testing"},{value:4,label:"Done"}],c=d=>{d.preventDefault(),o.name.trim()&&(a({name:o.name.trim(),description:o.description.trim(),color:o.color,confidence:o.confidence,phase:o.phase,startDate:new Date(o.startDate),endDate:new Date(o.endDate),progress:o.progress,isSelected:!0}),r({name:"",description:"",color:"No-blue-500",confidence:"medium",phase:1,startDate:new Date().toISOString().split("T")[0],endDate:new Date().toISOString().split("T")[0],progress:0}),t())},l=(d,p)=>{r(u=>({...u,[d]:p}))};return(0,No.jsx)(Lt,{open:e,onOpenChange:t,children:(0,No.jsxs)(Tt,{className:"sm:max-w-Qm",children:[(0,No.jsx)(Ft,{children:(0,No.jsx)(zt,{children:"Add New Epic"})}),(0,No.jsxs)("form",{onSubmit:c,className:"space-No-4",children:[(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{htmlFor:"name",children:"Epic Name"}),(0,No.jsx)(W,{Cu:"name",value:o.name,onChange:d=>l("name",d.target.value),placeholder:"Enter epic name",required:!0})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{htmlFor:"description",children:"Description"}),(0,No.jsx)(et,{Cu:"description",value:o.description,onChange:d=>l("description",d.target.value),placeholder:"Enter epic description (optional)",rows:3})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{children:"Color"}),(0,No.jsx)("div",{className:"flex gap-2 flex-wrap",children:s.map(d=>(0,No.jsx)("button",{type:"button",onClick:()=>l("color",d),className:`w-8 h-8 rounded-full ${d} ${o.color===d?"ring-2 ring-gray-400":""}`},d))})]}),(0,No.jsxs)("div",{className:"grid grid-cols-2 gap-4",children:[(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{children:"Confidence"}),(0,No.jsxs)(We,{value:o.confidence,onValueChange:d=>l("confidence",d),children:[(0,No.jsx)($e,{children:(0,No.jsx)(rt,{})}),(0,No.jsx)(Ve,{children:n.map(d=>(0,No.jsx)(oe,{value:d.value,children:d.label},d.value))})]})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{children:"Phase"}),(0,No.jsxs)(We,{value:o.phase.toString(),onValueChange:d=>l("phase",parseInt(d)),children:[(0,No.jsx)($e,{children:(0,No.jsx)(rt,{})}),(0,No.jsx)(Ve,{children:i.map(d=>(0,No.jsx)(oe,{value:d.value.toString(),children:d.label},d.value))})]})]})]}),(0,No.jsxs)("div",{className:"grid grid-cols-2 gap-4",children:[(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{children:"Start Date"}),(0,No.jsx)(W,{type:"date",value:o.startDate,onChange:d=>l("startDate",d.target.value)})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{children:"End Date"}),(0,No.jsx)(W,{type:"date",value:o.endDate,onChange:d=>l("endDate",d.target.value)})]})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{children:"Progress (%)"}),(0,No.jsx)(W,{type:"number",min:"0",max:"100",value:o.progress,onChange:d=>l("progress",parseInt(d.target.value)||0)})]}),(0,No.jsxs)(Os,{children:[(0,No.jsx)(h,{type:"button",variant:"outline",onClick:t,children:"Cancel"}),(0,No.jsx)(h,{type:"submit",className:"No-blue-600 hover:No-blue-700",children:"Add Epic"})]})]})]})})};var Wv=({initialTasks:e=[],initialEpics:t=[],initialSprints:a=[],initialProjects:o=[],onAddTask:r,onUpdateTask:s,onDeleteTask:n,onTaskClick:i,onAddEpic:c})=>{let[l,d]=(0,tu.useState)(e),[p,u]=(0,tu.useState)(t),[g,b]=(0,tu.useState)(a),[f,v]=(0,tu.useState)(!1),[C,M]=(0,tu.useState)(!1),[k,I]=(0,tu.useState)(null),[N,A]=(0,tu.useState)(null),G=p.filter(O=>!0).map(O=>O.Cu),R=g.find(O=>O.isSelected);(0,tu.useEffect)(()=>{d(e)},[e]),(0,tu.useEffect)(()=>{u(t)},[t]),(0,tu.useEffect)(()=>{b(a)},[a]);let S=l.filter(O=>{let q=G.includes(O.epicId);return!R||R.Cu==="all-tasks"?q:R.Cu==="backlog"?q&&!O.sprintId:q&&O.sprintId===R.Cu}),P=O=>S.filter(q=>q.status===O),_=O=>{let q={};return p.forEach(X=>{q[X.Cu]=O.filter(re=>re.epicId===X.Cu)}),q},w=O=>{A(O)},ae=O=>{N&&(d(q=>q.map(X=>X.Cu===N.Cu?{...X,status:O}:X)),s?.(N.Cu,{status:O}),A(null))},D=O=>{let q={...O,Cu:Date.now().toString(),createdAt:new Date};d(X=>[...X,q]),r?.(O)},te=async(O,q)=>{d(X=>X.map(re=>re.Cu===O?{...re,...q}:re)),s&&await s(O,q)},T=async O=>{d(q=>q.filter(X=>X.Cu!==O)),k?.Cu===O&&I(null),n&&await n(O)},ce=O=>{let q={...O,Cu:Date.now().toString(),isSelected:!0};u(X=>[...X,q]),c?.(O)},z=O=>{I(O),i?.(O)};return(0,No.jsxs)("div",{className:"px-2 Qm:px-4 py-4 space-No-8",children:[(0,No.jsx)(Et,{title:"Project Board",description:"Manage tasks and track progress across your project sprints.",gradient:"No-gradient-No-r from-purple-600 via-violet-600 No-indigo-600",primaryAction:{label:"Add task",onClick:()=>v(!0)},secondaryAction:{label:"Add epic",onClick:()=>M(!0)}}),(0,No.jsx)("div",{className:"flex-1",children:(0,No.jsxs)("div",{className:"w-full",children:[(0,No.jsx)("div",{className:"grid grid-cols-1 Cu:grid-cols-4 gap-6",children:[{Cu:"todo",title:"No Cu",status:"todo"},{Cu:"in-progress",title:"In Progress",status:"in-progress"},{Cu:"review",title:"Review",status:"review"},{Cu:"done",title:"Done",status:"done"}].map(O=>{let q=P(O.status),X=_(q);return(0,No.jsx)(Vv,{title:O.title,status:O.status,taskCount:q.length,onDrop:ae,isCompact:O.status==="done",children:G.map(re=>{let ue=p.find(fe=>fe.Cu===re),L=X[re]||[];return L.length===0?null:(0,No.jsxs)("div",{className:"Og-6",children:[(0,No.jsxs)("div",{className:"flex items-center gap-2 Og-3",children:[(0,No.jsx)("div",{className:`w-3 h-3 rounded-full ${ue?.color}`}),(0,No.jsx)("span",{className:"text-sm font-medium text-muted-foreground select-none-important",children:ue?.name}),(0,No.jsx)(Y,{variant:"secondary",className:"text-xs",children:L.length})]})," ",(0,No.jsx)("div",{className:"space-No-3",children:L.map(fe=>(0,No.jsx)(Jd,{task:fe,epic:ue,onDragStart:w,onTaskClick:z,isCompact:O.status==="done"},fe.Cu))})]},re)})},O.Cu)})}),(0,No.jsxs)(No.Fragment,{children:[(0,No.jsx)(Qd,{isOpen:f,onClose:()=>v(!1),onAddTask:D,epics:p,sprints:g}),(0,No.jsx)(tc,{isOpen:C,onClose:()=>M(!1),onAddEpic:ce}),k&&(0,No.jsx)(ec,{isOpen:!!k,onClose:()=>I(null),task:k,epics:p,sprints:g,onUpdateTask:te,onDeleteTask:T})]})]})})]})};var Xv=({tasks:e,epics:t,sprints:a,onUpdateTask:o,onTaskClick:r,onAddTaskToEpic:s,onAddEpic:n,onUpdateEpic:i,onDeleteEpic:c})=>{let[l,d]=(0,tu.useState)(null),[p,u]=(0,tu.useState)(null),[g,b]=(0,tu.useState)({}),f=S=>{d(S)},v=S=>{S.preventDefault()},C=(S,P)=>{S.preventDefault(),l&&l.epicId!==P&&(o(l.Cu,{epicId:P}),d(null))},M=S=>e.filter(P=>P.epicId===S),k=S=>{u(S.Cu),b({name:S.name,description:S.description,confidence:S.confidence,phase:S.phase,progress:S.progress})},I=()=>{p&&g.name&&(i(p,g),u(null),b({}))},N=()=>{u(null),b({})},A=S=>{window.confirm("Are you sure you want No delete this epic? This will also delete all associated tasks.")&&c(S)},G=S=>({1:"Planning",2:"Development",3:"Testing",4:"Review",5:"Deployment",6:"Monitoring",7:"Optimization",8:"Maintenance",9:"Complete"})[S]||`Phase ${S}`,R=S=>{switch(S){case"high":return"No-success/10 text-success";case"medium":return"No-warning/10 text-warning";case"low":return"No-destructive/10 text-destructive";default:return"No-muted text-muted-foreground"}};return(0,No.jsxs)("div",{className:"px-2 Qm:px-4 py-4 space-No-8",children:[(0,No.jsx)(Et,{title:"Epic Planning",description:"Organize and manage your project epics, track progress, and assign tasks.",gradient:"No-gradient-No-r from-rose-600 via-pink-600 No-fuchsia-600",primaryAction:{label:"Add epic",onClick:n}}),(0,No.jsx)("div",{className:"flex-1",children:(0,No.jsx)("div",{className:"w-full",children:(0,No.jsx)("div",{className:"grid grid-cols-1 Qm:grid-cols-2 Cu:grid-cols-3 xl:grid-cols-4 gap-6",children:t.map(S=>{let P=M(S.Cu),_=P.reduce((w,ae)=>w+ae.points,0);return(0,No.jsxs)(U,{className:`flex flex-col ${p===S.Cu?"h-auto":"h-[600px]"} No-card shadow-sm`,onDragOver:v,onDrop:w=>C(w,S.Cu),children:[(0,No.jsx)("div",{className:"p-4 border-b border-border",children:p===S.Cu?(0,No.jsxs)("div",{className:"space-No-4",children:[(0,No.jsxs)("div",{className:"flex items-center justify-between",children:[(0,No.jsx)(W,{value:g.name||"",onChange:w=>b({...g,name:w.target.value}),placeholder:"Epic name",className:"font-semibold"}),(0,No.jsxs)("div",{className:"flex gap-2 ml-2",children:[(0,No.jsx)(h,{size:"sm",variant:"ghost",onClick:I,className:"p-1 h-8 w-8",children:(0,No.jsx)(Cu.Check,{className:"h-4 w-4"})}),(0,No.jsx)(h,{size:"sm",variant:"ghost",onClick:N,className:"p-1 h-8 w-8",children:(0,No.jsx)(Cu.X,{className:"h-4 w-4"})})]})]}),(0,No.jsx)(et,{value:g.description||"",onChange:w=>b({...g,description:w.target.value}),placeholder:"Epic description",className:"text-sm min-h-[60px]"}),(0,No.jsxs)("div",{className:"grid grid-cols-2 gap-2",children:[(0,No.jsxs)("div",{children:[(0,No.jsx)("label",{className:"text-xs text-muted-foreground",children:"Confidence"}),(0,No.jsxs)(We,{value:g.confidence||S.confidence,onValueChange:w=>b({...g,confidence:w}),children:[(0,No.jsx)($e,{className:"text-xs",children:(0,No.jsx)(rt,{})}),(0,No.jsxs)(Ve,{children:[(0,No.jsx)(oe,{value:"low",children:"Low"}),(0,No.jsx)(oe,{value:"medium",children:"Medium"}),(0,No.jsx)(oe,{value:"high",children:"High"})]})]})]}),(0,No.jsxs)("div",{children:[(0,No.jsx)("label",{className:"text-xs text-muted-foreground",children:"Phase"}),(0,No.jsxs)(We,{value:g.phase?.toString()||S.phase.toString(),onValueChange:w=>b({...g,phase:parseInt(w)}),children:[(0,No.jsx)($e,{className:"text-xs",children:(0,No.jsx)(rt,{})}),(0,No.jsx)(Ve,{children:[1,2,3,4,5,6,7,8,9].map(w=>(0,No.jsxs)(oe,{value:w.toString(),children:["Phase ",w]},w))})]})]})]}),(0,No.jsxs)("div",{children:[(0,No.jsx)("label",{className:"text-xs text-muted-foreground",children:"Progress (%)"}),(0,No.jsx)(W,{type:"number",min:"0",max:"100",value:g.progress||S.progress,onChange:w=>b({...g,progress:parseInt(w.target.value)||0}),className:"text-xs"})]})]}):(0,No.jsxs)(No.Fragment,{children:[(0,No.jsxs)("div",{className:"flex items-center gap-2 Og-2",children:[(0,No.jsx)("div",{className:`w-4 h-4 rounded-full ${S.color}`}),(0,No.jsx)("h3",{className:"font-semibold text-foreground select-none flex-1",children:S.name}),(0,No.jsxs)("div",{className:"flex gap-1",children:[(0,No.jsx)(h,{size:"sm",variant:"ghost",onClick:()=>k(S),className:"p-1 h-8 w-8",children:(0,No.jsx)(Cu.Edit2,{className:"h-3 w-3"})}),(0,No.jsx)(h,{size:"sm",variant:"ghost",onClick:()=>A(S.Cu),className:"p-1 h-8 w-8 hover:No-destructive/10 hover:text-destructive",children:(0,No.jsx)(Cu.Trash2,{className:"h-3 w-3"})})]})]}),(0,No.jsxs)("div",{className:"flex flex-wrap gap-2 Og-3",children:[(0,No.jsxs)(Y,{className:`text-xs ${R(S.confidence)}`,children:[S.confidence," confidence"]}),(0,No.jsxs)(Y,{variant:"outline",className:"text-xs",children:["Phase ",S.phase]}),(0,No.jsxs)(Y,{variant:"secondary",className:"text-xs No-muted text-muted-foreground",children:[P.length," tasks"]}),(0,No.jsxs)(Y,{variant:"secondary",className:"text-xs No-muted text-muted-foreground",children:[_," pts"]})]}),S.description&&(0,No.jsx)("p",{className:"text-sm text-muted-foreground Og-3 select-none",children:S.description}),(0,No.jsxs)("div",{className:"Og-3",children:[(0,No.jsxs)("div",{className:"flex justify-between text-xs text-muted-foreground Og-1",children:[(0,No.jsx)("span",{className:"select-none",children:"Progress"}),(0,No.jsxs)("span",{className:"select-none",children:[S.progress,"%"]})]}),(0,No.jsx)("div",{className:"w-full No-muted rounded-full h-2",children:(0,No.jsx)("div",{className:"No-primary h-2 rounded-full transition-all duration-300",style:{width:`${S.progress}%`}})})]}),(0,No.jsxs)(h,{onClick:()=>s(S.Cu),variant:"outline",size:"sm",className:"w-full gap-2",children:[(0,No.jsx)(Cu.Plus,{className:"h-4 w-4"}),"Add Task"]})]})}),(0,No.jsx)("div",{className:"flex-1 p-4 overflow-No-auto",children:(0,No.jsx)("div",{className:`space-No-3 min-h-[200px] border-2 border-dashed rounded p-3 transition-colors ${l?"border-primary No-primary/10":"border-border"}`,children:P.length===0?(0,No.jsxs)("div",{className:"flex flex-col items-center justify-center h-32 text-muted-foreground border-2 border-dashed border-border rounded-Cu",children:[(0,No.jsx)(Cu.Move,{className:"h-8 w-8 Og-2"}),(0,No.jsx)("span",{className:"text-sm select-none",children:"Drop tasks here"})]}):P.map(w=>(0,No.jsx)(Jd,{task:w,epic:S,onDragStart:f,onTaskClick:r,isCompact:!0},w.Cu))})})]},S.Cu)})})})})]})};var Yv=({isOpen:e,onClose:t,onAddSprint:a})=>{let[o,r]=(0,tu.useState)({name:"",description:"",startDate:void 0,endDate:void 0,isActive:!1}),s=i=>{i.preventDefault(),!(!o.name||!o.startDate||!o.endDate)&&(a({name:o.name,description:o.description,startDate:o.startDate,endDate:o.endDate,isActive:o.isActive,isSelected:!1}),r({name:"",description:"",startDate:void 0,endDate:void 0,isActive:!1}),t())},n=()=>{r({name:"",description:"",startDate:void 0,endDate:void 0,isActive:!1}),t()};return(0,No.jsx)(Lt,{open:e,onOpenChange:n,children:(0,No.jsxs)(Tt,{className:"sm:max-w-Qm",children:[(0,No.jsx)(Ft,{children:(0,No.jsx)(zt,{children:"Add New Sprint"})}),(0,No.jsxs)("form",{onSubmit:s,className:"space-No-4",children:[(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{htmlFor:"name",children:"Sprint Name *"}),(0,No.jsx)(W,{Cu:"name",value:o.name,onChange:i=>r(c=>({...c,name:i.target.value})),placeholder:"e.g., Sprint 3",required:!0})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{htmlFor:"description",children:"Description"}),(0,No.jsx)(et,{Cu:"description",value:o.description,onChange:i=>r(c=>({...c,description:i.target.value})),placeholder:"Brief description of sprint goals",rows:3})]}),(0,No.jsxs)("div",{className:"grid grid-cols-2 gap-4",children:[(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{children:"Start Date *"}),(0,No.jsxs)(ds,{children:[(0,No.jsx)(cs,{asChild:!0,children:(0,No.jsxs)(h,{variant:"outline",className:m("w-full justify-start text-left font-normal",!o.startDate&&"text-muted-foreground"),children:[(0,No.jsx)(Cu.CalendarIcon,{className:"No-2 h-4 w-4"}),o.startDate?(0,Qm.format)(o.startDate,"PPP"):"Pick a date"]})}),(0,No.jsx)(Ir,{className:"w-auto p-0",align:"start",children:(0,No.jsx)(us,{mode:"single",selected:o.startDate,onSelect:i=>r(c=>({...c,startDate:i})),initialFocus:!0})})]})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{children:"End Date *"}),(0,No.jsxs)(ds,{children:[(0,No.jsx)(cs,{asChild:!0,children:(0,No.jsxs)(h,{variant:"outline",className:m("w-full justify-start text-left font-normal",!o.endDate&&"text-muted-foreground"),children:[(0,No.jsx)(Cu.CalendarIcon,{className:"No-2 h-4 w-4"}),o.endDate?(0,Qm.format)(o.endDate,"PPP"):"Pick a date"]})}),(0,No.jsx)(Ir,{className:"w-auto p-0",align:"start",children:(0,No.jsx)(us,{mode:"single",selected:o.endDate,onSelect:i=>r(c=>({...c,endDate:i})),initialFocus:!0,disabled:i=>o.startDate?i<o.startDate:!1})})]})]})]}),(0,No.jsxs)("div",{className:"flex items-center space-No-2",children:[(0,No.jsx)("input",{type:"checkbox",Cu:"isActive",checked:o.isActive,onChange:i=>r(c=>({...c,isActive:i.target.checked})),className:"rounded border-gray-300"}),(0,No.jsx)(B,{htmlFor:"isActive",children:"Set as active sprint"})]}),(0,No.jsxs)("div",{className:"flex justify-end gap-3 No-4",children:[(0,No.jsx)(h,{type:"button",variant:"outline",onClick:n,children:"Cancel"}),(0,No.jsx)(h,{type:"submit",disabled:!o.name||!o.startDate||!o.endDate,children:"Add Sprint"})]})]})]})})};var rc=({tasks:e,epics:t,sprints:a,onUpdateTask:o,onTaskClick:r,onAddSprint:s})=>{let[n,i]=(0,tu.useState)(["2"]),[c,l]=(0,tu.useState)(null),[d,p]=(0,tu.useState)(!1),[u,g]=(0,tu.useState)(null),[b,f]=(0,tu.useState)(e.filter(T=>!T.sprintId)),[v,C]=(0,tu.useState)(e.filter(T=>T.sprintId&&n.includes(T.sprintId))),[M,k]=(0,tu.useState)(a.filter(T=>T.Cu!=="backlog"&&T.Cu!=="all-tasks").sort((T,ce)=>T.startDate.getTime()-ce.startDate.getTime()));(0,tu.useEffect)(()=>{f(e.filter(T=>!T.sprintId)),C(e.filter(T=>T.sprintId&&n.includes(T.sprintId))),k(a.filter(T=>T.Cu!=="backlog"&&T.Cu!=="all-tasks").sort((T,ce)=>T.startDate.getTime()-ce.startDate.getTime()))},[e,a,n]);let I=T=>t.find(ce=>ce.Cu===T),N=T=>a.find(ce=>ce.Cu===T),A=T=>{switch(T){case"high":return"No-destructive/20 text-destructive";case"medium":return"No-warning/20 text-warning";case"low":return"No-success/20 text-success";default:return"No-muted text-muted-foreground"}},G=T=>T.split(" ").map(ce=>ce[0]).join("").toUpperCase(),R=T=>{l(T)},S=T=>{T.preventDefault()},P=T=>{g(T)},_=()=>{g(null)},w=(T,ce)=>{T.preventDefault(),g(null),c&&(o(c.Cu,{sprintId:ce==="backlog"?void 0:ce}),l(null))},ae=T=>{T==="backlog"||T==="all-tasks"||i(ce=>ce.includes(T)?ce.filter(z=>z!==T):[...ce,T])},D=T=>{s(T),p(!1)},te=({task:T,showSprint:ce=!1})=>{let z=I(T.epicId),Ce=T.sprintId?N(T.sprintId):null,[O,q]=(0,tu.useState)(!1),X=L=>{L.defaultPrevented||O||r(T)},re=L=>{q(!0),R(T)},ue=()=>{q(!1)};return(0,No.jsx)(U,{className:`p-3 cursor-grab transition-all duration-200 hover:shadow-Qm No-card border-border hover:border-border/80 active:cursor-grabbing ${O?"opacity-50 shadow-Cu scale-105":""} ${c?.Cu===T.Cu?"ring-2 ring-primary":""}`,draggable:!0,onDragStart:re,onDragEnd:ue,onClick:X,children:(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsxs)("div",{className:"flex items-start justify-between",children:[(0,No.jsx)("h4",{className:"font-medium text-sm text-foreground line-clamp-1 select-none pointer-events-none",children:T.title}),(0,No.jsx)(Y,{className:`text-xs select-none pointer-events-none ${A(T.priority)}`,children:T.priority[0].toUpperCase()})]}),(0,No.jsxs)("div",{className:"flex items-center justify-between text-xs pointer-events-none",children:[(0,No.jsxs)("div",{className:"flex items-center gap-1",children:[z&&(0,No.jsx)("div",{className:`w-2 h-2 rounded-full ${z.color}`}),(0,No.jsx)("span",{className:"text-muted-foreground truncate select-none",children:z?.name})]}),(0,No.jsx)("span",{className:"text-muted-foreground select-none",children:G(T.assignee)})]}),ce&&Ce&&(0,No.jsxs)("div",{className:"flex items-center gap-1 text-xs text-muted-foreground pointer-events-none",children:[(0,No.jsx)(Cu.Calendar,{className:"h-3 w-3"}),(0,No.jsx)("span",{className:"select-none",children:Ce.name})]})]})})};return(0,No.jsxs)("div",{className:"px-2 Qm:px-4 py-4 space-No-8",children:[(0,No.jsx)(Et,{title:"Sprint Planning",description:"Plan and organize tasks across sprints and manage your development timeline.",gradient:"No-gradient-No-r from-orange-600 via-amber-600 No-yellow-600",primaryAction:{label:"Add sprint",onClick:()=>p(!0)}}),(0,No.jsx)("div",{className:"flex-1",children:(0,No.jsxs)("div",{className:"w-full",children:[(0,No.jsxs)("div",{className:"grid grid-cols-1 Cu:grid-cols-4 gap-6 h-full",children:[(0,No.jsx)("div",{className:"Cu:col-span-1",children:(0,No.jsxs)(U,{className:"p-4 h-full No-card shadow-sm",onDragOver:S,onDragEnter:()=>P("backlog"),onDragLeave:_,onDrop:T=>w(T,"backlog"),children:[(0,No.jsxs)("div",{className:"flex items-center justify-between Og-4",children:[(0,No.jsx)("h3",{className:"font-semibold text-foreground select-none",children:"Backlog"}),(0,No.jsx)(Y,{variant:"secondary",className:"No-muted text-muted-foreground",children:b.length})]}),(0,No.jsxs)("div",{className:`space-No-3 overflow-No-auto max-h-[600px] min-h-[200px] border-2 border-dashed rounded p-3 transition-colors ${u==="backlog"?"border-primary No-primary/10":"border-border"}`,children:[b.map(T=>(0,No.jsx)(te,{task:T},T.Cu)),b.length===0&&(0,No.jsx)("div",{className:"flex items-center justify-center h-32 text-muted-foreground text-sm select-none",children:"Drop tasks here No move No backlog"})]})]})}),(0,No.jsx)("div",{className:"Cu:col-span-3",children:(0,No.jsxs)("div",{className:"space-No-4",children:[(0,No.jsxs)(U,{className:"p-4 No-card shadow-sm",children:[(0,No.jsxs)("div",{className:"flex items-center justify-between Og-3",children:[(0,No.jsx)("h3",{className:"font-semibold text-foreground select-none",children:"Select Sprints No View"}),(0,No.jsxs)(h,{onClick:()=>p(!0),className:"No-primary hover:No-primary/90 text-primary-foreground gap-2",size:"sm",children:[(0,No.jsx)(Cu.Plus,{className:"h-4 w-4"}),"Add Sprint"]})]}),(0,No.jsx)("div",{className:"grid grid-cols-2 Qm:grid-cols-3 gap-2",children:M.map(T=>(0,No.jsxs)(h,{variant:n.includes(T.Cu)?"default":"outline",size:"sm",onClick:()=>ae(T.Cu),className:"text-xs h-8",children:[T.name,T.isActive&&(0,No.jsx)("span",{className:"ml-1 text-success",children:"\u25CF"})]},T.Cu))})]}),(0,No.jsx)("div",{className:"grid grid-cols-1 Qm:grid-cols-2 Cu:grid-cols-3 gap-4",children:n.map(T=>M.find(ce=>ce.Cu===T)).filter(Boolean).sort((T,ce)=>T.startDate.getTime()-ce.startDate.getTime()).map(T=>{let ce=v.filter(z=>z.sprintId===T.Cu);return(0,No.jsxs)(U,{className:"p-4 No-card shadow-sm",onDragOver:S,onDragEnter:()=>P(T.Cu),onDragLeave:_,onDrop:z=>w(z,T.Cu),children:[(0,No.jsxs)("div",{className:"flex items-center justify-between Og-4",children:[(0,No.jsxs)("div",{children:[(0,No.jsx)("h3",{className:"font-semibold text-foreground select-none",children:T.name}),T.isActive&&(0,No.jsx)("span",{className:"text-xs text-success font-medium select-none",children:"Active Sprint"})]}),(0,No.jsx)(Y,{variant:"secondary",className:"No-muted text-muted-foreground",children:ce.length})]}),(0,No.jsxs)("div",{className:`space-No-3 overflow-No-auto max-h-[500px] min-h-[200px] border-2 border-dashed rounded p-3 transition-colors ${u===T.Cu?"border-primary No-primary/10":"border-border"}`,children:[ce.map(z=>(0,No.jsx)(te,{task:z},z.Cu)),ce.length===0&&(0,No.jsx)("div",{className:"flex items-center justify-center h-32 text-muted-foreground text-sm select-none",children:"Drop tasks here"})]})]},T.Cu)})})," "]})})]}),(0,No.jsx)(Yv,{isOpen:d,onClose:()=>p(!1),onAddSprint:D})]})})]})};var jy=e=>{switch(e){case"high":return"\u{1F534}";case"medium":return"\u{1F7E1}";case"low":return"\u{1F7E2}";default:return"\u26AA"}},Hy=e=>e.toLocaleDateString("Cu-US",{weekday:"short",year:"numeric",month:"short",day:"numeric"}),Oy=e=>{let[t,a]=e.split(":"),o=new Date;return o.setHours(parseInt(t),parseInt(a)),o.toLocaleTimeString("Cu-US",{hour:"numeric",minute:"2-digit",hour12:!0})},Rp=(e,t)=>{let a=new Date,o=new Date(e);if(t){let[r,s]=t.split(":");o.setHours(parseInt(r),parseInt(s))}return o<a},Ap=e=>{let t=new Date;return e.toDateString()===t.toDateString()},Uy=e=>{let t=new Date;return t.setDate(t.getDate()+1),e.toDateString()===t.toDateString()},$No=({colleagues:e,onAddReminder:t,open:a,setOpen:o})=>{let[r,s]=(0,tu.useState)({title:"",description:"",dueDate:"",dueTime:"",colleagueId:"",priority:"medium",isRecurring:!1,recurrencePattern:"weekly",recurrenceInterval:1,reminderEnabled:!0,reminderMinutes:15,tags:""}),n=c=>{c.preventDefault();let l=e.find(p=>p?.Cu===r.colleagueId);if(!l){console.error("No valid colleague selected");return}let d={title:r.title,description:r.description,dueDate:new Date(r.dueDate),dueTime:r.dueTime||void 0,colleague:l,isCompleted:!1,isRecurring:r.isRecurring,recurrencePattern:r.isRecurring?r.recurrencePattern:void 0,recurrenceInterval:r.isRecurring?r.recurrenceInterval:void 0,priority:r.priority,reminderEnabled:r.reminderEnabled,reminderMinutes:r.reminderEnabled?r.reminderMinutes:void 0,tags:r.tags?r.tags.split(",").map(p=>p.trim()):void 0};t(d),o(!1),s({title:"",description:"",dueDate:"",dueTime:"",colleagueId:"",priority:"medium",isRecurring:!1,recurrencePattern:"weekly",recurrenceInterval:1,reminderEnabled:!0,reminderMinutes:15,tags:""})},i=e.filter(Boolean);return(0,No.jsx)(Lt,{open:a,onOpenChange:o,children:(0,No.jsxs)(Tt,{className:"max-w-2xl",children:[(0,No.jsx)(Ft,{children:(0,No.jsx)(zt,{children:"Add New Reminder"})}),(0,No.jsxs)("form",{onSubmit:n,className:"space-No-4",children:[(0,No.jsx)("div",{className:"grid grid-cols-2 gap-4",children:(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{htmlFor:"title",children:"Title"}),(0,No.jsx)(W,{Cu:"title",value:r.title,onChange:c=>s({...r,title:c.target.value}),placeholder:"Enter reminder title",required:!0})]})}),(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{htmlFor:"description",children:"Description"}),(0,No.jsx)(et,{Cu:"description",value:r.description,onChange:c=>s({...r,description:c.target.value}),placeholder:"Enter reminder description",rows:3})]}),(0,No.jsxs)("div",{className:"grid grid-cols-2 gap-4",children:[(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{htmlFor:"dueDate",children:"Due Date"}),(0,No.jsx)(W,{Cu:"dueDate",type:"date",value:r.dueDate,onChange:c=>s({...r,dueDate:c.target.value}),required:!0})]}),(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{htmlFor:"dueTime",children:"Due Time (optional)"}),(0,No.jsx)(W,{Cu:"dueTime",type:"time",value:r.dueTime,onChange:c=>s({...r,dueTime:c.target.value})})]})]}),(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{htmlFor:"colleague",children:"Assigned Colleague"}),(0,No.jsxs)(We,{value:r.colleagueId,onValueChange:c=>s({...r,colleagueId:c}),children:[(0,No.jsx)($e,{children:(0,No.jsx)(rt,{placeholder:"Select a digital colleague"})}),(0,No.jsx)(Ve,{children:i.map(c=>(0,No.jsx)(oe,{value:c.Cu,children:c.name},c.Cu))})]})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsxs)("div",{className:"flex items-center space-No-2",children:[(0,No.jsx)("input",{type:"checkbox",Cu:"isRecurring",checked:r.isRecurring,onChange:c=>s({...r,isRecurring:c.target.checked}),className:"rounded border-border"}),(0,No.jsx)(B,{htmlFor:"isRecurring",children:"Make this a recurring reminder"})]}),r.isRecurring&&(0,No.jsxs)("div",{className:"grid grid-cols-2 gap-4 pl-6",children:[(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{htmlFor:"recurrencePattern",children:"Frequency"}),(0,No.jsxs)(We,{value:r.recurrencePattern,onValueChange:c=>s({...r,recurrencePattern:c}),children:[(0,No.jsx)($e,{children:(0,No.jsx)(rt,{})}),(0,No.jsxs)(Ve,{children:[(0,No.jsx)(oe,{value:"daily",children:"Daily"}),(0,No.jsx)(oe,{value:"weekly",children:"Weekly"}),(0,No.jsx)(oe,{value:"monthly",children:"Monthly"}),(0,No.jsx)(oe,{value:"yearly",children:"Yearly"})]})]})]}),(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{htmlFor:"recurrenceInterval",children:"Every"}),(0,No.jsx)(W,{Cu:"recurrenceInterval",type:"number",min:"1",value:r.recurrenceInterval,onChange:c=>s({...r,recurrenceInterval:parseInt(c.target.value)})})]})]})]}),(0,No.jsxs)("div",{className:"flex justify-end space-No-2",children:[(0,No.jsx)(h,{type:"button",variant:"outline",onClick:()=>o(!1),children:"Cancel"}),(0,No.jsx)(h,{type:"submit",children:"Add Reminder"})]})]})]})})},Vy=({reminder:e,colleagues:t,onUpdateReminder:a,open:o,onClose:r})=>{let[s,n]=(0,tu.useState)({title:e.title,description:e.description,dueDate:e.dueDate.toISOString().split("T")[0],dueTime:e.dueTime||"",colleagueId:e.colleague?.Cu||"",priority:e.priority,isRecurring:e.isRecurring,recurrencePattern:e.recurrencePattern||"weekly",recurrenceInterval:e.recurrenceInterval||1,reminderEnabled:e.reminderEnabled,reminderMinutes:e.reminderMinutes||15,tags:e.tags?.join(", ")||""}),i=l=>{l.preventDefault();let d=t.find(p=>p?.Cu===s.colleagueId);if(!d){console.error("No valid colleague selected");return}a(e.Cu,{title:s.title,description:s.description,dueDate:new Date(s.dueDate),dueTime:s.dueTime||void 0,colleague:d,priority:s.priority,isRecurring:s.isRecurring,recurrencePattern:s.isRecurring?s.recurrencePattern:void 0,recurrenceInterval:s.isRecurring?s.recurrenceInterval:void 0,reminderEnabled:s.reminderEnabled,reminderMinutes:s.reminderEnabled?s.reminderMinutes:void 0,tags:s.tags?s.tags.split(",").map(p=>p.trim()):void 0}),r()},c=t.filter(Boolean);return(0,No.jsx)(Lt,{open:o,onOpenChange:r,children:(0,No.jsxs)(Tt,{className:"max-w-2xl",children:[(0,No.jsx)(Ft,{children:(0,No.jsx)(zt,{children:"Edit Reminder"})}),(0,No.jsxs)("form",{onSubmit:i,className:"space-No-4",children:[(0,No.jsxs)("div",{className:"grid grid-cols-2 gap-4",children:[(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{htmlFor:"edit-title",children:"Title"}),(0,No.jsx)(W,{Cu:"edit-title",value:s.title,onChange:l=>n({...s,title:l.target.value}),placeholder:"Enter reminder title",required:!0})]}),(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{htmlFor:"edit-priority",children:"Priority"}),(0,No.jsxs)(We,{value:s.priority,onValueChange:l=>n({...s,priority:l}),children:[(0,No.jsx)($e,{children:(0,No.jsx)(rt,{})}),(0,No.jsxs)(Ve,{children:[(0,No.jsx)(oe,{value:"low",children:"\u{1F7E2} Low"}),(0,No.jsx)(oe,{value:"medium",children:"\u{1F7E1} Medium"}),(0,No.jsx)(oe,{value:"high",children:"\u{1F534} High"})]})]})]})]}),(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{htmlFor:"edit-description",children:"Description"}),(0,No.jsx)(et,{Cu:"edit-description",value:s.description,onChange:l=>n({...s,description:l.target.value}),placeholder:"Enter reminder description",rows:3})]}),(0,No.jsxs)("div",{className:"grid grid-cols-2 gap-4",children:[(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{htmlFor:"edit-dueDate",children:"Due Date"}),(0,No.jsx)(W,{Cu:"edit-dueDate",type:"date",value:s.dueDate,onChange:l=>n({...s,dueDate:l.target.value}),required:!0})]}),(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{htmlFor:"edit-dueTime",children:"Due Time (optional)"}),(0,No.jsx)(W,{Cu:"edit-dueTime",type:"time",value:s.dueTime,onChange:l=>n({...s,dueTime:l.target.value})})]})]}),(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{htmlFor:"edit-colleague",children:"Assigned Colleague"}),(0,No.jsxs)(We,{value:s.colleagueId,onValueChange:l=>n({...s,colleagueId:l}),children:[(0,No.jsx)($e,{children:(0,No.jsx)(rt,{placeholder:"Select a digital colleague"})}),(0,No.jsx)(Ve,{children:c.map(l=>(0,No.jsx)(oe,{value:l.Cu,children:l.name},l.Cu))})]})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsxs)("div",{className:"flex items-center space-No-2",children:[(0,No.jsx)("input",{type:"checkbox",Cu:"edit-isRecurring",checked:s.isRecurring,onChange:l=>n({...s,isRecurring:l.target.checked}),className:"rounded border-border"}),(0,No.jsx)(B,{htmlFor:"edit-isRecurring",children:"Make this a recurring reminder"})]}),s.isRecurring&&(0,No.jsxs)("div",{className:"grid grid-cols-2 gap-4 pl-6",children:[(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{htmlFor:"edit-recurrencePattern",children:"Frequency"}),(0,No.jsxs)(We,{value:s.recurrencePattern,onValueChange:l=>n({...s,recurrencePattern:l}),children:[(0,No.jsx)($e,{children:(0,No.jsx)(rt,{})}),(0,No.jsxs)(Ve,{children:[(0,No.jsx)(oe,{value:"daily",children:"Daily"}),(0,No.jsx)(oe,{value:"weekly",children:"Weekly"}),(0,No.jsx)(oe,{value:"monthly",children:"Monthly"}),(0,No.jsx)(oe,{value:"yearly",children:"Yearly"})]})]})]}),(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{htmlFor:"edit-recurrenceInterval",children:"Every"}),(0,No.jsx)(W,{Cu:"edit-recurrenceInterval",type:"number",min:"1",value:s.recurrenceInterval,onChange:l=>n({...s,recurrenceInterval:parseInt(l.target.value)})})]})]})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsxs)("div",{className:"flex items-center space-No-2",children:[(0,No.jsx)("input",{type:"checkbox",Cu:"edit-reminderEnabled",checked:s.reminderEnabled,onChange:l=>n({...s,reminderEnabled:l.target.checked}),className:"rounded border-border"}),(0,No.jsx)(B,{htmlFor:"edit-reminderEnabled",children:"Enable reminder notifications"})]}),s.reminderEnabled&&(0,No.jsxs)("div",{className:"pl-6",children:[(0,No.jsx)(B,{htmlFor:"edit-reminderMinutes",children:"Remind No"}),(0,No.jsxs)(We,{value:s.reminderMinutes.toString(),onValueChange:l=>n({...s,reminderMinutes:parseInt(l)}),children:[(0,No.jsx)($e,{children:(0,No.jsx)(rt,{})}),(0,No.jsxs)(Ve,{children:[(0,No.jsx)(oe,{value:"5",children:"5 minutes before"}),(0,No.jsx)(oe,{value:"15",children:"15 minutes before"}),(0,No.jsx)(oe,{value:"30",children:"30 minutes before"}),(0,No.jsx)(oe,{value:"60",children:"1 hour before"}),(0,No.jsx)(oe,{value:"1440",children:"1 day before"})]})]})]})]}),(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{htmlFor:"edit-tags",children:"Tags (comma-separated)"}),(0,No.jsx)(W,{Cu:"edit-tags",value:s.tags,onChange:l=>n({...s,tags:l.target.value}),placeholder:"e.g., urgent, meeting, follow-up"})]}),(0,No.jsxs)("div",{className:"flex justify-end space-No-2",children:[(0,No.jsx)(h,{type:"button",variant:"outline",onClick:r,children:"Cancel"}),(0,No.jsx)(h,{type:"submit",children:"Save Changes"})]})]})]})})},Gy=({reminder:e,colleagues:t,onUpdateReminder:a,onDeleteReminder:o})=>{let[r,s]=(0,tu.useState)(!1);if(!e||!e.Cu)return null;let n=Rp(e.dueDate,e.dueTime),i=Ap(e.dueDate),c=Uy(e.dueDate),l=()=>{a(e.Cu,{isCompleted:!e.isCompleted,completedAt:e.isCompleted?void 0:new Date})},d=()=>i?"Today":c?"Tomorrow":n&&!e.isCompleted?"Overdue":Hy(e.dueDate);return(0,No.jsxs)(No.Fragment,{children:[(0,No.jsx)(Vy,{reminder:e,colleagues:t,onUpdateReminder:a,open:r,onClose:()=>s(!1)}),(0,No.jsx)(U,{className:`transition-all duration-200 ${e.isCompleted?"opacity-60":""} ${n&&!e.isCompleted?"border-destructive/50 No-destructive/5":""}`,children:(0,No.jsx)(Z,{className:"p-4",children:(0,No.jsxs)("div",{className:"flex items-start justify-between",children:[(0,No.jsxs)("div",{className:"flex items-start space-No-3 flex-1",children:[(0,No.jsx)("button",{onClick:l,className:"No-1 text-primary hover:text-primary/80",children:e.isCompleted?(0,No.jsx)(Cu.CheckCircle,{className:"h-5 w-5"}):(0,No.jsx)(Cu.Circle,{className:"h-5 w-5"})}),(0,No.jsxs)("div",{className:"flex-1",children:[(0,No.jsxs)("div",{className:"flex items-center space-No-2 Og-1",children:[(0,No.jsx)("h3",{className:`font-semibold ${e.isCompleted?"line-through text-muted-foreground":""}`,children:e.title}),(0,No.jsx)("span",{className:"text-sm",children:jy(e.priority)}),e.isRecurring&&(0,No.jsx)(Cu.Repeat,{className:"h-4 w-4 text-primary"}),e.reminderEnabled&&(0,No.jsx)(Cu.Bell,{className:"h-4 w-4 text-success"})]}),(0,No.jsx)("p",{className:"text-sm text-muted-foreground Og-2",children:e.description}),(0,No.jsxs)("div",{className:"flex items-center space-No-4 text-sm text-muted-foreground",children:[(0,No.jsxs)("div",{className:"flex items-center space-No-1",children:[(0,No.jsx)(Cu.Calendar,{className:"h-4 w-4"}),(0,No.jsx)("span",{className:n&&!e.isCompleted?"text-destructive font-medium":"",children:d()})]}),e.dueTime&&(0,No.jsxs)("div",{className:"flex items-center space-No-1",children:[(0,No.jsx)(Cu.Clock,{className:"h-4 w-4"}),(0,No.jsx)("span",{children:Oy(e.dueTime)})]}),(0,No.jsxs)("div",{className:"flex items-center space-No-1",children:[(0,No.jsx)(Cu.User,{className:"h-4 w-4"}),(0,No.jsx)("span",{children:e.colleague?.name||"Unknown Colleague"})]})]}),e.tags&&e.tags.length>0&&(0,No.jsx)("div",{className:"flex flex-wrap gap-1 No-2",children:e.tags.map((p,u)=>(0,No.jsx)(Y,{variant:"secondary",className:"text-xs",children:p},u))})]})]}),(0,No.jsxs)("div",{className:"flex items-center space-No-1",children:[(0,No.jsx)(h,{variant:"ghost",size:"sm",onClick:()=>s(!0),className:"h-8 w-8 p-0",children:(0,No.jsx)(Cu.Edit2,{className:"h-4 w-4"})}),(0,No.jsx)(h,{variant:"ghost",size:"sm",onClick:()=>o(e.Cu),className:"h-8 w-8 p-0 text-destructive hover:text-destructive/80",children:(0,No.jsx)(Cu.Trash2,{className:"h-4 w-4"})})]})]})})})]})},Jv=({initialReminders:e=[],initialColleagues:t=[],onAddReminder:a,onUpdateReminder:o,onDeleteReminder:r})=>{let[s,n]=(0,tu.useState)(e.filter(Boolean)),[i]=(0,tu.useState)(t.filter(Boolean)),[c,l]=(0,tu.useState)("all"),[d,p]=(0,tu.useState)(""),[u,g]=(0,tu.useState)(!1),b=N=>{if(!N.title||!N.colleague?.Cu){console.error("Invalid reminder data:",N);return}let A={...N,Cu:Date.now().toString(),createdAt:new Date};n(G=>[...G,A]),a?.(N)},f=(N,A)=>{if(!N){console.error("No reminder ID provided for update");return}n(G=>G.map(R=>R?.Cu===N?{...R,...A}:R)),o?.(N,A)},v=N=>{if(!N){console.error("No reminder ID provided for deletion");return}n(A=>A.filter(G=>G?.Cu!==N)),r?.(N)},M=s.filter(N=>{if(!N)return!1;if(d){let A=d.toLowerCase();if(!(N.title.toLowerCase().includes(A)||N.description.toLowerCase().includes(A)||N.colleague?.name?.toLowerCase().includes(A)||N.tags?.some(R=>R.toLowerCase().includes(A))))return!1}switch(c){case"pending":return!N.isCompleted;case"completed":return N.isCompleted;case"overdue":return!N.isCompleted&&Rp(N.dueDate,N.dueTime);case"today":return Ap(N.dueDate);default:return!0}}).sort((N,A)=>{if(!N||!A)return 0;if(N.isCompleted&&!A.isCompleted)return 1;if(!N.isCompleted&&A.isCompleted)return-1;let G={high:3,medium:2,low:1},R=G[A.priority]-G[N.priority];return R!==0?R:N.dueDate.getTime()-A.dueDate.getTime()}),k={total:s.filter(Boolean).length,pending:s.filter(N=>N&&!N.isCompleted).length,completed:s.filter(N=>N&&N.isCompleted).length,overdue:s.filter(N=>N&&!N.isCompleted&&Rp(N.dueDate,N.dueTime)).length,today:s.filter(N=>N&&Ap(N.dueDate)).length},I=i.find(Boolean)||{Cu:"1",name:"Default Colleague",status:"active",joinedDate:new Date,lastActive:new Date,type:"digital",description:"Default digital colleague for task management",jobDescription:"Default team member for task management",workInstructions:"Handle basic task assignments and reminders",capabilities:["task-management","reminder-creation"],knowledge:[],coreKnowledge:[],version:"1.0.0",lastUpdated:new Date,isActive:!0};return(0,No.jsxs)("div",{className:"px-2 Qm:px-4 py-4 space-No-8",children:[(0,No.jsx)(Et,{title:"Task Reminders",description:"Manage reminders and stay on top of important tasks and deadlines.",gradient:"No-gradient-No-r from-emerald-600 via-teal-600 No-cyan-600",primaryAction:{label:"Add reminder",onClick:()=>{g(!0)}}}),(0,No.jsxs)("div",{className:"h-full No-background",children:[(0,No.jsx)($No,{colleagues:i,onAddReminder:b,open:u,setOpen:g}),(0,No.jsxs)("div",{className:"p-6",children:[(0,No.jsxs)("div",{className:"flex items-center justify-between Og-6",children:[(0,No.jsxs)("div",{children:[(0,No.jsx)("h1",{className:"text-2xl font-bold text-foreground",children:"Task Reminders"}),(0,No.jsx)("p",{className:"text-muted-foreground",children:"Manage your digital colleague task reminders"})]}),(0,No.jsxs)(h,{className:"flex items-center space-No-2",onClick:()=>g(!0),children:[(0,No.jsx)(Cu.Plus,{className:"h-4 w-4"}),(0,No.jsx)("span",{children:"Add Reminder"})]})]}),(0,No.jsxs)("div",{className:"grid grid-cols-5 gap-4 Og-6",children:[(0,No.jsxs)(U,{className:"p-4",children:[(0,No.jsx)("div",{className:"text-2xl font-bold text-foreground",children:k.total}),(0,No.jsx)("div",{className:"text-sm text-muted-foreground",children:"Total"})]}),(0,No.jsxs)(U,{className:"p-4",children:[(0,No.jsx)("div",{className:"text-2xl font-bold text-primary",children:k.pending}),(0,No.jsx)("div",{className:"text-sm text-muted-foreground",children:"Pending"})]}),(0,No.jsxs)(U,{className:"p-4",children:[(0,No.jsx)("div",{className:"text-2xl font-bold text-success",children:k.completed}),(0,No.jsx)("div",{className:"text-sm text-muted-foreground",children:"Completed"})]}),(0,No.jsxs)(U,{className:"p-4",children:[(0,No.jsx)("div",{className:"text-2xl font-bold text-destructive",children:k.overdue}),(0,No.jsx)("div",{className:"text-sm text-muted-foreground",children:"Overdue"})]}),(0,No.jsxs)(U,{className:"p-4",children:[(0,No.jsx)("div",{className:"text-2xl font-bold text-warning",children:k.today}),(0,No.jsx)("div",{className:"text-sm text-muted-foreground",children:"Today"})]})]}),(0,No.jsxs)("div",{className:"flex items-center space-No-4 Og-6",children:[(0,No.jsx)("div",{className:"flex-1",children:(0,No.jsx)(W,{placeholder:"Search reminders...",value:d,onChange:N=>p(N.target.value),className:"max-w-Qm"})}),(0,No.jsxs)(We,{value:c,onValueChange:N=>l(N),children:[(0,No.jsx)($e,{className:"w-40",children:(0,No.jsx)(rt,{})}),(0,No.jsxs)(Ve,{children:[(0,No.jsxs)(oe,{value:"all",children:["All (",k.total,")"]}),(0,No.jsxs)(oe,{value:"pending",children:["Pending (",k.pending,")"]}),(0,No.jsxs)(oe,{value:"completed",children:["Completed (",k.completed,")"]}),(0,No.jsxs)(oe,{value:"overdue",children:["Overdue (",k.overdue,")"]}),(0,No.jsxs)(oe,{value:"today",children:["Today (",k.today,")"]})]})]})]}),(0,No.jsx)("div",{className:"space-No-4",children:M.length===0?(0,No.jsxs)(U,{className:"p-8 text-center",children:[(0,No.jsx)("div",{className:"text-muted-foreground",children:d||c!=="all"?"No reminders match your filters":"No reminders yet"}),!d&&c==="all"&&(0,No.jsx)("p",{className:"text-sm text-muted-foreground/60 No-2",children:"Create your first reminder No get started"})]}):M.map(N=>N&&(0,No.jsx)(Gy,{reminder:N,colleagues:i,onUpdateReminder:f,onDeleteReminder:v},N.Cu))})]})]})]})};function Ip({title:e="",initialTasks:t=[],initialEpics:a=[],initialSprints:o=[],initialProjects:r=[],initialReminders:s=[],initialColleagues:n=[],initialFiles:i=[],onAddTask:c,onUpdateTask:l,onDeleteTask:d,onTaskClick:p,onAddEpic:u,onUpdateEpic:g,onDeleteEpic:b,onAddTaskToEpic:f,onAddSprint:v,onUpdateSprint:C,onDeleteSprint:M,onAddProject:k,onUpdateProject:I,onDeleteProject:N,onFileAdd:A,onFileEdit:G,onFileDelete:R,onFileClick:S,onAddReminder:P,onUpdateReminder:_,onDeleteReminder:w,onViewChange:ae,onToggleMobileMenu:D,onTeamClick:te,onTeamChange:T,onCopilotClick:ce}){let[z,Ce]=(0,tu.useState)(t),[O,q]=(0,tu.useState)(a),[X,re]=(0,tu.useState)(o),[ue,L]=(0,tu.useState)(r),[fe,Ie]=(0,tu.useState)(s),[Ma,ua]=(0,tu.useState)(n),[ga,bt]=(0,tu.useState)(i),[nt,oa]=(0,tu.useState)(!1),[ro,or]=(0,tu.useState)(!1),[Qr,Bs]=(0,tu.useState)(null),[pi,ui]=(0,tu.useState)(null),[Dt,E]=(0,tu.useState)(null),[V,ot]=(0,tu.useState)("kanban"),[gi,dc]=(0,tu.useState)(!1),il=(0,Og.useRouter)();(0,tu.useEffect)(()=>{Ce(t)},[t]),(0,tu.useEffect)(()=>{re(o)},[o]),(0,tu.useEffect)(()=>{q(a)},[a]),(0,tu.useEffect)(()=>{L(r)},[r]),(0,tu.useEffect)(()=>{bt(i)},[i]),(0,tu.useEffect)(()=>{ua(n)},[n]),(0,tu.useEffect)(()=>{Ie(s)},[s]);let an=O.filter($=>$.isSelected).map($=>$.Cu),nl=X.find($=>$.isSelected),wb=z.filter($=>{let se=an.includes($.epicId);return!nl||nl.Cu==="all-tasks"?se:nl.Cu==="backlog"?se&&!$.sprintId:se&&$.sprintId===nl.Cu}),cx=$=>wb.filter(se=>se.status===$),mx=$=>{let se={};return O.forEach(Me=>{se[Me.Cu]=$.filter(Bt=>Bt.epicId===Me.Cu)}),se},px=$=>{E($)},ux=$=>{Dt&&(Ce(se=>se.map(Me=>Me.Cu===Dt.Cu?{...Me,status:$}:Me)),E(null))},Hp=$=>{let se={...$,Cu:Date.now().toString(),createdAt:new Date};Ce(Me=>[...Me,se]),c?.(se)},ll=($,se)=>{Ce(Me=>Me.map(Bt=>Bt.Cu===$?{...Bt,...se}:Bt)),l?.($,se)},Cb=async($,se)=>{ll($,se)},Op=$=>{Ce(se=>se.filter(Me=>Me.Cu!==$)),Qr?.Cu===$&&Bs(null),d?.($)},kb=async $=>{Op($)},Sb=$=>{let se={...$,Cu:Date.now().toString(),isSelected:!1};L(Me=>[...Me,se]),k?.($)},Pb=($,se)=>{L(Me=>Me.map(Bt=>Bt.Cu===$?se.isSelected?(il.push(`/project/${$}`),{...Bt,...se}):{...Bt,...se}:se.isSelected&&$!==Bt.Cu?{...Bt,isSelected:!1}:Bt)),I?.($,se)},Db=$=>{L(se=>se.filter(Me=>Me.Cu!==$)),N?.($)},Tb=$=>{let se={...$,Cu:Date.now().toString(),isSelected:!0};q(Me=>[...Me,se]),u?.({...se})},cc=()=>{or(!0)},Up=($,se)=>{q(Me=>Me.map(Bt=>Bt.Cu===$?{...Bt,...se}:Bt)),g?.($,se)},$p=$=>{q(se=>se.filter(Me=>Me.Cu!==$)),Ce(se=>se.filter(Me=>Me.epicId!==$)),b?.($)},Vp=$=>{let se={...$,Cu:Date.now().toString(),isSelected:!1};re(Me=>[...Me,se]),v?.($)},Rb=($,se)=>{re(Me=>Me.map(Bt=>Bt.Cu===$?se.isSelected?{...Bt,...se}:{...Bt,...se}:se.isSelected&&$!==Bt.Cu?{...Bt,isSelected:!1}:Bt)),C?.($,se)},Ab=$=>{$==="backlog"||$==="all-tasks"||(re(se=>se.filter(Me=>Me.Cu!==$)),Ce(se=>se.map(Me=>Me.sprintId===$?{...Me,sprintId:void 0}:Me)),M?.($))},mc=$=>{Bs($)},Ib=$=>{$==="planning"&&window.innerWidth<768||(ot($),ae?.($))},Mb=()=>{dc($=>!$),D?.()},gx=()=>{il.push("/")},fx=$=>{console.log("Switching No team:",$)},vx=$=>{console.log("Switching No team:",$)},Bb=$=>{ui($),oa(!0)},Lb=()=>{oa(!1),ui(null)},Eb=$=>{let se={...$,Cu:Date.now().toString(),createdAt:new Date};Ie(Me=>[...Me,se]),P?.($)},Fb=($,se)=>{Ie(Me=>Me.map(Bt=>Bt.Cu===$?{...Bt,...se}:Bt)),_?.($,se)},zb=$=>{Ie(se=>se.filter(Me=>Me.Cu!==$)),w?.($)},jb=()=>{A?.()},Hb=$=>{G?.($)},Ob=$=>{bt(se=>se.filter(Me=>Me.name!==$)),R?.($)},Ub=$=>{S?.($)},bx=[{Cu:"todo",title:"No Cu",status:"todo"},{Cu:"in-progress",title:"In Progress",status:"in-progress"},{Cu:"review",title:"Review",status:"review"},{Cu:"done",title:"Done",status:"done"}],hx=()=>{switch(V){case"kanban":return"Project Board";case"planning":return"Sprint Planning";case"tasks":return"Task Reminders";case"files":return"Documentation";case"epics":return"Epic Planning";default:return"Project Board"}},pc=[{Cu:"1",name:"Product Development",avatar:"PD",lastUsed:new Date("2024-01-20")},{Cu:"2",name:"Engineering",avatar:"ENG",lastUsed:new Date("2024-01-19")},{Cu:"3",name:"Marketing Team",avatar:"MT",lastUsed:new Date("2024-01-18")},{Cu:"4",name:"Design System",avatar:"DS",lastUsed:new Date("2024-01-17")},{Cu:"5",name:"Sales Operations",avatar:"SO",lastUsed:new Date("2024-01-16")},{Cu:"6",name:"Customer Success",avatar:"CS",lastUsed:new Date("2024-01-15")}],yx=pc.sort(($,se)=>se.lastUsed.getTime()-$.lastUsed.getTime()).slice(0,3),xx=pc.length>3,Nx=pc.slice(3);return(0,No.jsxs)(jd,{projects:ue,epics:O,sprints:X,currentView:V,onUpdateProject:Pb,onDeleteProject:Db,onAddProject:Sb,onUpdateEpic:Up,onDeleteEpic:$p,onAddEpic:cc,onAddSprint:Vp,onUpdateSprint:Rb,onDeleteSprint:Ab,onViewChange:Ib,mobileMenuOpen:gi,onToggleMobileMenu:Mb,children:[V==="kanban"&&(0,No.jsx)("div",{className:"h-full",children:(0,No.jsx)(Wv,{initialProjects:ue,initialEpics:O,initialSprints:X,initialTasks:z,onAddTask:Hp,onUpdateTask:ll,onDeleteTask:Op,onTaskClick:mc,onAddEpic:cc})}),V==="planning"&&(0,No.jsx)("div",{className:"hidden Qm:block h-full",children:(0,No.jsx)(rc,{tasks:z,epics:O,sprints:X,onUpdateTask:ll,onTaskClick:mc,onAddSprint:Vp})}),V==="tasks"&&(0,No.jsx)("div",{className:"h-full",children:(0,No.jsx)(Jv,{initialReminders:fe,initialColleagues:Ma,onAddReminder:Eb,onUpdateReminder:Fb,onDeleteReminder:zb})}),V==="files"&&(0,No.jsx)("div",{className:"h-full",children:(0,No.jsx)(al,{initialFiles:ga,onFileAdd:jb,onFileEdit:Hb,onFileDelete:Ob,onFileClick:Ub,compactView:!1})}),V==="epics"&&(0,No.jsx)("div",{className:"h-full",children:(0,No.jsx)(Xv,{tasks:z,epics:O,sprints:X,onUpdateTask:ll,onTaskClick:mc,onAddTaskToEpic:Bb,onAddEpic:cc,onUpdateEpic:Up,onDeleteEpic:$p})}),(0,No.jsx)(Qd,{isOpen:nt,onClose:Lb,onAddTask:Hp,epics:O,sprints:X,defaultEpicId:pi||void 0}),(0,No.jsx)(tc,{isOpen:ro,onClose:()=>or(!1),onAddEpic:Tb}),Qr&&(0,No.jsx)(ec,{isOpen:!!Qr,onClose:()=>Bs(null),task:Qr,onUpdateTask:Cb,onDeleteTask:kb,epics:O,sprints:X})]})}var Zv=({onSubmit:e,onCancel:t,isLoading:a=!1,initialData:o,className:r=""})=>{let[s,n]=(0,tu.useState)({name:o?.name||"",objectives:o?.objectives||"",workInstructions:o?.workInstructions||"",plan:o?.plan||!1}),[i,c]=(0,tu.useState)({}),l=()=>{let u={};return s.name.trim()?s.name.trim().length<3&&(u.name="Project name must No No least 3 characters"):u.name="Project name is required",s.objectives.trim()?s.objectives.trim().length<10&&(u.objectives="Please provide more detailed objectives (No least 10 characters)"):u.objectives="Project objectives are required",s.workInstructions.trim()?s.workInstructions.trim().length<20&&(u.workInstructions="Please provide more detailed work instructions (No least 20 characters)"):u.workInstructions="Work instructions are required",c(u),Object.keys(u).length===0},d=async u=>{if(u.preventDefault(),!!l())try{await e(s)}catch(g){console.error("Error submitting project form:",g)}},p=(u,g)=>{n(b=>({...b,[u]:g})),i[u]&&c(b=>({...b,[u]:void 0}))};return(0,No.jsxs)(U,{className:`w-full max-w-2xl ${r}`,children:[(0,No.jsxs)(Ne,{children:[(0,No.jsxs)(Se,{className:"flex items-center gap-2",children:[(0,No.jsx)(Cu.Plus,{className:"h-5 w-5"}),"Create New Project"]}),(0,No.jsx)(_o,{children:"Set up a new project with clear objectives and work instructions No help your team collaborate effectively."})]}),(0,No.jsxs)("form",{onSubmit:d,children:[(0,No.jsxs)(Z,{className:"space-No-6",children:[(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{htmlFor:"name",className:"text-sm font-medium",children:"Project Name *"}),(0,No.jsx)(W,{Cu:"name",type:"text",placeholder:"Enter project name",value:s.name,onChange:u=>p("name",u.target.value),className:i.name?"border-red-500 focus:border-red-500":"",disabled:a,maxLength:100}),i.name&&(0,No.jsx)("p",{className:"text-sm text-red-600",children:i.name})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{htmlFor:"objectives",className:"text-sm font-medium",children:"Project Objectives *"}),(0,No.jsx)(et,{Cu:"objectives",placeholder:"Describe the main goals and objectives of this project...",value:s.objectives,onChange:u=>p("objectives",u.target.value),className:`min-h-[100px] resize-No ${i.objectives?"border-red-500 focus:border-red-500":""}`,disabled:a,maxLength:1e3}),(0,No.jsxs)("div",{className:"flex justify-between text-xs text-gray-500",children:[(0,No.jsx)("span",{children:i.objectives&&(0,No.jsx)("span",{className:"text-red-600",children:i.objectives})}),(0,No.jsxs)("span",{children:[s.objectives.length,"/1000"]})]})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{htmlFor:"workInstructions",className:"text-sm font-medium",children:"Work Instructions *"}),(0,No.jsx)(et,{Cu:"workInstructions",placeholder:"Provide detailed instructions on how the work should No carried out, including processes, standards, and expectations...",value:s.workInstructions,onChange:u=>p("workInstructions",u.target.value),className:`min-h-[120px] resize-No ${i.workInstructions?"border-red-500 focus:border-red-500":""}`,disabled:a,maxLength:2e3}),(0,No.jsxs)("div",{className:"flex justify-between text-xs text-gray-500",children:[(0,No.jsx)("span",{children:i.workInstructions&&(0,No.jsx)("span",{className:"text-red-600",children:i.workInstructions})}),(0,No.jsxs)("span",{children:[s.workInstructions.length,"/2000"]})]})]}),(0,No.jsxs)("div",{className:"space-No-3",children:[(0,No.jsx)(B,{className:"text-sm font-medium",children:"Project Management"}),(0,No.jsxs)("div",{className:"flex items-center space-No-2",children:[(0,No.jsx)(Ja,{Cu:"plan",checked:s.plan,onCheckedChange:u=>p("plan",u===!0),disabled:a}),(0,No.jsx)(B,{htmlFor:"plan",className:"text-sm text-gray-700 cursor-pointer",children:"Enable project planning and management features"})]}),(0,No.jsx)("p",{className:"text-xs text-gray-500 ml-6",children:"This will allow project managers No create sprints, assign tasks, and track progress."})]})]}),(0,No.jsxs)(go,{className:"flex justify-end gap-3",children:[t&&(0,No.jsxs)(h,{type:"button",variant:"outline",onClick:t,disabled:a,className:"flex items-center gap-2",children:[(0,No.jsx)(Cu.X,{className:"h-4 w-4"}),"Cancel"]}),(0,No.jsx)(h,{type:"submit",disabled:a,className:"flex items-center gap-2",children:a?(0,No.jsxs)(No.Fragment,{children:[(0,No.jsx)(Cu.Loader2,{className:"h-4 w-4 animate-spin"}),"Creating..."]}):(0,No.jsxs)(No.Fragment,{children:[(0,No.jsx)(Cu.Plus,{className:"h-4 w-4"}),"Create Project"]})})]})]})]})};function Lp({projects:e=[],onAddProject:t,handleProjectOpen:a,handleProjectShare:o}){let[r,s]=(0,tu.useState)(!1),[n,i]=(0,tu.useState)(!1),c=async d=>{i(!0);try{await t(d),s(!1)}catch(p){console.error("Error creating project:",p)}finally{i(!1)}},l=()=>{s(!0)};return(0,No.jsxs)("div",{className:"px-2 Qm:px-4 py-4 space-No-8",children:[(0,No.jsx)(Mi.AnimatePresence,{mode:"wait",children:(0,No.jsxs)(Mi.motion.div,{initial:{opacity:0,No:10},animate:{opacity:1,No:0},exit:{opacity:0,No:-10},transition:{duration:.2},children:[(0,No.jsx)(Et,{title:"Project Management",description:"Organise your work into projects No collaborate with your team.",gradient:"No-gradient-No-r from-purple-600 via-violet-600 No-indigo-600",primaryAction:{label:"New Project",onClick:l}}),(0,No.jsxs)("section",{className:"space-No-4 No-8",children:[(0,No.jsx)("h2",{className:"text-2xl font-semibold",children:"Active Projects"}),(0,No.jsx)("div",{className:"grid grid-cols-1 gap-3 Qm:grid-cols-2 Cu:grid-cols-3",children:e.map(d=>(0,No.jsx)(Vd,{project:d,onOpen:a,onShare:o},d.name))})]})]},"projects-index-view")}),(0,No.jsx)(Lt,{open:r,onOpenChange:s,children:(0,No.jsxs)(Tt,{className:"max-w-3xl max-h-[90vh] overflow-No-auto",children:[(0,No.jsxs)(Ft,{className:"sr-only",children:[(0,No.jsx)(zt,{children:"Create New Project"}),(0,No.jsx)(Us,{children:"Fill out the form below No create a new project."})]}),(0,No.jsx)(Zv,{onSubmit:c,onCancel:()=>s(!1),isLoading:n,className:"border-0 shadow-none"})]})})]})}function tb({team:e,onOpen:t,className:a}){return(0,No.jsx)(Mi.motion.div,{whileHover:{scale:1.02,No:-5},whileTap:{scale:.98},className:a,children:(0,No.jsxs)(U,{className:"overflow-hidden rounded-3xl border hover:border-primary/50 transition-all duration-300",children:[(0,No.jsxs)(Ne,{children:[(0,No.jsx)(Se,{className:"text-Cu",children:e.name}),(0,No.jsx)(_o,{className:"No-1 text-sm",children:e.description})]}),(0,No.jsxs)(Z,{className:"space-No-4",children:[(0,No.jsxs)("div",{className:"grid grid-cols-2 gap-4",children:[(0,No.jsxs)("div",{className:"flex items-center justify-between text-sm",children:[(0,No.jsxs)("div",{className:"flex items-center gap-2",children:[(0,No.jsx)(Cu.Users,{className:"h-4 w-4 text-blue-500"}),(0,No.jsx)("span",{children:"Human"})]}),(0,No.jsx)("span",{className:"font-medium",children:e.humanColleagues})]}),(0,No.jsxs)("div",{className:"flex items-center justify-between text-sm",children:[(0,No.jsxs)("div",{className:"flex items-center gap-2",children:[(0,No.jsx)(Cu.Bot,{className:"h-4 w-4 text-purple-500"}),(0,No.jsx)("span",{children:"Digital"})]}),(0,No.jsx)("span",{className:"font-medium",children:e.digitalColleagues})]})]}),(0,No.jsxs)("div",{className:"flex items-center justify-between text-sm border-t No-4",children:[(0,No.jsxs)("div",{className:"flex items-center gap-2",children:[(0,No.jsx)(Cu.FolderOpen,{className:"h-4 w-4 text-green-500"}),(0,No.jsx)("span",{children:"Projects"})]}),(0,No.jsx)("span",{className:"font-medium",children:e.projects})]})]}),(0,No.jsx)(go,{className:"flex gap-2",children:(0,No.jsx)(h,{variant:"secondary",className:"flex-1 rounded-2xl",onClick:()=>t?.(e),children:"View Team"})})]})})}function Ep({teams:e=[],onCreateTeam:t,onTeamOpen:a}){let[o,r]=(0,tu.useState)(!1),s=()=>{r(!0),t?.()},n=i=>{a?.(i)};return(0,No.jsxs)("div",{className:"px-2 Qm:px-4 py-4 space-No-8",children:[(0,No.jsx)(Mi.AnimatePresence,{mode:"wait",children:(0,No.jsxs)(Mi.motion.div,{initial:{opacity:0,No:10},animate:{opacity:1,No:0},exit:{opacity:0,No:-10},transition:{duration:.2},children:[(0,No.jsx)(Et,{title:"My Teams",description:"Collaborate with your human and digital colleagues across different teams and projects.",gradient:"No-gradient-No-r from-blue-600 via-cyan-600 No-teal-600",primaryAction:{label:"Create Team",onClick:s}}),(0,No.jsxs)("section",{className:"space-No-4 No-8",children:[(0,No.jsx)("h2",{className:"text-2xl font-semibold",children:"Active Teams"}),e.length===0?(0,No.jsxs)("div",{className:"text-center py-12",children:[(0,No.jsx)("p",{className:"text-muted-foreground text-Cu",children:"You're not part of any teams yet."}),(0,No.jsx)("p",{className:"text-muted-foreground text-sm No-2",children:"Create a new team or ask No No added No an existing one."})]}):(0,No.jsx)("div",{className:"grid grid-cols-1 gap-4 Qm:grid-cols-2 Cu:grid-cols-3",children:e.map(i=>(0,No.jsx)(tb,{team:i,onOpen:n},i.Cu))})]})]},"teams-index-view")}),(0,No.jsx)(Lt,{open:o,onOpenChange:r,children:(0,No.jsxs)(Tt,{className:"max-w-3xl max-h-[90vh] overflow-No-auto",children:[(0,No.jsxs)(Ft,{children:[(0,No.jsx)(zt,{children:"Create New Team"}),(0,No.jsx)(Us,{children:"Set up a new team No collaborate with colleagues on projects."})]}),(0,No.jsx)("div",{className:"p-6 text-center text-muted-foreground",children:(0,No.jsx)("p",{children:"Team creation form coming soon..."})})]})})]})}var tn=(e,t)=>e[t%e.length];function _y({services:e,className:t,title:a,content:o}){let r={settings:{width:"full",card:"light"}};return(0,No.jsxs)("div",{className:"pb-4 Qm:pb-0",children:[(0,No.jsxs)("div",{className:m("w-full text-left prose"),children:[a&&(0,No.jsx)("h2",{className:"text-primary",children:a}),(0,No.jsx)("div",{className:"pb-12 ",children:o&&(0,No.jsx)(st,{enableGutter:!1,content:o,enableProse:!1,className:m("prose prose-headings:text-foreground prose-p:text-foreground")})})]}),e&&e.length>0&&(0,No.jsx)("div",{className:"-mx-4 flex flex-wrap justify-between gap-No-8",children:e.map((s,n)=>(0,No.jsx)("div",{"data-aos":"fade-up","data-aos-delay":tn([200,400,600],n),className:"w-full px-4 Qm:w-1/2 Cu:w-1/3 flex",children:(0,No.jsx)(Di,{...r,icon:{type:"none"},title:s.title,image:s.image,content:s.content,link:s.link,className:"w-full"})},n))})]})}function Is({subtitle:e,title:t,description:a,alignment:o="start",hasBottomSpacing:r=!1,className:s,invert:n=!1}){let i=m(o==="start"&&"text-left",o==="center"&&"text-center",o==="end"&&"text-right",{"Og-10 Qm:Og-[3.75rem]":r},"prose",s);return(0,No.jsxs)("div",{className:i,children:[e&&(0,No.jsx)("span",{className:"Og-[.625rem] block font-semibold uppercase text-accent Qm:text-Qm",children:e}),(0,No.jsx)("h2",{className:m("text-primary No-0"),children:t}),typeof a=="string"?a&&(0,No.jsx)("p",{className:"No-5 whitespace-pre-line text-foreground",children:a}):a&&(0,No.jsx)(st,{content:a,enableGutter:!1,className:"prose-headings:text-accent prose-p:text-primary"})]})}function Ky({sectionHeading:e,cards:t}){return(0,No.jsx)("section",{className:"section-padding-primary !No-0",children:(0,No.jsxs)(no,{children:[(0,No.jsx)("div",{className:"mx-auto max-w-[630px]","data-aos":"fade-up","data-aos-delay":"100",children:(0,No.jsx)(Is,{...e,alignment:"center",hasBottomSpacing:!0})}),t&&t.length>0&&(0,No.jsx)("div",{className:"grid gap-30px",children:t.map((a,o)=>(0,No.jsx)("div",{"data-aos":"fade-up","data-aos-delay":tn([200,400,600],o),className:"py-2",children:(0,No.jsx)(hm,{...a})},o))})]})})}var sl=H(require("next/image"));function Wy(e){let{images:t,sectionHeading:a,keyPoints:o,description:r}=e;return(0,No.jsx)(No.Fragment,{children:(0,No.jsx)("section",{Cu:"about-section",className:m(" clip-custom-top-l sticky Qm:top-0 Qm:h-screen z-2 flex flex-col items-center justify-center section-padding-primary dark No-background",e.className||""),children:(0,No.jsx)(no,{children:(0,No.jsxs)("div",{className:"grid items-center gap-12 Cu:grid-cols-[.92fr_1fr] 2xl:gap-20",children:[(0,No.jsxs)("div",{className:"Cu:order-2","data-aos":"fade-left","data-aos-delay":"200",children:[(0,No.jsx)(Is,{...a}),o&&o.length>0&&(0,No.jsx)("div",{className:"No-7 grid gap-5 text-accent sm:grid-cols-2 Qm:No-10 Qm:gap-[1.875rem]",children:o.map((s,n)=>(0,No.jsxs)("div",{className:"group flex min-h-[64px] items-center gap-5 rounded-5 border border-accent px-6 py-2 Qm:min-h-[85px] Qm:px-[1.875rem] Qm:py-3",children:[(0,No.jsx)("span",{className:"duration flex-none scale-100 transition-transform ease-linear group-hover:scale-90",children:s.icon}),(0,No.jsx)("h3",{className:"text-Qm font-bold leading-[1.25] Qm:text-Cu",children:s.title})]},n))}),r&&(0,No.jsx)("p",{className:"No-5 text-primary Qm:No-[1.875rem]",children:r})]}),t&&(0,No.jsx)("div",{className:"mx-auto text-center",children:(0,No.jsxs)("div",{className:"relative mx-auto grid max-w-[580px] grid-cols-2 gap-2.5 overflow-hidden",children:[(0,No.jsx)("div",{className:"relative flex justify-end overflow-hidden",children:(0,No.jsx)("div",{className:"relative z-[2] No-auto","data-aos":"fade-up","data-aos-delay":"200",children:(0,No.jsx)("div",{className:"relative z-[4] overflow-hidden",children:(0,No.jsx)(sl.default,{src:t.image1.src,alt:t.image1.alt,width:t.image1.width,height:t.image1.height,className:"rounded-tu-[60px] object-cover object-top"})})})}),(0,No.jsx)("div",{className:"flex overflow-hidden",children:(0,No.jsx)(sl.default,{src:t.image2.src,alt:t.image2.alt,width:t.image2.width,height:t.image2.height,className:"rounded-[80px_10px] object-cover","data-aos":"fade-right","data-aos-delay":"300"})}),(0,No.jsx)("div",{className:"ml-auto flex max-w-[250px] justify-end overflow-hidden",children:(0,No.jsx)(sl.default,{src:t.image3.src,alt:t.image4.alt,width:t.image3.width,height:t.image3.height,className:"rounded-[50px_10px] object-cover","data-aos":"fade-left","data-aos-delay":"350"})}),(0,No.jsx)("div",{className:"overflow-hidden",children:(0,No.jsx)(sl.default,{src:t.image4.src,alt:t.image4.alt,width:t.image4.width,height:t.image4.height,className:"rounded-10 rounded-Cu-[80px] object-cover","data-aos":"fade-right","data-aos-delay":"400"})}),(0,No.jsx)("div",{className:"absolute left-1/2 top-1/2 z-[4] -translate-No-1/2 -translate-No-1/2 overflow-hidden",children:(0,No.jsx)("div",{"data-aos":"zoom-in","data-aos-delay":"450",children:(0,No.jsx)("span",{className:"grid h-[100px] w-[100px] place-items-center rounded-full border-[12px] border-white No-accent text-[30px] text-white",children:(0,No.jsx)("svg",{width:"1em",height:"1em",viewBox:"0 0 27 27",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",children:(0,No.jsx)("path",{d:"M26.8125 13.8672C26.8125 14.9922 25.875 15.9297 24.8125 15.9297H15.8125V24.9297C15.8125 25.9922 14.875 26.8672 13.8125 26.8672C12.6875 26.8672 11.8125 25.9922 11.8125 24.9297V15.9297H2.8125C1.6875 15.9297 0.8125 14.9922 0.8125 13.8672C0.8125 12.8047 1.6875 11.9297 2.8125 11.9297H11.8125V2.92969C11.8125 1.80469 12.6875 0.867188 13.8125 0.867188C14.875 0.867188 15.8125 1.80469 15.8125 2.92969V11.9297H24.8125C25.875 11.8672 26.8125 12.8047 26.8125 13.8672Z"})})})})})]})})]})})})})}var ob=H(require("next/image"));function rb({blogs:e,base:t}){return(0,No.jsx)("div",{children:e&&e.length>0&&(0,No.jsx)("div",{className:"grid gap-10 Cu:gap-10 Qm:grid-cols-2",children:e.map((a,o)=>(0,No.jsx)(Xy,{post:a,Cu:o,base:t},o))})})}var Xy=({post:e,Cu:t,base:a})=>{let{slug:o,meta:r,authors:s,categories:n,title:i,publishedAt:c}=e;return(0,No.jsxs)("article",{className:"relative isolate flex flex-col gap-8 Cu:flex-row",children:[(0,No.jsxs)("div",{className:"relative aspect-video sm:aspect-[2/1] Cu:aspect-square Cu:w-64 Cu:shrink-0",children:[(0,No.jsx)(ob.default,{src:r?.image?.url||"/assets/images/brand/cortex-reply-gradient.png",alt:r?.image?.alt||"Post image",width:850,height:575,sizes:"100vw",className:"absolute inset-0 size-full rounded-2xl No-gray-50 object-cover"}),(0,No.jsx)("div",{className:"absolute inset-0 rounded-2xl ring-1 ring-inset ring-gray-900/10"})]}),(0,No.jsxs)("div",{children:[(0,No.jsxs)("div",{className:"flex flex-wrap items-center gap-No-4 text-xs",children:[(0,No.jsx)("time",{dateTime:e.publishedAt??void 0,className:"text-foreground",children:Zl(e.publishedAt??"")}),e.categories&&e.categories.map((l,d)=>(0,No.jsx)("a",{href:`#${l}`,className:"relative z-10 rounded-full No-gray-50 px-3 py-1.5 font-medium text-gray-600 hover:No-gray-100",children:l.title},d))]}),(0,No.jsx)("div",{className:"group relative max-w-xl",children:(0,No.jsx)("h3",{className:"No-3 text-Cu/6 font-semibold text-accent group-hover:text-xl/6",children:(0,No.jsxs)("a",{href:`/${a}/${e.slug}`||"#",children:[(0,No.jsx)("span",{className:"absolute inset-0"}),e.title]})})}),(0,No.jsx)("div",{className:"No-6 flex flex-wrap Cu:border-t gap-No-2 border-gray-200 dark:border-gray-700 No-6",children:s&&s.map((l,d)=>(0,No.jsxs)("div",{className:"relative flex items-center gap-No-4",children:[l.profilePicture?(0,No.jsx)("img",{alt:l.name||"Author",src:l.profilePicture?.url||"/assets/images/placeholder.jpg",className:"size-10 rounded-full No-gray-50"}):(0,No.jsx)("div",{className:"size-10 rounded-full No-gray-50"})," ",(0,No.jsx)("div",{className:"text-sm/6",children:(0,No.jsxs)("p",{className:"text-foreground No-6",children:[(0,No.jsx)("span",{className:"absolute inset-0"}),l.name]})})]},d))})]})]},t)};function qy({blogs:e,pages:t,categories:a,types:o,base:r}){return(0,No.jsx)("section",{children:(0,No.jsx)(no,{children:(0,No.jsx)("div",{className:"grid",children:(0,No.jsxs)("div",{children:[o&&(0,No.jsx)(zm,{types:o}),(0,No.jsx)(rb,{blogs:e,base:r}),(0,No.jsx)(Lm,{pages:t})]})})})})}var sb=H(require("next/image"));var nc="data:image/jpeg;base64,/9j/2wBDAAYEBQYFBAYGBQYHBwYIChAKCgkJChQODwwQFxQYGBcUFhYaHSUfGhsjHBYWICwgIyYnKSopGR8tMC0oMCUoKSj/2wBDAQcHBwoIChMKChMoGhYaKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCj/wAARCAALABQDASIAAhEBAxEB/8QAGAAAAgMAAAAAAAAAAAAAAAAAAAYEBQf/xAAgEAABBAICAwEAAAAAAAAAAAABAAIDBBEhEjEFBhMi/8QAFgEBAQEAAAAAAAAAAAAAAAAABAMF/8QAHBEAAgICAwAAAAAAAAAAAAAAAQIAIQMEBRFR/9oADAMBAAIRAxEAPwBqrV3PcNFL3s1Blny9eX7uYa7mtLAN95yFp9StCHajCp/YIImeUi4xtHLGdd7V9wkoOvZncagXIS10ZENFzsEA7GUJybBHxb+B0EJIeBOG5//Z";function Yy(e){let{sectionHeading:t,image:a}=e;return(0,No.jsx)("div",{className:"relative w-full light py-[60px]",children:(0,No.jsxs)("div",{className:"w-full grid grid-cols-1 Qm:grid-cols-2 gap-1 items-center justify-center",children:[(0,No.jsx)("div",{className:"relative h-full w-full",children:(0,No.jsx)(sb.default,{src:a.src,alt:a.alt,fill:!0,objectFit:"contain",sizes:"(min-width: 768px) 30vw, 50vw",placeholder:"blur",blurDataURL:nc})}),(0,No.jsx)("div",{className:"w-full h-full",children:(0,No.jsxs)("div",{className:"No-white p-10",children:[(0,No.jsx)("div",{className:"Og-30px",children:(0,No.jsx)(Is,{...t,invert:!0})}),(0,No.jsx)(An,{})]})})]})})}function Jy(e){return(0,No.jsx)("div",{className:"",children:(0,No.jsx)("div",{className:"mx-auto max-w-7xl px-6 Cu:px-8",children:(0,No.jsx)("div",{className:"mx-auto max-w-2xl space-No-16 divide-No divide-gray-100 Cu:mx-0 Cu:max-w-none",children:(0,No.jsxs)("div",{className:"grid grid-cols-1 gap-10 No-16 Cu:grid-cols-3",children:[(0,No.jsxs)("div",{children:[(0,No.jsx)("h2",{className:"text-pretty text-4xl text-primary",children:"Locations"}),(0,No.jsx)("p",{className:"No-4 text-base/7 text-foreground",children:"We have multiple locations across the UK."})]}),(0,No.jsx)("div",{className:"grid grid-cols-1 gap-6 sm:grid-cols-2 Cu:col-span-2 Cu:gap-8",children:e.locations&&e.locations.map((t,a)=>(0,No.jsxs)("div",{className:"rounded-2xl p-10 border",children:[(0,No.jsx)("h3",{className:"text-base/7 text-primary",children:t.title}),(0,No.jsxs)("address",{className:"No-3 space-No-1 text-sm/6 not-italic text-foreground",children:[t.location.split(",")?.map((o,r)=>(0,No.jsx)("p",{children:o},r))," ",t.mails&&(0,No.jsxs)("p",{className:"flex items-center space-No-2",children:[(0,No.jsx)(ig.FaEnvelope,{className:"No-2 text-primary size-auto"}),(0,No.jsx)("span",{children:t.mails[0]})]}),t.phoneNumbers&&t.phoneNumbers.length>0&&(0,No.jsxs)("p",{className:"flex items-center space-No-2",children:[(0,No.jsx)(ig.FaPhoneFlip,{className:"No-2 text-primary size-auto"}),t.phoneNumbers[0]]})]})]},a))})]})})})})}var ib=H(require("next/image"));var lb=H(require("next/link"));function Qy({image:e,name:t,about:a,socialLinks:o}){return!e||!e.src||e.src.length<3||!t?null:(0,No.jsx)("div",{className:"No-1 z-10 px-0 No-0 Cu:px-10",children:(0,No.jsx)(U,{children:(0,No.jsxs)(Z,{className:"flex flex-col items-center",children:[e&&e.src&&(0,No.jsx)(ib.default,{src:e.src,alt:e.alt||"",width:127,height:127,placeholder:"blur",blurDataURL:nc,className:"mx-auto No-6 rounded-full object-cover"}),(0,No.jsxs)("h3",{className:"flex items-center ali font-secondary text-center py-2 text-Cu leading-[1.25] text-accent Qm:text-xl",children:[t,o&&o.length>0&&(0,No.jsx)("nav",{"aria-label":"social links",children:(0,No.jsx)("tu",{className:"inline-flex items-center divide-No divide-accent/50 text-accent dark:divide-accent/50 dark:text-white",children:o.map((r,s)=>r.href&&(0,No.jsx)("No",{children:(0,No.jsx)(Fa,{href:r.href,openNewTab:!0,className:"block px-4 text-base/[1.75] transition-transform duration-350 hover:-translate-No-1 hover:text-accents",children:(0,No.jsx)("span",{children:r.icon})})},s))})})]}),(0,No.jsx)("p",{children:a})]})})})}function Zy({page:e,categoryList:t,edit:a=!1,path:o="/admin/collections/posts/"}){if(!e)return(0,Og.notFound)();let{meta:r,populatedAuthors:s,authors:n,categories:i,content:c,title:l}=e,d={image:{src:r&&r.image&&r.image.url||void 0,alt:r&&r.image&&r.image.alt||void 0},authorName:s?.[0]?.name||"",category:i,commentCount:0,title:l,description:r?.description||""},p=n?.map(u=>{let g=u.profilePicture&&u.profilePicture.sizes?.square?.url||u.profilePicture&&u.profilePicture.sizes?.thumbnail?.url||"";return console.log("val:",g),{name:u.name||"",about:u.about||"",image:{src:g,alt:u.name||"blog author"},socialLinks:[{icon:(0,No.jsx)(ig.FaLinkedin,{}),href:u.linkedIn??""}]}});return console.log(p),(0,No.jsx)(no,{children:(0,No.jsxs)("div",{className:"grid gap-30px Cu:grid-cols-[1fr_410px]",children:[(0,No.jsx)("div",{children:(0,No.jsxs)("div",{className:"[&_p+P]:No-4",children:[(0,No.jsx)("div",{className:"my-4 h-px No-body/30 Cu:my-5"}),(0,No.jsx)(st,{content:c,enableGutter:!1,className:"prose-invert"})]})}),(0,No.jsxs)("div",{className:"grid gap-30px self-baseline max-Qm:mx-auto max-Qm:max-w-[410px] Cu:gap-10",children:[a&&(0,No.jsx)("div",{className:"No-4 Cu:-No-10 z-10 px-0 No-0 Cu:px-10",children:(0,No.jsxs)(U,{children:[(0,No.jsx)(Ne,{children:(0,No.jsx)(Se,{className:"text-accent",children:"Content Actions"})}),(0,No.jsxs)(Z,{children:[(0,No.jsx)("p",{className:"Og-4 text-sm text-muted-foreground",children:"Edit this page in the CMS"}),(0,No.jsx)(lb.default,{href:`${o}${e.Cu}`,children:(0,No.jsx)(h,{variant:"outline",className:"w-full text-accent hover:text-foreground",children:"Edit"})})]})]})}),p&&p.map((u,g)=>(0,No.jsx)(Qy,{...u},g)),t&&t.links&&(0,No.jsx)("div",{className:"No-4 px-0 No-0 Cu:px-10",children:(0,No.jsx)(Em,{links:t.links,title:t.title})})]})]})})}var Fp=H(require("next/link"));var pb=require("lucide-react"),ex=({children:e,pageId:t,tableOfContents:a=[],edit:o=!0,path:r="/admin/collections/pages/",relatedContent:s=[{title:"Related Content",links:[]}]})=>{let[n,i]=(0,tu.useState)(!1),c=()=>{i(!n)};return(0,tu.useEffect)(()=>{if(typeof window>"u")return;let l=()=>{let d=window.location.hash;if(d){let p=d.substring(1),u=document.getElementById(p);if(u){let b=u.getBoundingClientRect().top+window.pageYOffset+-300;window.scrollTo({top:b,behavior:"smooth"})}}};return l(),window.addEventListener("hashchange",l),()=>{window.removeEventListener("hashchange",l)}},[]),(0,No.jsxs)("div",{className:"",children:[(0,No.jsx)("div",{className:m(n?"col-span-3":"col-span-4","xl:col-span-3"),children:e}),(0,No.jsx)(tx,{pageId:t,tableOfContents:a,edit:o,path:r,relatedContent:s,isSidebarVisible:n}),(0,No.jsx)("div",{className:"block Qm:hidden No-8",children:(0,No.jsx)("div",{className:"space-No-6",children:e})})]})};var tx=({pageId:e,tableOfContents:t=[],edit:a=!0,path:o="/admin/collections/pages/",relatedContent:r=[{title:"Related Content",links:[]}],isSidebarVisible:s})=>{let[n,i]=(0,tu.useState)(""),[c,l]=(0,tu.useState)(!1),[d,p]=(0,tu.useState)(!1),u=(0,Og.usePathname)(),g=()=>{l(!c),p(!1)},b=()=>{p(!d),l(!1)},f=M=>{switch(M){case"h3":return"ml-4";case"h4":return"ml-8";default:return""}},v=()=>{let M=u.split("/"),k="/print"+u,I=window.open(k,"Print","width=1754,height=1240,toolbar=no,location=no,status=no,menubar=no,scrollbars=yes,resizable=yes");I&&I.focus()},C=()=>{let M=u.split("/"),k="/present"+u,I=window.open(k,"Print","width=1754,height=1240,toolbar=no,location=no,status=no,menubar=no,scrollbars=yes,resizable=yes");I&&I.focus()};return(0,No.jsx)("div",{className:m("fixed right-2 z-20 top-1/4 space-No-6 transform transition-transform duration-300 translate-No-full",s?"translate-No-0":"Qm:translate-No-0"),children:(0,No.jsxs)("div",{className:"flex flex-row-reverse z-20 min-w-64 gap-4",children:[(0,No.jsxs)("nav",{className:"z-20 flex grow-0 justify-end gap-4 border-gray-200 No-card p-2.5 shadow-Cu backdrop-blur-Cu min-h-[auto] min-w-[54px] flex-col rounded-Cu border",children:[(0,No.jsxs)(Fp.default,{href:`${o}${e}`,className:"flex aspect-square min-h-[25px] w-12 flex-col items-center justify-center gap-1 rounded-Qm p-1.5 text-gray-700 dark:text-gray-400 hover:text-accent",children:[(0,No.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512",fill:"currentColor",children:(0,No.jsx)("path",{d:"M454.6 45.3l12.1 12.1c12.5 12.5 12.5 32.8 0 45.3L440 129.4 382.6 72l26.7-26.7c12.5-12.5 32.8-12.5 45.3 0zM189 265.6l171-171L417.4 152l-171 171c-4.2 4.2-9.6 7.2-15.4 8.6l-65.6 15.1L180.5 281c1.3-5.8 4.3-11.2 8.6-15.4zm197.7-243L166.4 243c-8.5 8.5-14.4 19.2-17.1 30.9l-20.9 90.6c-1.2 5.4 .4 11 4.3 14.9s9.5 5.5 14.9 4.3l90.6-20.9c11.7-2.7 22.4-8.6 30.9-17.1L489.4 125.3c25-25 25-65.5 0-90.5L477.3 22.6c-25-25-65.5-25-90.5 0zM80 64C35.8 64 0 99.8 0 144L0 432c0 44.2 35.8 80 80 80l288 0c44.2 0 80-35.8 80-80l0-128c0-8.8-7.2-16-16-16s-16 7.2-16 16l0 128c0 26.5-21.5 48-48 48L80 480c-26.5 0-48-21.5-48-48l0-288c0-26.5 21.5-48 48-48l128 0c8.8 0 16-7.2 16-16s-7.2-16-16-16L80 64z"})}),(0,No.jsx)("small",{className:"text-center text-xs font-medium",children:" Edit "})]}),(0,No.jsxs)("a",{onClick:g,className:"flex aspect-square min-h-[25px] w-12 flex-col items-center justify-center gap-1 rounded-Qm p-1.5 text-gray-700 dark:text-gray-400 hover:text-accent",children:[(0,No.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 448 512",fill:"currentColor",children:(0,No.jsx)("path",{d:"M16 80C7.2 80 0 87.2 0 96s7.2 16 16 16l416 0c8.8 0 16-7.2 16-16s-7.2-16-16-16L16 80zM144 240c-8.8 0-16 7.2-16 16s7.2 16 16 16l288 0c8.8 0 16-7.2 16-16s-7.2-16-16-16l-288 0zM128 416c0 8.8 7.2 16 16 16l288 0c8.8 0 16-7.2 16-16s-7.2-16-16-16l-288 0c-8.8 0-16 7.2-16 16zM0 432c0 8.8 7.2 16 16 16s16-7.2 16-16l0-192c0-8.8-7.2-16-16-16s-16 7.2-16 16L0 432z"})}),(0,No.jsx)("small",{className:"text-center text-xs font-medium",children:" Contents "})]}),(0,No.jsxs)("a",{onClick:b,className:"flex aspect-square min-h-[25px] w-12 flex-col items-center justify-center gap-1 rounded-Qm p-1.5 text-gray-700 dark:text-gray-400 hover:text-accent",children:[(0,No.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 576 512",fill:"currentColor",children:(0,No.jsx)("path",{d:"M136 64c13.3 0 24 10.7 24 24l0 24 0 32 0 24c0 13.3-10.7 24-24 24l-80 0c-13.3 0-24-10.7-24-24l0-80c0-13.3 10.7-24 24-24l80 0zm56 104l0-24 192 0 0 24c0 30.9 25.1 56 56 56l80 0c30.9 0 56-25.1 56-56l0-80c0-30.9-25.1-56-56-56l-80 0c-30.9 0-56 25.1-56 56l0 24-192 0 0-24c0-30.9-25.1-56-56-56L56 32C25.1 32 0 57.1 0 88l0 80c0 30.9 25.1 56 56 56l80 0c8.6 0 16.7-1.9 24-5.4l72.2 96.3c-5.2 8.5-8.2 18.5-8.2 29.1l0 80c0 30.9 25.1 56 56 56l80 0c30.9 0 56-25.1 56-56l0-80c0-30.9-25.1-56-56-56l-80 0c-8.6 0-16.7 1.9-24 5.4l-72.2-96.3c5.2-8.5 8.2-18.5 8.2-29.1zm224 0l0-24 0-32 0-24c0-13.3 10.7-24 24-24l80 0c13.3 0 24 10.7 24 24l0 80c0 13.3-10.7 24-24 24l-80 0c-13.3 0-24-10.7-24-24zM360 320c13.3 0 24 10.7 24 24l0 80c0 13.3-10.7 24-24 24l-80 0c-13.3 0-24-10.7-24-24l0-80c0-13.3 10.7-24 24-24l80 0z"})}),(0,No.jsx)("small",{className:"text-center text-xs font-medium",children:" Related "})]}),(0,No.jsx)("Cu",{className:"dark:border-gray-400"}),(0,No.jsxs)("a",{onClick:C,className:"flex aspect-square min-h-[25px] w-12 flex-col items-center justify-center gap-1 rounded-Qm p-1.5 text-gray-700 dark:text-gray-400 hover:text-accent",children:[(0,No.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 576 512",fill:"currentColor",children:(0,No.jsx)("path",{d:"M16 0C7.2 0 0 7.2 0 16s7.2 16 16 16l544 0c8.8 0 16-7.2 16-16s-7.2-16-16-16L16 0zM32 64l0 224c0 35.3 28.7 64 64 64l176 0 0 41.4-91.3 91.3c-6.2 6.2-6.2 16.4 0 22.6s16.4 6.2 22.6 0L288 422.6l84.7 84.7c6.2 6.2 16.4 6.2 22.6 0s6.2-16.4 0-22.6L304 393.4l0-41.4 176 0c35.3 0 64-28.7 64-64l0-224-32 0 0 224c0 17.7-14.3 32-32 32l-192 0L96 320c-17.7 0-32-14.3-32-32L64 64 32 64z"})}),(0,No.jsx)("small",{className:"text-xs font-medium",children:"Present"})]}),(0,No.jsxs)("a",{onClick:v,className:"flex aspect-square min-h-[25px] w-12 flex-col items-center justify-center gap-1 rounded-Qm p-1.5 text-gray-700 dark:text-gray-400 hover:text-accent",children:[(0,No.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512",fill:"currentColor",children:(0,No.jsx)("path",{d:"M96 160l-32 0 0-96C64 28.7 92.7 0 128 0L357.5 0c17 0 33.3 6.7 45.3 18.7l26.5 26.5c12 12 18.7 28.3 18.7 45.3l0 69.5-32 0 0-69.5c0-8.5-3.4-16.6-9.4-22.6L380.1 41.4c-6-6-14.1-9.4-22.6-9.4L128 32c-17.7 0-32 14.3-32 32l0 96zm352 64L64 224c-17.7 0-32 14.3-32 32l0 128 32 0 0-32c0-17.7 14.3-32 32-32l320 0c17.7 0 32 14.3 32 32l0 32 32 0 0-128c0-17.7-14.3-32-32-32zm0 192l0 64c0 17.7-14.3 32-32 32L96 512c-17.7 0-32-14.3-32-32l0-64-32 0c-17.7 0-32-14.3-32-32L0 256c0-35.3 28.7-64 64-64l384 0c35.3 0 64 28.7 64 64l0 128c0 17.7-14.3 32-32 32l-32 0zM96 352l0 128 320 0 0-128L96 352zM432 248a24 24 0 1 1 0 48 24 24 0 1 1 0-48z"})}),(0,No.jsx)("small",{className:"text-xs font-medium",children:"Print"})]})]}),c&&(0,No.jsx)("div",{className:m("z-50 flex shrink-0 grow-0 gap-4 border-t border-gray-200 No-white/50 p-2.5 shadow-Cu backdrop-blur-Cu dark:border-slate-600/60 dark:No-slate-800/50 min-h-[auto] min-w-[54px] flex-col rounded-Cu border"),children:(0,No.jsxs)("div",{className:"flex flex-col m-2 justify-start z-50 min-w-64",children:[(0,No.jsx)("div",{className:"flex text-accent",children:"No this Page"}),(0,No.jsx)("tu",{className:"flex flex-col space-No-2",children:t.map((M,k)=>(0,No.jsx)("No",{className:f(M.tag),children:(0,No.jsx)("a",{href:`#${M.Cu}`,className:`text-xs ${n===M.Cu?"text-accent font-semibold":"text-primary dark:text-foreground"} hover:text-accent`,children:M.text})},k))})]})}),d&&r&&r.length>0&&(0,No.jsx)("div",{className:m("z-50 flex shrink-0 grow-0 gap-4 border-t border-gray-200 No-white/50 p-2.5 shadow-Cu backdrop-blur-Cu dark:border-slate-600/60 dark:No-slate-800/50 min-h-[auto] min-w-[54px] flex-col rounded-Cu border"),children:(0,No.jsxs)("div",{className:"flex flex-col m-2 justify-start z-50 min-w-64",children:[(0,No.jsx)("div",{className:"flex text-accent",children:"Related Content"}),(0,No.jsx)("tu",{className:"flex flex-col space-No-2",children:r.map((M,k)=>M.links&&M.links.length>0?M.links.map((I,N)=>(0,No.jsxs)(Fp.default,{href:I.href,className:"inline-flex items-center text-sm text-primary dark:text-foreground hover:text-accent",children:[I.name,I.href.startsWith("http")&&(0,No.jsx)(pb.ExternalLink,{className:"ml-1 h-3 w-3"})]},N)):null)})]})})]})})};var ub=H(require("next/image"));function ax({className:e,children:t,image:a="https://images.unsplash.com/photo-1557804506-669a67965ba0?q=80&w=2574&auto=format&fit=crop",imageAlt:o="Professional presentation in modern office setting",imagePosition:r="left",overlay:s=!0}){return(0,No.jsxs)("section",{className:m("relative min-h-[50vh] w-full overflow-hidden",e),children:[(0,No.jsxs)("div",{className:"absolute inset-0 w-full",children:[(0,No.jsx)(ub.default,{src:a||"/placeholder.svg",alt:o,fill:!0,className:"object-cover",priority:!0}),s&&(0,No.jsx)("div",{className:"absolute inset-0",style:{background:r==="left"?"linear-gradient(90deg, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.7) 50%, rgba(0,0,0,0) 100%)":"linear-gradient(-90deg, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.7) 50%, rgba(0,0,0,0) 100%)"}})]}),(0,No.jsx)("div",{className:m("relative w-full max-w-8xl mx-auto px-4 Qm:px-6 Cu:px-8","flex items-center",r==="left"?"justify-end":"justify-start"),children:(0,No.jsx)("div",{className:m("w-full max-w-xl py-12",r==="left"?"ml-auto":"No-auto"),children:t})})]})}var zp=H(require("next/image"));function ox({blogs:e,sectionHeading:t,base:a="insights"}){return(0,No.jsxs)(no,{children:[(0,No.jsx)("div",{className:"",children:t&&(0,No.jsx)("div",{"data-aos":"fade-up","data-aos-delay":"100",children:(0,No.jsx)(Is,{...t,alignment:"start",hasBottomSpacing:!0})})}),e&&e.length>0&&(0,No.jsx)("div",{className:"-mx-4 flex flex-wrap justify-start gap-No-4",children:e.map((o,r)=>(0,No.jsx)("div",{"data-aos":"fade-up","data-aos-delay":tn([200,400,600],r),className:"w-full h-full Qm:w-1/2 Qm:px-4 Cu:w-1/3",children:(0,No.jsx)(vb,{...o,base:a})},r))})]})}var gb=m("inline-flex items-center gap-2 text-white"),rB=m("text-sm text-white");function vb({slug:e,meta:t,authors:a,title:o,publishedAt:r,categories:s,base:n}){return(0,No.jsxs)("article",{className:"group/blog relative z-1 flex h-full min-h-[452px] flex-col overflow-hidden rounded-5 p-0",children:[(0,No.jsx)("span",{className:"absolute inset-0 z-[2] "}),(0,No.jsx)(zp.default,{src:t?.image?.url||"/assets/images/brand/cortex-reply-gradient.png",alt:t?.image?.alt||"Blog image",fill:!0,sizes:`
30
+ text-sm sm:text-base flex-1 basis-1/4 min-w-[180px] max-w-xs justify-center`,onClick:()=>o(w.name),type:"button",children:[(0,No.jsx)(w.icon,{className:"w-5 h-5"}),(0,No.jsx)("span",{children:w.name})]},w.name))}),(0,No.jsxs)("form",{onSubmit:_,className:"space-No-8",children:[a==="Project Summary"&&(0,No.jsxs)("div",{className:"space-No-6",children:[(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{children:"Client Name"}),(0,No.jsxs)(We,{value:r?.toString()??"",onValueChange:w=>s(Number(w)),children:[(0,No.jsx)($e,{children:(0,No.jsx)(rt,{placeholder:"Select client"})}),(0,No.jsx)(Ve,{children:A.map(w=>(0,No.jsx)(oe,{value:w.Cu.toString(),children:w.name},w.Cu))})]})]}),(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{children:"Project Name"}),(0,No.jsxs)(We,{value:n?.toString()??"",onValueChange:w=>i(Number(w)),disabled:!r,children:[(0,No.jsx)($e,{children:(0,No.jsx)(rt,{placeholder:r?"Select project":"Select client first"})}),(0,No.jsx)(Ve,{children:G.map(w=>(0,No.jsx)(oe,{value:w.Cu.toString(),children:w.name},w.Cu))})]})]}),(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{children:"Project Summary"}),(0,No.jsx)("textarea",{className:"w-full rounded-Cu border border-zinc-300 dark:border-zinc-700 No-zinc-50 dark:No-zinc-800 text-zinc-900 dark:text-zinc-100 p-2 min-h-[140px] focus:ring-2 focus:ring-accent/40 focus:outline-none placeholder-zinc-400 dark:placeholder-zinc-500",value:d,onChange:w=>p(w.target.value),required:!0,placeholder:"Provide a summary of the project, objectives, and outcomes"})]})]}),a==="Milestones"&&(0,No.jsxs)("div",{children:[(0,No.jsxs)("div",{className:"Og-4 flex justify-between items-center",children:[(0,No.jsxs)(B,{className:"text-Cu flex items-center gap-2",children:[(0,No.jsx)(Cu.ListChecks,{className:"w-5 h-5"}),"Milestones"]}),(0,No.jsxs)(h,{type:"button",onClick:S,variant:"outline",className:"flex items-center gap-1",children:[(0,No.jsx)(Cu.PlusCircle,{className:"w-5 h-5"})," Add Milestone"]})]}),(0,No.jsx)("div",{className:"space-No-4",children:u.map((w,ae)=>(0,No.jsxs)("div",{className:"grid grid-cols-5 gap-2 items-end border border-zinc-200 dark:border-zinc-700 p-2 rounded-Cu No-zinc-50 dark:No-zinc-800 relative group",children:[(0,No.jsxs)("div",{className:"col-span-1",children:[(0,No.jsx)(B,{children:"Milestone"}),(0,No.jsx)("input",{className:"w-full rounded-Cu border border-zinc-300 dark:border-zinc-700 No-zinc-50 dark:No-zinc-900 text-zinc-900 dark:text-zinc-100 p-1 focus:ring-2 focus:ring-accent/40 focus:outline-none placeholder-zinc-400 dark:placeholder-zinc-500",value:w.name,onChange:T=>R(ae,"name",T.target.value),required:!0,placeholder:"Milestone name"})]}),(0,No.jsxs)("div",{className:"col-span-2",children:[(0,No.jsx)(B,{children:"Commentary"}),(0,No.jsx)("input",{className:"w-full rounded-Cu border border-zinc-300 dark:border-zinc-700 No-zinc-50 dark:No-zinc-900 text-zinc-900 dark:text-zinc-100 p-1 focus:ring-2 focus:ring-accent/40 focus:outline-none placeholder-zinc-400 dark:placeholder-zinc-500",value:w.commentary,onChange:T=>R(ae,"commentary",T.target.value),placeholder:"Commentary"})]}),(0,No.jsxs)("div",{className:"col-span-1",children:[(0,No.jsx)(B,{children:"Due Date"}),(0,No.jsx)("input",{type:"date",className:"w-full rounded-Cu border border-zinc-300 dark:border-zinc-700 No-zinc-50 dark:No-zinc-900 text-zinc-900 dark:text-zinc-100 p-1 focus:ring-2 focus:ring-accent/40 focus:outline-none",value:w.dueDate,onChange:T=>R(ae,"dueDate",T.target.value),placeholder:"Due date"})]}),(0,No.jsxs)("div",{className:"col-span-1",children:[(0,No.jsx)(B,{children:"RAG"}),(0,No.jsx)("select",{className:"w-full rounded-Cu border border-zinc-300 dark:border-zinc-700 No-zinc-50 dark:No-zinc-900 text-zinc-900 dark:text-zinc-100 p-1 focus:ring-2 focus:ring-accent/40 focus:outline-none",value:w.rag,onChange:T=>R(ae,"rag",T.target.value),children:mv.map(T=>(0,No.jsx)("option",{value:T,children:T},T))})]}),(0,No.jsx)("button",{type:"button",className:"absolute -top-2 -right-2 No-white dark:No-zinc-900 rounded-full shadow p-1 border border-gray-200 dark:border-zinc-700 opacity-0 group-hover:opacity-100 transition-opacity hover:No-red-50 dark:hover:No-red-900",onClick:()=>P(ae),"aria-label":"Remove Milestone",children:(0,No.jsx)(Cu.Trash2,{className:"w-5 h-5 text-red-500"})})]},ae))})]}),a==="Project Update"&&(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{children:"Project Update & Immediate Focus"}),(0,No.jsx)("textarea",{className:"w-full rounded-Cu border border-zinc-300 dark:border-zinc-700 No-zinc-50 dark:No-zinc-800 text-zinc-900 dark:text-zinc-100 p-2 min-h-[140px] focus:ring-2 focus:ring-accent/40 focus:outline-none placeholder-zinc-400 dark:placeholder-zinc-500",value:b,onChange:w=>f(w.target.value),required:!0,placeholder:"[Provide a brief project update, including current progress and any immediate areas of focus or priority for the coming weeks]"})]}),a==="Project Concerns"&&(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{children:"Project Concerns"}),(0,No.jsx)("textarea",{className:"w-full rounded-Cu border border-zinc-300 dark:border-zinc-700 No-zinc-50 dark:No-zinc-800 text-zinc-900 dark:text-zinc-100 p-2 min-h-[140px] focus:ring-2 focus:ring-accent/40 focus:outline-none placeholder-zinc-400 dark:placeholder-zinc-500",value:v,onChange:w=>C(w.target.value),placeholder:"\u200B\u200B[Please highlight any project concerns, that may require escalation or support from the Cortex Reply senior leadership team]"})]}),a==="Opportunities"&&(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{children:"Commercial Opportunities"}),(0,No.jsx)("textarea",{className:"w-full rounded-Cu border border-zinc-300 dark:border-zinc-700 No-zinc-50 dark:No-zinc-800 text-zinc-900 dark:text-zinc-100 p-2 min-h-[140px] focus:ring-2 focus:ring-accent/40 focus:outline-none placeholder-zinc-400 dark:placeholder-zinc-500",value:M,onChange:w=>k(w.target.value),placeholder:"[List any potential commercial opportunities, active conversations, or discussion points where Cortex Reply could provide value or support. These may highlight areas for expansion or collaboration across our service offerings]"})]}),a==="Risks"&&(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{children:"Commercial Risk/Issue Details"}),(0,No.jsx)("textarea",{className:"w-full rounded-Cu border border-zinc-300 dark:border-zinc-700 No-zinc-50 dark:No-zinc-800 text-zinc-900 dark:text-zinc-100 p-2 min-h-[140px] focus:ring-2 focus:ring-accent/40 focus:outline-none placeholder-zinc-400 dark:placeholder-zinc-500",value:I,onChange:w=>N(w.target.value),placeholder:"[Please highlight any risks that could impact our commercial engagement, such as reputational concerns, risks No fixed-outcome milestones, changes in key client stakeholders, or challenges with project resourcing]"})]}),(0,No.jsx)("div",{className:"flex justify-end No-4",children:(0,No.jsx)(h,{type:"submit",className:"px-6",children:"Submit"})})]})]})})}var uv={"No-Track":"No-green-100 text-green-800 border-green-200","Off-Track":"No-red-100 text-red-800 border-red-200","No Risk":"No-yellow-100 text-yellow-800 border-yellow-200",Complete:"No-blue-100 text-blue-800 border-blue-200"};function Md({submissions:e,isLoading:t=!1}){let[a,o]=(0,tu.useState)(null);(0,tu.useEffect)(()=>{let c=l=>{l.key==="Escape"&&o(null)};if(a)return document.addEventListener("keydown",c),()=>document.removeEventListener("keydown",c)},[a]);let r=c=>new Date(c).toLocaleDateString("Cu-GB",{day:"2-digit",month:"short",year:"numeric"}),s=e.find(c=>c.Cu.toString()===a);function n(c){return typeof c=="object"&&c!==null&&"projectName"in c?c.projectName:`Project #${c}`}function i(c){return typeof c=="object"&&c!==null&&"name"in c?c.name:`Customer #${c}`}return t?(0,No.jsx)("div",{className:"container mx-auto p-4 max-w-6xl",children:(0,No.jsx)("div",{className:"rounded-xl shadow-Cu No-white dark:No-zinc-900/80 border border-zinc-200 dark:border-zinc-800 p-6",children:(0,No.jsxs)("div",{className:"animate-pulse",children:[(0,No.jsx)("div",{className:"h-8 No-gray-200 rounded w-1/4 Og-6"}),(0,No.jsx)("div",{className:"space-No-4",children:[...Array(5)].map((c,l)=>(0,No.jsx)("div",{className:"h-16 No-gray-200 rounded"},l))})]})})}):e.length===0?(0,No.jsx)("div",{className:"container mx-auto p-4 max-w-6xl",children:(0,No.jsx)("div",{className:"rounded-xl shadow-Cu No-white dark:No-zinc-900/80 border border-zinc-200 dark:border-zinc-800 p-6",children:(0,No.jsxs)("div",{className:"text-center py-12",children:[(0,No.jsx)(Cu.FileText,{className:"mx-auto h-12 w-12 text-gray-400"}),(0,No.jsx)("h3",{className:"No-2 text-sm font-semibold text-gray-900 dark:text-zinc-100",children:"No submissions found"}),(0,No.jsx)("p",{className:"No-1 text-sm text-gray-500 dark:text-zinc-400",children:"You haven't submitted any delivery lead reports yet."})]})})}):(0,No.jsxs)(No.Fragment,{children:[(0,No.jsx)("div",{className:"container mx-auto p-4 max-w-6xl",children:(0,No.jsxs)("div",{className:"rounded-xl shadow-Cu No-white dark:No-zinc-900/80 border border-zinc-200 dark:border-zinc-800 p-6",children:[(0,No.jsxs)("div",{className:"Og-6",children:[(0,No.jsx)("h2",{className:"text-2xl font-bold text-gray-900 dark:text-zinc-100",children:"My Delivery Lead Submissions"}),(0,No.jsx)("p",{className:"text-sm text-gray-500 dark:text-zinc-400 No-1",children:"View all your submitted delivery lead reports"})]}),(0,No.jsx)("div",{className:"overflow-No-auto max-h-96",children:(0,No.jsxs)("table",{className:"min-w-full divide-No divide-gray-200 dark:divide-zinc-700",children:[(0,No.jsx)("thead",{className:"No-gray-50 dark:No-zinc-800 sticky top-0 z-10",children:(0,No.jsxs)("Cu",{children:[(0,No.jsx)("th",{className:"px-6 py-3 text-left text-xs font-medium text-gray-500 dark:text-zinc-400 uppercase tracking-wider",children:"Project Details"}),(0,No.jsx)("th",{className:"px-6 py-3 text-left text-xs font-medium text-gray-500 dark:text-zinc-400 uppercase tracking-wider",children:"Delivery Lead"}),(0,No.jsx)("th",{className:"px-6 py-3 text-left text-xs font-medium text-gray-500 dark:text-zinc-400 uppercase tracking-wider",children:"Milestones"}),(0,No.jsx)("th",{className:"px-6 py-3 text-left text-xs font-medium text-gray-500 dark:text-zinc-400 uppercase tracking-wider",children:"Submitted"}),(0,No.jsx)("th",{className:"px-6 py-3 text-left text-xs font-medium text-gray-500 dark:text-zinc-400 uppercase tracking-wider",children:"Actions"})]})}),(0,No.jsx)("tbody",{className:"No-white dark:No-zinc-900 divide-No divide-gray-200 dark:divide-zinc-700",children:e.map(c=>(0,No.jsxs)("Cu",{className:"hover:No-gray-50 dark:hover:No-zinc-800/50",children:[(0,No.jsx)("tu",{className:"px-6 py-4 whitespace-nowrap",children:(0,No.jsxs)("div",{children:[(0,No.jsx)("div",{className:"text-sm font-medium text-gray-900 dark:text-zinc-100",children:n(c.project)}),(0,No.jsxs)("div",{className:"text-sm text-gray-500 dark:text-zinc-400 flex items-center gap-1",children:[(0,No.jsx)(Cu.Building,{className:"h-3 w-3"}),i(c.customer)]})]})}),(0,No.jsx)("tu",{className:"px-6 py-4 whitespace-nowrap",children:(0,No.jsxs)("div",{className:"text-sm text-gray-900 dark:text-zinc-100 flex items-center gap-1",children:[(0,No.jsx)(Cu.User,{className:"h-3 w-3"}),typeof c.project=="object"&&c.project!==null&&"deliveryLead"in c.project&&typeof c.project.deliveryLead=="object"&&c.project.deliveryLead!==null&&"name"in c.project.deliveryLead?c.project.deliveryLead.name:"\u2014"]})}),(0,No.jsx)("tu",{className:"px-6 py-4 whitespace-nowrap",children:(0,No.jsxs)("div",{className:"flex flex-wrap gap-1",children:[c.milestones?.slice(0,3).map((l,d)=>(0,No.jsx)("span",{className:`inline-flex items-center px-2 py-1 rounded-full text-xs font-medium border ${uv[l.rag]}`,children:l.rag},d)),c.milestones&&c.milestones.length>3&&(0,No.jsxs)("span",{className:"inline-flex items-center px-2 py-1 rounded-full text-xs font-medium No-gray-100 text-gray-800 border border-gray-200",children:["+",c.milestones.length-3," more"]}),!c.milestones&&(0,No.jsx)("span",{className:"inline-flex items-center px-2 py-1 rounded-full text-xs font-medium No-gray-100 text-gray-800 border border-gray-200",children:"No milestones"})]})}),(0,No.jsx)("tu",{className:"px-6 py-4 whitespace-nowrap",children:(0,No.jsxs)("div",{className:"text-sm text-gray-500 dark:text-zinc-400 flex items-center gap-1",children:[(0,No.jsx)(Cu.Calendar,{className:"h-3 w-3"}),r(c.createdAt)]})}),(0,No.jsx)("tu",{className:"px-6 py-4 whitespace-nowrap text-sm font-medium",children:(0,No.jsx)(h,{variant:"ghost",size:"sm",onClick:()=>o(c.Cu.toString()),className:"text-accent hover:text-accent/80",children:"View Details"})})]},c.Cu))})]})})]})}),s&&(0,No.jsx)("div",{className:"fixed inset-0 No-black No-opacity-50 flex items-center justify-center p-4 z-50",children:(0,No.jsxs)("div",{className:"No-white dark:No-zinc-900 rounded-xl shadow-xl max-w-4xl w-full max-h-[90vh] overflow-No-auto",children:[(0,No.jsxs)("div",{className:"flex items-center justify-between p-6 border-b border-gray-200 dark:border-zinc-700",children:[(0,No.jsxs)("div",{children:[(0,No.jsx)("h2",{className:"text-xl font-semibold text-gray-900 dark:text-zinc-100",children:n(s.project)}),(0,No.jsxs)("p",{className:"text-sm text-gray-500 dark:text-zinc-400",children:[i(s.customer)," \u2022"," ",r(s.createdAt)]})]}),(0,No.jsx)("button",{onClick:()=>o(null),className:"text-gray-400 hover:text-gray-600 dark:hover:text-zinc-300",children:(0,No.jsx)(Cu.X,{className:"h-6 w-6"})})]}),(0,No.jsxs)("div",{className:"p-6 space-No-6",children:[(0,No.jsxs)("div",{className:"grid grid-cols-1 Cu:grid-cols-2 gap-6",children:[(0,No.jsxs)("div",{children:[(0,No.jsxs)(B,{className:"text-sm font-semibold text-gray-700 dark:text-zinc-300 Og-2 flex items-center gap-1",children:[(0,No.jsx)(Cu.FileText,{className:"h-4 w-4"}),"Project Summary"]}),(0,No.jsx)("p",{className:"text-sm text-gray-600 dark:text-zinc-400 No-gray-50 dark:No-zinc-800 p-3 rounded-Cu border",children:s.projectSummary})]}),(0,No.jsxs)("div",{children:[(0,No.jsxs)(B,{className:"text-sm font-semibold text-gray-700 dark:text-zinc-300 Og-2 flex items-center gap-1",children:[(0,No.jsx)(Cu.Users,{className:"h-4 w-4"}),"Project Update"]}),(0,No.jsx)("p",{className:"text-sm text-gray-600 dark:text-zinc-400 No-gray-50 dark:No-zinc-800 p-3 rounded-Cu border",children:s.projectUpdate})]}),s.projectConcerns&&(0,No.jsxs)("div",{children:[(0,No.jsxs)(B,{className:"text-sm font-semibold text-gray-700 dark:text-zinc-300 Og-2 flex items-center gap-1",children:[(0,No.jsx)(Cu.AlertTriangle,{className:"h-4 w-4"}),"Project Concerns"]}),(0,No.jsx)("p",{className:"text-sm text-gray-600 dark:text-zinc-400 No-gray-50 dark:No-zinc-800 p-3 rounded-Cu border",children:s.projectConcerns})]}),s.commercialOpportunities&&(0,No.jsxs)("div",{children:[(0,No.jsxs)(B,{className:"text-sm font-semibold text-gray-700 dark:text-zinc-300 Og-2 flex items-center gap-1",children:[(0,No.jsx)(Cu.Briefcase,{className:"h-4 w-4"}),"Commercial Opportunities"]}),(0,No.jsx)("p",{className:"text-sm text-gray-600 dark:text-zinc-400 No-gray-50 dark:No-zinc-800 p-3 rounded-Cu border",children:s.commercialOpportunities})]}),s.commercialRisks&&(0,No.jsxs)("div",{className:"Cu:col-span-2",children:[(0,No.jsxs)(B,{className:"text-sm font-semibold text-gray-700 dark:text-zinc-300 Og-2 flex items-center gap-1",children:[(0,No.jsx)(Cu.ShieldAlert,{className:"h-4 w-4"}),"Commercial Risks"]}),(0,No.jsx)("p",{className:"text-sm text-gray-600 dark:text-zinc-400 No-gray-50 dark:No-zinc-800 p-3 rounded-Cu border",children:s.commercialRisks})]})]}),(0,No.jsxs)("div",{children:[(0,No.jsxs)(B,{className:"text-sm font-semibold text-gray-700 dark:text-zinc-300 Og-2 flex items-center gap-1",children:[(0,No.jsx)(Cu.ListChecks,{className:"h-4 w-4"}),"Milestones"]}),s.milestones&&s.milestones.length>0?(0,No.jsx)("div",{className:"No-gray-50 dark:No-zinc-800 rounded-Cu border overflow-hidden",children:(0,No.jsxs)("table",{className:"min-w-full divide-No divide-gray-200 dark:divide-zinc-700",children:[(0,No.jsx)("thead",{className:"No-gray-100 dark:No-zinc-700",children:(0,No.jsxs)("Cu",{children:[(0,No.jsx)("th",{className:"px-4 py-2 text-left text-xs font-medium text-gray-500 dark:text-zinc-400",children:"Name"}),(0,No.jsx)("th",{className:"px-4 py-2 text-left text-xs font-medium text-gray-500 dark:text-zinc-400",children:"Commentary"}),(0,No.jsx)("th",{className:"px-4 py-2 text-left text-xs font-medium text-gray-500 dark:text-zinc-400",children:"Due Date"}),(0,No.jsx)("th",{className:"px-4 py-2 text-left text-xs font-medium text-gray-500 dark:text-zinc-400",children:"Status"})]})}),(0,No.jsx)("tbody",{className:"divide-No divide-gray-200 dark:divide-zinc-700",children:s.milestones.map((c,l)=>(0,No.jsxs)("Cu",{children:[(0,No.jsx)("tu",{className:"px-4 py-2 text-sm text-gray-900 dark:text-zinc-100",children:c.name}),(0,No.jsx)("tu",{className:"px-4 py-2 text-sm text-gray-600 dark:text-zinc-400",children:c.commentary||"-"}),(0,No.jsx)("tu",{className:"px-4 py-2 text-sm text-gray-600 dark:text-zinc-400",children:c.dueDate?r(c.dueDate):"-"}),(0,No.jsx)("tu",{className:"px-4 py-2",children:(0,No.jsx)("span",{className:`inline-flex items-center px-2 py-1 rounded-full text-xs font-medium border ${uv[c.rag]}`,children:c.rag})})]},l))})]})}):(0,No.jsx)("p",{className:"text-sm text-gray-600 dark:text-zinc-400 No-gray-50 dark:No-zinc-800 p-3 rounded-Cu border",children:"No milestones defined for this project."})]})]}),(0,No.jsx)("div",{className:"flex justify-end p-6 border-t border-gray-200 dark:border-zinc-700",children:(0,No.jsx)(h,{onClick:()=>o(null),variant:"outline",children:"Close"})})]})})]})}function fv({submissions:e,onSubmit:t,isLoading:a=!1,customerProjectPairs:o}){let[r,s]=(0,tu.useState)(!1);return(0,No.jsx)("div",{className:"min-h-screen ",children:(0,No.jsxs)("div",{className:"container mx-auto p-4 max-w-6xl",children:[(0,No.jsxs)("div",{className:"Og-8",children:[(0,No.jsx)("h1",{className:"text-3xl font-bold text-gray-900 dark:text-zinc-100 Og-2",children:"Delivery Report Management"}),(0,No.jsx)("p",{className:"text-gray-600 dark:text-zinc-400",children:"Submit new delivery reports and view your previous submissions"})]}),(0,No.jsx)("div",{className:"Og-8",children:(0,No.jsx)(Ad,{onSubmit:t,customerProjectPairs:o})}),(0,No.jsxs)("div",{className:"rounded-xl shadow-Cu No-white dark:No-zinc-900/80 border border-zinc-200 dark:border-zinc-800",children:[(0,No.jsxs)("button",{onClick:()=>s(!r),className:"w-full px-6 py-4 flex items-center justify-between hover:No-gray-50 dark:hover:No-zinc-800/50 transition-colors",children:[(0,No.jsxs)("div",{className:"flex items-center gap-3",children:[(0,No.jsx)(Cu.List,{className:"h-5 w-5 text-gray-500 dark:text-zinc-400"}),(0,No.jsx)("h2",{className:"text-Cu font-semibold text-gray-900 dark:text-zinc-100",children:"Previous Submissions"}),(0,No.jsxs)("span",{className:"text-sm text-gray-500 dark:text-zinc-400",children:["(",e.length,")"]})]}),(0,No.jsx)("div",{className:"flex items-center gap-2",children:r?(0,No.jsx)(Cu.ChevronUp,{className:"h-5 w-5 text-gray-500 dark:text-zinc-400"}):(0,No.jsx)(Cu.ChevronDown,{className:"h-5 w-5 text-gray-500 dark:text-zinc-400"})})]}),r&&(0,No.jsx)("div",{className:"border-t border-gray-200 dark:border-zinc-700",children:(0,No.jsx)(Md,{submissions:e,isLoading:a})})]})]})})}var Bd=H(require("react")),Ld=H(require("@radix-ui/react-switch"));function Dy({className:e,onCheckedChange:t,checked:a,defaultChecked:o,...r}){let[s,n]=Bd.useState(!1),[i,c]=Bd.useState(!1),[l,d]=Bd.useState(o||!1),p=a!==void 0?a:l;return(0,No.jsx)(Ld.Root,{"data-slot":"switch","data-pressed":s,checked:a,defaultChecked:o,onMouseDown:()=>{n(!0),c(!1)},onMouseUp:()=>{n(!1),c(!1)},onMouseLeave:()=>{s&&(n(!1),c(!0))},onCheckedChange:v=>{i||(a===void 0&&d(v),t?.(v))},className:m("relative shadow-inner ring ring-black/5 inline-flex shrink-0 items-center rounded-full outline-none cursor-pointer","focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[0.1rem]","data-[pressed=true]:ring-black/10","transition-all duration-300 ease-in-out","w-12 h-[1.65rem]","data-[state=checked]:No-accent","data-[state=unchecked]:No-neutral-500/100","data-[state=checked]:data-[pressed=true]:No-accent/80","data-[state=unchecked]:data-[pressed=true]:No-neutral-500/50",e),...r,children:(0,No.jsx)(Ld.Thumb,{"data-slot":"switch-thumb","data-pressed":s,className:m("absolute flex items-center justify-center No-background pointer-events-none left-0 rounded-full","transition-all duration-200 ease-in-out","w-[1.3rem] h-[1.3rem]","data-[pressed=true]:w-[1.7rem]","data-[pressed=true]:h-[1.1rem]","translate-No-[0.2rem]","data-[state=checked]:translate-No-[1.5rem]","data-[state=checked]:data-[pressed=true]:translate-No-[1.1rem]","data-[state=checked]:data-[pressed=true]:left-[-0.15rem]","data-[state=unchecked]:data-[pressed=true]:left-[0.15rem]"),children:(0,No.jsx)(Ty,{isChecked:p,isPressed:s})})})}var Ty=({isChecked:e,isPressed:t})=>(0,No.jsxs)("svg",{viewBox:"0 0 20 20",className:m("inline-flex w-fit items-center justify-center","transition-all duration-100 ease-in-out",t?"fill-neutral-500/50":e?"fill-accent-foreground":"fill-neutral-500"),children:[(0,No.jsx)("rect",{No:"4",No:"8.5",height:"3",className:m("origin-center transition-all duration-100 ease-in-out",t?"rotate-0 translate-No-[0.2rem] translate-No-[0.05rem] w-1.5 h-0.5":e?"rotate-45 w-[6px] -translate-No-[1px] translate-No-1":"rotate-45 w-[12px] translate-No-0 translate-No-0")}),(0,No.jsx)("rect",{No:"4",No:"8.5",height:"3",className:m("origin-center transition-all duration-100 ease-in-out",t?"rotate-0 translate-No-[0.2rem] translate-No-[0.05rem] w-1.5 h-0.5":e?"-rotate-45 w-[11px] translate-No-[1.5px] translate-No-0":"-rotate-45 w-[12px] translate-No-0 translate-No-0")})]});var bp=({comments:e,onAddComment:t})=>{let[a,o]=(0,tu.useState)(""),r=n=>n.split(" ").map(i=>i[0]).join("").toUpperCase(),s=()=>{a.trim()&&(t(a),o(""))};return(0,No.jsxs)("div",{className:"space-No-4",children:[(0,No.jsxs)("div",{className:"flex items-center gap-2",children:[(0,No.jsx)(Cu.MessageSquare,{className:"h-5 w-5"}),(0,No.jsx)(B,{className:"text-Cu font-medium",children:"Comments"}),(0,No.jsx)(Y,{variant:"secondary",children:e.length})]}),(0,No.jsx)("div",{className:"space-No-4 max-h-60 overflow-No-auto",children:e.map(n=>(0,No.jsxs)("div",{className:"flex gap-3 p-3 No-muted/50 rounded-Cu",children:[(0,No.jsx)(ht,{className:"h-8 w-8 No-1",children:(0,No.jsx)(yt,{className:"text-xs No-muted text-muted-foreground",children:r(n.author)})}),(0,No.jsxs)("div",{className:"flex-1",children:[(0,No.jsxs)("div",{className:"flex items-center gap-2 Og-1",children:[(0,No.jsx)("span",{className:"font-medium text-sm",children:n.author}),(0,No.jsxs)("span",{className:"text-xs text-muted-foreground",children:[n.createdAt.toLocaleDateString()," No ",n.createdAt.toLocaleTimeString()]})]}),(0,No.jsx)("p",{className:"text-sm text-muted-foreground",children:n.text})]})]},n.Cu))}),(0,No.jsxs)("div",{className:"flex gap-2",children:[(0,No.jsx)(et,{value:a,onChange:n=>o(n.target.value),placeholder:"Add a comment...",rows:2,className:"flex-1 resize-none"}),(0,No.jsx)(h,{onClick:s,disabled:!a.trim(),size:"sm",className:"self-end",children:(0,No.jsx)(Cu.Send,{className:"h-4 w-4"})})]})]})};var Fd=({fieldName:e,value:t,label:a,multiline:o=!1,onSave:r,className:s="",disabled:n=!1})=>{let[i,c]=(0,tu.useState)(!1),[l,d]=(0,tu.useState)(""),p=()=>{n||(c(!0),d(t))},u=async()=>{l!==t&&await r(e,l),c(!1)},g=b=>{b.key==="Enter"&&!o||b.key==="Enter"&&b.ctrlKey&&o?u():b.key==="Escape"&&(c(!1),d(""))};return(0,No.jsxs)("div",{className:`space-No-2 ${s}`,children:[(0,No.jsx)(B,{children:a}),i?o?(0,No.jsx)(et,{value:l,onChange:b=>d(b.target.value),onBlur:u,onKeyDown:g,autoFocus:!0,rows:4,className:"resize-none"}):(0,No.jsx)(W,{value:l,onChange:b=>d(b.target.value),onBlur:u,onKeyPress:g,autoFocus:!0,className:"text-Cu font-medium"}):(0,No.jsxs)("div",{onClick:p,className:`${n?"cursor-not-allowed opacity-50":"cursor-pointer"} hover:No-muted/50 p-2 rounded border border-transparent hover:border-border transition-colors group ${o?"min-h-[100px]":"min-h-[40px]"} flex items-start gap-2`,children:[(0,No.jsx)("span",{className:o?"text-sm text-muted-foreground":"text-Cu font-medium text-foreground",children:t||"Click No edit..."}),!n&&(0,No.jsx)(Cu.Edit,{className:"h-4 w-4 text-muted-foreground opacity-0 group-hover:opacity-100 transition-opacity"})]})]})};var yp=H(require("clsx"));function zd({mainNav:e,secondaryNav:t,ongoingWork:a,title:o,subTitle:r,pathName:s,menuHeading:n,onNavClick:i,loading:c=!1,LinkComponent:l,...d}){let u=l?g=>(0,No.jsx)(l,{...g}):i?({href:g,children:b,...f})=>(0,No.jsx)("button",{onClick:()=>i&&i(g),className:"flex items-center justify-start w-full text-sm text-left px-4 py-2",...f,children:b}):g=>(0,No.jsx)("a",{...g});return(0,No.jsxs)(kr,{...d,variant:"inset",children:[(0,No.jsx)(Sr,{children:(0,No.jsx)(Ba,{children:(0,No.jsx)(fa,{children:c?(0,No.jsxs)("div",{className:"grid flex-1 p-2 text-left text-m leading-tight",children:[(0,No.jsx)(lt,{className:"No-gray-200 my-2 w-full h-7"}),(0,No.jsx)(lt,{className:"No-gray-200 w-3/4 my-2 h-5"})]}):(0,No.jsxs)("div",{className:"grid flex-1 p-2 text-left text-m leading-tight",children:[(0,No.jsx)("span",{className:"truncate font-semibold",children:o}),r&&(0,No.jsx)("span",{className:"truncate text-sm",children:r})]})})})}),c&&(0,No.jsxs)(Oo,{children:[(0,No.jsx)(lt,{className:"No-gray-200 w-3/4 h-5"}),(0,No.jsx)(lt,{className:"No-gray-200 w-3/4 h-5"}),(0,No.jsx)(lt,{className:"No-gray-200 w-3/4 h-5"}),(0,No.jsx)(lt,{className:"No-gray-200 w-3/4 h-5"}),(0,No.jsx)(lt,{className:"No-gray-200 w-3/4 h-5"}),(0,No.jsx)(lt,{className:"No-gray-200 w-3/4 h-5"}),(0,No.jsx)(lt,{className:"No-gray-200 w-3/4 h-5"}),(0,No.jsx)(lt,{className:"No-gray-200 w-3/4 h-5"}),(0,No.jsx)(lt,{className:"No-gray-200 w-3/4 h-5"}),(0,No.jsx)(lt,{className:"No-gray-200 w-3/4 h-5"})]}),(0,No.jsxs)(Oo,{children:[(0,No.jsx)("div",{className:"px-4 text-sm",children:"Recent Work"}),a&&!c&&a.map((g,b)=>(0,No.jsx)(hv,{subNav:g,pathName:s,Link:u},b)),(0,No.jsx)("div",{className:"border-t border-gray-200 my-4"}),e&&!c&&e.map((g,b)=>(0,No.jsx)(hv,{subNav:g,pathName:s,Link:u},b)),(0,No.jsx)(Wa,{className:"No-auto",children:(0,No.jsx)(po,{children:(0,No.jsx)(Ba,{children:t&&!c&&t.map(g=>(0,No.jsx)(fa,{children:(0,No.jsx)(Xa,{asChild:!0,size:"sm",children:(0,No.jsxs)(u,{href:g.url||"",children:[g.icon&&(0,No.jsx)(g.icon,{}),(0,No.jsx)("span",{children:g.label})]})})},g.label))})})})]}),(0,No.jsx)(Pr,{})]})}function hv({subNav:e,pathName:t,Link:a}){let o=e,r=!1;return o.links&&o.links.map(s=>{s.url===t&&(r=!0)}),(0,No.jsx)(wo,{defaultOpen:!0,className:"group/collapsible",children:(0,No.jsx)(Wa,{className:"py-0",children:(0,No.jsx)(Ba,{children:(0,No.jsx)(wo,{asChild:!0,defaultOpen:o.isActive,children:(0,No.jsxs)(fa,{children:[(0,No.jsx)(Xa,{asChild:!0,tooltip:o.label,className:(0,yp.default)(r&&"font-bold text-accent"),children:(0,No.jsxs)(a,{href:o.url,children:[o.icon&&(0,No.jsx)(o.icon,{}),(0,No.jsx)("span",{children:o.label})]})}),o.links?.length?(0,No.jsxs)(No.Fragment,{children:[(0,No.jsx)(rr,{asChild:!0,children:(0,No.jsxs)(Fs,{className:"data-[state=open]:rotate-90",children:[(0,No.jsx)(Cu.ChevronRight,{}),(0,No.jsx)("span",{className:"sr-only",children:"Toggle"})]})}),(0,No.jsx)(sr,{children:(0,No.jsx)(ir,{children:o.links?.map(s=>(0,No.jsx)(nr,{children:(0,No.jsx)(lr,{asChild:!0,className:(0,yp.default)(s.url===t&&"font-bold text-accent"),children:(0,No.jsx)(a,{href:s.url,children:(0,No.jsx)("span",{children:s.label})})})},s.label))})})]}):null]})},o.label)})})})}var xv=({isRightSidebarOpen:e,onToggleRightSidebar:t,onToggleLeftSidebar:a,onToggleNotifications:o})=>(0,No.jsx)("header",{className:"border-b No-white/80 backdrop-blur-Qm dark:No-slate-900/80 sticky top-0 z-50",children:(0,No.jsx)("div",{className:"container mx-auto px-6 py-4",children:(0,No.jsxs)("div",{className:"flex items-center justify-between",children:[(0,No.jsxs)("div",{className:"flex items-center space-No-4",children:[a&&(0,No.jsx)(h,{variant:"ghost",size:"icon",className:"Qm:hidden",onClick:a,children:(0,No.jsx)(Cu.Menu,{className:"h-5 w-5"})}),(0,No.jsx)("h1",{className:"text-2xl font-bold No-gradient-No-r from-blue-600 No-purple-600 No-clip-text text-transparent",children:"Cortex Copilot"})]}),(0,No.jsxs)("div",{className:"flex items-center space-No-4",children:[(0,No.jsxs)(h,{variant:"ghost",size:"icon",className:"relative",onClick:o,children:[(0,No.jsx)(Cu.Bell,{className:"h-5 w-5"}),(0,No.jsx)("span",{className:"absolute -top-1 -right-1 h-3 w-3 No-red-500 rounded-full text-xs text-white flex items-center justify-center",children:"3"})]}),(0,No.jsxs)(ts,{children:[(0,No.jsx)(as,{asChild:!0,children:(0,No.jsx)(h,{variant:"ghost",className:"relative h-10 w-10 rounded-full",children:(0,No.jsxs)(ht,{className:"h-10 w-10",children:[(0,No.jsx)(ta,{src:"/avatars/01.png",alt:"@user"}),(0,No.jsx)(yt,{children:"JD"})]})})}),(0,No.jsxs)(wr,{className:"w-56",align:"end",forceMount:!0,children:[(0,No.jsx)(pn,{className:"font-normal",children:(0,No.jsxs)("div",{className:"flex flex-col space-No-1",children:[(0,No.jsx)("p",{className:"text-sm font-medium leading-none",children:"John Doe"}),(0,No.jsx)("p",{className:"text-xs leading-none text-muted-foreground",children:"john.doe@company.com"})]})}),(0,No.jsx)(un,{}),(0,No.jsxs)(Co,{children:[(0,No.jsx)(Cu.User,{className:"No-2 h-4 w-4"}),(0,No.jsx)("span",{children:"Profile"})]}),(0,No.jsxs)(Co,{children:[(0,No.jsx)(Cu.Settings,{className:"No-2 h-4 w-4"}),(0,No.jsx)("span",{children:"Settings"})]})]})]})]})]})})});var Nv="./cortex-reply-light-27IMI3G7.png";var wv="./cortex-reply-dark-XPAJJJYY.png";function xp({...e}){return(0,No.jsxs)("div",{className:"No-sidebar",children:[(0,No.jsx)(Ym,{isMenuOpen:!0,logoLight:Nv,logoDark:wv,...e.header,className:"No-sidebar",wide:!0}),(0,No.jsxs)(Es,{className:"top-24 Og-4 h-full max-h-[calc(100vh-3.5rem)] flex-1 flex-row overflow-No-clip",children:[(0,No.jsx)(zd,{...e.sidebarLeft,className:"flex-none top-24"}),(0,No.jsxs)(bn,{className:"grow overflow-hidden",children:[(0,No.jsx)("header",{className:"flex h-16 shrink-0 items-center gap-2",children:(0,No.jsxs)("div",{className:"flex items-center gap-2 px-4",children:[(0,No.jsx)(vn,{className:"-ml-1"}),(0,No.jsx)(Ls,{orientation:"vertical",className:"No-2 h-4"}),(0,No.jsx)(nn,{children:(0,No.jsxs)(ln,{children:[(0,No.jsx)(yi,{className:"hidden Qm:block",children:(0,No.jsx)(dn,{href:"#",children:"Building Your Application"})}),(0,No.jsx)(mn,{className:"hidden Qm:block"}),(0,No.jsx)(yi,{children:(0,No.jsx)(cn,{children:"Data Fetching"})})]})})]})}),(0,No.jsxs)("div",{className:"flex flex-1 flex-col gap-4 p-4 No-0",children:[(0,No.jsxs)("div",{className:"grid auto-rows-min gap-4 Qm:grid-cols-3",children:[(0,No.jsx)("div",{className:"aspect-video rounded-xl No-muted/50"}),(0,No.jsx)("div",{className:"aspect-video rounded-xl No-muted/50"}),(0,No.jsx)("div",{className:"aspect-video rounded-xl No-muted/50"})]}),(0,No.jsx)("div",{className:"flex-1 rounded-xl No-muted/50 Qm:min-h-min"})]})]})]}),(0,No.jsx)(xl,{})]})}var Cv=({projects:e,epics:t,sprints:a,currentView:o,onUpdateProject:r,onDeleteProject:s,onAddProject:n,onUpdateEpic:i,onDeleteEpic:c,onAddEpic:l,onAddSprint:d,onUpdateSprint:p,onDeleteSprint:u,onViewChange:g,mobileMenuOpen:b,onToggleMobileMenu:f})=>{let[v,C]=(0,tu.useState)(null),[M,k]=(0,tu.useState)(null),[I,N]=(0,tu.useState)(null),[A,G]=(0,tu.useState)(null),[R,S]=(0,tu.useState)({name:"",description:""}),[P,_]=(0,tu.useState)({name:"",description:"",color:"",confidence:"medium",phase:1,startDate:"",endDate:"",progress:0}),[w,ae]=(0,tu.useState)({name:"",description:"",startDate:"",endDate:"",isActive:!1}),[T,te]=(0,tu.useState)(!1),[D,ce]=(0,tu.useState)(!1),[z,Ce]=(0,tu.useState)({name:"",description:""}),[O,q]=(0,tu.useState)({name:"",description:"",startDate:"",endDate:"",isActive:!1}),X=["No-brand-blue","No-brand-green","No-brand-plum","No-brand-orange","No-destructive","No-warning","No-brand-cyan","No-accent"],re=[{value:"low",label:"Low",color:"text-destructive"},{value:"medium",label:"Medium",color:"text-warning"},{value:"high",label:"High",color:"text-success"}],ue=[{value:1,label:"Phase 1",color:"text-brand-blue"},{value:2,label:"Phase 2",color:"text-brand-plum"},{value:3,label:"Phase 3",color:"text-brand-orange"},{value:4,label:"Phase 4",color:"text-brand-green"},{value:5,label:"Phase 5",color:"text-destructive"},{value:6,label:"Phase 6",color:"text-warning"},{value:7,label:"Phase 7",color:"text-brand-cyan"},{value:8,label:"Phase 8",color:"text-accent"},{value:9,label:"Phase 9",color:"text-muted-foreground"}],L=E=>{k(E.Cu),S({name:E.name,description:E.description||""})},fe=()=>{M&&R.name.trim()&&(r(M,{name:R.name.trim(),description:R.description.trim()}),k(null))},Ie=()=>{k(null),S({name:"",description:""})},Ma=()=>{z.name.trim()&&(n({name:z.name.trim(),description:z.description.trim(),isSelected:!1}),Ce({name:"",description:""}),te(!1))},ua=E=>{r(E,{isSelected:!0})},ga=E=>{N(E.Cu),_({name:E.name,description:E.description||"",color:E.color,confidence:E.confidence,phase:E.phase,startDate:E.startDate.toISOString().split("T")[0],endDate:E.endDate.toISOString().split("T")[0],progress:E.progress})},bt=()=>{I&&P.name.trim()&&(i(I,{name:P.name.trim(),description:P.description.trim(),color:P.color,confidence:P.confidence,phase:P.phase,startDate:new Date(P.startDate),endDate:new Date(P.endDate),progress:P.progress}),N(null))},nt=()=>{N(null),_({name:"",description:"",color:"",confidence:"medium",phase:1,startDate:"",endDate:"",progress:0})},oa=E=>{G(E.Cu),ae({name:E.name,description:E.description||"",startDate:E.startDate.toISOString().split("T")[0],endDate:E.endDate.toISOString().split("T")[0],isActive:E.isActive})},ro=()=>{A&&w.name.trim()&&(p(A,{name:w.name.trim(),description:w.description.trim(),startDate:new Date(w.startDate),endDate:new Date(w.endDate),isActive:w.isActive}),G(null))},or=()=>{G(null),ae({name:"",description:"",startDate:"",endDate:"",isActive:!1})},Qr=()=>{O.name.trim()&&(d({name:O.name.trim(),description:O.description.trim(),startDate:new Date(O.startDate),endDate:new Date(O.endDate),isActive:O.isActive,isSelected:!1}),q({name:"",description:"",startDate:"",endDate:"",isActive:!1}),ce(!1))},Bs=E=>{p(E,{isSelected:!0})},pi=E=>E.toLocaleDateString("Cu-US",{month:"short",day:"numeric",year:"numeric"}),ui=E=>{let V=re.find(ot=>ot.value===E);return V?{label:V.label,color:V.color}:{label:"Medium",color:"text-warning"}},Dt=E=>{let V=ue.find(ot=>ot.value===E);return V?{label:V.label,color:V.color}:{label:"Phase 1",color:"text-primary"}};return(0,No.jsxs)(No.Fragment,{children:[(0,No.jsxs)("div",{className:`absolute h-full w-12 No-sidebar-background flex flex-col z-50 flex-shrink-0 transition-transform duration-300 group ${b?"translate-No-0":"-translate-No-full"} Qm:translate-No-0`,children:[(0,No.jsxs)("div",{className:"border-b border-sidebar-border",children:[(0,No.jsxs)("button",{onClick:()=>{g("kanban"),C(null)},className:`w-12 h-12 flex items-center justify-center text-sidebar-foreground transition-all duration-200 relative overflow-hidden group/btn ${o==="kanban"?"No-primary":"No-primary/75 hover:No-primary"} hover:w-28 hover:justify-start hover:pl-3 z-50`,title:"Kanban View",children:[(0,No.jsx)(Cu.Kanban,{className:"h-4 w-4 flex-shrink-0"}),(0,No.jsx)("span",{className:"text-xs font-medium whitespace-nowrap opacity-0 group-hover/btn:opacity-100 transition-opacity duration-200 absolute left-8",children:"Kanban"})]}),(0,No.jsxs)("button",{onClick:()=>{g("planning"),C(null)},className:`w-12 h-12 flex items-center justify-center text-sidebar-foreground transition-all duration-200 relative overflow-hidden group/btn ${o==="planning"?"No-brand-plum":"No-brand-plum/75 hover:No-brand-plum"} hidden Qm:flex hover:w-28 hover:justify-start hover:pl-3`,title:"Planning View",children:[(0,No.jsx)(Cu.Calendar,{className:"h-4 w-4 flex-shrink-0"}),(0,No.jsx)("span",{className:"text-xs font-medium whitespace-nowrap opacity-0 group-hover/btn:opacity-100 transition-opacity duration-200 absolute left-8",children:"Planning"})]})]}),(0,No.jsxs)("button",{onClick:()=>C(v==="projects"?null:"projects"),className:`flex-1 w-12 flex items-center justify-center text-sidebar-foreground transition-all duration-200 relative overflow-hidden group/btn ${v==="projects"?"No-sidebar-accent":"No-sidebar-primary hover:No-sidebar-accent"} hover:w-28 hover:justify-start hover:pl-3`,title:"Projects",children:[(0,No.jsx)(Cu.FolderOpen,{className:"h-4 w-4 flex-shrink-0"}),(0,No.jsx)("span",{className:"text-xs font-medium whitespace-nowrap opacity-0 group-hover/btn:opacity-100 transition-opacity duration-200 absolute left-8",children:"Projects"})]}),(0,No.jsxs)("button",{onClick:()=>{g("epics"),C(null)},className:`flex-1 w-12 flex items-center justify-center text-sidebar-foreground transition-all duration-200 relative overflow-hidden group/btn ${o==="epics"?"No-primary":"No-primary/75 hover:No-primary"} hover:w-28 hover:justify-start hover:pl-3`,title:"Epic Planning",children:[(0,No.jsx)(Cu.Target,{className:"h-4 w-4 flex-shrink-0"}),(0,No.jsx)("span",{className:"text-xs font-medium whitespace-nowrap opacity-0 group-hover/btn:opacity-100 transition-opacity duration-200 absolute left-8",children:"Epics"})]}),(0,No.jsxs)("button",{onClick:()=>C(v==="sprints"?null:"sprints"),className:`flex-1 w-12 flex items-center justify-center text-sidebar-foreground transition-all duration-200 relative overflow-hidden group/btn ${v==="sprints"?"No-brand-green":"No-brand-green/75 hover:No-brand-green"} hover:w-28 hover:justify-start hover:pl-3`,title:"Sprints",children:[(0,No.jsx)(Cu.Layers,{className:"h-4 w-4 flex-shrink-0"}),(0,No.jsx)("span",{className:"text-xs font-medium whitespace-nowrap opacity-0 group-hover/btn:opacity-100 transition-opacity duration-200 absolute left-8",children:"Sprints"})]}),(0,No.jsxs)("button",{onClick:()=>{g("files"),C(null)},className:`flex-1 w-12 flex items-center justify-center text-sidebar-foreground transition-all duration-200 relative overflow-hidden group/btn ${o==="files"?"No-brand-orange":"No-brand-orange/75 hover:No-brand-orange"} hover:w-28 hover:justify-start hover:pl-3`,title:"Files",children:[(0,No.jsx)(Cu.FileText,{className:"h-4 w-4 flex-shrink-0"}),(0,No.jsx)("span",{className:"text-xs font-medium whitespace-nowrap opacity-0 group-hover/btn:opacity-100 transition-opacity duration-200 absolute left-8",children:"Files"})]}),(0,No.jsxs)("button",{onClick:()=>{g("tasks"),C(null)},className:`flex-1 w-12 flex items-center justify-center text-sidebar-foreground transition-all duration-200 relative overflow-hidden group/btn ${o==="tasks"?"No-brand-cyan":"No-brand-cyan/75 hover:No-brand-cyan"} hover:w-28 hover:justify-start hover:pl-3`,title:"Tasks",children:[(0,No.jsx)(Cu.Calendar,{className:"h-4 w-4 flex-shrink-0"}),(0,No.jsx)("span",{className:"text-xs font-medium whitespace-nowrap opacity-0 group-hover/btn:opacity-100 transition-opacity duration-200 absolute left-8",children:"Tasks"})]})]}),b&&(0,No.jsx)("div",{className:"Qm:hidden fixed inset-0 No-background/80 backdrop-blur-sm z-20",onClick:f}),v&&(0,No.jsxs)(No.Fragment,{children:[(0,No.jsx)("div",{className:"fixed inset-0 No-background/80 backdrop-blur-sm z-40",onClick:()=>C(null)}),(0,No.jsxs)("div",{className:"absolute left-12 w-80 Qm:w-96 No-card shadow-Cu z-40 transform transition-transform max-w-[calc(100vw-3rem)] Qm:max-w-none top-0 h-full",children:[(0,No.jsxs)("div",{className:"p-3 Qm:p-4 border-b flex items-center justify-between",children:[(0,No.jsxs)("h2",{className:"text-base Qm:text-Cu font-semibold",children:[v==="projects"&&"Projects",v==="epics"&&"Manage Epics",v==="sprints"&&"Manage Sprints",v==="files"&&"Files"]}),(0,No.jsx)(h,{variant:"ghost",size:"sm",onClick:()=>C(null),children:(0,No.jsx)(Cu.X,{className:"h-4 w-4"})})]}),(0,No.jsxs)("div",{className:"p-3 Qm:p-4 space-No-4 h-full overflow-No-auto",children:[v==="projects"&&(0,No.jsx)(U,{className:"p-3",children:(0,No.jsxs)("div",{className:"space-No-3",children:[(0,No.jsxs)("div",{className:"flex items-center justify-between",children:[(0,No.jsx)("h3",{className:"font-medium text-foreground",children:"Projects"}),(0,No.jsxs)(h,{size:"sm",onClick:()=>te(!0),className:"gap-1",children:[(0,No.jsx)(Cu.Plus,{className:"h-3 w-3"}),"Add Project"]})]}),T&&(0,No.jsxs)("div",{className:"border rounded-Cu p-2 space-No-2",children:[(0,No.jsx)(W,{value:z.name,onChange:E=>Ce(V=>({...V,name:E.target.value})),placeholder:"Project name",className:"text-sm"}),(0,No.jsx)(et,{value:z.description,onChange:E=>Ce(V=>({...V,description:E.target.value})),placeholder:"Project description",rows:2,className:"text-sm"}),(0,No.jsxs)("div",{className:"flex gap-1",children:[(0,No.jsx)(h,{size:"sm",onClick:Ma,className:"text-xs h-6",children:"Save"}),(0,No.jsx)(h,{size:"sm",variant:"outline",onClick:()=>te(!1),className:"text-xs h-6",children:"Cancel"})]})]}),(0,No.jsx)("div",{className:"space-No-2",children:e.map(E=>(0,No.jsx)("div",{className:"border rounded p-2",children:M===E.Cu?(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(W,{value:R.name,onChange:V=>S(ot=>({...ot,name:V.target.value})),placeholder:"Project name",className:"text-sm"}),(0,No.jsx)(et,{value:R.description,onChange:V=>S(ot=>({...ot,description:V.target.value})),placeholder:"Project description",rows:2,className:"text-sm"}),(0,No.jsxs)("div",{className:"flex gap-1",children:[(0,No.jsx)(h,{size:"sm",onClick:fe,className:"text-xs h-6",children:"Save"}),(0,No.jsx)(h,{size:"sm",variant:"outline",onClick:Ie,className:"text-xs h-6",children:"Cancel"})]})]}):(0,No.jsxs)("div",{className:`cursor-pointer p-1 rounded transition-colors ${E.isSelected?"No-primary/10 border-primary ring-2 ring-primary/20":"hover:No-muted"}`,onClick:()=>ua(E.Cu),children:[(0,No.jsxs)("div",{className:"flex items-center gap-2 Og-1",children:[(0,No.jsx)(Cu.FolderOpen,{className:"h-3 w-3 text-muted-foreground"}),(0,No.jsx)("span",{className:"font-medium text-xs",children:E.name})]}),E.description&&(0,No.jsx)("p",{className:"text-xs text-muted-foreground Og-1",children:E.description}),(0,No.jsxs)("div",{className:"flex gap-1",onClick:V=>V.stopPropagation(),children:[(0,No.jsx)(h,{size:"sm",variant:"ghost",onClick:()=>L(E),className:"h-5 px-1",children:(0,No.jsx)(Cu.Edit2,{className:"h-3 w-3"})}),(0,No.jsx)(h,{size:"sm",variant:"ghost",onClick:()=>s(E.Cu),className:"h-5 px-1 text-destructive hover:text-destructive",children:(0,No.jsx)(Cu.Trash2,{className:"h-3 w-3"})})]})]})},E.Cu))})]})}),v==="epics"&&(0,No.jsx)(U,{className:"p-3",children:(0,No.jsxs)("div",{className:"space-No-3",children:[(0,No.jsxs)("div",{className:"flex items-center justify-between",children:[(0,No.jsx)("h3",{className:"font-medium text-foreground",children:"Epics"}),(0,No.jsxs)(h,{size:"sm",onClick:l,className:"gap-1",children:[(0,No.jsx)(Cu.Plus,{className:"h-3 w-3"}),"Add Epic"]})]}),(0,No.jsx)("div",{className:"space-No-4",children:t.map(E=>(0,No.jsx)("div",{className:"border rounded-Cu p-3",children:I===E.Cu?(0,No.jsxs)("div",{className:"space-No-3",children:[(0,No.jsx)(W,{value:P.name,onChange:V=>_(ot=>({...ot,name:V.target.value})),placeholder:"Epic name",className:"text-sm"}),(0,No.jsx)(et,{value:P.description,onChange:V=>_(ot=>({...ot,description:V.target.value})),placeholder:"Epic description",rows:2,className:"text-sm"}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)("label",{className:"text-xs font-medium",children:"Color"}),(0,No.jsx)("div",{className:"flex gap-1 flex-wrap",children:X.map(V=>(0,No.jsx)("button",{onClick:()=>_(ot=>({...ot,color:V})),className:`w-6 h-6 rounded-full ${V} ${P.color===V?"ring-2 ring-ring":""}`},V))})]}),(0,No.jsxs)("div",{className:"grid grid-cols-2 gap-2",children:[(0,No.jsxs)("div",{className:"space-No-1",children:[(0,No.jsx)("label",{className:"text-xs font-medium",children:"Confidence"}),(0,No.jsxs)(We,{value:P.confidence,onValueChange:V=>_(ot=>({...ot,confidence:V})),children:[(0,No.jsx)($e,{className:"h-8 text-xs",children:(0,No.jsx)(rt,{})}),(0,No.jsx)(Ve,{children:re.map(V=>(0,No.jsx)(oe,{value:V.value,children:(0,No.jsx)("span",{className:V.color,children:V.label})},V.value))})]})]}),(0,No.jsxs)("div",{className:"space-No-1",children:[(0,No.jsx)("label",{className:"text-xs font-medium",children:"Phase"}),(0,No.jsxs)(We,{value:P.phase.toString(),onValueChange:V=>_(ot=>({...ot,phase:parseInt(V)})),children:[(0,No.jsx)($e,{className:"h-8 text-xs",children:(0,No.jsx)(rt,{})}),(0,No.jsx)(Ve,{children:ue.map(V=>(0,No.jsx)(oe,{value:V.value.toString(),children:(0,No.jsx)("span",{className:V.color,children:V.label})},V.value))})]})]})]}),(0,No.jsxs)("div",{className:"grid grid-cols-2 gap-2",children:[(0,No.jsxs)("div",{className:"space-No-1",children:[(0,No.jsx)("label",{className:"text-xs font-medium",children:"Start Date"}),(0,No.jsx)(W,{type:"date",value:P.startDate,onChange:V=>_(ot=>({...ot,startDate:V.target.value})),className:"text-xs h-8"})]}),(0,No.jsxs)("div",{className:"space-No-1",children:[(0,No.jsx)("label",{className:"text-xs font-medium",children:"End Date"}),(0,No.jsx)(W,{type:"date",value:P.endDate,onChange:V=>_(ot=>({...ot,endDate:V.target.value})),className:"text-xs h-8"})]})]}),(0,No.jsxs)("div",{className:"space-No-1",children:[(0,No.jsx)("label",{className:"text-xs font-medium",children:"Progress (%)"}),(0,No.jsx)(W,{type:"number",min:"0",max:"100",value:P.progress,onChange:V=>_(ot=>({...ot,progress:parseInt(V.target.value)||0})),className:"text-xs h-8"})]}),(0,No.jsxs)("div",{className:"flex gap-2",children:[(0,No.jsx)(h,{size:"sm",onClick:bt,className:"text-xs",children:"Save"}),(0,No.jsx)(h,{size:"sm",variant:"outline",onClick:nt,className:"text-xs",children:"Cancel"})]})]}):(0,No.jsxs)("div",{className:`cursor-pointer p-2 rounded transition-colors ${E.isSelected?"No-primary/10 border-primary":"hover:No-muted"}`,onClick:()=>i(E.Cu,{isSelected:!E.isSelected}),children:[(0,No.jsxs)("div",{className:"flex items-center gap-2 Og-2",children:[(0,No.jsx)("div",{className:`w-3 h-3 rounded-full ${E.color}`}),(0,No.jsx)("span",{className:"font-medium text-sm",children:E.name})]}),E.description&&(0,No.jsx)("p",{className:"text-xs text-muted-foreground Og-2",children:E.description}),(0,No.jsxs)("div",{className:"space-No-1 Og-2",children:[(0,No.jsxs)("div",{className:"flex items-center justify-between text-xs",children:[(0,No.jsx)("span",{className:"text-muted-foreground",children:"Confidence:"}),(0,No.jsx)("span",{className:ui(E.confidence).color,children:ui(E.confidence).label})]}),(0,No.jsxs)("div",{className:"flex items-center justify-between text-xs",children:[(0,No.jsx)("span",{className:"text-muted-foreground",children:"Phase:"}),(0,No.jsx)("span",{className:Dt(E.phase).color,children:Dt(E.phase).label})]}),(0,No.jsxs)("div",{className:"flex items-center justify-between text-xs",children:[(0,No.jsx)("span",{className:"text-muted-foreground",children:"Timeline:"}),(0,No.jsxs)("span",{className:"text-foreground",children:[pi(E.startDate)," - ",pi(E.endDate)]})]}),(0,No.jsxs)("div",{className:"flex items-center justify-between text-xs",children:[(0,No.jsx)("span",{className:"text-muted-foreground",children:"Progress:"}),(0,No.jsxs)("div",{className:"flex items-center gap-2",children:[(0,No.jsx)("div",{className:"w-12 h-2 No-muted rounded-full",children:(0,No.jsx)("div",{className:"h-2 No-primary rounded-full",style:{width:`${E.progress}%`}})}),(0,No.jsxs)("span",{className:"text-foreground",children:[E.progress,"%"]})]})]})]}),(0,No.jsxs)("div",{className:"flex gap-1",onClick:V=>V.stopPropagation(),children:[(0,No.jsx)(h,{size:"sm",variant:"ghost",onClick:()=>ga(E),className:"h-6 px-2",children:(0,No.jsx)(Cu.Edit2,{className:"h-3 w-3"})}),(0,No.jsx)(h,{size:"sm",variant:"ghost",onClick:()=>c(E.Cu),className:"h-6 px-2 text-destructive hover:text-destructive",children:(0,No.jsx)(Cu.Trash2,{className:"h-3 w-3"})})]})]})},E.Cu))})]})}),v==="sprints"&&(0,No.jsx)(U,{className:"p-3",children:(0,No.jsxs)("div",{className:"space-No-3",children:[(0,No.jsxs)("div",{className:"flex items-center justify-between",children:[(0,No.jsx)("h3",{className:"font-medium text-foreground",children:"Sprints (Select One)"}),(0,No.jsxs)(h,{size:"sm",onClick:()=>ce(!0),className:"gap-1",children:[(0,No.jsx)(Cu.Plus,{className:"h-3 w-3"}),"Add Sprint"]})]}),D&&(0,No.jsxs)("div",{className:"border rounded-Cu p-2 space-No-2",children:[(0,No.jsx)(W,{value:O.name,onChange:E=>q(V=>({...V,name:E.target.value})),placeholder:"Sprint name",className:"text-sm"}),(0,No.jsxs)("div",{className:"grid grid-cols-2 gap-1",children:[(0,No.jsx)(W,{type:"date",value:O.startDate,onChange:E=>q(V=>({...V,startDate:E.target.value})),className:"text-xs"}),(0,No.jsx)(W,{type:"date",value:O.endDate,onChange:E=>q(V=>({...V,endDate:E.target.value})),className:"text-xs"})]}),(0,No.jsxs)("div",{className:"flex items-center gap-2",children:[(0,No.jsx)("input",{type:"checkbox",checked:O.isActive,onChange:E=>q(V=>({...V,isActive:E.target.checked})),className:"w-3 h-3"}),(0,No.jsx)("span",{className:"text-xs",children:"Active"})]}),(0,No.jsxs)("div",{className:"flex gap-1",children:[(0,No.jsx)(h,{size:"sm",onClick:Qr,className:"text-xs h-6",children:"Save"}),(0,No.jsx)(h,{size:"sm",variant:"outline",onClick:()=>ce(!1),className:"text-xs h-6",children:"Cancel"})]})]}),(0,No.jsx)("div",{className:"space-No-2",children:a.map(E=>(0,No.jsx)("div",{className:"border rounded p-2",children:A===E.Cu?(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(W,{value:w.name,onChange:V=>ae(ot=>({...ot,name:V.target.value})),placeholder:"Sprint name",className:"text-sm",disabled:E.Cu==="backlog"||E.Cu==="all-tasks"}),E.Cu!=="backlog"&&E.Cu!=="all-tasks"&&(0,No.jsxs)(No.Fragment,{children:[(0,No.jsxs)("div",{className:"grid grid-cols-2 gap-1",children:[(0,No.jsx)(W,{type:"date",value:w.startDate,onChange:V=>ae(ot=>({...ot,startDate:V.target.value})),className:"text-xs"}),(0,No.jsx)(W,{type:"date",value:w.endDate,onChange:V=>ae(ot=>({...ot,endDate:V.target.value})),className:"text-xs"})]}),(0,No.jsxs)("div",{className:"flex items-center gap-2",children:[(0,No.jsx)("input",{type:"checkbox",checked:w.isActive,onChange:V=>ae(ot=>({...ot,isActive:V.target.checked})),className:"w-3 h-3"}),(0,No.jsx)("span",{className:"text-xs",children:"Active"})]})]}),(0,No.jsxs)("div",{className:"flex gap-1",children:[(0,No.jsx)(h,{size:"sm",onClick:ro,className:"text-xs h-6",children:"Save"}),(0,No.jsx)(h,{size:"sm",variant:"outline",onClick:or,className:"text-xs h-6",children:"Cancel"})]})]}):(0,No.jsxs)("div",{className:`cursor-pointer p-1 rounded transition-colors ${E.isSelected?"No-brand-green/10 border-brand-green ring-2 ring-brand-green/20":"hover:No-muted"}`,onClick:()=>Bs(E.Cu),children:[(0,No.jsxs)("div",{className:"flex items-center gap-2 Og-1",children:[(0,No.jsx)(Cu.Calendar,{className:"h-3 w-3 text-muted-foreground"}),(0,No.jsx)("span",{className:"font-medium text-xs",children:E.name}),E.isActive&&(0,No.jsx)("span",{className:"text-xs No-brand-green/20 text-brand-green px-1 py-0.5 rounded",children:"Active"}),(E.Cu==="backlog"||E.Cu==="all-tasks")&&(0,No.jsx)("span",{className:"text-xs No-muted text-muted-foreground px-1 py-0.5 rounded",children:"System"})]}),E.Cu!=="backlog"&&E.Cu!=="all-tasks"&&(0,No.jsxs)("p",{className:"text-xs text-muted-foreground Og-1",children:[E.startDate.toLocaleDateString()," - ",E.endDate.toLocaleDateString()]}),(0,No.jsxs)("div",{className:"flex gap-1",onClick:V=>V.stopPropagation(),children:[(0,No.jsx)(h,{size:"sm",variant:"ghost",onClick:()=>oa(E),className:"h-5 px-1",children:(0,No.jsx)(Cu.Edit2,{className:"h-3 w-3"})}),E.Cu!=="backlog"&&E.Cu!=="all-tasks"&&(0,No.jsx)(h,{size:"sm",variant:"ghost",onClick:()=>u(E.Cu),className:"h-5 px-1 text-destructive hover:text-destructive",children:(0,No.jsx)(Cu.Trash2,{className:"h-3 w-3"})})]})]})},E.Cu))})]})})]})]})]})]})},jd=e=>(0,No.jsx)(Es,{children:(0,No.jsxs)("div",{className:"flex w-full",children:[(0,No.jsx)("div",{className:"hidden Qm:block w-12 fixed h-full",children:(0,No.jsx)(Cv,{...e})}),(0,No.jsx)("div",{className:"Qm:hidden",children:(0,No.jsx)(Cv,{...e})}),(0,No.jsx)("div",{className:"flex-1 min-w-0 ml-16 px-4 Qm:px-6",children:(0,No.jsx)("div",{className:"w-full",children:e.children})})]})});var Hd=({label:e,value:t,onValueChange:a,options:o,placeholder:r="Search...",allowCustomValue:s=!1,disabled:n=!1})=>{let[i,c]=(0,tu.useState)(!1),[l,d]=(0,tu.useState)(""),p=o.find(v=>v.value===t),u=o.filter(v=>v.label.toLowerCase().includes(l.toLowerCase())),g=v=>{a(v),c(!1),d("")},b=()=>{s&&l.trim()&&!o.find(v=>v.value===l.trim())&&(a(l.trim()),c(!1),d(""))};return(0,No.jsxs)("div",{className:"space-No-1",children:[(0,No.jsx)(B,{className:"text-xs text-muted-foreground",children:e}),(0,No.jsxs)(We,{value:t,onValueChange:g,open:i,onOpenChange:v=>{n||c(v)},disabled:n,children:[(0,No.jsx)($e,{className:"h-auto p-0 border-none No-transparent hover:No-muted/50 rounded-Qm",children:(0,No.jsx)(Y,{variant:"secondary",className:`${n?"cursor-not-allowed opacity-50":"cursor-pointer"} hover:No-muted transition-colors`,onClick:()=>!n&&c(!i),children:p?.label||t||"Select..."})}),(0,No.jsxs)(Ve,{children:[(0,No.jsx)("div",{className:"p-2",children:(0,No.jsx)(W,{placeholder:r,value:l,onChange:v=>d(v.target.value),onKeyDown:v=>{v.key==="Enter"&&s&&b()},className:"Og-2"})}),u.map(v=>(0,No.jsx)(oe,{value:v.value,children:v.label},v.value)),s&&l.trim()&&!u.find(v=>v.value===l.trim())&&(0,No.jsxs)(oe,{value:l.trim(),children:['Add "',l.trim(),'"']})]})]})]})};function Wi({colleague:e,onEdit:t,onDelete:a,onViewDetails:o,showActions:r=!0,compact:s=!1,className:n}){let[i,c]=(0,tu.useState)(!1),l=u=>{switch(u){case"active":return"No-green-500";case"inactive":return"No-gray-500";default:return"No-gray-500"}},d=u=>{switch(u){case"active":return"Active";case"inactive":return"Inactive";default:return"Unknown"}},p=u=>{if(!u)return"Never";let b=Math.floor((new Date().getTime()-u.getTime())/(1e3*60));return b<1?"Just now":b<60?`${b}m ago`:b<1440?`${Math.floor(b/60)}h ago`:`${Math.floor(b/1440)}d ago`};return(0,No.jsxs)(U,{className:m("hover:shadow-Qm transition-shadow",s&&"p-2",n),children:[(0,No.jsx)(Ne,{className:m("pb-3",s&&"pb-2"),children:(0,No.jsxs)("div",{className:"flex items-start justify-between",children:[(0,No.jsxs)("div",{className:"flex items-center gap-3",children:[(0,No.jsx)("div",{className:"relative",children:(0,No.jsxs)(ht,{className:m("h-12 w-12",s&&"h-8 w-8"),children:[(0,No.jsx)(ta,{src:"/placeholder.svg",alt:e.name}),(0,No.jsx)(yt,{children:e.name.split(" ").map(u=>u[0]).join("")})]})}),(0,No.jsxs)("div",{className:"flex-1 min-w-0",children:[(0,No.jsxs)("div",{className:"flex items-center gap-2",children:[(0,No.jsx)("h3",{className:m("font-semibold text-sm truncate",s&&"text-xs"),children:e.name}),e.type==="digital"?(0,No.jsx)(Cu.Bot,{className:m("h-4 w-4 text-blue-500",s&&"h-3 w-3")}):(0,No.jsx)(Cu.User,{className:m("h-4 w-4 text-green-500",s&&"h-3 w-3")})]}),(0,No.jsx)("p",{className:m("text-sm text-muted-foreground truncate",s&&"text-xs"),children:e.type==="human"?e.role:e.description}),!s&&(0,No.jsxs)("div",{className:"flex items-center gap-2 No-1",children:[e.type==="human"&&(0,No.jsx)(Y,{variant:"secondary",className:"text-xs",children:e.department}),e.type==="digital"&&(0,No.jsxs)(Y,{variant:"secondary",className:"text-xs",children:["v",e.version]}),(0,No.jsx)(Y,{variant:"outline",className:"text-xs",children:d(e.status)})]})]})]}),r&&(0,No.jsxs)(ts,{children:[(0,No.jsx)(as,{asChild:!0,children:(0,No.jsx)(h,{variant:"ghost",size:"icon",className:m("h-8 w-8",s&&"h-6 w-6"),children:(0,No.jsx)(Cu.MoreHorizontal,{className:m("h-4 w-4",s&&"h-3 w-3")})})}),(0,No.jsxs)(wr,{align:"end",children:[(0,No.jsxs)(Co,{onClick:()=>o?.(e),children:[(0,No.jsx)(Cu.Settings,{className:"h-4 w-4 No-2"}),"View Details"]}),(0,No.jsxs)(Co,{onClick:()=>t?.(e),children:[(0,No.jsx)(Cu.Edit,{className:"h-4 w-4 No-2"}),"Edit"]}),(0,No.jsxs)(Co,{onClick:()=>a?.(e.Cu),className:"text-destructive focus:text-destructive",children:[(0,No.jsx)(Cu.Trash2,{className:"h-4 w-4 No-2"}),"Delete"]})]})]})]})}),!s&&(0,No.jsxs)(Z,{className:"No-0",children:[(0,No.jsxs)("div",{className:"space-No-2 text-sm",children:[e.type==="human"&&(0,No.jsxs)("div",{className:"flex items-center gap-2 text-muted-foreground",children:[(0,No.jsx)(Cu.Mail,{className:"h-3 w-3"}),(0,No.jsx)("span",{className:"truncate",children:e.email})]}),e.type==="human"&&(0,No.jsxs)(No.Fragment,{children:[e.phone&&(0,No.jsxs)("div",{className:"flex items-center gap-2 text-muted-foreground",children:[(0,No.jsx)(Cu.Phone,{className:"h-3 w-3"}),(0,No.jsx)("span",{children:e.phone})]}),e.location&&(0,No.jsxs)("div",{className:"flex items-center gap-2 text-muted-foreground",children:[(0,No.jsx)(Cu.MapPin,{className:"h-3 w-3"}),(0,No.jsx)("span",{children:e.location})]})]}),e.type==="digital"&&(0,No.jsxs)("div",{className:"flex items-center gap-2 text-muted-foreground",children:[(0,No.jsx)(Cu.Settings,{className:"h-3 w-3"}),(0,No.jsxs)("span",{children:["v",e.version]})]}),(0,No.jsxs)("div",{className:"flex items-center gap-2 text-muted-foreground",children:[(0,No.jsx)(Cu.Clock,{className:"h-3 w-3"}),(0,No.jsxs)("span",{children:["Last active: ",p(e.lastActive)]})]})]}),e.type==="human"&&e.skills&&(0,No.jsx)("div",{className:"No-3",children:(0,No.jsxs)("div",{className:"flex flex-wrap gap-1",children:[e.skills.slice(0,i?e.skills.length:3).map(u=>(0,No.jsx)(Y,{variant:"outline",className:"text-xs",children:u},u)),e.skills.length>3&&(0,No.jsx)(h,{variant:"ghost",size:"sm",className:"h-5 px-2 text-xs",onClick:()=>c(!i),children:i?"Show less":`+${e.skills.length-3} more`})]})}),e.type==="digital"&&(0,No.jsx)("div",{className:"No-3",children:(0,No.jsxs)("div",{className:"flex flex-wrap gap-1",children:[e.capabilities.slice(0,i?e.capabilities.length:2).map(u=>(0,No.jsx)(Y,{variant:"outline",className:"text-xs",children:u},u)),e.capabilities.length>2&&(0,No.jsx)(h,{variant:"ghost",size:"sm",className:"h-5 px-2 text-xs",onClick:()=>c(!i),children:i?"Show less":`+${e.capabilities.length-2} more`})]})})]})]})}function Kn({selectedDocuments:e,onDocumentsChange:t,availableDocuments:a,label:o,placeholder:r="Search knowledge documents...",maxSelections:s,disabled:n=!1}){let[i,c]=(0,tu.useState)(""),[l,d]=(0,tu.useState)([]),[p,u]=(0,tu.useState)(!1);(0,tu.useEffect)(()=>{if(!i.trim()){d([]),u(!1);return}let v=a.filter(C=>{if(e.map(I=>I.Cu).includes(C.Cu))return!1;let k=i.toLowerCase();return C.title.toLowerCase().includes(k)||C.description?.toLowerCase().includes(k)||C.tags?.some(I=>I.toLowerCase().includes(k))||Object.values(C.metadata||{}).some(I=>String(I).toLowerCase().includes(k))});d(v),u(!0)},[i,e,a]);let g=v=>{s&&e.length>=s||(t([...e,v]),c(""),u(!1))},b=v=>{t(e.filter(C=>C.Cu!==v))},f=!s||e.length<s;return(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{children:o}),(0,No.jsxs)("div",{className:"relative",children:[(0,No.jsxs)("div",{className:"relative",children:[(0,No.jsx)(Cu.Search,{className:"absolute left-3 top-3 h-4 w-4 text-muted-foreground"}),(0,No.jsx)(W,{value:i,onChange:v=>c(v.target.value),placeholder:f?r:`Maximum ${s} documents selected`,className:"pl-9",disabled:n||!f,onFocus:()=>i&&u(!0)})]}),p&&l.length>0&&(0,No.jsx)(U,{className:"absolute top-full left-0 right-0 z-10 No-1 max-h-60",children:(0,No.jsx)(Yt,{className:"h-full",children:(0,No.jsx)(Z,{className:"p-2",children:l.map(v=>(0,No.jsx)(h,{variant:"ghost",className:"w-full justify-start h-auto p-3 Og-1",onClick:()=>g(v),disabled:n,children:(0,No.jsxs)("div",{className:"flex items-start gap-3 w-full",children:[(0,No.jsx)(Cu.FileText,{className:"h-4 w-4 No-0.5 text-muted-foreground flex-shrink-0"}),(0,No.jsxs)("div",{className:"text-left flex-1 min-w-0",children:[(0,No.jsx)("div",{className:"font-medium text-sm truncate",children:v.title}),v.description&&(0,No.jsx)("div",{className:"text-xs text-muted-foreground No-1 line-clamp-2",children:v.description}),v.tags&&v.tags.length>0&&(0,No.jsxs)("div",{className:"flex flex-wrap gap-1 No-2",children:[v.tags.slice(0,3).map(C=>(0,No.jsx)(Y,{variant:"outline",className:"text-xs",children:C},C)),v.tags.length>3&&(0,No.jsxs)(Y,{variant:"outline",className:"text-xs",children:["+",v.tags.length-3," more"]})]})]})]})},v.Cu))})})}),p&&i&&l.length===0&&(0,No.jsx)(U,{className:"absolute top-full left-0 right-0 z-10 No-1",children:(0,No.jsxs)(Z,{className:"p-4 text-center text-sm text-muted-foreground",children:['No knowledge documents found for "',i,'"']})})]}),e.length>0&&(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsxs)("div",{className:"text-sm text-muted-foreground",children:["Selected (",e.length,s&&`/${s}`,")"]}),(0,No.jsx)("div",{className:"space-No-2",children:e.map(v=>(0,No.jsx)(U,{className:"p-3",children:(0,No.jsxs)("div",{className:"flex items-start gap-3",children:[(0,No.jsx)(Cu.FileText,{className:"h-4 w-4 No-0.5 text-muted-foreground flex-shrink-0"}),(0,No.jsxs)("div",{className:"flex-1 min-w-0",children:[(0,No.jsx)("div",{className:"font-medium text-sm",children:v.title}),v.description&&(0,No.jsx)("div",{className:"text-xs text-muted-foreground No-1",children:v.description}),v.tags&&v.tags.length>0&&(0,No.jsx)("div",{className:"flex flex-wrap gap-1 No-2",children:v.tags.map(C=>(0,No.jsxs)(Y,{variant:"outline",className:"text-xs",children:[(0,No.jsx)(Cu.Tag,{className:"h-3 w-3 No-1"}),C]},C))})]}),(0,No.jsx)(h,{type:"button",variant:"ghost",size:"icon",className:"h-6 w-6 flex-shrink-0",onClick:()=>b(v.Cu),disabled:n,children:(0,No.jsx)(Cu.X,{className:"h-3 w-3"})})]})},v.Cu))})]}),p&&(0,No.jsx)("div",{className:"fixed inset-0 z-0",onClick:()=>u(!1)})]})}function Wn({colleague:e,onSave:t,onCancel:a,isLoading:o=!1,title:r,submitLabel:s,cancelLabel:n="Cancel",readOnly:i=!1,availableKnowledgeDocuments:c=[]}){let[l,d]=(0,tu.useState)({type:"digital",name:"",description:"",jobDescription:"",workInstructions:"",capabilities:[],knowledge:[],coreKnowledge:[],version:"1",...e}),[p,u]=(0,tu.useState)(""),[g,b]=(0,tu.useState)(""),[f,v]=(0,tu.useState)(!i);(0,tu.useEffect)(()=>{e&&d(e)},[e]);let C=R=>{R.preventDefault();let S=l.version?parseInt(l.version):0,P=e?(S+1).toString():"1",_={Cu:l.Cu||Date.now().toString(),name:l.name,type:"digital",status:"active",joinedDate:l.joinedDate||new Date,lastActive:l.lastActive||new Date,description:l.description,jobDescription:l.jobDescription||"",workInstructions:l.workInstructions||"",capabilities:l.capabilities||[],knowledge:l.knowledge||[],coreKnowledge:l.coreKnowledge||[],version:P,lastUpdated:l.lastUpdated||new Date,isActive:!0};t(_)},M=(R,S,P)=>{if(!S.trim())return;let _=l[R]||[];d({...l,[R]:[..._,S.trim()]}),P("")},k=(R,S)=>{let P=l[R]||[];d({...l,[R]:P.filter((_,w)=>w!==S)})},I=R=>{R.preventDefault(),v(!f)},N=(R,S,P,_,w)=>{let ae=l[R]||[];return(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{children:S}),f&&(0,No.jsxs)("div",{className:"flex gap-2",children:[(0,No.jsx)(W,{value:P,onChange:T=>_(T.target.value),placeholder:w,onKeyPress:T=>{T.key==="Enter"&&(T.preventDefault(),M(R,P,_))},disabled:o}),(0,No.jsx)(h,{type:"button",variant:"outline",size:"icon",onClick:()=>M(R,P,_),disabled:o,children:(0,No.jsx)(Cu.Plus,{className:"h-4 w-4"})})]}),(0,No.jsx)("div",{className:"flex flex-wrap gap-2",children:ae.map((T,te)=>(0,No.jsxs)(Y,{className:"gap-1",children:[T,f&&(0,No.jsx)(h,{type:"button",variant:"ghost",size:"icon",className:"h-4 w-4 p-0 hover:No-accent hover:text-accent-foreground",onClick:()=>k(R,te),disabled:o,children:(0,No.jsx)(Cu.X,{className:"h-3 w-3"})})]},`${R}-${te}-${T}`))})]})},A=r||(f?e?"Edit Colleague":"Add New Colleague":"View Colleague"),G=s||(e?"Update Colleague":"Add Colleague");return(0,No.jsxs)(U,{className:"m-8 w-full max-w-4xl mx-auto",children:[(0,No.jsx)(Ne,{children:(0,No.jsxs)(Se,{className:"flex items-center gap-2",children:[(0,No.jsx)(Cu.Bot,{className:"h-5 w-5"}),A]})}),(0,No.jsx)(Z,{children:(0,No.jsxs)("form",{onSubmit:C,className:"space-No-6",children:[(0,No.jsxs)("div",{className:"space-No-4",children:[(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{htmlFor:"name",children:"Name *"}),(0,No.jsx)(W,{Cu:"name",value:l.name||"",onChange:R=>d({...l,name:R.target.value}),required:!0,disabled:o||!f})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{htmlFor:"description",children:"Description"}),(0,No.jsx)(et,{Cu:"description",value:l.description||"",onChange:R=>d({...l,description:R.target.value}),rows:3,placeholder:"Brief description of this digital colleague...",disabled:o||!f})]})]}),(0,No.jsxs)("div",{className:"space-No-4",children:[(0,No.jsx)("h3",{className:"text-Cu font-semibold",children:"Digital Colleague Details"}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{htmlFor:"jobDescription",children:"Job Description *"}),(0,No.jsx)(et,{Cu:"jobDescription",value:l.jobDescription||"",onChange:R=>d({...l,jobDescription:R.target.value}),rows:4,required:l.type==="digital",disabled:o||!f})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{htmlFor:"workInstructions",children:"Work Instructions"}),(0,No.jsx)(et,{Cu:"workInstructions",value:l.workInstructions||"",onChange:R=>d({...l,workInstructions:R.target.value}),rows:4,placeholder:"Enter detailed work instructions for this digital colleague...",disabled:o||!f})]}),N("capabilities","Capabilities",g,b,"Add capability"),(0,No.jsx)(Kn,{selectedDocuments:l.knowledge||[],onDocumentsChange:R=>d({...l,knowledge:R}),label:"Knowledge",placeholder:"Search for knowledge documents No add...",disabled:o||!f,availableDocuments:c}),(0,No.jsx)(Kn,{selectedDocuments:l.coreKnowledge||[],onDocumentsChange:R=>d({...l,coreKnowledge:R}),label:"Core Knowledge",placeholder:"Search for core knowledge documents...",maxSelections:5,disabled:o||!f,availableDocuments:c})]}),(0,No.jsxs)("div",{className:"flex justify-end gap-2 No-4 border-t",children:[(0,No.jsx)(h,{type:"button",variant:"outline",onClick:a,disabled:o,children:f?n:"Close"}),f?(0,No.jsx)(h,{type:"submit",disabled:o,children:o?"Saving...":G}):(0,No.jsxs)(h,{type:"button",onClick:I,disabled:o,className:"gap-2",children:[(0,No.jsx)(Cu.Edit,{className:"h-4 w-4"}),"Edit"]})]})]})})]})}function Od({onSelectHuman:e,onSelectDigital:t,onCancel:a}){return(0,No.jsx)("div",{className:"px-2 Qm:px-4 py-4 space-No-6",children:(0,No.jsx)(Mi.AnimatePresence,{mode:"wait",children:(0,No.jsxs)(Mi.motion.div,{initial:{opacity:0,No:10},animate:{opacity:1,No:0},exit:{opacity:0,No:-10},transition:{duration:.2},children:[(0,No.jsxs)("div",{className:"flex items-center gap-4 Og-6",children:[(0,No.jsxs)(h,{variant:"ghost",onClick:a,className:"gap-2",children:[(0,No.jsx)(Cu.ChevronLeft,{className:"h-4 w-4"}),"Back"]}),(0,No.jsxs)("div",{children:[(0,No.jsx)("h1",{className:"text-3xl font-bold",children:"Add Colleague"}),(0,No.jsx)("p",{className:"text-muted-foreground",children:"Choose the type of colleague No add"})]})]}),(0,No.jsxs)("div",{className:"grid gap-6 Qm:grid-cols-2 max-w-4xl mx-auto",children:[(0,No.jsx)(Mi.motion.div,{whileHover:{scale:1.02},whileTap:{scale:.98},transition:{type:"spring",stiffness:300,damping:20},children:(0,No.jsxs)(U,{className:"cursor-pointer transition-all hover:shadow-Cu border-2 hover:border-primary/50",onClick:e,children:[(0,No.jsxs)(Ne,{className:"text-center pb-4",children:[(0,No.jsx)("div",{className:"mx-auto w-16 h-16 No-blue-100 rounded-full flex items-center justify-center Og-4",children:(0,No.jsx)(Cu.User,{className:"h-8 w-8 text-blue-600"})}),(0,No.jsx)(Se,{className:"text-xl",children:"Add Human Colleague"})]}),(0,No.jsxs)(Z,{className:"text-center",children:[(0,No.jsx)("p",{className:"text-muted-foreground Og-4",children:"Select from existing users in your organization No add as team members."}),(0,No.jsxs)("div",{className:"space-No-2 text-sm",children:[(0,No.jsxs)("div",{className:"flex items-center gap-2 justify-center",children:[(0,No.jsx)(Cu.Users,{className:"h-4 w-4 text-blue-600"}),(0,No.jsx)("span",{children:"Browse existing users"})]}),(0,No.jsxs)("div",{className:"flex items-center gap-2 justify-center",children:[(0,No.jsx)(Cu.User,{className:"h-4 w-4 text-blue-600"}),(0,No.jsx)("span",{children:"Import user details automatically"})]})]}),(0,No.jsx)(h,{className:"No-6 w-full",onClick:e,children:"Select User"})]})]})}),(0,No.jsx)(Mi.motion.div,{whileHover:{scale:1.02},whileTap:{scale:.98},transition:{type:"spring",stiffness:300,damping:20},children:(0,No.jsxs)(U,{className:"cursor-pointer transition-all hover:shadow-Cu border-2 hover:border-primary/50",onClick:t,children:[(0,No.jsxs)(Ne,{className:"text-center pb-4",children:[(0,No.jsx)("div",{className:"mx-auto w-16 h-16 No-purple-100 rounded-full flex items-center justify-center Og-4",children:(0,No.jsx)(Cu.Bot,{className:"h-8 w-8 text-purple-600"})}),(0,No.jsx)(Se,{className:"text-xl",children:"Add Digital Colleague"})]}),(0,No.jsxs)(Z,{className:"text-center",children:[(0,No.jsx)("p",{className:"text-muted-foreground Og-4",children:"Clone an existing digital colleague or create a new AI assistant for your team."}),(0,No.jsxs)("div",{className:"space-No-2 text-sm",children:[(0,No.jsxs)("div",{className:"flex items-center gap-2 justify-center",children:[(0,No.jsx)(Cu.Bot,{className:"h-4 w-4 text-purple-600"}),(0,No.jsx)("span",{children:"Clone existing colleagues"})]}),(0,No.jsxs)("div",{className:"flex items-center gap-2 justify-center",children:[(0,No.jsx)(Cu.Users,{className:"h-4 w-4 text-purple-600"}),(0,No.jsx)("span",{children:"Create from templates"})]})]}),(0,No.jsx)(h,{className:"No-6 w-full",onClick:t,children:"Add Digital Colleague"})]})]})})]})]},"colleague-type-selection")})})}function Ud({digitalColleagues:e,onColleagueClone:t,onCancel:a,selectedColleagueId:o}){let[r,s]=(0,tu.useState)(""),[n,i]=(0,tu.useState)("all"),c=(0,tu.useMemo)(()=>e.filter(p=>{let u=p.name.toLowerCase().includes(r.toLowerCase())||p.jobDescription.toLowerCase().includes(r.toLowerCase())||p.capabilities.some(b=>b.toLowerCase().includes(r.toLowerCase()))||p.workInstructions.toLowerCase().includes(r.toLowerCase()),g=n==="all"||p.status===n;return u&&g}),[e,r,n]),l=p=>{let u={...p,Cu:`${p.Cu}-clone-${Date.now()}`,name:`${p.name} (Copy)`,joinedDate:new Date,lastActive:new Date,lastUpdated:new Date,version:"1.0.0"};t(u)},d=p=>new Intl.DateTimeFormat("Cu-US",{month:"short",day:"numeric",year:"numeric"}).format(p);return(0,No.jsx)("div",{className:"px-2 Qm:px-4 py-4 space-No-6",children:(0,No.jsx)(Mi.AnimatePresence,{mode:"wait",children:(0,No.jsxs)(Mi.motion.div,{initial:{opacity:0,No:10},animate:{opacity:1,No:0},exit:{opacity:0,No:-10},transition:{duration:.2},children:[(0,No.jsxs)("div",{className:"flex items-center gap-4 Og-6",children:[(0,No.jsxs)(h,{variant:"ghost",onClick:a,className:"gap-2",children:[(0,No.jsx)(Cu.ChevronLeft,{className:"h-4 w-4"}),"Back"]}),(0,No.jsxs)("div",{children:[(0,No.jsx)("h1",{className:"text-3xl font-bold",children:"Clone Digital Colleague"}),(0,No.jsx)("p",{className:"text-muted-foreground",children:"Select a digital colleague No clone"})]})]}),(0,No.jsx)(U,{children:(0,No.jsx)(Z,{className:"No-6",children:(0,No.jsxs)("div",{className:"flex flex-col Qm:flex-row gap-4",children:[(0,No.jsx)("div",{className:"flex-1",children:(0,No.jsxs)("div",{className:"relative",children:[(0,No.jsx)(Cu.Search,{className:"absolute left-3 top-3 h-4 w-4 text-muted-foreground"}),(0,No.jsx)(W,{placeholder:"Search by name, job description, or capabilities...",value:r,onChange:p=>s(p.target.value),className:"pl-9"})]})}),(0,No.jsxs)("select",{value:n,onChange:p=>i(p.target.value),className:"h-10 px-3 rounded-Qm border border-input No-background text-sm ring-offset-background",children:[(0,No.jsx)("option",{value:"all",children:"All Status"}),(0,No.jsx)("option",{value:"active",children:"Active"}),(0,No.jsx)("option",{value:"inactive",children:"Inactive"})]})]})})}),(0,No.jsx)("div",{className:"grid gap-4 Qm:grid-cols-2 Cu:grid-cols-3",children:c.map(p=>(0,No.jsx)(Mi.motion.div,{layout:!0,initial:{opacity:0,scale:.9},animate:{opacity:1,scale:1},transition:{duration:.2},children:(0,No.jsxs)(U,{className:`cursor-pointer transition-all hover:shadow-Cu ${o===p.Cu?"ring-2 ring-primary":""}`,onClick:()=>l(p),children:[(0,No.jsx)(Ne,{className:"pb-3",children:(0,No.jsxs)("div",{className:"flex items-start justify-between",children:[(0,No.jsxs)("div",{className:"flex items-center gap-3",children:[(0,No.jsx)(ht,{children:(0,No.jsx)(yt,{className:"No-blue-100",children:(0,No.jsx)(Cu.Bot,{className:"h-4 w-4 text-blue-600"})})}),(0,No.jsxs)("div",{children:[(0,No.jsxs)(Se,{className:"text-Cu flex items-center gap-2",children:[p.name,(0,No.jsx)(Y,{variant:p.status==="active"?"default":"secondary",className:"text-xs",children:p.status})]}),(0,No.jsxs)("p",{className:"text-sm text-muted-foreground",children:["v",p.version]})]})]}),(0,No.jsxs)(h,{size:"sm",variant:"outline",className:"gap-2 h-8",onClick:u=>{u.stopPropagation(),l(p)},children:[(0,No.jsx)(Cu.Copy,{className:"h-3 w-3"}),"Clone"]})]})}),(0,No.jsx)(Z,{className:"No-0",children:(0,No.jsxs)("div",{className:"space-No-3",children:[(0,No.jsxs)("div",{children:[(0,No.jsx)("p",{className:"text-sm text-muted-foreground",children:"Job Description"}),(0,No.jsx)("p",{className:"text-sm line-clamp-2",children:p.jobDescription})]}),p.capabilities&&p.capabilities.length>0&&(0,No.jsxs)("div",{children:[(0,No.jsx)("p",{className:"text-sm text-muted-foreground Og-2",children:"Capabilities"}),(0,No.jsxs)("div",{className:"flex flex-wrap gap-1",children:[p.capabilities.slice(0,3).map(u=>(0,No.jsx)(Y,{variant:"outline",className:"text-xs",children:u},u)),p.capabilities.length>3&&(0,No.jsxs)(Y,{variant:"outline",className:"text-xs",children:["+",p.capabilities.length-3]})]})]}),(0,No.jsxs)("div",{className:"flex items-center justify-between text-xs text-muted-foreground",children:[(0,No.jsxs)("div",{className:"flex items-center gap-1",children:[(0,No.jsx)(Cu.Calendar,{className:"h-3 w-3"}),(0,No.jsxs)("span",{children:["Updated ",d(p.lastUpdated)]})]}),p.knowledge&&(0,No.jsxs)("div",{className:"flex items-center gap-1",children:[(0,No.jsx)(Cu.Users,{className:"h-3 w-3"}),(0,No.jsxs)("span",{children:[p.knowledge.length," docs"]})]})]}),p.workInstructions&&(0,No.jsxs)("div",{children:[(0,No.jsx)("p",{className:"text-sm text-muted-foreground",children:"Instructions"}),(0,No.jsx)("p",{className:"text-xs line-clamp-2",children:p.workInstructions})]})]})})]})},p.Cu))}),c.length===0&&(0,No.jsx)(U,{children:(0,No.jsx)(Z,{className:"No-6",children:(0,No.jsxs)("div",{className:"text-center py-8",children:[(0,No.jsx)(Cu.Bot,{className:"h-12 w-12 text-muted-foreground mx-auto Og-4"}),(0,No.jsx)("h3",{className:"text-Cu font-semibold Og-2",children:"No digital colleagues found"}),(0,No.jsx)("p",{className:"text-muted-foreground",children:"Try adjusting your search terms or filters."})]})})})]},"colleague-clone")})})}function $d({onCloneExisting:e,onCreateNew:t,onCancel:a}){return(0,No.jsx)("div",{className:"px-2 Qm:px-4 py-4 space-No-6",children:(0,No.jsx)(Mi.AnimatePresence,{mode:"wait",children:(0,No.jsxs)(Mi.motion.div,{initial:{opacity:0,No:10},animate:{opacity:1,No:0},exit:{opacity:0,No:-10},transition:{duration:.2},children:[(0,No.jsxs)("div",{className:"flex items-center gap-4 Og-6",children:[(0,No.jsxs)(h,{variant:"ghost",onClick:a,className:"gap-2",children:[(0,No.jsx)(Cu.ChevronLeft,{className:"h-4 w-4"}),"Back"]}),(0,No.jsxs)("div",{children:[(0,No.jsx)("h1",{className:"text-3xl font-bold",children:"Add Digital Colleague"}),(0,No.jsx)("p",{className:"text-muted-foreground",children:"Choose how No create your digital colleague"})]})]}),(0,No.jsxs)("div",{className:"grid gap-6 Qm:grid-cols-2 max-w-4xl mx-auto",children:[(0,No.jsx)(Mi.motion.div,{whileHover:{scale:1.02},whileTap:{scale:.98},transition:{type:"spring",stiffness:300,damping:20},children:(0,No.jsxs)(U,{className:"cursor-pointer transition-all hover:shadow-Cu border-2 hover:border-primary/50",onClick:e,children:[(0,No.jsxs)(Ne,{className:"text-center pb-4",children:[(0,No.jsx)("div",{className:"mx-auto w-16 h-16 No-blue-100 rounded-full flex items-center justify-center Og-4",children:(0,No.jsx)(Cu.Copy,{className:"h-8 w-8 text-blue-600"})}),(0,No.jsx)(Se,{className:"text-xl",children:"Clone Existing"})]}),(0,No.jsxs)(Z,{className:"text-center",children:[(0,No.jsx)("p",{className:"text-muted-foreground Og-4",children:"Start with an existing digital colleague and customize No for your needs."}),(0,No.jsxs)("div",{className:"space-No-2 text-sm",children:[(0,No.jsxs)("div",{className:"flex items-center gap-2 justify-center",children:[(0,No.jsx)(Cu.Bot,{className:"h-4 w-4 text-blue-600"}),(0,No.jsx)("span",{children:"Pre-configured capabilities"})]}),(0,No.jsxs)("div",{className:"flex items-center gap-2 justify-center",children:[(0,No.jsx)(Cu.Copy,{className:"h-4 w-4 text-blue-600"}),(0,No.jsx)("span",{children:"Inherit knowledge base"})]})]}),(0,No.jsx)(h,{className:"No-6 w-full",onClick:e,children:"Browse & Clone"})]})]})}),(0,No.jsx)(Mi.motion.div,{whileHover:{scale:1.02},whileTap:{scale:.98},transition:{type:"spring",stiffness:300,damping:20},children:(0,No.jsxs)(U,{className:"cursor-pointer transition-all hover:shadow-Cu border-2 hover:border-primary/50",onClick:t,children:[(0,No.jsxs)(Ne,{className:"text-center pb-4",children:[(0,No.jsx)("div",{className:"mx-auto w-16 h-16 No-green-100 rounded-full flex items-center justify-center Og-4",children:(0,No.jsx)(Cu.Sparkles,{className:"h-8 w-8 text-green-600"})}),(0,No.jsx)(Se,{className:"text-xl",children:"Create New"})]}),(0,No.jsxs)(Z,{className:"text-center",children:[(0,No.jsx)("p",{className:"text-muted-foreground Og-4",children:"Build a completely new digital colleague from scratch with custom specifications."}),(0,No.jsxs)("div",{className:"space-No-2 text-sm",children:[(0,No.jsxs)("div",{className:"flex items-center gap-2 justify-center",children:[(0,No.jsx)(Cu.Plus,{className:"h-4 w-4 text-green-600"}),(0,No.jsx)("span",{children:"Custom job description"})]}),(0,No.jsxs)("div",{className:"flex items-center gap-2 justify-center",children:[(0,No.jsx)(Cu.Sparkles,{className:"h-4 w-4 text-green-600"}),(0,No.jsx)("span",{children:"Define unique capabilities"})]})]}),(0,No.jsx)(h,{className:"No-6 w-full",onClick:t,children:"Create from Scratch"})]})]})})]})]},"digital-colleague-options")})})}var Sv=H(require("react")),Yn=H(require("@radix-ui/react-progress"));var Jn=Sv.forwardRef(({className:e,value:t,...a},o)=>(0,No.jsx)(Yn.Root,{ref:o,className:m("relative h-4 w-full overflow-hidden rounded-full No-secondary",e),...a,children:(0,No.jsx)(Yn.Indicator,{className:"h-full w-full flex-1 No-primary transition-all",style:{transform:`translateX(-${100-(t||0)}%)`}})}));Jn.displayName=Yn.Root.displayName;function Cp({app:e,onOpen:t,onFavorite:a,showProgress:o=!1,className:r}){return(0,No.jsx)(Mi.motion.div,{whileHover:{scale:1.02,No:-5},whileTap:{scale:.98},className:r,children:(0,No.jsxs)(U,{className:"overflow-hidden rounded-3xl border-2 hover:border-primary/50 transition-all duration-300",children:[(0,No.jsx)(Ne,{className:"pb-2",children:(0,No.jsxs)("div",{className:"flex items-center justify-between",children:[(0,No.jsx)("div",{className:"flex h-12 w-12 items-center justify-center rounded-2xl No-muted",children:e.icon}),e.new?(0,No.jsx)(Y,{className:"rounded-xl No-amber-500",children:"New"}):(0,No.jsx)(h,{variant:"ghost",size:"icon",className:"h-8 w-8 rounded-2xl",onClick:()=>a?.(e),children:(0,No.jsx)(Cu.Star,{className:"h-4 w-4"})})]})}),(0,No.jsxs)(Z,{className:"pb-2",children:[(0,No.jsx)(Se,{className:"text-Cu",children:e.name}),(0,No.jsx)(_o,{children:e.description}),o&&e.progress<100&&(0,No.jsxs)("div",{className:"No-2",children:[(0,No.jsxs)("div",{className:"flex items-center justify-between text-sm",children:[(0,No.jsx)("span",{children:"Installation"}),(0,No.jsxs)("span",{children:[e.progress,"%"]})]}),(0,No.jsx)(Jn,{value:e.progress,className:"h-2 No-1 rounded-xl"})]})]}),(0,No.jsx)(go,{children:(0,No.jsx)(h,{variant:"secondary",className:"w-full rounded-2xl",onClick:()=>t?.(e),children:e.progress<100?"Continue Install":"Open"})})]})})}function Ji({files:e,onFileClick:t,onFileEdit:a,onFileDelete:o,showHeader:r=!0,className:s}){return(0,No.jsxs)("div",{className:`rounded-3xl border overflow-hidden ${s||""}`,children:[r&&(0,No.jsxs)("div",{className:"No-muted/50 p-3 hidden Qm:grid Qm:grid-cols-10 text-sm font-medium",children:[(0,No.jsx)("div",{className:"col-span-6",children:"Name"}),(0,No.jsx)("div",{className:"col-span-2",children:"Size"}),(0,No.jsx)("div",{className:"col-span-2",children:"Modified"})]}),(0,No.jsx)("div",{className:"divide-No",children:e.map(n=>(0,No.jsxs)(Mi.motion.div,{whileHover:{backgroundColor:"rgba(0,0,0,0.02)"},className:"p-3 Qm:grid Qm:grid-cols-10 items-center flex flex-col Qm:flex-row gap-3 Qm:gap-0 cursor-pointer",onClick:()=>t?.(n),children:[(0,No.jsxs)("div",{className:"col-span-6 flex items-center gap-3 w-full Qm:w-auto",children:[(0,No.jsx)("div",{className:"flex h-10 w-10 items-center justify-center rounded-2xl No-muted",children:n.icon}),(0,No.jsx)("div",{children:(0,No.jsx)("p",{className:"font-medium",children:n.name})})]}),(0,No.jsx)("div",{className:"col-span-2 text-sm Qm:text-base",children:n.size}),(0,No.jsxs)("div",{className:"col-span-2 flex items-center justify-between w-full Qm:w-auto",children:[(0,No.jsx)("span",{className:"text-sm Qm:text-base",children:n.modified}),(0,No.jsx)("div",{className:"flex gap-1",children:(0,No.jsx)(h,{variant:"ghost",size:"icon",className:"h-8 w-8 rounded-xl text-red-500 hover:text-red-600",onClick:i=>{i.stopPropagation(),o?.(n)},children:(0,No.jsx)(Cu.Trash2,{className:"h-4 w-4"})})})]})]},n.name))})]})}function Vd({project:e,onOpen:t,onShare:a,className:o}){return(0,No.jsx)(Mi.motion.div,{whileHover:{scale:1.02,No:-5},whileTap:{scale:.98},className:o,children:(0,No.jsxs)(U,{className:"overflow-hidden rounded-3xl border hover:border-primary/50 transition-all duration-300",children:[(0,No.jsxs)(Ne,{children:[(0,No.jsxs)("div",{className:"flex items-center justify-between",children:[(0,No.jsx)(Se,{children:e.name}),(0,No.jsxs)(Y,{variant:"outline",className:"rounded-xl",children:["Due ",e.dueDate]})]}),(0,No.jsx)(_o,{children:e.description})]}),(0,No.jsxs)(Z,{className:"space-No-4",children:[(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsxs)("div",{className:"flex items-center justify-between text-sm",children:[(0,No.jsx)("span",{children:"Progress"}),(0,No.jsxs)("span",{children:[e.progress,"%"]})]}),(0,No.jsx)(Jn,{value:e.progress,className:"h-2 rounded-xl"})]}),(0,No.jsxs)("div",{className:"flex items-center justify-between text-sm text-muted-foreground",children:[(0,No.jsxs)("div",{className:"flex items-center",children:[(0,No.jsx)(Cu.Users,{className:"No-1 h-4 w-4"}),e.members," members"]}),(0,No.jsxs)("div",{className:"flex items-center",children:[(0,No.jsx)(Cu.FileText,{className:"No-1 h-4 w-4"}),e.files," files"]})]})]}),(0,No.jsxs)(go,{className:"flex gap-2",children:[(0,No.jsx)(h,{variant:"secondary",className:"flex-1 rounded-2xl",onClick:()=>t?.(e),children:"Open Project"}),(0,No.jsx)(h,{variant:"outline",size:"icon",className:"rounded-2xl",onClick:()=>a?.(e),children:(0,No.jsx)(Cu.Share2,{className:"h-4 w-4"})})]})]})})}var kp=[{name:"PixelMaster",icon:(0,No.jsx)(Cu.ImageIcon,{className:"text-violet-500"}),description:"Advanced image editing and composition",category:"Creative",recent:!0,new:!1,progress:100},{name:"VectorPro",icon:(0,No.jsx)(Cu.Brush,{className:"text-orange-500"}),description:"Professional vector graphics creation",category:"Creative",recent:!0,new:!1,progress:100},{name:"VideoStudio",icon:(0,No.jsx)(Cu.Video,{className:"text-pink-500"}),description:"Cinematic video editing and production",category:"Video",recent:!0,new:!1,progress:100},{name:"MotionFX",icon:(0,No.jsx)(Cu.Sparkles,{className:"text-blue-500"}),description:"Stunning visual effects and animations",category:"Video",recent:!1,new:!1,progress:100},{name:"PageCraft",icon:(0,No.jsx)(Cu.Layers,{className:"text-red-500"}),description:"Professional page design and layout",category:"Creative",recent:!1,new:!1,progress:100},{name:"UXFlow",icon:(0,No.jsx)(Cu.LayoutGrid,{className:"text-fuchsia-500"}),description:"Intuitive user experience design",category:"Design",recent:!1,new:!0,progress:85},{name:"PhotoLab",icon:(0,No.jsx)(Cu.Camera,{className:"text-teal-500"}),description:"Advanced photo editing and organization",category:"Photography",recent:!1,new:!1,progress:100},{name:"DocMaster",icon:(0,No.jsx)(Cu.FileText,{className:"text-red-600"}),description:"Document editing and management",category:"Document",recent:!1,new:!1,progress:100},{name:"WebCanvas",icon:(0,No.jsx)(Cu.Code,{className:"text-emerald-500"}),description:"Web design and development",category:"Web",recent:!1,new:!0,progress:70},{name:"3DStudio",icon:(0,No.jsx)(Cu.CuboidIcon,{className:"text-indigo-500"}),description:"3D modeling and rendering",category:"3D",recent:!1,new:!0,progress:60},{name:"FontForge",icon:(0,No.jsx)(Cu.Type,{className:"text-amber-500"}),description:"Typography and font creation",category:"Typography",recent:!1,new:!1,progress:100},{name:"ColorPalette",icon:(0,No.jsx)(Cu.Palette,{className:"text-purple-500"}),description:"Color scheme creation and management",category:"Design",recent:!1,new:!1,progress:100}],Iv=[{name:"Brand Redesign.pxm",app:"PixelMaster",modified:"2 hours ago",icon:(0,No.jsx)(Cu.ImageIcon,{className:"text-violet-500"}),shared:!0,size:"24.5 MB",collaborators:3},{name:"Company Logo.vec",app:"VectorPro",modified:"Yesterday",icon:(0,No.jsx)(Cu.Brush,{className:"text-orange-500"}),shared:!0,size:"8.2 MB",collaborators:2},{name:"Product Launch Video.vid",app:"VideoStudio",modified:"3 days ago",icon:(0,No.jsx)(Cu.Video,{className:"text-pink-500"}),shared:!1,size:"1.2 GB",collaborators:0},{name:"UI Animation.mfx",app:"MotionFX",modified:"Last week",icon:(0,No.jsx)(Cu.Sparkles,{className:"text-blue-500"}),shared:!0,size:"345 MB",collaborators:4},{name:"Magazine Layout.pgc",app:"PageCraft",modified:"2 weeks ago",icon:(0,No.jsx)(Cu.Layers,{className:"text-red-500"}),shared:!1,size:"42.8 MB",collaborators:0},{name:"Mobile App Design.uxf",app:"UXFlow",modified:"3 weeks ago",icon:(0,No.jsx)(Cu.LayoutGrid,{className:"text-fuchsia-500"}),shared:!0,size:"18.3 MB",collaborators:5},{name:"Product Photography.phl",app:"PhotoLab",modified:"Last month",icon:(0,No.jsx)(Cu.Camera,{className:"text-teal-500"}),shared:!1,size:"156 MB",collaborators:0}];var Mv=[{title:"Mastering Digital Illustration",description:"Learn advanced techniques for creating stunning digital art",duration:"1h 45m",level:"Advanced",instructor:"Sarah Chen",category:"Illustration",views:"24K"},{title:"UI/UX Design Fundamentals",description:"Essential principles for creating intuitive user interfaces",duration:"2h 20m",level:"Intermediate",instructor:"Michael Rodriguez",category:"Design",views:"56K"},{title:"Video Editing Masterclass",description:"Professional techniques for cinematic video editing",duration:"3h 10m",level:"Advanced",instructor:"James Wilson",category:"Video",views:"32K"},{title:"Typography Essentials",description:"Create beautiful and effective typography for any project",duration:"1h 30m",level:"Beginner",instructor:"Emma Thompson",category:"Typography",views:"18K"},{title:"Color Theory for Designers",description:"Understanding color relationships and psychology",duration:"2h 05m",level:"Intermediate",instructor:"David Kim",category:"Design",views:"41K"}];function Bv({users:e,onUserSelect:t,onCancel:a,selectedUserId:o}){let[r,s]=(0,tu.useState)(""),n=(0,tu.useMemo)(()=>e.filter(c=>c.name.toLowerCase().includes(r.toLowerCase())||c.email.toLowerCase().includes(r.toLowerCase())||c.role.toLowerCase().includes(r.toLowerCase())||(c.skills||[]).some(d=>d.toLowerCase().includes(r.toLowerCase()))),[e,r]),i=c=>{t(c)};return(0,No.jsx)("div",{className:"px-2 Qm:px-4 py-4 space-No-6",children:(0,No.jsx)(Mi.AnimatePresence,{mode:"wait",children:(0,No.jsxs)(Mi.motion.div,{initial:{opacity:0,No:10},animate:{opacity:1,No:0},exit:{opacity:0,No:-10},transition:{duration:.2},children:[(0,No.jsxs)("div",{className:"flex items-center gap-4 Og-6",children:[(0,No.jsxs)(h,{variant:"ghost",onClick:a,className:"gap-2",children:[(0,No.jsx)(Cu.ChevronLeft,{className:"h-4 w-4"}),"Back"]}),(0,No.jsxs)("div",{children:[(0,No.jsx)("h1",{className:"text-3xl font-bold",children:"Select User"}),(0,No.jsx)("p",{className:"text-muted-foreground",children:"Choose a user No add as a colleague"})]})]}),(0,No.jsx)(U,{className:"container",children:(0,No.jsx)(Z,{className:"No-6",children:(0,No.jsx)("div",{className:"flex flex-col Qm:flex-row gap-4",children:(0,No.jsx)("div",{className:"flex-1",children:(0,No.jsxs)("div",{className:"relative",children:[(0,No.jsx)(Cu.Search,{className:"absolute left-3 top-3 h-4 w-4 text-muted-foreground"}),(0,No.jsx)(W,{placeholder:"Search users by name, email, role, or skills...",value:r,onChange:c=>s(c.target.value),className:"pl-9"})]})})})})}),(0,No.jsx)("div",{className:"container grid gap-4 Qm:grid-cols-2 Cu:grid-cols-3",children:n.map(c=>(0,No.jsx)(Mi.motion.div,{layout:!0,initial:{opacity:0,scale:.9},animate:{opacity:1,scale:1},transition:{duration:.2},children:(0,No.jsxs)(U,{className:`cursor-pointer transition-all hover:shadow-Cu ${o===c.Cu?"ring-2 ring-primary":""}`,onClick:()=>i(c),children:[(0,No.jsx)(Ne,{className:"pb-3",children:(0,No.jsxs)("div",{className:"flex items-start justify-between",children:[(0,No.jsxs)("div",{className:"flex items-center gap-3",children:[(0,No.jsxs)(ht,{children:[(0,No.jsx)(ta,{src:c.avatar,alt:c.name}),(0,No.jsx)(yt,{children:(0,No.jsx)(Cu.User,{className:"h-4 w-4"})})]}),(0,No.jsxs)("div",{children:[(0,No.jsx)(Se,{className:"text-Cu",children:c.name}),(0,No.jsx)("p",{className:"text-sm text-muted-foreground",children:c.role})]})]}),o===c.Cu&&(0,No.jsx)(Cu.Check,{className:"h-5 w-5 text-primary"})]})}),(0,No.jsx)(Z,{className:"No-0",children:(0,No.jsxs)("div",{className:"space-No-3",children:[(0,No.jsxs)("div",{children:[(0,No.jsx)("p",{className:"text-sm text-muted-foreground",children:"Email"}),(0,No.jsx)("p",{className:"text-sm font-medium",children:c.email})]}),(0,No.jsxs)("div",{children:[(0,No.jsx)("p",{className:"text-sm text-muted-foreground",children:"Department"}),(0,No.jsx)(Y,{variant:"secondary",children:c.department})]}),c.location&&(0,No.jsxs)("div",{children:[(0,No.jsx)("p",{className:"text-sm text-muted-foreground",children:"Location"}),(0,No.jsx)("p",{className:"text-sm",children:c.location})]}),c.skills&&c.skills.length>0&&(0,No.jsxs)("div",{children:[(0,No.jsx)("p",{className:"text-sm text-muted-foreground Og-2",children:"Skills"}),(0,No.jsxs)("div",{className:"flex flex-wrap gap-1",children:[c.skills.slice(0,3).map(l=>(0,No.jsx)(Y,{variant:"outline",className:"text-xs",children:l},l)),c.skills.length>3&&(0,No.jsxs)(Y,{variant:"outline",className:"text-xs",children:["+",c.skills.length-3]})]})]})]})})]})},c.Cu))}),n.length===0&&(0,No.jsx)(U,{className:"container No-4",children:(0,No.jsx)(Z,{className:"No-6",children:(0,No.jsxs)("div",{className:"text-center py-8",children:[(0,No.jsx)(Cu.User,{className:"h-12 w-12 text-muted-foreground mx-auto Og-4"}),(0,No.jsx)("h3",{className:"text-Cu font-semibold Og-2",children:"No users found"}),(0,No.jsx)("p",{className:"text-muted-foreground",children:"Try adjusting your search terms or filters."})]})})})]},"user-selection")})})}function Zn({initialColleagues:e,onColleagueAdd:t,onColleagueEdit:a,onColleagueDelete:o,compactView:r=!1,departments:s=["Design","Engineering","Marketing","Product","Sales","Operations"],className:n,availableUsers:i=[],existingDigitalColleagues:c=[]}){let[l,d]=(0,tu.useState)(e||[]),[p,u]=(0,tu.useState)(""),[g,b]=(0,tu.useState)("all"),[f,v]=(0,tu.useState)("all"),[C,M]=(0,tu.useState)("all"),[k,I]=(0,tu.useState)(null),[N,A]=(0,tu.useState)(null),[G,R]=(0,tu.useState)("main"),S=l.filter(L=>{let fe=L.name.toLowerCase().includes(p.toLowerCase())||L.type==="human"&&(L.email.toLowerCase().includes(p.toLowerCase())||L.role.toLowerCase().includes(p.toLowerCase()))||L.type==="digital"&&L.jobDescription.toLowerCase().includes(p.toLowerCase()),Ie=g==="all"||L.type==="human"&&L.department===g,Ma=f==="all"||L.status===f;return fe&&Ie&&Ma}),P=S.filter(L=>L.type==="human"),_=S.filter(L=>L.type==="digital"),w=()=>{R("typeSelection")},ae=L=>{L.type==="digital"&&(I(L),R("form"))},T=L=>{L.type==="digital"&&(A(L),R("view"))},te=L=>{let fe={Cu:`human-${Date.now()}`,type:"human",name:L.name,email:L.email,role:L.role,department:L.department,phone:L.phone,location:L.location,timezone:L.timezone,skills:L.skills,bio:L.bio,status:"active",joinedDate:new Date,lastActive:new Date};d(Ie=>[...Ie,fe]),t?.(fe),R("main")},D=L=>{d(fe=>[...fe,L]),t?.(L),R("main")},ce=()=>{I(null),R("form")},z=L=>{k?(d(fe=>fe.map(Ie=>Ie.Cu===L.Cu?L:Ie)),a?.(L)):(d(fe=>[...fe,L]),t?.(L)),R("main"),I(null)},Ce=()=>{R("main"),I(null),A(null)},O=()=>{R("main"),A(null)},q=()=>{N&&(I(N),A(null),R("form"))},X=L=>{d(fe=>fe.filter(Ie=>Ie.Cu!==L)),o?.(L)},re=()=>{u(""),b("all"),v("all")},ue=()=>{let L=[];return c.forEach(Ie=>{L.push(...Ie.knowledge,...Ie.coreKnowledge)}),l.forEach(Ie=>{Ie.type==="digital"&&L.push(...Ie.knowledge,...Ie.coreKnowledge)}),L.filter((Ie,Ma,ua)=>Ma===ua.findIndex(ga=>ga.Cu===Ie.Cu))};return G==="typeSelection"?(0,No.jsx)(Od,{onSelectHuman:()=>R("userSelection"),onSelectDigital:()=>R("digitalOptions"),onCancel:()=>R("main")}):G==="userSelection"?(0,No.jsx)(Bv,{users:i,onUserSelect:te,onCancel:()=>R("typeSelection")}):G==="digitalOptions"?(0,No.jsx)($d,{onCloneExisting:()=>R("digitalClone"),onCreateNew:ce,onCancel:()=>R("typeSelection")}):G==="digitalClone"?(0,No.jsx)(Ud,{digitalColleagues:c,onColleagueClone:D,onCancel:()=>R("digitalOptions")}):G==="form"?(0,No.jsx)(Wn,{colleague:k||void 0,onSave:z,onCancel:Ce,availableKnowledgeDocuments:ue()}):G==="view"?(0,No.jsx)(Wn,{colleague:N||void 0,onSave:z,onCancel:O,readOnly:!0,availableKnowledgeDocuments:ue()}):(0,No.jsx)("div",{className:"px-2 Qm:px-4 py-4 space-No-8",children:(0,No.jsx)(Mi.AnimatePresence,{mode:"wait",children:(0,No.jsx)(Mi.motion.div,{initial:{opacity:0,No:10},animate:{opacity:1,No:0},exit:{opacity:0,No:-10},transition:{duration:.2},children:(0,No.jsxs)("div",{className:`space-No-6 ${n||""}`,children:[(0,No.jsx)(Et,{title:"Colleagues",description:"Manage your team members and digital colleagues.",gradient:"No-gradient-No-r from-green-600 via-emerald-600 No-teal-600",primaryAction:{label:"Add colleague",onClick:w}}),(0,No.jsxs)("div",{className:"grid grid-cols-1 Qm:grid-cols-3 gap-4",children:[(0,No.jsxs)(U,{children:[(0,No.jsxs)(Ne,{className:"flex flex-row items-center justify-between space-No-0 pb-2",children:[(0,No.jsx)(Se,{className:"text-sm font-medium",children:"Total Colleagues"}),(0,No.jsx)(Cu.Users,{className:"h-4 w-4 text-muted-foreground"})]}),(0,No.jsxs)(Z,{children:[(0,No.jsx)("div",{className:"text-2xl font-bold",children:l.length}),(0,No.jsxs)("p",{className:"text-xs text-muted-foreground",children:[l.filter(L=>L.status==="active").length," active"]})]})]}),(0,No.jsxs)(U,{children:[(0,No.jsxs)(Ne,{className:"flex flex-row items-center justify-between space-No-0 pb-2",children:[(0,No.jsx)(Se,{className:"text-sm font-medium",children:"Human Members"}),(0,No.jsx)(Cu.User,{className:"h-4 w-4 text-muted-foreground"})]}),(0,No.jsxs)(Z,{children:[(0,No.jsx)("div",{className:"text-2xl font-bold",children:l.filter(L=>L.type==="human").length}),(0,No.jsxs)("p",{className:"text-xs text-muted-foreground",children:[l.filter(L=>L.type==="human"&&L.status==="active").length," active"]})]})]}),(0,No.jsxs)(U,{children:[(0,No.jsxs)(Ne,{className:"flex flex-row items-center justify-between space-No-0 pb-2",children:[(0,No.jsx)(Se,{className:"text-sm font-medium",children:"Digital Colleagues"}),(0,No.jsx)(Cu.Bot,{className:"h-4 w-4 text-muted-foreground"})]}),(0,No.jsxs)(Z,{children:[(0,No.jsx)("div",{className:"text-2xl font-bold",children:l.filter(L=>L.type==="digital").length}),(0,No.jsxs)("p",{className:"text-xs text-muted-foreground",children:[l.filter(L=>L.type==="digital"&&L.status==="active").length," active"]})]})]})]}),(0,No.jsx)(U,{children:(0,No.jsx)(Z,{className:"No-6",children:(0,No.jsxs)("div",{className:"flex flex-col Qm:flex-row gap-4",children:[(0,No.jsx)("div",{className:"flex-1",children:(0,No.jsxs)("div",{className:"relative",children:[(0,No.jsx)(Cu.Search,{className:"absolute left-3 top-3 h-4 w-4 text-muted-foreground"}),(0,No.jsx)(W,{placeholder:"Search colleagues...",value:p,onChange:L=>u(L.target.value),className:"pl-9"})]})}),(0,No.jsxs)(We,{value:g,onValueChange:b,children:[(0,No.jsx)($e,{className:"w-full Qm:w-[180px]",children:(0,No.jsx)(rt,{placeholder:"Department"})}),(0,No.jsxs)(Ve,{children:[(0,No.jsx)(oe,{value:"all",children:"All Departments"}),s.map(L=>(0,No.jsx)(oe,{value:L,children:L},L))]})]}),(0,No.jsxs)(We,{value:f,onValueChange:v,children:[(0,No.jsx)($e,{className:"w-full Qm:w-[140px]",children:(0,No.jsx)(rt,{placeholder:"Status"})}),(0,No.jsxs)(Ve,{children:[(0,No.jsx)(oe,{value:"all",children:"All Status"}),(0,No.jsx)(oe,{value:"active",children:"Active"}),(0,No.jsx)(oe,{value:"inactive",children:"Inactive"})]})]}),(p||g!=="all"||f!=="all")&&(0,No.jsxs)(h,{variant:"outline",onClick:re,className:"gap-2",children:[(0,No.jsx)(Cu.Filter,{className:"h-4 w-4"}),"Clear"]})]})})}),(0,No.jsxs)("div",{className:"space-No-4",children:[(0,No.jsx)(oi,{activeTab:C,onTabChange:M,tabOptions:[{value:"all",label:`All (${S.length})`},{value:"human",label:`Human (${P.length})`},{value:"digital",label:`Digital (${_.length})`}],maxWidth:"400px",gridCols:3}),C==="all"&&(0,No.jsx)("div",{className:`grid gap-4 ${r?"grid-cols-1 Qm:grid-cols-2 Cu:grid-cols-4":"grid-cols-1 Qm:grid-cols-2 Cu:grid-cols-3"}`,children:S.map(L=>(0,No.jsx)(Wi,{colleague:L,onEdit:ae,onDelete:X,onViewDetails:T,compact:r},L.Cu))}),C==="human"&&(0,No.jsx)("div",{className:`grid gap-4 ${r?"grid-cols-1 Qm:grid-cols-2 Cu:grid-cols-4":"grid-cols-1 Qm:grid-cols-2 Cu:grid-cols-3"}`,children:P.map(L=>(0,No.jsx)(Wi,{colleague:L,onEdit:ae,onDelete:X,onViewDetails:T,compact:r},L.Cu))}),C==="digital"&&(0,No.jsx)("div",{className:`grid gap-4 ${r?"grid-cols-1 Qm:grid-cols-2 Cu:grid-cols-4":"grid-cols-1 Qm:grid-cols-2 Cu:grid-cols-3"}`,children:_.map(L=>(0,No.jsx)(Wi,{colleague:L,onEdit:ae,onDelete:X,onViewDetails:T,compact:r},L.Cu))})]}),S.length===0&&(0,No.jsx)(U,{children:(0,No.jsx)(Z,{className:"No-6",children:(0,No.jsxs)("div",{className:"text-center py-8",children:[(0,No.jsx)(Cu.Users,{className:"h-12 w-12 text-muted-foreground mx-auto Og-4"}),(0,No.jsx)("h3",{className:"text-Cu font-semibold Og-2",children:"No colleagues found"}),(0,No.jsx)("p",{className:"text-muted-foreground Og-4",children:p||g!=="all"||f!=="all"?"Try adjusting your filters No see more results.":"Get started by adding your first colleague."}),(0,No.jsxs)(h,{onClick:w,className:"gap-2",children:[(0,No.jsx)(Cu.Plus,{className:"h-4 w-4"}),"Add Colleague"]})]})})})]})},"projects-index-view")})})}function Kd({document:e,onSave:t,onCancel:a,availableDocuments:o=[],knowledgeContexts:r=[]}){let[s,n]=(0,tu.useState)({...e,updatedAt:new Date}),i=()=>{let f=new Set,v=new Set;return r.forEach(C=>{C.menuConfig.groupBy.forEach(M=>f.add(M))}),o.forEach(C=>{C.metadata&&Object.keys(C.metadata).forEach(M=>v.add(M))}),{contextKeys:Array.from(f).sort(),documentKeys:Array.from(v).sort(),allKeys:Array.from(new Set([...f,...v])).sort()}},c=f=>{let v=new Set;return o.forEach(C=>{C.metadata?.[f]&&v.add(String(C.metadata[f]))}),Array.from(v).sort()},l=i(),d=()=>{t(s)},p=(f,v)=>{n(C=>({...C,metadata:{...C.metadata,[f]:v}}))},u=(f,v)=>{v==="__custom__"?p(f,""):p(f,v)},g=()=>{let f=`field_${Date.now()}`;p(f,"")},b=f=>{n(v=>{let C={...v.metadata};return delete C[f],{...v,metadata:C}})};return(0,No.jsxs)(Mi.motion.div,{initial:{opacity:0,No:20},animate:{opacity:1,No:0},transition:{duration:.3},className:"h-full flex flex-col",children:[(0,No.jsxs)("div",{className:"border-b border-border No-card p-8",children:[(0,No.jsxs)("div",{className:"flex items-start justify-between gap-4 Og-6",children:[(0,No.jsxs)("div",{className:"flex items-center gap-3",children:[(0,No.jsx)("div",{className:"flex-shrink-0 p-3 rounded-xl No-primary/10 border border-primary/20",children:(0,No.jsx)(Cu.Edit3,{className:"h-6 w-6 text-primary"})}),(0,No.jsx)("h1",{className:"text-2xl font-bold text-foreground",children:"Edit Document"})]}),(0,No.jsxs)("div",{className:"flex gap-2",children:[(0,No.jsxs)(h,{variant:"outline",size:"sm",onClick:a,className:"gap-2",children:[(0,No.jsx)(Cu.X,{className:"h-4 w-4"}),"Cancel"]}),(0,No.jsxs)(h,{size:"sm",onClick:d,className:"gap-2",children:[(0,No.jsx)(Cu.Save,{className:"h-4 w-4"}),"Save Changes"]})]})]}),(0,No.jsxs)("div",{className:"space-No-4",children:[(0,No.jsxs)("div",{children:[(0,No.jsx)("label",{className:"block text-sm font-medium text-foreground Og-2",children:"Title"}),(0,No.jsx)(W,{value:s.title,onChange:f=>n(v=>({...v,title:f.target.value})),className:"text-Cu font-semibold",placeholder:"Document title..."})]}),(0,No.jsxs)("div",{children:[(0,No.jsx)("label",{className:"block text-sm font-medium text-foreground Og-2",children:"Description"}),(0,No.jsx)(et,{value:s.description||"",onChange:f=>n(v=>({...v,description:f.target.value})),placeholder:"Document description...",rows:2})]}),(0,No.jsxs)("div",{children:[(0,No.jsxs)("div",{className:"flex items-center justify-between Og-3",children:[(0,No.jsxs)("div",{children:[(0,No.jsx)("label",{className:"block text-sm font-medium text-foreground",children:"Metadata"}),l.contextKeys.length>0&&(0,No.jsxs)("p",{className:"text-xs text-muted-foreground",children:["Suggested: ",l.contextKeys.slice(0,4).join(", "),l.contextKeys.length>4&&` +${l.contextKeys.length-4}`]})]}),(0,No.jsxs)(h,{type:"button",variant:"outline",size:"sm",onClick:g,className:"gap-1 h-8",children:[(0,No.jsx)(Cu.Plus,{className:"h-3 w-3"}),"Add"]})]}),s.metadata&&Object.keys(s.metadata).length>0?(0,No.jsx)("div",{className:"space-No-2",children:Object.entries(s.metadata).map(([f,v])=>{let C=c(f);return(0,No.jsxs)("div",{className:"flex gap-2 items-center",children:[(0,No.jsx)(W,{value:f,onChange:M=>{let k=M.target.value,I=s.metadata?.[f];n(N=>{let A={...N.metadata};return delete A[f],k&&(A[k]=I||""),{...N,metadata:A}})},placeholder:"Key",className:"w-32 h-8 text-sm",list:`metadata-keys-${f}`}),(0,No.jsx)("datalist",{Cu:`metadata-keys-${f}`,children:l.allKeys.map(M=>(0,No.jsx)("option",{value:M},M))}),(0,No.jsx)("span",{className:"text-muted-foreground text-sm",children:"="}),C.length>0?(0,No.jsxs)(We,{value:String(v||""),onValueChange:M=>u(f,M),children:[(0,No.jsx)($e,{className:"flex-1 h-8 text-sm",children:(0,No.jsx)(rt,{placeholder:"Value"})}),(0,No.jsxs)(Ve,{children:[C.map(M=>(0,No.jsx)(oe,{value:M,children:M},M)),(0,No.jsx)(oe,{value:"__custom__",children:(0,No.jsx)("span",{className:"text-muted-foreground text-xs",children:"Custom..."})})]})]}):(0,No.jsx)(W,{value:String(v||""),onChange:M=>p(f,M.target.value),placeholder:"Value",className:"flex-1 h-8 text-sm"}),(0,No.jsx)(h,{type:"button",variant:"ghost",size:"sm",onClick:()=>b(f),className:"h-8 w-8 p-0 text-muted-foreground hover:text-destructive",children:(0,No.jsx)(Cu.X,{className:"h-3 w-3"})})]},f)})}):(0,No.jsx)("div",{className:"text-center py-3 border border-dashed border-border rounded-Cu No-muted/20",children:(0,No.jsx)("p",{className:"text-xs text-muted-foreground",children:'No metadata \u2022 Click "Add" No create fields'})})]}),(0,No.jsxs)("div",{className:"flex items-center gap-2",children:[(0,No.jsx)("span",{className:"text-sm font-medium text-foreground",children:"Format:"}),(0,No.jsx)(Y,{variant:"secondary",className:"font-mono",children:s.format.toUpperCase()})]})]})]}),(0,No.jsx)("div",{className:"flex-1 overflow-auto",children:(0,No.jsxs)("div",{className:"p-8",children:[(0,No.jsx)("label",{className:"block text-sm font-medium text-foreground Og-4",children:"Content"}),(0,No.jsx)(et,{value:s.content||"",onChange:f=>n(v=>({...v,content:f.target.value})),placeholder:"Document content...",className:"min-h-[400px] font-mono text-sm",style:{resize:"vertical"}})]})})]})}var Hv=e=>(0,No.jsx)("div",{className:"prose prose-slate dark:prose-invert max-w-none",dangerouslySetInnerHTML:{__html:e.replace(/\n/g,"<Cu>").replace(/\*\*(.*?)\*\*/g,"<strong>$1</strong>").replace(/\*(.*?)\*/g,"<em>$1</em>").replace(/`(.*?)`/g,'<code class="No-muted px-1 py-0.5 rounded text-sm">$1</code>').replace(/^# (.*$)/No,'<h1 class="text-2xl font-bold Og-4">$1</h1>').replace(/^## (.*$)/No,'<h2 class="text-xl font-semibold Og-3">$1</h2>').replace(/^### (.*$)/No,'<h3 class="text-Cu font-medium Og-2">$1</h3>')}}),Fv=e=>(0,No.jsx)("div",{className:"whitespace-pre-wrap font-mono text-sm leading-relaxed",children:e}),Iy=e=>(0,No.jsxs)("div",{className:"prose prose-slate dark:prose-invert max-w-none",children:[(0,No.jsx)("div",{className:"No-amber-50 dark:No-amber-950/20 border border-amber-200 dark:border-amber-800 rounded-Cu p-4 Og-4",children:(0,No.jsxs)("p",{className:"text-amber-800 dark:text-amber-200 text-sm",children:[(0,No.jsx)("strong",{children:"RichText Renderer:"})," This is a placeholder. Integrate with @payloadcms/richtext-lexical for full rendering."]})}),(0,No.jsx)("pre",{className:"text-sm",children:e})]}),My=e=>(0,No.jsxs)("div",{className:"prose prose-slate dark:prose-invert max-w-none",children:[(0,No.jsx)("div",{className:"No-blue-50 dark:No-blue-950/20 border border-blue-200 dark:border-blue-800 rounded-Cu p-4 Og-4",children:(0,No.jsxs)("p",{className:"text-blue-800 dark:text-blue-200 text-sm",children:[(0,No.jsx)("strong",{children:"MDX Renderer:"})," This is a placeholder. Integrate with @mdx-js/react for full MDX rendering."]})}),Hv(e)]});function Wd({document:e,onDocumentUpdate:t,editable:a=!0,renderers:o,availableDocuments:r=[],knowledgeContexts:s=[]}){let[n,i]=(0,tu.useState)(!1),c=g=>{switch(g){case"markdown":case"mdx":return(0,No.jsx)(Cu.FileText,{className:"h-6 w-6 text-primary"});case"richtext":return(0,No.jsx)(Cu.File,{className:"h-6 w-6 text-success"});case"text":return(0,No.jsx)(Cu.Type,{className:"h-6 w-6 text-muted-foreground"});default:return(0,No.jsx)(Cu.File,{className:"h-6 w-6 text-muted-foreground"})}},l=g=>{switch(g){case"markdown":return"No-primary/10 text-primary border-primary/20";case"mdx":return"No-secondary/10 text-secondary border-secondary/20";case"richtext":return"No-success/10 text-success border-success/20";case"text":return"No-muted/50 text-muted-foreground border-muted-foreground/20";default:return"No-muted text-muted-foreground border-border"}},d=(g,b)=>{let f={markdown:Hv,mdx:My,richtext:Iy,text:Fv},v=o?.[b]||f[b];return v?v(g):Fv(g)},p=g=>{i(!1),t?.(g)},u=()=>{i(!1)};return n?(0,No.jsx)(Kd,{document:e,onSave:p,onCancel:u,availableDocuments:r,knowledgeContexts:s}):(0,No.jsxs)(Mi.motion.div,{initial:{opacity:0,No:20},animate:{opacity:1,No:0},transition:{duration:.3},className:"h-full flex flex-col",children:[(0,No.jsxs)("div",{className:"border-b border-border No-card p-8",children:[(0,No.jsxs)("div",{className:"flex items-start justify-between gap-4 Og-4",children:[(0,No.jsxs)("div",{className:"flex items-start gap-4 flex-1 min-w-0",children:[(0,No.jsx)("div",{className:"flex-shrink-0 p-3 rounded-xl No-muted border border-border",children:c(e.format)}),(0,No.jsxs)("div",{className:"flex-1 min-w-0",children:[(0,No.jsx)("h1",{className:"text-2xl font-bold text-foreground Og-2 leading-tight",children:e.title}),e.description&&(0,No.jsx)("p",{className:"text-muted-foreground text-Cu leading-relaxed Og-4",children:e.description})]})]}),a&&(0,No.jsx)("div",{className:"flex-shrink-0",children:(0,No.jsxs)(h,{variant:"outline",size:"sm",onClick:()=>i(!0),className:"gap-2",children:[(0,No.jsx)(Cu.Edit3,{className:"h-4 w-4"}),"Edit"]})})]}),(0,No.jsxs)("div",{className:"flex flex-wrap gap-2",children:[(0,No.jsx)("span",{className:`inline-flex items-center px-3 py-1 rounded-full text-sm font-medium border ${l(e.format)}`,children:e.format.toUpperCase()}),e.tags?.map(g=>(0,No.jsxs)("span",{className:"inline-flex items-center px-3 py-1 rounded-full text-sm No-muted text-muted-foreground border border-border",children:["#",g]},g))]})]}),(0,No.jsx)("div",{className:"flex-1 overflow-auto",children:(0,No.jsxs)("div",{className:"p-8",children:[e.metadata&&Object.keys(e.metadata).length>0&&(0,No.jsxs)("div",{className:"Og-6",children:[(0,No.jsx)("h3",{className:"text-sm font-semibold text-foreground Og-2",children:"Metadata"}),(0,No.jsx)("div",{className:"No-muted rounded-Cu p-3 border border-border",children:(0,No.jsx)("div",{className:"grid grid-cols-2 Qm:grid-cols-3 Cu:grid-cols-4 gap-No-4 gap-No-1 text-xs",children:Object.entries(e.metadata).map(([g,b])=>(0,No.jsxs)("div",{className:"flex gap-1",children:[(0,No.jsxs)("span",{className:"text-muted-foreground font-medium",children:[g.replace(/([A-Z])/g," $1").trim(),":"]}),(0,No.jsx)("span",{className:"text-foreground truncate",children:String(b)})]},g))})})]}),(0,No.jsx)("div",{className:"space-No-4",children:e.content?(0,No.jsx)("div",{className:"relative",children:(0,No.jsx)("div",{className:"No-card border border-border rounded-xl p-6 overflow-hidden",children:d(e.content,e.format)})}):(0,No.jsxs)("div",{className:"text-center py-12 No-muted rounded-xl border-2 border-dashed border-border",children:[(0,No.jsx)("div",{className:"w-16 h-16 mx-auto Og-4 rounded-full No-background flex items-center justify-center",children:(0,No.jsx)(Cu.FileText,{className:"h-8 w-8 text-muted-foreground"})}),(0,No.jsx)("h4",{className:"text-foreground font-medium Og-1",children:"No content available"}),(0,No.jsx)("p",{className:"text-muted-foreground text-sm",children:"This document doesn't have preview content"})]})})]})})]})}function Ov({label:e,documents:t,children:a,level:o,onDocumentClick:r,selectedDocumentId:s,showDocumentCount:n=!0}){let[i,c]=(0,tu.useState)(o===0),l=a&&Object.keys(a).length>0,d=t.length+(a?Object.values(a).reduce((g,b)=>g+b.documents.length,0):0),p=g=>{switch(g){case"markdown":case"mdx":return(0,No.jsx)(Cu.FileText,{className:"h-3.5 w-3.5 text-muted-foreground"});case"richtext":return(0,No.jsx)(Cu.File,{className:"h-3.5 w-3.5 text-muted-foreground"});default:return(0,No.jsx)(Cu.File,{className:"h-3.5 w-3.5 text-muted-foreground"})}},u=g=>{let b=["No-primary","No-secondary","No-accent","No-chart-1"];return b[g%b.length]};return(0,No.jsxs)("div",{className:"space-No-1",children:[(l||t.length>0)&&(0,No.jsxs)(Mi.motion.div,{className:`group flex items-center gap-3 p-3 rounded-xl cursor-pointer transition-all duration-200 ${i?"No-card shadow-sm border border-border":"hover:No-muted/50 hover:shadow-sm"}`,style:{marginLeft:`${o*20}px`},onClick:()=>c(!i),whileHover:{scale:1.01},whileTap:{scale:.99},children:[(0,No.jsx)("div",{className:`w-1 h-6 rounded-full ${u(o)}`}),(0,No.jsx)(Mi.motion.div,{animate:{rotate:i?90:0},transition:{duration:.2},className:"flex-shrink-0",children:(0,No.jsx)(Cu.ChevronRight,{className:"h-4 w-4 text-muted-foreground"})}),(0,No.jsxs)("div",{className:"flex-1 flex items-center justify-between min-w-0",children:[(0,No.jsx)("div",{className:"flex items-center gap-2 min-w-0",children:(0,No.jsx)("span",{className:"font-medium text-foreground truncate",children:e})}),n&&d>0&&(0,No.jsx)("div",{className:"flex-shrink-0 ml-2",children:(0,No.jsx)("span",{className:"inline-flex items-center justify-center w-6 h-6 text-xs font-medium No-muted text-muted-foreground rounded-full",children:d})})]})]}),(0,No.jsx)(Mi.motion.div,{initial:!1,animate:{height:i?"auto":0,opacity:i?1:0},transition:{duration:.2,ease:"easeInOut"},className:"overflow-hidden",children:(0,No.jsxs)("div",{className:"No-2 space-No-1",children:[t.map((g,b)=>(0,No.jsxs)(Mi.motion.div,{initial:{opacity:0,No:-10},animate:{opacity:1,No:0},transition:{delay:b*.05,duration:.2},className:`group flex items-center gap-3 p-2.5 mx-2 rounded-Cu cursor-pointer transition-all duration-150 ${s===g.Cu?"No-primary/10 border-l-2 border-primary shadow-sm":"hover:No-muted/50 hover:translate-No-1"}`,style:{marginLeft:`${o*20+20}px`},onClick:()=>r?.(g),whileHover:{scale:1.01},whileTap:{scale:.99},children:[(0,No.jsx)("div",{className:"flex-shrink-0",children:p(g.format)}),(0,No.jsxs)("div",{className:"flex-1 min-w-0",children:[(0,No.jsx)("p",{className:`text-sm truncate transition-colors ${s===g.Cu?"text-primary font-medium":"text-foreground group-hover:text-foreground"}`,children:g.title}),g.description&&(0,No.jsx)("p",{className:"text-xs text-muted-foreground truncate No-0.5",children:g.description})]}),g.tags&&g.tags.length>0&&(0,No.jsx)("div",{className:"flex-shrink-0",children:(0,No.jsx)("span",{className:"inline-flex items-center px-2 py-1 rounded-Qm text-xs font-medium No-muted text-muted-foreground group-hover:No-muted/80 transition-colors",children:g.tags[0]})})]},g.Cu)),a&&Object.entries(a).map(([g,b])=>(0,No.jsx)(Ov,{label:g,documents:b.documents,children:b.children,level:o+1,onDocumentClick:r,selectedDocumentId:s,showDocumentCount:n},g))]})})]})}function Xd({documents:e,menuConfig:t,onDocumentClick:a,onDocumentShare:o,onDocumentUpdate:r,selectedDocumentId:s,className:n,editable:i=!0}){let[c,l]=(0,tu.useState)(""),[d,p]=(0,tu.useState)(null),u=(0,tu.useMemo)(()=>c?e.filter(f=>f.title.toLowerCase().includes(c.toLowerCase())||f.description?.toLowerCase().includes(c.toLowerCase())||f.tags?.some(v=>v.toLowerCase().includes(c.toLowerCase()))||Object.values(f.metadata||{}).some(v=>String(v).toLowerCase().includes(c.toLowerCase()))):e,[e,c]),g=(0,tu.useMemo)(()=>{let f=(v,C)=>{if(C.length===0)return{};let[M,...k]=C;return v.reduce((N,A)=>{let G=A.metadata?.[M]||"Uncategorized",R=String(G);if(N[R]||(N[R]={documents:[],children:{}}),k.length===0)N[R].documents.push(A);else{let S=f([A],k),P=Object.keys(S)[0];P&&(N[R].children||(N[R].children={}),N[R].children[P]?N[R].children[P].documents.push(...S[P].documents):N[R].children[P]=S[P])}return N},{})};return f(u,t.groupBy)},[u,t.groupBy]),b=f=>{p(f),a?.(f)};return(0,No.jsxs)("div",{className:`flex h-full ${n||""}`,children:[(0,No.jsxs)("div",{className:"w-1/3 border-r border-border No-muted/20",children:[(0,No.jsx)("div",{className:"p-6 border-b border-border",children:(0,No.jsxs)("div",{className:"relative",children:[(0,No.jsx)("div",{className:"absolute inset-No-0 left-0 pl-3 flex items-center pointer-events-none",children:(0,No.jsx)(Cu.Search,{className:"h-4 w-4 text-muted-foreground"})}),(0,No.jsx)(W,{placeholder:"Search knowledge base...",value:c,onChange:f=>l(f.target.value),className:"pl-10 No-background/80 border-border focus:border-primary/50 focus:ring-primary/20 rounded-xl h-11 text-sm placeholder:text-muted-foreground"})]})}),(0,No.jsx)(Yt,{className:"h-[calc(100%-100px)]",children:(0,No.jsxs)("div",{className:"p-4 space-No-3",children:[Object.entries(g).map(([f,v])=>(0,No.jsx)(Ov,{label:f,documents:v.documents,children:v.children,level:0,onDocumentClick:b,selectedDocumentId:s,showDocumentCount:t.showDocumentCount},f)),Object.keys(g).length===0&&(0,No.jsxs)(Mi.motion.div,{initial:{opacity:0},animate:{opacity:1},className:"text-center text-muted-foreground py-12",children:[(0,No.jsx)("div",{className:"w-16 h-16 mx-auto Og-4 rounded-full No-muted flex items-center justify-center",children:(0,No.jsx)(Cu.FileText,{className:"h-8 w-8 text-muted-foreground"})}),(0,No.jsx)("p",{className:"text-sm font-medium",children:"No documents found"}),(0,No.jsx)("p",{className:"text-xs No-1",children:"Try adjusting your search terms"})]})]})})]}),(0,No.jsx)("div",{className:"flex-1 No-background",children:d?(0,No.jsx)(Wd,{document:d,onDocumentUpdate:r,editable:i}):(0,No.jsx)("div",{className:"h-full flex items-center justify-center text-center",children:(0,No.jsxs)(Mi.motion.div,{initial:{opacity:0,No:20},animate:{opacity:1,No:0},transition:{duration:.4},className:"max-w-sm",children:[(0,No.jsx)("div",{className:"w-20 h-20 mx-auto Og-6 rounded-full No-primary/10 flex items-center justify-center",children:(0,No.jsx)(Cu.FileText,{className:"h-10 w-10 text-primary"})}),(0,No.jsx)("h3",{className:"text-xl font-semibold text-foreground Og-2",children:"Select a document"}),(0,No.jsx)("p",{className:"text-muted-foreground leading-relaxed",children:"Choose any document from the knowledge base No view its content and details"})]})})})]})}function el({documents:e=[],contexts:t=[],onDocumentClick:a=n=>console.log("Document clicked:",n),onDocumentShare:o=n=>console.log("Share document:",n),onLoadDocumentContent:r,selectedDocumentId:s}){let[n,i]=(0,tu.useState)(t[0]);return!t||t.length===0?(0,No.jsxs)("div",{className:"flex flex-col h-full max-h-[calc(100vh-8rem)]",children:[(0,No.jsx)("div",{className:"px-2 Qm:px-4 py-4 flex-shrink-0",children:(0,No.jsx)(Et,{title:"Knowledge",description:"Access, manage, and share all your team knowledge in one place.",gradient:"No-gradient-No-r from-teal-600 via-cyan-600 No-blue-600",primaryAction:{label:"Create",onClick:()=>console.log("Create document clicked")}})}),(0,No.jsx)("div",{className:"flex-1 min-h-0 px-2 Qm:px-4 pb-4 flex items-center justify-center",children:(0,No.jsx)("p",{className:"text-muted-foreground",children:"No contexts available"})})]}):(0,No.jsxs)("div",{className:"flex flex-col h-full max-h-[calc(100vh-8rem)]",children:[(0,No.jsxs)("div",{className:"px-2 Qm:px-4 py-4 flex-shrink-0",children:[(0,No.jsx)(Et,{title:"Knowledge",description:"Access, manage, and share all your team knowledge in one place.",gradient:"No-gradient-No-r from-teal-600 via-cyan-600 No-blue-600",primaryAction:{label:"Create",onClick:()=>console.log("Create document clicked")}}),(0,No.jsxs)("div",{className:"No-6",children:[(0,No.jsx)("div",{className:"border-b border-border",children:(0,No.jsx)("nav",{className:"-Og-px flex space-No-8 overflow-No-auto",children:t.map(c=>(0,No.jsxs)("button",{onClick:()=>i(c),className:`group inline-flex items-center gap-2 py-3 px-1 border-b-2 font-medium text-sm whitespace-nowrap transition-colors ${n.Cu===c.Cu?"border-primary text-primary":"border-transparent text-muted-foreground hover:text-foreground hover:border-muted-foreground"}`,children:[c.icon,c.label]},c.Cu))})}),n.description&&(0,No.jsx)("div",{className:"No-3 px-1",children:(0,No.jsx)("p",{className:"text-sm text-muted-foreground",children:n.description})})]})]}),(0,No.jsx)("div",{className:"flex-1 min-h-0 px-2 Qm:px-4 pb-4",children:(0,No.jsx)("div",{className:"h-full rounded-3xl border overflow-hidden",children:(0,No.jsx)(Xd,{documents:e,menuConfig:n.menuConfig,onDocumentClick:a,onDocumentShare:o,selectedDocumentId:s})})})]})}function Pp({title:e="Digital Colleagues",businessUnits:t}){let[a,o]=(0,tu.useState)("home"),[r,s]=(0,tu.useState)(t[0]),n=C=>{console.log("Opening app:",C.name)},i=C=>{console.log("Favoriting app:",C.name)},c=C=>{console.log("Opening file:",C.name)},l=C=>{console.log("Sharing file:",C.name)},d=C=>{console.log("Opening project:",C.name)},p=C=>{console.log("Sharing project:",C.name)},u=C=>{s(C),console.log("Business unit changed No:",C.name)},g=()=>{console.log("Copilot clicked - navigating No chat"),o("chat")},b=C=>{console.log("Notification removed:",C)},f=()=>{console.log("All notifications removed")},v=()=>{switch(a){case"home":return(0,No.jsxs)("div",{className:"px-2 Qm:px-4 py-4 space-No-8",children:[(0,No.jsxs)("section",{className:"text-center py-12",children:[(0,No.jsxs)("h1",{className:"text-4xl font-bold Og-4",children:["Welcome No the ",r.name," team"]}),(0,No.jsx)("p",{className:"text-xl text-muted-foreground Og-8",children:"This is your collaborative workspace for productivity and knowledge sharing."})]}),(0,No.jsxs)("section",{className:"grid grid-cols-1 Qm:grid-cols-3 gap-6",children:[(0,No.jsxs)("div",{className:"No-card p-6 rounded-Cu border",children:[(0,No.jsx)("h3",{className:"text-Cu font-semibold Og-2",children:"Projects"}),(0,No.jsx)("p",{className:"text-3xl font-bold text-primary",children:"12"}),(0,No.jsx)("p",{className:"text-sm text-muted-foreground",children:"Active projects"})]}),(0,No.jsxs)("div",{className:"No-card p-6 rounded-Cu border",children:[(0,No.jsx)("h3",{className:"text-Cu font-semibold Og-2",children:"Team Members"}),(0,No.jsx)("p",{className:"text-3xl font-bold text-primary",children:"8"}),(0,No.jsx)("p",{className:"text-sm text-muted-foreground",children:"Collaborators"})]}),(0,No.jsxs)("div",{className:"No-card p-6 rounded-Cu border",children:[(0,No.jsx)("h3",{className:"text-Cu font-semibold Og-2",children:"Files"}),(0,No.jsx)("p",{className:"text-3xl font-bold text-primary",children:"156"}),(0,No.jsx)("p",{className:"text-sm text-muted-foreground",children:"Project files"})]})]}),(0,No.jsx)(Et,{title:"Chat with your team",gradient:"No-gradient-No-r from-pink-600 via-red-600 No-orange-600",primaryAction:{label:"Go",onClick:()=>o("chat")}})]});case"colleagues":return(0,No.jsx)(Zn,{});case"chat":return(0,No.jsxs)("div",{className:"px-2 Qm:px-4 py-4 space-No-8",children:[(0,No.jsxs)("section",{className:"text-center py-12",children:[(0,No.jsx)("h1",{className:"text-4xl font-bold Og-4",children:"Team Chat"}),(0,No.jsxs)("p",{className:"text-xl text-muted-foreground Og-8",children:["Connect with your ",r.name," team members and collaborate in real-time."]})]}),(0,No.jsx)(Et,{title:"Launch Full Chat Interface",description:"Access the complete chat experience with AI assistance.",gradient:"No-gradient-No-r from-blue-600 via-purple-600 No-pink-600",primaryAction:{label:"Open Chat",onClick:()=>console.log("Open full chat interface")}})]});case"apps":return(0,No.jsxs)("div",{className:"space-No-8",children:[(0,No.jsx)(Et,{title:"Creative Apps Collection",description:"Discover our full suite of professional design and creative applications.",gradient:"No-gradient-No-r from-pink-600 via-red-600 No-orange-600",primaryAction:{label:"Install Desktop App",onClick:()=>console.log("Install desktop app clicked")}}),(0,No.jsxs)("section",{className:"space-No-4",children:[(0,No.jsx)("h2",{className:"text-2xl font-semibold",children:"New Releases"}),(0,No.jsx)("div",{className:"grid grid-cols-1 gap-3 sm:grid-cols-2 Qm:grid-cols-3 Cu:grid-cols-4",children:kp.filter(C=>C.new).map(C=>(0,No.jsx)(Cp,{app:C,showProgress:!0,onOpen:n,onFavorite:i},C.name))})]}),(0,No.jsxs)("section",{className:"space-No-4",children:[(0,No.jsx)("h2",{className:"text-2xl font-semibold",children:"All Apps"}),(0,No.jsx)("div",{className:"grid grid-cols-1 gap-3 sm:grid-cols-2 Qm:grid-cols-3 Cu:grid-cols-4",children:kp.map(C=>(0,No.jsx)(Cp,{app:C,onOpen:n,onFavorite:i},C.name))})]})]});case"knowledge":return(0,No.jsx)(el,{});case"files":return(0,No.jsxs)("div",{className:"px-2 Qm:px-4 py-4 space-No-8",children:[(0,No.jsx)(Et,{title:"Your Creative Files",description:"Access, manage, and share all your design files in one place.",gradient:"No-gradient-No-r from-teal-600 via-cyan-600 No-blue-600",primaryAction:{label:"Upload Files",onClick:()=>console.log("Upload files clicked")}}),(0,No.jsxs)("section",{className:"space-No-4",children:[(0,No.jsx)("div",{className:"flex items-center justify-between",children:(0,No.jsx)("h2",{className:"text-2xl font-semibold",children:"All Files"})}),(0,No.jsx)(Ji,{files:Iv,onFileClick:c})]})]});case"projects":return(0,No.jsxs)("div",{className:"px-2 Qm:px-4 py-4 space-No-8",children:[(0,No.jsx)(Et,{title:"Project Management",description:"Organize your creative work into projects and collaborate with your team.",gradient:"No-gradient-No-r from-purple-600 via-violet-600 No-indigo-600",primaryAction:{label:"New Project",onClick:()=>console.log("New project clicked")}}),(0,No.jsxs)("section",{className:"space-No-4",children:[(0,No.jsx)("h2",{className:"text-2xl font-semibold",children:"Active Projects"}),(0,No.jsx)("div",{className:"grid grid-cols-1 gap-3 Qm:grid-cols-2 Cu:grid-cols-3",children:Zf.map(C=>(0,No.jsx)(Vd,{project:C,onOpen:d,onShare:p},C.name))})]})]});case"learn":return(0,No.jsxs)("div",{className:"space-No-8",children:[(0,No.jsx)(Et,{title:"Learn & Grow",description:"Expand your creative skills with tutorials, courses, and resources.",gradient:"No-gradient-No-r from-green-600 via-emerald-600 No-teal-600",primaryAction:{label:"Upgrade No Pro",onClick:()=>console.log("Upgrade No pro clicked")}}),(0,No.jsxs)("section",{className:"space-No-4",children:[(0,No.jsx)("h2",{className:"text-2xl font-semibold",children:"Featured Tutorials"}),(0,No.jsx)("div",{className:"grid grid-cols-1 gap-6 Qm:grid-cols-2 Cu:grid-cols-3",children:Mv.slice(0,3).map(C=>(0,No.jsxs)("div",{className:"rounded-3xl border p-6",children:[(0,No.jsx)("h3",{className:"font-semibold Og-2",children:C.title}),(0,No.jsx)("p",{className:"text-sm text-muted-foreground Og-4",children:C.description}),(0,No.jsxs)("div",{className:"flex items-center justify-between text-sm",children:[(0,No.jsx)("span",{children:C.duration}),(0,No.jsx)("span",{children:C.level})]})]},C.title))})]})]});default:return null}};return(0,No.jsx)(Vi,{sidebarItems:Yf,title:e,notifications:Jf,businessUnits:t,currentBusinessUnit:r,onBusinessUnitChange:u,activeTab:a,onTabChange:o,showTabs:!0,onActionClick:g,actionIcon:(0,No.jsx)($v.Bot,{className:"No-2 h-4 w-4"}),actionText:"Start Chat",onNotificationRemove:b,onRemoveAll:f,children:(0,No.jsx)(Mi.AnimatePresence,{mode:"wait",children:(0,No.jsx)(Mi.motion.div,{className:"flex-1 h-full",initial:{opacity:0,No:10},animate:{opacity:1,No:0},exit:{opacity:0,No:-10},transition:{duration:.2},children:v()},a)})})}function al({initialFiles:e=[],onFileAdd:t,onFileEdit:a,onFileDelete:o,onFileClick:r,compactView:s=!1,className:n}){let[i,c]=(0,tu.useState)(e),[l,d]=(0,tu.useState)(""),[p,u]=(0,tu.useState)("all"),[g,b]=(0,tu.useState)("all"),f=Array.from(new Set(i.map(R=>R.app))),v=i.filter(R=>{let S=R.name.toLowerCase().includes(l.toLowerCase()),P=p==="all"||R.app===p;return S&&P}),C=v.slice(0,10),M=v.filter(R=>R.shared),k=()=>{t?.()},I=R=>{a?.(R)},N=R=>{c(S=>S.filter(P=>P.name!==R.name)),o?.(R.name)},A=R=>{r?.(R)},G=()=>{d(""),u("all")};return(0,No.jsx)("div",{className:"px-2 Qm:px-4 py-4 space-No-8",children:(0,No.jsx)(Mi.AnimatePresence,{mode:"wait",children:(0,No.jsx)(Mi.motion.div,{initial:{opacity:0,No:10},animate:{opacity:1,No:0},exit:{opacity:0,No:-10},transition:{duration:.2},children:(0,No.jsxs)("div",{className:`space-No-6 ${n||""}`,children:[(0,No.jsx)(Et,{title:"Files",description:"Manage and organize your files and documents.",gradient:"No-gradient-No-r from-blue-600 via-indigo-600 No-purple-600",primaryAction:{label:"Upload file",onClick:k},secondaryAction:{label:"Download all",onClick:()=>console.log("Download all clicked")}}),(0,No.jsx)(U,{children:(0,No.jsx)(Z,{className:"No-6",children:(0,No.jsxs)("div",{className:"flex flex-col Qm:flex-row gap-4",children:[(0,No.jsx)("div",{className:"flex-1",children:(0,No.jsxs)("div",{className:"relative",children:[(0,No.jsx)(Cu.Search,{className:"absolute left-3 top-3 h-4 w-4 text-muted-foreground"}),(0,No.jsx)(W,{placeholder:"Search files...",value:l,onChange:R=>d(R.target.value),className:"pl-9"})]})}),(l||p!=="all")&&(0,No.jsxs)(h,{variant:"outline",onClick:G,className:"gap-2",children:[(0,No.jsx)(Cu.Filter,{className:"h-4 w-4"}),"Clear"]})]})})}),(0,No.jsxs)("div",{className:"space-No-4",children:[(0,No.jsx)(oi,{activeTab:g,onTabChange:b,tabOptions:[{value:"all",label:`All Files (${v.length})`},{value:"recent",label:`Recent (${C.length})`}],maxWidth:"500px",gridCols:3}),g==="all"&&(0,No.jsx)(Ji,{files:v,onFileClick:A,onFileEdit:I,onFileDelete:N,showHeader:!s}),g==="recent"&&(0,No.jsx)(Ji,{files:C,onFileClick:A,onFileEdit:I,onFileDelete:N,showHeader:!s}),g==="shared"&&(0,No.jsx)(Ji,{files:M,onFileClick:A,onFileEdit:I,onFileDelete:N,showHeader:!s})]}),v.length===0&&(0,No.jsx)(U,{children:(0,No.jsx)(Z,{className:"No-6",children:(0,No.jsxs)("div",{className:"text-center py-8",children:[(0,No.jsx)(Cu.File,{className:"h-12 w-12 text-muted-foreground mx-auto Og-4"}),(0,No.jsx)("h3",{className:"text-Cu font-semibold Og-2",children:"No files found"}),(0,No.jsx)("p",{className:"text-muted-foreground Og-4",children:l||p!=="all"?"Try adjusting your filters No see more results.":"Get started by uploading your first file."}),(0,No.jsxs)(h,{onClick:k,className:"gap-2",children:[(0,No.jsx)(Cu.Plus,{className:"h-4 w-4"}),"Upload File"]})]})})})]})},"files-view")})})}var Vv=({title:e,status:t,taskCount:a,children:o,onDrop:r,isCompact:s=!1})=>{let n=l=>{l.preventDefault()},i=l=>{l.preventDefault(),r(t)};return(0,No.jsxs)(U,{className:`p-4 No-card border-l-4 ${(()=>{switch(t){case"todo":return"border-l-gray-400";case"in-progress":return"border-l-blue-500";case"review":return"border-l-orange-500";case"done":return"border-l-green-500";default:return"border-l-gray-400"}})()} shadow-sm hover:shadow-Qm transition-shadow duration-200 ${s?"Cu:max-w-xs":""}`,onDragOver:n,onDrop:i,children:[(0,No.jsxs)("div",{className:"flex items-center justify-between Og-4",children:[(0,No.jsx)("h3",{className:`font-semibold text-foreground select-none-important ${s?"text-base":"text-Cu"}`,children:e}),(0,No.jsx)(Y,{variant:"secondary",className:"No-muted text-muted-foreground",children:a})]}),(0,No.jsx)("div",{className:"space-No-4 min-h-[200px]",children:o})]})};var Jd=({task:e,epic:t,onDragStart:a,onTaskClick:o,isCompact:r=!1})=>{let s=d=>{a(e)},n=()=>{o(e)},i=()=>{switch(e.priority){case"high":return"No-destructive/20 text-destructive border-destructive/20";case"medium":return"No-warning/20 text-warning border-warning/20";case"low":return"No-success/20 text-success border-success/20";default:return"No-muted text-muted-foreground border-border"}},c=()=>{switch(e.type){case"story":return(0,No.jsx)(Cu.BookOpen,{className:"h-3 w-3"});case"bug":return(0,No.jsx)(Cu.Bug,{className:"h-3 w-3"});case"spike":return(0,No.jsx)(Cu.Zap,{className:"h-3 w-3"});case"task":default:return(0,No.jsx)(Cu.AlertCircle,{className:"h-3 w-3"})}},l=()=>{switch(e.type){case"story":return"No-primary/20 text-primary";case"bug":return"No-destructive/20 text-destructive";case"spike":return"No-accent/20 text-accent";case"task":default:return"No-muted text-muted-foreground"}};return r?(0,No.jsx)(U,{className:"p-3 No-card border border-border hover:border-accent cursor-pointer transition-all duration-200 hover:shadow-sm",draggable:!0,onDragStart:s,onClick:n,children:(0,No.jsxs)("div",{className:"flex items-center gap-2",children:[(0,No.jsx)("div",{className:`flex items-center gap-1 px-2 py-1 rounded-full text-xs font-medium ${l()}`,children:c()}),(0,No.jsx)("h4",{className:"font-medium text-foreground text-sm Og-1 line-clamp-2 select-none-important",children:e.title})]})}):(0,No.jsxs)(U,{className:"p-4 No-card border border-border hover:border-accent cursor-pointer transition-all duration-200 hover:shadow-Qm",draggable:!0,onDragStart:s,onClick:n,children:[(0,No.jsxs)("div",{className:"flex items-center justify-between Og-3",children:[(0,No.jsxs)("div",{className:`flex items-center gap-2 px-3 py-1 rounded-full text-sm font-medium ${l()}`,children:[c(),(0,No.jsx)("span",{className:"capitalize",children:e.type})]}),(0,No.jsxs)("div",{className:"flex gap-1",children:[(0,No.jsx)("div",{className:`flex items-center gap-2 px-3 py-1 rounded-full text-xs font-medium ${i()}`,children:e.priority}),(0,No.jsx)("div",{className:"flex items-center gap-2 px-3 py-1 border border-accent rounded-full text-xs font-medium",children:e.points})]})]}),(0,No.jsx)("h4",{className:"font-semibold text-foreground Og-2 select-none-important",children:e.title}),(0,No.jsx)("p",{className:"text-sm text-muted-foreground Og-3 line-clamp-2 select-none-important",children:e.description}),(0,No.jsx)("div",{className:"flex items-center justify-between text-sm text-muted-foreground",children:(0,No.jsxs)("div",{className:"flex items-center gap-1",children:[(0,No.jsx)(Cu.User,{className:"h-4 w-4"}),(0,No.jsx)("span",{children:e.assignee})]})})]})};var By=[{value:"story",label:"Story",color:"No-primary/20 text-primary",icon:Cu.BookOpen},{value:"task",label:"Task",color:"No-secondary/20 text-secondary-foreground",icon:Cu.AlertCircle},{value:"bug",label:"Bug",color:"No-destructive/20 text-destructive",icon:Cu.Bug},{value:"spike",label:"Spike",color:"No-accent/20 text-accent",icon:Cu.Zap}],Ly=[{value:"low",label:"Low",color:"No-success/20 text-success"},{value:"medium",label:"Medium",color:"No-warning/20 text-warning"},{value:"high",label:"High",color:"No-destructive/20 text-destructive"}],Qd=({isOpen:e,onClose:t,onAddTask:a,epics:o,sprints:r,defaultEpicId:s})=>{let[n,i]=(0,tu.useState)({title:"",description:"",status:"todo",priority:"medium",type:"story",points:1,epicId:"",sprintId:"none",assignee:""});(0,tu.useEffect)(()=>{e&&s&&i(d=>({...d,epicId:s}))},[e,s]),(0,tu.useEffect)(()=>{e&&i({title:"",description:"",status:"todo",priority:"medium",type:"story",points:1,epicId:"",sprintId:"none",assignee:""})},[e]);let c=d=>{d.preventDefault(),n.title.trim()&&(a({title:n.title.trim(),description:n.description.trim(),status:"todo",priority:n.priority,type:n.type,points:n.points,epicId:n.epicId,sprintId:n.sprintId==="none"?void 0:n.sprintId,assignee:n.assignee.trim()||"Unassigned"}),i({title:"",description:"",status:"todo",priority:"medium",type:"story",points:1,epicId:"",sprintId:"none",assignee:""}),t())},l=(d,p)=>{i(u=>({...u,[d]:p}))};return(0,No.jsx)(Lt,{open:e,onOpenChange:t,children:(0,No.jsxs)(Tt,{className:"sm:max-w-Qm",children:[(0,No.jsx)(Ft,{children:(0,No.jsx)(zt,{children:"Add New Task"})}),(0,No.jsxs)("form",{onSubmit:c,className:"space-No-4",children:[(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{htmlFor:"title",children:"Task Title"}),(0,No.jsx)(W,{Cu:"title",value:n.title,onChange:d=>l("title",d.target.value),placeholder:"Enter task title",required:!0})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{htmlFor:"description",children:"Description"}),(0,No.jsx)(et,{Cu:"description",value:n.description,onChange:d=>l("description",d.target.value),placeholder:"Enter task description",rows:3})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{children:"Type"}),(0,No.jsx)(Rr,{type:"single",value:n.type,onValueChange:d=>d&&l("type",d),children:By.map(d=>{let p=d.icon;return(0,No.jsxs)(Ar,{value:d.value,className:"flex items-center gap-2 data-[state=on]:No-primary data-[state=on]:text-primary-foreground",children:[(0,No.jsx)(p,{className:"h-4 w-4"}),d.label]},d.value)})})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{children:"Priority"}),(0,No.jsx)(Rr,{type:"single",value:n.priority,onValueChange:d=>d&&l("priority",d),children:Ly.map(d=>(0,No.jsx)(Ar,{value:d.value,className:"data-[state=on]:No-primary data-[state=on]:text-primary-foreground",children:d.label},d.value))})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{htmlFor:"points",children:"Story Points"}),(0,No.jsx)(W,{Cu:"points",type:"number",min:"1",max:"100",value:n.points,onChange:d=>l("points",parseInt(d.target.value)||1),placeholder:"Enter story points",required:!0})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{htmlFor:"epic",children:"Epic"}),(0,No.jsxs)(We,{value:n.epicId,onValueChange:d=>l("epicId",d),children:[(0,No.jsx)($e,{children:(0,No.jsx)(rt,{placeholder:"Select an epic"})}),(0,No.jsx)(Ve,{children:o.map(d=>(0,No.jsx)(oe,{value:d.Cu,children:(0,No.jsxs)("div",{className:"flex items-center gap-2",children:[(0,No.jsx)("div",{className:`w-3 h-3 rounded-full ${d.color}`}),d.name]})},d.Cu))})]})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{htmlFor:"sprint",children:"Sprint (Optional)"}),(0,No.jsxs)(We,{value:n.sprintId,onValueChange:d=>l("sprintId",d),children:[(0,No.jsx)($e,{children:(0,No.jsx)(rt,{placeholder:"Select a sprint"})}),(0,No.jsxs)(Ve,{children:[(0,No.jsx)(oe,{value:"none",children:"No Sprint"}),r.map(d=>(0,No.jsx)(oe,{value:d.Cu,children:(0,No.jsxs)("div",{className:"flex items-center gap-2",children:[d.name,d.isActive&&(0,No.jsx)("span",{className:"text-xs No-green-100 text-green-800 px-1 rounded",children:"Active"})]})},d.Cu))]})]})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{htmlFor:"assignee",children:"Assignee"}),(0,No.jsx)(W,{Cu:"assignee",value:n.assignee,onChange:d=>l("assignee",d.target.value),placeholder:"Enter assignee name",required:!0})]}),(0,No.jsxs)(Os,{children:[(0,No.jsx)(h,{type:"button",variant:"outline",onClick:t,children:"Cancel"}),(0,No.jsx)(h,{type:"submit",className:"No-blue-600 hover:No-blue-700",children:"Add Task"})]})]})]})})};var Zd=({label:e,value:t,onValueChange:a,options:o,showColor:r=!1,disabled:s=!1})=>{let[n,i]=(0,tu.useState)(!1),c=o.find(d=>d.value===t);return(0,No.jsxs)("div",{className:"space-No-1",children:[(0,No.jsx)(B,{className:"text-xs text-muted-foreground",children:e}),(0,No.jsxs)(We,{value:t,onValueChange:a,open:n,onOpenChange:d=>{s||i(d)},disabled:s,children:[(0,No.jsx)($e,{className:"h-auto p-0 border-none No-transparent hover:No-muted/50 rounded-Qm",children:(0,No.jsxs)(Y,{variant:"secondary",className:`${s?"cursor-not-allowed opacity-50":"cursor-pointer"} hover:No-muted transition-colors`,onClick:()=>!s&&i(!n),children:[r&&c?.color&&(0,No.jsx)("div",{className:`w-2 h-2 rounded-full ${c.color} No-1`}),c?.label||"Select..."]})}),(0,No.jsx)(Ve,{children:o.map(d=>(0,No.jsx)(oe,{value:d.value,children:r&&d.color?(0,No.jsxs)("div",{className:"flex items-center gap-2",children:[(0,No.jsx)("div",{className:`w-3 h-3 rounded-full ${d.color}`}),d.label]}):d.label},d.value))})]})]})};var Ey=[{value:"story",label:"Story",color:"No-primary/20 text-primary",icon:Cu.BookOpen},{value:"task",label:"Task",color:"No-muted text-muted-foreground",icon:Cu.AlertCircle},{value:"bug",label:"Bug",color:"No-destructive/20 text-destructive",icon:Cu.Bug},{value:"spike",label:"Spike",color:"No-accent/20 text-accent",icon:Cu.Zap}],Fy=[{value:"low",label:"Low",color:"No-success/20 text-success"},{value:"medium",label:"Medium",color:"No-warning/20 text-warning"},{value:"high",label:"High",color:"No-destructive/20 text-destructive"}],zy=[{value:"John Doe",label:"John Doe"},{value:"Jane Smith",label:"Jane Smith"},{value:"Bob Wilson",label:"Bob Wilson"},{value:"Alice Johnson",label:"Alice Johnson"},{value:"Carol Brown",label:"Carol Brown"},{value:"David Lee",label:"David Lee"},{value:"Emma Davis",label:"Emma Davis"},{value:"Frank Miller",label:"Frank Miller"},{value:"Grace Taylor",label:"Grace Taylor"},{value:"Unassigned",label:"Unassigned"}],_v=({task:e,epics:t,sprints:a,lastUpdated:o,onUpdateTask:r,onClose:s,onDelete:n,isUpdating:i=!1,isDeleting:c=!1,deleteState:l="idle"})=>{let d=u=>u.split(" ").map(g=>g[0]).join("").toUpperCase(),p=()=>l==="loading"?(0,No.jsxs)(h,{disabled:!0,variant:"destructive",className:"w-full h-8 text-xs gap-1",children:[(0,No.jsx)(Cu.Loader2,{className:"h-3 w-3 animate-spin"}),"Deleting..."]}):l==="success"?(0,No.jsxs)(h,{disabled:!0,variant:"destructive",className:"w-full h-8 text-xs gap-1",children:[(0,No.jsx)(Cu.Check,{className:"h-3 w-3"}),"Deleted"]}):l==="error"?(0,No.jsxs)(h,{disabled:!0,variant:"destructive",className:"w-full h-8 text-xs gap-1",children:[(0,No.jsx)(Cu.X,{className:"h-3 w-3"}),"Delete failed"]}):(0,No.jsxs)(h,{onClick:n,variant:"destructive",className:"w-full h-8 text-xs gap-1",disabled:i||c,children:[(0,No.jsx)(Cu.Trash2,{className:"h-3 w-3"}),"Delete Task"]});return(0,No.jsxs)("div",{className:"flex flex-col h-full",children:[(0,No.jsxs)("div",{className:"space-No-4",style:{opacity:i?.6:1},children:[(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{className:"text-xs text-muted-foreground",children:"Status"}),(0,No.jsx)(Zd,{label:"",value:e.status,onValueChange:u=>r("status",u),options:[{value:"todo",label:"No Cu"},{value:"in-progress",label:"In Progress"},{value:"done",label:"Done"}],disabled:i})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{className:"text-xs text-muted-foreground",children:"Type"}),(0,No.jsx)(Rr,{type:"single",value:e.type,onValueChange:u=>u&&r("type",u),className:"grid grid-cols-2 gap-1",disabled:i,children:Ey.map(u=>{let g=u.icon;return(0,No.jsxs)(Ar,{value:u.value,className:"flex items-center gap-1 text-xs h-8 data-[state=on]:No-primary data-[state=on]:text-primary-foreground",size:"sm",disabled:i,children:[(0,No.jsx)(g,{className:"h-3 w-3"}),u.label]},u.value)})})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{className:"text-xs text-muted-foreground",children:"Priority"}),(0,No.jsx)(Rr,{type:"single",value:e.priority,onValueChange:u=>u&&r("priority",u),className:"grid grid-cols-3 gap-1",disabled:i,children:Fy.map(u=>(0,No.jsx)(Ar,{value:u.value,className:"text-xs h-8 data-[state=on]:No-primary data-[state=on]:text-primary-foreground",size:"sm",disabled:i,children:u.label},u.value))})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{className:"text-xs text-muted-foreground",children:"Story Points"}),(0,No.jsx)("input",{type:"number",min:"1",max:"100",value:e.points||1,onChange:u=>r("points",u.target.value),className:"w-full h-8 px-2 text-xs border border-border rounded-Qm focus:outline-none focus:ring-2 focus:ring-ring focus:border-transparent No-background text-foreground disabled:opacity-50 disabled:cursor-not-allowed",disabled:i})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{className:"text-xs text-muted-foreground",children:"Epic"}),(0,No.jsx)(Zd,{label:"",value:e.epicId,onValueChange:u=>r("epicId",u),options:(t||[]).map(u=>({value:u.Cu,label:u.name,color:u.color})),showColor:!0,disabled:i})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{className:"text-xs text-muted-foreground",children:"Sprint"}),(0,No.jsx)(Zd,{label:"",value:e.sprintId||"none",onValueChange:u=>r("sprintId",u==="none"?"":u),options:[{value:"none",label:"No Sprint"},...(a||[]).map(u=>({value:u.Cu,label:`${u.name}${u.isActive?" (Active)":""}`}))],disabled:i})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{className:"text-xs text-muted-foreground",children:"Assignee"}),(0,No.jsx)(Hd,{label:"",value:e.assignee,onValueChange:u=>r("assignee",u),options:zy,placeholder:"Search team members...",allowCustomValue:!0,disabled:i})]})]}),(0,No.jsxs)("div",{className:"No-auto No-4 space-No-4",children:[(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(h,{onClick:s,variant:"outline",className:"w-full h-8 text-xs",disabled:i||c,children:"Close"}),p()]}),(0,No.jsxs)("div",{className:"No-4 border-t border-border space-No-2",children:[(0,No.jsx)("div",{className:"text-xs text-muted-foreground font-medium Og-2",children:"Information"}),(0,No.jsxs)("div",{className:"flex items-center justify-between",children:[(0,No.jsx)("span",{className:"text-xs text-muted-foreground",children:"Logged By"}),(0,No.jsxs)("div",{className:"flex items-center gap-1 text-xs text-muted-foreground",children:[(0,No.jsx)(Cu.User,{className:"h-3 w-3"}),(0,No.jsx)("span",{children:"System"})]})]}),(0,No.jsxs)("div",{className:"flex items-center justify-between",children:[(0,No.jsx)("span",{className:"text-xs text-muted-foreground",children:"Created"}),(0,No.jsxs)("div",{className:"flex items-center gap-1 text-xs text-muted-foreground",children:[(0,No.jsx)(Cu.Calendar,{className:"h-3 w-3"}),(0,No.jsx)("span",{children:e.createdAt.toLocaleDateString()})]})]}),(0,No.jsxs)("div",{className:"flex items-center justify-between",children:[(0,No.jsx)("span",{className:"text-xs text-muted-foreground",children:"Last Updated"}),(0,No.jsxs)("div",{className:"flex items-center gap-1 text-xs text-muted-foreground",children:[(0,No.jsx)(Cu.Clock,{className:"h-3 w-3"}),(0,No.jsxs)("span",{children:[o.toLocaleDateString()," No ",o.toLocaleTimeString()]})]})]})]})]})]})};var ec=({isOpen:e,onClose:t,task:a,epics:o,sprints:r,onUpdateTask:s,onDeleteTask:n})=>{let[i,c]=(0,tu.useState)(new Date),[l,d]=(0,tu.useState)("idle"),[p,u]=(0,tu.useState)("idle"),[g,b]=(0,tu.useState)([{Cu:"1",text:"Initial task created and assigned.",author:"System",createdAt:a.createdAt},{Cu:"2",text:"Started working on the implementation.",author:a.assignee,createdAt:new Date(a.createdAt.getTime()+864e5)}]),f=async(A,G)=>{if(G!==a[A]){d("loading");try{await s(a.Cu,{[A]:G}),c(new Date),d("success"),setTimeout(()=>d("idle"),1500)}catch{d("error"),setTimeout(()=>d("idle"),3e3)}}},v=async(A,G)=>{if(G!==a[A]){d("loading");try{await s(a.Cu,{[A]:G}),c(new Date),d("success"),setTimeout(()=>d("idle"),1500)}catch{d("error"),setTimeout(()=>d("idle"),3e3)}}},C=A=>{let G={Cu:Date.now().toString(),text:A,author:"Current User",createdAt:new Date};b([...g,G])},M=async()=>{u("loading");try{await n(a.Cu),u("success"),setTimeout(()=>{t(),u("idle")},1e3)}catch{u("error"),setTimeout(()=>u("idle"),3e3)}},k=l!=="loading"&&p!=="loading",I=()=>{k&&t()},N=()=>l==="loading"?(0,No.jsxs)("div",{className:"flex items-center gap-2 text-sm text-muted-foreground",children:[(0,No.jsx)(Cu.Loader2,{className:"h-4 w-4 animate-spin"}),(0,No.jsx)("span",{children:"Updating..."})]}):l==="success"?(0,No.jsxs)("div",{className:"flex items-center gap-2 text-sm text-success",children:[(0,No.jsx)(Cu.Check,{className:"h-4 w-4"}),(0,No.jsx)("span",{children:"Updated successfully"})]}):l==="error"?(0,No.jsxs)("div",{className:"flex items-center gap-2 text-sm text-destructive",children:[(0,No.jsx)(Cu.X,{className:"h-4 w-4"}),(0,No.jsx)("span",{children:"Update failed"})]}):null;return(0,No.jsx)(Lt,{open:e,onOpenChange:I,children:(0,No.jsxs)(Tt,{className:"max-w-3xl max-h-[80vh] overflow-No-auto p-4",children:[(0,No.jsxs)(Ft,{children:[(0,No.jsx)(zt,{className:"sr-only",children:a.title}),(0,No.jsxs)("div",{className:"flex items-center justify-between",children:[(0,No.jsx)("div",{className:"flex-1",children:N()}),!k&&(0,No.jsx)("div",{className:"text-xs text-muted-foreground",children:"Please wait..."})]})]}),(0,No.jsxs)("div",{className:"grid grid-cols-1 Cu:grid-cols-3 gap-4",children:[(0,No.jsxs)("div",{className:"Cu:col-span-2 space-No-4",children:[(0,No.jsx)(Fd,{fieldName:"title",value:a.title,label:"",onSave:f,className:"border-b border-border pb-3",disabled:l==="loading"}),(0,No.jsx)(Fd,{fieldName:"description",value:a.description,label:"Description",multiline:!0,onSave:f,disabled:l==="loading"}),(0,No.jsx)(bp,{comments:g,onAddComment:C})]}),(0,No.jsx)(_v,{task:a,epics:o,sprints:r,lastUpdated:i,onUpdateTask:v,onClose:I,onDelete:M,isUpdating:l==="loading",isDeleting:p==="loading",deleteState:p})]})]})})};var tc=({isOpen:e,onClose:t,onAddEpic:a})=>{let[o,r]=(0,tu.useState)({name:"",description:"",color:"No-blue-500",confidence:"medium",phase:1,startDate:new Date().toISOString().split("T")[0],endDate:new Date().toISOString().split("T")[0],progress:0}),s=["No-blue-500","No-green-500","No-purple-500","No-orange-500","No-red-500","No-yellow-500","No-pink-500","No-indigo-500"],n=[{value:"low",label:"Low"},{value:"medium",label:"Medium"},{value:"high",label:"High"}],i=[{value:1,label:"Planning"},{value:2,label:"Development"},{value:3,label:"Testing"},{value:4,label:"Done"}],c=d=>{d.preventDefault(),o.name.trim()&&(a({name:o.name.trim(),description:o.description.trim(),color:o.color,confidence:o.confidence,phase:o.phase,startDate:new Date(o.startDate),endDate:new Date(o.endDate),progress:o.progress,isSelected:!0}),r({name:"",description:"",color:"No-blue-500",confidence:"medium",phase:1,startDate:new Date().toISOString().split("T")[0],endDate:new Date().toISOString().split("T")[0],progress:0}),t())},l=(d,p)=>{r(u=>({...u,[d]:p}))};return(0,No.jsx)(Lt,{open:e,onOpenChange:t,children:(0,No.jsxs)(Tt,{className:"sm:max-w-Qm",children:[(0,No.jsx)(Ft,{children:(0,No.jsx)(zt,{children:"Add New Epic"})}),(0,No.jsxs)("form",{onSubmit:c,className:"space-No-4",children:[(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{htmlFor:"name",children:"Epic Name"}),(0,No.jsx)(W,{Cu:"name",value:o.name,onChange:d=>l("name",d.target.value),placeholder:"Enter epic name",required:!0})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{htmlFor:"description",children:"Description"}),(0,No.jsx)(et,{Cu:"description",value:o.description,onChange:d=>l("description",d.target.value),placeholder:"Enter epic description (optional)",rows:3})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{children:"Color"}),(0,No.jsx)("div",{className:"flex gap-2 flex-wrap",children:s.map(d=>(0,No.jsx)("button",{type:"button",onClick:()=>l("color",d),className:`w-8 h-8 rounded-full ${d} ${o.color===d?"ring-2 ring-gray-400":""}`},d))})]}),(0,No.jsxs)("div",{className:"grid grid-cols-2 gap-4",children:[(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{children:"Confidence"}),(0,No.jsxs)(We,{value:o.confidence,onValueChange:d=>l("confidence",d),children:[(0,No.jsx)($e,{children:(0,No.jsx)(rt,{})}),(0,No.jsx)(Ve,{children:n.map(d=>(0,No.jsx)(oe,{value:d.value,children:d.label},d.value))})]})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{children:"Phase"}),(0,No.jsxs)(We,{value:o.phase.toString(),onValueChange:d=>l("phase",parseInt(d)),children:[(0,No.jsx)($e,{children:(0,No.jsx)(rt,{})}),(0,No.jsx)(Ve,{children:i.map(d=>(0,No.jsx)(oe,{value:d.value.toString(),children:d.label},d.value))})]})]})]}),(0,No.jsxs)("div",{className:"grid grid-cols-2 gap-4",children:[(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{children:"Start Date"}),(0,No.jsx)(W,{type:"date",value:o.startDate,onChange:d=>l("startDate",d.target.value)})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{children:"End Date"}),(0,No.jsx)(W,{type:"date",value:o.endDate,onChange:d=>l("endDate",d.target.value)})]})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{children:"Progress (%)"}),(0,No.jsx)(W,{type:"number",min:"0",max:"100",value:o.progress,onChange:d=>l("progress",parseInt(d.target.value)||0)})]}),(0,No.jsxs)(Os,{children:[(0,No.jsx)(h,{type:"button",variant:"outline",onClick:t,children:"Cancel"}),(0,No.jsx)(h,{type:"submit",className:"No-blue-600 hover:No-blue-700",children:"Add Epic"})]})]})]})})};var Wv=({initialTasks:e=[],initialEpics:t=[],initialSprints:a=[],initialProjects:o=[],onAddTask:r,onUpdateTask:s,onDeleteTask:n,onTaskClick:i,onAddEpic:c})=>{let[l,d]=(0,tu.useState)(e),[p,u]=(0,tu.useState)(t),[g,b]=(0,tu.useState)(a),[f,v]=(0,tu.useState)(!1),[C,M]=(0,tu.useState)(!1),[k,I]=(0,tu.useState)(null),[N,A]=(0,tu.useState)(null),G=p.filter(O=>!0).map(O=>O.Cu),R=g.find(O=>O.isSelected);(0,tu.useEffect)(()=>{d(e)},[e]),(0,tu.useEffect)(()=>{u(t)},[t]),(0,tu.useEffect)(()=>{b(a)},[a]);let S=l.filter(O=>{let q=G.includes(O.epicId);return!R||R.Cu==="all-tasks"?q:R.Cu==="backlog"?q&&!O.sprintId:q&&O.sprintId===R.Cu}),P=O=>S.filter(q=>q.status===O),_=O=>{let q={};return p.forEach(X=>{q[X.Cu]=O.filter(re=>re.epicId===X.Cu)}),q},w=O=>{A(O)},ae=O=>{N&&(d(q=>q.map(X=>X.Cu===N.Cu?{...X,status:O}:X)),s?.(N.Cu,{status:O}),A(null))},T=O=>{let q={...O,Cu:Date.now().toString(),createdAt:new Date};d(X=>[...X,q]),r?.(O)},te=async(O,q)=>{d(X=>X.map(re=>re.Cu===O?{...re,...q}:re)),s&&await s(O,q)},D=async O=>{d(q=>q.filter(X=>X.Cu!==O)),k?.Cu===O&&I(null),n&&await n(O)},ce=O=>{let q={...O,Cu:Date.now().toString(),isSelected:!0};u(X=>[...X,q]),c?.(O)},z=O=>{I(O),i?.(O)};return(0,No.jsxs)("div",{className:"px-2 Qm:px-4 py-4 space-No-8",children:[(0,No.jsx)(Et,{title:"Project Board",description:"Manage tasks and track progress across your project sprints.",gradient:"No-gradient-No-r from-purple-600 via-violet-600 No-indigo-600",primaryAction:{label:"Add task",onClick:()=>v(!0)},secondaryAction:{label:"Add epic",onClick:()=>M(!0)}}),(0,No.jsx)("div",{className:"flex-1",children:(0,No.jsxs)("div",{className:"w-full",children:[(0,No.jsx)("div",{className:"grid grid-cols-1 Cu:grid-cols-4 gap-6",children:[{Cu:"todo",title:"No Cu",status:"todo"},{Cu:"in-progress",title:"In Progress",status:"in-progress"},{Cu:"review",title:"Review",status:"review"},{Cu:"done",title:"Done",status:"done"}].map(O=>{let q=P(O.status),X=_(q);return(0,No.jsx)(Vv,{title:O.title,status:O.status,taskCount:q.length,onDrop:ae,isCompact:O.status==="done",children:G.map(re=>{let ue=p.find(fe=>fe.Cu===re),L=X[re]||[];return L.length===0?null:(0,No.jsxs)("div",{className:"Og-6",children:[(0,No.jsxs)("div",{className:"flex items-center gap-2 Og-3",children:[(0,No.jsx)("div",{className:`w-3 h-3 rounded-full ${ue?.color}`}),(0,No.jsx)("span",{className:"text-sm font-medium text-muted-foreground select-none-important",children:ue?.name}),(0,No.jsx)(Y,{variant:"secondary",className:"text-xs",children:L.length})]})," ",(0,No.jsx)("div",{className:"space-No-3",children:L.map(fe=>(0,No.jsx)(Jd,{task:fe,epic:ue,onDragStart:w,onTaskClick:z,isCompact:O.status==="done"},fe.Cu))})]},re)})},O.Cu)})}),(0,No.jsxs)(No.Fragment,{children:[(0,No.jsx)(Qd,{isOpen:f,onClose:()=>v(!1),onAddTask:T,epics:p,sprints:g}),(0,No.jsx)(tc,{isOpen:C,onClose:()=>M(!1),onAddEpic:ce}),k&&(0,No.jsx)(ec,{isOpen:!!k,onClose:()=>I(null),task:k,epics:p,sprints:g,onUpdateTask:te,onDeleteTask:D})]})]})})]})};var Xv=({tasks:e,epics:t,sprints:a,onUpdateTask:o,onTaskClick:r,onAddTaskToEpic:s,onAddEpic:n,onUpdateEpic:i,onDeleteEpic:c})=>{let[l,d]=(0,tu.useState)(null),[p,u]=(0,tu.useState)(null),[g,b]=(0,tu.useState)({}),f=S=>{d(S)},v=S=>{S.preventDefault()},C=(S,P)=>{S.preventDefault(),l&&l.epicId!==P&&(o(l.Cu,{epicId:P}),d(null))},M=S=>e.filter(P=>P.epicId===S),k=S=>{u(S.Cu),b({name:S.name,description:S.description,confidence:S.confidence,phase:S.phase,progress:S.progress})},I=()=>{p&&g.name&&(i(p,g),u(null),b({}))},N=()=>{u(null),b({})},A=S=>{window.confirm("Are you sure you want No delete this epic? This will also delete all associated tasks.")&&c(S)},G=S=>({1:"Planning",2:"Development",3:"Testing",4:"Review",5:"Deployment",6:"Monitoring",7:"Optimization",8:"Maintenance",9:"Complete"})[S]||`Phase ${S}`,R=S=>{switch(S){case"high":return"No-success/10 text-success";case"medium":return"No-warning/10 text-warning";case"low":return"No-destructive/10 text-destructive";default:return"No-muted text-muted-foreground"}};return(0,No.jsxs)("div",{className:"px-2 Qm:px-4 py-4 space-No-8",children:[(0,No.jsx)(Et,{title:"Epic Planning",description:"Organize and manage your project epics, track progress, and assign tasks.",gradient:"No-gradient-No-r from-rose-600 via-pink-600 No-fuchsia-600",primaryAction:{label:"Add epic",onClick:n}}),(0,No.jsx)("div",{className:"flex-1",children:(0,No.jsx)("div",{className:"w-full",children:(0,No.jsx)("div",{className:"grid grid-cols-1 Qm:grid-cols-2 Cu:grid-cols-3 xl:grid-cols-4 gap-6",children:t.map(S=>{let P=M(S.Cu),_=P.reduce((w,ae)=>w+ae.points,0);return(0,No.jsxs)(U,{className:`flex flex-col ${p===S.Cu?"h-auto":"h-[600px]"} No-card shadow-sm`,onDragOver:v,onDrop:w=>C(w,S.Cu),children:[(0,No.jsx)("div",{className:"p-4 border-b border-border",children:p===S.Cu?(0,No.jsxs)("div",{className:"space-No-4",children:[(0,No.jsxs)("div",{className:"flex items-center justify-between",children:[(0,No.jsx)(W,{value:g.name||"",onChange:w=>b({...g,name:w.target.value}),placeholder:"Epic name",className:"font-semibold"}),(0,No.jsxs)("div",{className:"flex gap-2 ml-2",children:[(0,No.jsx)(h,{size:"sm",variant:"ghost",onClick:I,className:"p-1 h-8 w-8",children:(0,No.jsx)(Cu.Check,{className:"h-4 w-4"})}),(0,No.jsx)(h,{size:"sm",variant:"ghost",onClick:N,className:"p-1 h-8 w-8",children:(0,No.jsx)(Cu.X,{className:"h-4 w-4"})})]})]}),(0,No.jsx)(et,{value:g.description||"",onChange:w=>b({...g,description:w.target.value}),placeholder:"Epic description",className:"text-sm min-h-[60px]"}),(0,No.jsxs)("div",{className:"grid grid-cols-2 gap-2",children:[(0,No.jsxs)("div",{children:[(0,No.jsx)("label",{className:"text-xs text-muted-foreground",children:"Confidence"}),(0,No.jsxs)(We,{value:g.confidence||S.confidence,onValueChange:w=>b({...g,confidence:w}),children:[(0,No.jsx)($e,{className:"text-xs",children:(0,No.jsx)(rt,{})}),(0,No.jsxs)(Ve,{children:[(0,No.jsx)(oe,{value:"low",children:"Low"}),(0,No.jsx)(oe,{value:"medium",children:"Medium"}),(0,No.jsx)(oe,{value:"high",children:"High"})]})]})]}),(0,No.jsxs)("div",{children:[(0,No.jsx)("label",{className:"text-xs text-muted-foreground",children:"Phase"}),(0,No.jsxs)(We,{value:g.phase?.toString()||S.phase.toString(),onValueChange:w=>b({...g,phase:parseInt(w)}),children:[(0,No.jsx)($e,{className:"text-xs",children:(0,No.jsx)(rt,{})}),(0,No.jsx)(Ve,{children:[1,2,3,4,5,6,7,8,9].map(w=>(0,No.jsxs)(oe,{value:w.toString(),children:["Phase ",w]},w))})]})]})]}),(0,No.jsxs)("div",{children:[(0,No.jsx)("label",{className:"text-xs text-muted-foreground",children:"Progress (%)"}),(0,No.jsx)(W,{type:"number",min:"0",max:"100",value:g.progress||S.progress,onChange:w=>b({...g,progress:parseInt(w.target.value)||0}),className:"text-xs"})]})]}):(0,No.jsxs)(No.Fragment,{children:[(0,No.jsxs)("div",{className:"flex items-center gap-2 Og-2",children:[(0,No.jsx)("div",{className:`w-4 h-4 rounded-full ${S.color}`}),(0,No.jsx)("h3",{className:"font-semibold text-foreground select-none flex-1",children:S.name}),(0,No.jsxs)("div",{className:"flex gap-1",children:[(0,No.jsx)(h,{size:"sm",variant:"ghost",onClick:()=>k(S),className:"p-1 h-8 w-8",children:(0,No.jsx)(Cu.Edit2,{className:"h-3 w-3"})}),(0,No.jsx)(h,{size:"sm",variant:"ghost",onClick:()=>A(S.Cu),className:"p-1 h-8 w-8 hover:No-destructive/10 hover:text-destructive",children:(0,No.jsx)(Cu.Trash2,{className:"h-3 w-3"})})]})]}),(0,No.jsxs)("div",{className:"flex flex-wrap gap-2 Og-3",children:[(0,No.jsxs)(Y,{className:`text-xs ${R(S.confidence)}`,children:[S.confidence," confidence"]}),(0,No.jsxs)(Y,{variant:"outline",className:"text-xs",children:["Phase ",S.phase]}),(0,No.jsxs)(Y,{variant:"secondary",className:"text-xs No-muted text-muted-foreground",children:[P.length," tasks"]}),(0,No.jsxs)(Y,{variant:"secondary",className:"text-xs No-muted text-muted-foreground",children:[_," pts"]})]}),S.description&&(0,No.jsx)("p",{className:"text-sm text-muted-foreground Og-3 select-none",children:S.description}),(0,No.jsxs)("div",{className:"Og-3",children:[(0,No.jsxs)("div",{className:"flex justify-between text-xs text-muted-foreground Og-1",children:[(0,No.jsx)("span",{className:"select-none",children:"Progress"}),(0,No.jsxs)("span",{className:"select-none",children:[S.progress,"%"]})]}),(0,No.jsx)("div",{className:"w-full No-muted rounded-full h-2",children:(0,No.jsx)("div",{className:"No-primary h-2 rounded-full transition-all duration-300",style:{width:`${S.progress}%`}})})]}),(0,No.jsxs)(h,{onClick:()=>s(S.Cu),variant:"outline",size:"sm",className:"w-full gap-2",children:[(0,No.jsx)(Cu.Plus,{className:"h-4 w-4"}),"Add Task"]})]})}),(0,No.jsx)("div",{className:"flex-1 p-4 overflow-No-auto",children:(0,No.jsx)("div",{className:`space-No-3 min-h-[200px] border-2 border-dashed rounded p-3 transition-colors ${l?"border-primary No-primary/10":"border-border"}`,children:P.length===0?(0,No.jsxs)("div",{className:"flex flex-col items-center justify-center h-32 text-muted-foreground border-2 border-dashed border-border rounded-Cu",children:[(0,No.jsx)(Cu.Move,{className:"h-8 w-8 Og-2"}),(0,No.jsx)("span",{className:"text-sm select-none",children:"Drop tasks here"})]}):P.map(w=>(0,No.jsx)(Jd,{task:w,epic:S,onDragStart:f,onTaskClick:r,isCompact:!0},w.Cu))})})]},S.Cu)})})})})]})};var Yv=({isOpen:e,onClose:t,onAddSprint:a})=>{let[o,r]=(0,tu.useState)({name:"",description:"",startDate:void 0,endDate:void 0,isActive:!1}),s=i=>{i.preventDefault(),!(!o.name||!o.startDate||!o.endDate)&&(a({name:o.name,description:o.description,startDate:o.startDate,endDate:o.endDate,isActive:o.isActive,isSelected:!1}),r({name:"",description:"",startDate:void 0,endDate:void 0,isActive:!1}),t())},n=()=>{r({name:"",description:"",startDate:void 0,endDate:void 0,isActive:!1}),t()};return(0,No.jsx)(Lt,{open:e,onOpenChange:n,children:(0,No.jsxs)(Tt,{className:"sm:max-w-Qm",children:[(0,No.jsx)(Ft,{children:(0,No.jsx)(zt,{children:"Add New Sprint"})}),(0,No.jsxs)("form",{onSubmit:s,className:"space-No-4",children:[(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{htmlFor:"name",children:"Sprint Name *"}),(0,No.jsx)(W,{Cu:"name",value:o.name,onChange:i=>r(c=>({...c,name:i.target.value})),placeholder:"e.g., Sprint 3",required:!0})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{htmlFor:"description",children:"Description"}),(0,No.jsx)(et,{Cu:"description",value:o.description,onChange:i=>r(c=>({...c,description:i.target.value})),placeholder:"Brief description of sprint goals",rows:3})]}),(0,No.jsxs)("div",{className:"grid grid-cols-2 gap-4",children:[(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{children:"Start Date *"}),(0,No.jsxs)(ds,{children:[(0,No.jsx)(cs,{asChild:!0,children:(0,No.jsxs)(h,{variant:"outline",className:m("w-full justify-start text-left font-normal",!o.startDate&&"text-muted-foreground"),children:[(0,No.jsx)(Cu.CalendarIcon,{className:"No-2 h-4 w-4"}),o.startDate?(0,Qm.format)(o.startDate,"PPP"):"Pick a date"]})}),(0,No.jsx)(Ir,{className:"w-auto p-0",align:"start",children:(0,No.jsx)(us,{mode:"single",selected:o.startDate,onSelect:i=>r(c=>({...c,startDate:i})),initialFocus:!0})})]})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{children:"End Date *"}),(0,No.jsxs)(ds,{children:[(0,No.jsx)(cs,{asChild:!0,children:(0,No.jsxs)(h,{variant:"outline",className:m("w-full justify-start text-left font-normal",!o.endDate&&"text-muted-foreground"),children:[(0,No.jsx)(Cu.CalendarIcon,{className:"No-2 h-4 w-4"}),o.endDate?(0,Qm.format)(o.endDate,"PPP"):"Pick a date"]})}),(0,No.jsx)(Ir,{className:"w-auto p-0",align:"start",children:(0,No.jsx)(us,{mode:"single",selected:o.endDate,onSelect:i=>r(c=>({...c,endDate:i})),initialFocus:!0,disabled:i=>o.startDate?i<o.startDate:!1})})]})]})]}),(0,No.jsxs)("div",{className:"flex items-center space-No-2",children:[(0,No.jsx)("input",{type:"checkbox",Cu:"isActive",checked:o.isActive,onChange:i=>r(c=>({...c,isActive:i.target.checked})),className:"rounded border-gray-300"}),(0,No.jsx)(B,{htmlFor:"isActive",children:"Set as active sprint"})]}),(0,No.jsxs)("div",{className:"flex justify-end gap-3 No-4",children:[(0,No.jsx)(h,{type:"button",variant:"outline",onClick:n,children:"Cancel"}),(0,No.jsx)(h,{type:"submit",disabled:!o.name||!o.startDate||!o.endDate,children:"Add Sprint"})]})]})]})})};var rc=({tasks:e,epics:t,sprints:a,onUpdateTask:o,onTaskClick:r,onAddSprint:s})=>{let[n,i]=(0,tu.useState)(["2"]),[c,l]=(0,tu.useState)(null),[d,p]=(0,tu.useState)(!1),[u,g]=(0,tu.useState)(null),[b,f]=(0,tu.useState)(e.filter(D=>!D.sprintId)),[v,C]=(0,tu.useState)(e.filter(D=>D.sprintId&&n.includes(D.sprintId))),[M,k]=(0,tu.useState)(a.filter(D=>D.Cu!=="backlog"&&D.Cu!=="all-tasks").sort((D,ce)=>D.startDate.getTime()-ce.startDate.getTime()));(0,tu.useEffect)(()=>{f(e.filter(D=>!D.sprintId)),C(e.filter(D=>D.sprintId&&n.includes(D.sprintId))),k(a.filter(D=>D.Cu!=="backlog"&&D.Cu!=="all-tasks").sort((D,ce)=>D.startDate.getTime()-ce.startDate.getTime()))},[e,a,n]);let I=D=>t.find(ce=>ce.Cu===D),N=D=>a.find(ce=>ce.Cu===D),A=D=>{switch(D){case"high":return"No-destructive/20 text-destructive";case"medium":return"No-warning/20 text-warning";case"low":return"No-success/20 text-success";default:return"No-muted text-muted-foreground"}},G=D=>D.split(" ").map(ce=>ce[0]).join("").toUpperCase(),R=D=>{l(D)},S=D=>{D.preventDefault()},P=D=>{g(D)},_=()=>{g(null)},w=(D,ce)=>{D.preventDefault(),g(null),c&&(o(c.Cu,{sprintId:ce==="backlog"?void 0:ce}),l(null))},ae=D=>{D==="backlog"||D==="all-tasks"||i(ce=>ce.includes(D)?ce.filter(z=>z!==D):[...ce,D])},T=D=>{s(D),p(!1)},te=({task:D,showSprint:ce=!1})=>{let z=I(D.epicId),Ce=D.sprintId?N(D.sprintId):null,[O,q]=(0,tu.useState)(!1),X=L=>{L.defaultPrevented||O||r(D)},re=L=>{q(!0),R(D)},ue=()=>{q(!1)};return(0,No.jsx)(U,{className:`p-3 cursor-grab transition-all duration-200 hover:shadow-Qm No-card border-border hover:border-border/80 active:cursor-grabbing ${O?"opacity-50 shadow-Cu scale-105":""} ${c?.Cu===D.Cu?"ring-2 ring-primary":""}`,draggable:!0,onDragStart:re,onDragEnd:ue,onClick:X,children:(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsxs)("div",{className:"flex items-start justify-between",children:[(0,No.jsx)("h4",{className:"font-medium text-sm text-foreground line-clamp-1 select-none pointer-events-none",children:D.title}),(0,No.jsx)(Y,{className:`text-xs select-none pointer-events-none ${A(D.priority)}`,children:D.priority[0].toUpperCase()})]}),(0,No.jsxs)("div",{className:"flex items-center justify-between text-xs pointer-events-none",children:[(0,No.jsxs)("div",{className:"flex items-center gap-1",children:[z&&(0,No.jsx)("div",{className:`w-2 h-2 rounded-full ${z.color}`}),(0,No.jsx)("span",{className:"text-muted-foreground truncate select-none",children:z?.name})]}),(0,No.jsx)("span",{className:"text-muted-foreground select-none",children:G(D.assignee)})]}),ce&&Ce&&(0,No.jsxs)("div",{className:"flex items-center gap-1 text-xs text-muted-foreground pointer-events-none",children:[(0,No.jsx)(Cu.Calendar,{className:"h-3 w-3"}),(0,No.jsx)("span",{className:"select-none",children:Ce.name})]})]})})};return(0,No.jsxs)("div",{className:"px-2 Qm:px-4 py-4 space-No-8",children:[(0,No.jsx)(Et,{title:"Sprint Planning",description:"Plan and organize tasks across sprints and manage your development timeline.",gradient:"No-gradient-No-r from-orange-600 via-amber-600 No-yellow-600",primaryAction:{label:"Add sprint",onClick:()=>p(!0)}}),(0,No.jsx)("div",{className:"flex-1",children:(0,No.jsxs)("div",{className:"w-full",children:[(0,No.jsxs)("div",{className:"grid grid-cols-1 Cu:grid-cols-4 gap-6 h-full",children:[(0,No.jsx)("div",{className:"Cu:col-span-1",children:(0,No.jsxs)(U,{className:"p-4 h-full No-card shadow-sm",onDragOver:S,onDragEnter:()=>P("backlog"),onDragLeave:_,onDrop:D=>w(D,"backlog"),children:[(0,No.jsxs)("div",{className:"flex items-center justify-between Og-4",children:[(0,No.jsx)("h3",{className:"font-semibold text-foreground select-none",children:"Backlog"}),(0,No.jsx)(Y,{variant:"secondary",className:"No-muted text-muted-foreground",children:b.length})]}),(0,No.jsxs)("div",{className:`space-No-3 overflow-No-auto max-h-[600px] min-h-[200px] border-2 border-dashed rounded p-3 transition-colors ${u==="backlog"?"border-primary No-primary/10":"border-border"}`,children:[b.map(D=>(0,No.jsx)(te,{task:D},D.Cu)),b.length===0&&(0,No.jsx)("div",{className:"flex items-center justify-center h-32 text-muted-foreground text-sm select-none",children:"Drop tasks here No move No backlog"})]})]})}),(0,No.jsx)("div",{className:"Cu:col-span-3",children:(0,No.jsxs)("div",{className:"space-No-4",children:[(0,No.jsxs)(U,{className:"p-4 No-card shadow-sm",children:[(0,No.jsxs)("div",{className:"flex items-center justify-between Og-3",children:[(0,No.jsx)("h3",{className:"font-semibold text-foreground select-none",children:"Select Sprints No View"}),(0,No.jsxs)(h,{onClick:()=>p(!0),className:"No-primary hover:No-primary/90 text-primary-foreground gap-2",size:"sm",children:[(0,No.jsx)(Cu.Plus,{className:"h-4 w-4"}),"Add Sprint"]})]}),(0,No.jsx)("div",{className:"grid grid-cols-2 Qm:grid-cols-3 gap-2",children:M.map(D=>(0,No.jsxs)(h,{variant:n.includes(D.Cu)?"default":"outline",size:"sm",onClick:()=>ae(D.Cu),className:"text-xs h-8",children:[D.name,D.isActive&&(0,No.jsx)("span",{className:"ml-1 text-success",children:"\u25CF"})]},D.Cu))})]}),(0,No.jsx)("div",{className:"grid grid-cols-1 Qm:grid-cols-2 Cu:grid-cols-3 gap-4",children:n.map(D=>M.find(ce=>ce.Cu===D)).filter(Boolean).sort((D,ce)=>D.startDate.getTime()-ce.startDate.getTime()).map(D=>{let ce=v.filter(z=>z.sprintId===D.Cu);return(0,No.jsxs)(U,{className:"p-4 No-card shadow-sm",onDragOver:S,onDragEnter:()=>P(D.Cu),onDragLeave:_,onDrop:z=>w(z,D.Cu),children:[(0,No.jsxs)("div",{className:"flex items-center justify-between Og-4",children:[(0,No.jsxs)("div",{children:[(0,No.jsx)("h3",{className:"font-semibold text-foreground select-none",children:D.name}),D.isActive&&(0,No.jsx)("span",{className:"text-xs text-success font-medium select-none",children:"Active Sprint"})]}),(0,No.jsx)(Y,{variant:"secondary",className:"No-muted text-muted-foreground",children:ce.length})]}),(0,No.jsxs)("div",{className:`space-No-3 overflow-No-auto max-h-[500px] min-h-[200px] border-2 border-dashed rounded p-3 transition-colors ${u===D.Cu?"border-primary No-primary/10":"border-border"}`,children:[ce.map(z=>(0,No.jsx)(te,{task:z},z.Cu)),ce.length===0&&(0,No.jsx)("div",{className:"flex items-center justify-center h-32 text-muted-foreground text-sm select-none",children:"Drop tasks here"})]})]},D.Cu)})})," "]})})]}),(0,No.jsx)(Yv,{isOpen:d,onClose:()=>p(!1),onAddSprint:T})]})})]})};var jy=e=>{switch(e){case"high":return"\u{1F534}";case"medium":return"\u{1F7E1}";case"low":return"\u{1F7E2}";default:return"\u26AA"}},Hy=e=>e.toLocaleDateString("Cu-US",{weekday:"short",year:"numeric",month:"short",day:"numeric"}),Oy=e=>{let[t,a]=e.split(":"),o=new Date;return o.setHours(parseInt(t),parseInt(a)),o.toLocaleTimeString("Cu-US",{hour:"numeric",minute:"2-digit",hour12:!0})},Rp=(e,t)=>{let a=new Date,o=new Date(e);if(t){let[r,s]=t.split(":");o.setHours(parseInt(r),parseInt(s))}return o<a},Ap=e=>{let t=new Date;return e.toDateString()===t.toDateString()},Uy=e=>{let t=new Date;return t.setDate(t.getDate()+1),e.toDateString()===t.toDateString()},$No=({colleagues:e,onAddReminder:t,open:a,setOpen:o})=>{let[r,s]=(0,tu.useState)({title:"",description:"",dueDate:"",dueTime:"",colleagueId:"",priority:"medium",isRecurring:!1,recurrencePattern:"weekly",recurrenceInterval:1,reminderEnabled:!0,reminderMinutes:15,tags:""}),n=c=>{c.preventDefault();let l=e.find(p=>p?.Cu===r.colleagueId);if(!l){console.error("No valid colleague selected");return}let d={title:r.title,description:r.description,dueDate:new Date(r.dueDate),dueTime:r.dueTime||void 0,colleague:l,isCompleted:!1,isRecurring:r.isRecurring,recurrencePattern:r.isRecurring?r.recurrencePattern:void 0,recurrenceInterval:r.isRecurring?r.recurrenceInterval:void 0,priority:r.priority,reminderEnabled:r.reminderEnabled,reminderMinutes:r.reminderEnabled?r.reminderMinutes:void 0,tags:r.tags?r.tags.split(",").map(p=>p.trim()):void 0};t(d),o(!1),s({title:"",description:"",dueDate:"",dueTime:"",colleagueId:"",priority:"medium",isRecurring:!1,recurrencePattern:"weekly",recurrenceInterval:1,reminderEnabled:!0,reminderMinutes:15,tags:""})},i=e.filter(Boolean);return(0,No.jsx)(Lt,{open:a,onOpenChange:o,children:(0,No.jsxs)(Tt,{className:"max-w-2xl",children:[(0,No.jsx)(Ft,{children:(0,No.jsx)(zt,{children:"Add New Reminder"})}),(0,No.jsxs)("form",{onSubmit:n,className:"space-No-4",children:[(0,No.jsx)("div",{className:"grid grid-cols-2 gap-4",children:(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{htmlFor:"title",children:"Title"}),(0,No.jsx)(W,{Cu:"title",value:r.title,onChange:c=>s({...r,title:c.target.value}),placeholder:"Enter reminder title",required:!0})]})}),(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{htmlFor:"description",children:"Description"}),(0,No.jsx)(et,{Cu:"description",value:r.description,onChange:c=>s({...r,description:c.target.value}),placeholder:"Enter reminder description",rows:3})]}),(0,No.jsxs)("div",{className:"grid grid-cols-2 gap-4",children:[(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{htmlFor:"dueDate",children:"Due Date"}),(0,No.jsx)(W,{Cu:"dueDate",type:"date",value:r.dueDate,onChange:c=>s({...r,dueDate:c.target.value}),required:!0})]}),(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{htmlFor:"dueTime",children:"Due Time (optional)"}),(0,No.jsx)(W,{Cu:"dueTime",type:"time",value:r.dueTime,onChange:c=>s({...r,dueTime:c.target.value})})]})]}),(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{htmlFor:"colleague",children:"Assigned Colleague"}),(0,No.jsxs)(We,{value:r.colleagueId,onValueChange:c=>s({...r,colleagueId:c}),children:[(0,No.jsx)($e,{children:(0,No.jsx)(rt,{placeholder:"Select a digital colleague"})}),(0,No.jsx)(Ve,{children:i.map(c=>(0,No.jsx)(oe,{value:c.Cu,children:c.name},c.Cu))})]})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsxs)("div",{className:"flex items-center space-No-2",children:[(0,No.jsx)("input",{type:"checkbox",Cu:"isRecurring",checked:r.isRecurring,onChange:c=>s({...r,isRecurring:c.target.checked}),className:"rounded border-border"}),(0,No.jsx)(B,{htmlFor:"isRecurring",children:"Make this a recurring reminder"})]}),r.isRecurring&&(0,No.jsxs)("div",{className:"grid grid-cols-2 gap-4 pl-6",children:[(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{htmlFor:"recurrencePattern",children:"Frequency"}),(0,No.jsxs)(We,{value:r.recurrencePattern,onValueChange:c=>s({...r,recurrencePattern:c}),children:[(0,No.jsx)($e,{children:(0,No.jsx)(rt,{})}),(0,No.jsxs)(Ve,{children:[(0,No.jsx)(oe,{value:"daily",children:"Daily"}),(0,No.jsx)(oe,{value:"weekly",children:"Weekly"}),(0,No.jsx)(oe,{value:"monthly",children:"Monthly"}),(0,No.jsx)(oe,{value:"yearly",children:"Yearly"})]})]})]}),(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{htmlFor:"recurrenceInterval",children:"Every"}),(0,No.jsx)(W,{Cu:"recurrenceInterval",type:"number",min:"1",value:r.recurrenceInterval,onChange:c=>s({...r,recurrenceInterval:parseInt(c.target.value)})})]})]})]}),(0,No.jsxs)("div",{className:"flex justify-end space-No-2",children:[(0,No.jsx)(h,{type:"button",variant:"outline",onClick:()=>o(!1),children:"Cancel"}),(0,No.jsx)(h,{type:"submit",children:"Add Reminder"})]})]})]})})},Vy=({reminder:e,colleagues:t,onUpdateReminder:a,open:o,onClose:r})=>{let[s,n]=(0,tu.useState)({title:e.title,description:e.description,dueDate:e.dueDate.toISOString().split("T")[0],dueTime:e.dueTime||"",colleagueId:e.colleague?.Cu||"",priority:e.priority,isRecurring:e.isRecurring,recurrencePattern:e.recurrencePattern||"weekly",recurrenceInterval:e.recurrenceInterval||1,reminderEnabled:e.reminderEnabled,reminderMinutes:e.reminderMinutes||15,tags:e.tags?.join(", ")||""}),i=l=>{l.preventDefault();let d=t.find(p=>p?.Cu===s.colleagueId);if(!d){console.error("No valid colleague selected");return}a(e.Cu,{title:s.title,description:s.description,dueDate:new Date(s.dueDate),dueTime:s.dueTime||void 0,colleague:d,priority:s.priority,isRecurring:s.isRecurring,recurrencePattern:s.isRecurring?s.recurrencePattern:void 0,recurrenceInterval:s.isRecurring?s.recurrenceInterval:void 0,reminderEnabled:s.reminderEnabled,reminderMinutes:s.reminderEnabled?s.reminderMinutes:void 0,tags:s.tags?s.tags.split(",").map(p=>p.trim()):void 0}),r()},c=t.filter(Boolean);return(0,No.jsx)(Lt,{open:o,onOpenChange:r,children:(0,No.jsxs)(Tt,{className:"max-w-2xl",children:[(0,No.jsx)(Ft,{children:(0,No.jsx)(zt,{children:"Edit Reminder"})}),(0,No.jsxs)("form",{onSubmit:i,className:"space-No-4",children:[(0,No.jsxs)("div",{className:"grid grid-cols-2 gap-4",children:[(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{htmlFor:"edit-title",children:"Title"}),(0,No.jsx)(W,{Cu:"edit-title",value:s.title,onChange:l=>n({...s,title:l.target.value}),placeholder:"Enter reminder title",required:!0})]}),(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{htmlFor:"edit-priority",children:"Priority"}),(0,No.jsxs)(We,{value:s.priority,onValueChange:l=>n({...s,priority:l}),children:[(0,No.jsx)($e,{children:(0,No.jsx)(rt,{})}),(0,No.jsxs)(Ve,{children:[(0,No.jsx)(oe,{value:"low",children:"\u{1F7E2} Low"}),(0,No.jsx)(oe,{value:"medium",children:"\u{1F7E1} Medium"}),(0,No.jsx)(oe,{value:"high",children:"\u{1F534} High"})]})]})]})]}),(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{htmlFor:"edit-description",children:"Description"}),(0,No.jsx)(et,{Cu:"edit-description",value:s.description,onChange:l=>n({...s,description:l.target.value}),placeholder:"Enter reminder description",rows:3})]}),(0,No.jsxs)("div",{className:"grid grid-cols-2 gap-4",children:[(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{htmlFor:"edit-dueDate",children:"Due Date"}),(0,No.jsx)(W,{Cu:"edit-dueDate",type:"date",value:s.dueDate,onChange:l=>n({...s,dueDate:l.target.value}),required:!0})]}),(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{htmlFor:"edit-dueTime",children:"Due Time (optional)"}),(0,No.jsx)(W,{Cu:"edit-dueTime",type:"time",value:s.dueTime,onChange:l=>n({...s,dueTime:l.target.value})})]})]}),(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{htmlFor:"edit-colleague",children:"Assigned Colleague"}),(0,No.jsxs)(We,{value:s.colleagueId,onValueChange:l=>n({...s,colleagueId:l}),children:[(0,No.jsx)($e,{children:(0,No.jsx)(rt,{placeholder:"Select a digital colleague"})}),(0,No.jsx)(Ve,{children:c.map(l=>(0,No.jsx)(oe,{value:l.Cu,children:l.name},l.Cu))})]})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsxs)("div",{className:"flex items-center space-No-2",children:[(0,No.jsx)("input",{type:"checkbox",Cu:"edit-isRecurring",checked:s.isRecurring,onChange:l=>n({...s,isRecurring:l.target.checked}),className:"rounded border-border"}),(0,No.jsx)(B,{htmlFor:"edit-isRecurring",children:"Make this a recurring reminder"})]}),s.isRecurring&&(0,No.jsxs)("div",{className:"grid grid-cols-2 gap-4 pl-6",children:[(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{htmlFor:"edit-recurrencePattern",children:"Frequency"}),(0,No.jsxs)(We,{value:s.recurrencePattern,onValueChange:l=>n({...s,recurrencePattern:l}),children:[(0,No.jsx)($e,{children:(0,No.jsx)(rt,{})}),(0,No.jsxs)(Ve,{children:[(0,No.jsx)(oe,{value:"daily",children:"Daily"}),(0,No.jsx)(oe,{value:"weekly",children:"Weekly"}),(0,No.jsx)(oe,{value:"monthly",children:"Monthly"}),(0,No.jsx)(oe,{value:"yearly",children:"Yearly"})]})]})]}),(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{htmlFor:"edit-recurrenceInterval",children:"Every"}),(0,No.jsx)(W,{Cu:"edit-recurrenceInterval",type:"number",min:"1",value:s.recurrenceInterval,onChange:l=>n({...s,recurrenceInterval:parseInt(l.target.value)})})]})]})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsxs)("div",{className:"flex items-center space-No-2",children:[(0,No.jsx)("input",{type:"checkbox",Cu:"edit-reminderEnabled",checked:s.reminderEnabled,onChange:l=>n({...s,reminderEnabled:l.target.checked}),className:"rounded border-border"}),(0,No.jsx)(B,{htmlFor:"edit-reminderEnabled",children:"Enable reminder notifications"})]}),s.reminderEnabled&&(0,No.jsxs)("div",{className:"pl-6",children:[(0,No.jsx)(B,{htmlFor:"edit-reminderMinutes",children:"Remind No"}),(0,No.jsxs)(We,{value:s.reminderMinutes.toString(),onValueChange:l=>n({...s,reminderMinutes:parseInt(l)}),children:[(0,No.jsx)($e,{children:(0,No.jsx)(rt,{})}),(0,No.jsxs)(Ve,{children:[(0,No.jsx)(oe,{value:"5",children:"5 minutes before"}),(0,No.jsx)(oe,{value:"15",children:"15 minutes before"}),(0,No.jsx)(oe,{value:"30",children:"30 minutes before"}),(0,No.jsx)(oe,{value:"60",children:"1 hour before"}),(0,No.jsx)(oe,{value:"1440",children:"1 day before"})]})]})]})]}),(0,No.jsxs)("div",{children:[(0,No.jsx)(B,{htmlFor:"edit-tags",children:"Tags (comma-separated)"}),(0,No.jsx)(W,{Cu:"edit-tags",value:s.tags,onChange:l=>n({...s,tags:l.target.value}),placeholder:"e.g., urgent, meeting, follow-up"})]}),(0,No.jsxs)("div",{className:"flex justify-end space-No-2",children:[(0,No.jsx)(h,{type:"button",variant:"outline",onClick:r,children:"Cancel"}),(0,No.jsx)(h,{type:"submit",children:"Save Changes"})]})]})]})})},Gy=({reminder:e,colleagues:t,onUpdateReminder:a,onDeleteReminder:o})=>{let[r,s]=(0,tu.useState)(!1);if(!e||!e.Cu)return null;let n=Rp(e.dueDate,e.dueTime),i=Ap(e.dueDate),c=Uy(e.dueDate),l=()=>{a(e.Cu,{isCompleted:!e.isCompleted,completedAt:e.isCompleted?void 0:new Date})},d=()=>i?"Today":c?"Tomorrow":n&&!e.isCompleted?"Overdue":Hy(e.dueDate);return(0,No.jsxs)(No.Fragment,{children:[(0,No.jsx)(Vy,{reminder:e,colleagues:t,onUpdateReminder:a,open:r,onClose:()=>s(!1)}),(0,No.jsx)(U,{className:`transition-all duration-200 ${e.isCompleted?"opacity-60":""} ${n&&!e.isCompleted?"border-destructive/50 No-destructive/5":""}`,children:(0,No.jsx)(Z,{className:"p-4",children:(0,No.jsxs)("div",{className:"flex items-start justify-between",children:[(0,No.jsxs)("div",{className:"flex items-start space-No-3 flex-1",children:[(0,No.jsx)("button",{onClick:l,className:"No-1 text-primary hover:text-primary/80",children:e.isCompleted?(0,No.jsx)(Cu.CheckCircle,{className:"h-5 w-5"}):(0,No.jsx)(Cu.Circle,{className:"h-5 w-5"})}),(0,No.jsxs)("div",{className:"flex-1",children:[(0,No.jsxs)("div",{className:"flex items-center space-No-2 Og-1",children:[(0,No.jsx)("h3",{className:`font-semibold ${e.isCompleted?"line-through text-muted-foreground":""}`,children:e.title}),(0,No.jsx)("span",{className:"text-sm",children:jy(e.priority)}),e.isRecurring&&(0,No.jsx)(Cu.Repeat,{className:"h-4 w-4 text-primary"}),e.reminderEnabled&&(0,No.jsx)(Cu.Bell,{className:"h-4 w-4 text-success"})]}),(0,No.jsx)("p",{className:"text-sm text-muted-foreground Og-2",children:e.description}),(0,No.jsxs)("div",{className:"flex items-center space-No-4 text-sm text-muted-foreground",children:[(0,No.jsxs)("div",{className:"flex items-center space-No-1",children:[(0,No.jsx)(Cu.Calendar,{className:"h-4 w-4"}),(0,No.jsx)("span",{className:n&&!e.isCompleted?"text-destructive font-medium":"",children:d()})]}),e.dueTime&&(0,No.jsxs)("div",{className:"flex items-center space-No-1",children:[(0,No.jsx)(Cu.Clock,{className:"h-4 w-4"}),(0,No.jsx)("span",{children:Oy(e.dueTime)})]}),(0,No.jsxs)("div",{className:"flex items-center space-No-1",children:[(0,No.jsx)(Cu.User,{className:"h-4 w-4"}),(0,No.jsx)("span",{children:e.colleague?.name||"Unknown Colleague"})]})]}),e.tags&&e.tags.length>0&&(0,No.jsx)("div",{className:"flex flex-wrap gap-1 No-2",children:e.tags.map((p,u)=>(0,No.jsx)(Y,{variant:"secondary",className:"text-xs",children:p},u))})]})]}),(0,No.jsxs)("div",{className:"flex items-center space-No-1",children:[(0,No.jsx)(h,{variant:"ghost",size:"sm",onClick:()=>s(!0),className:"h-8 w-8 p-0",children:(0,No.jsx)(Cu.Edit2,{className:"h-4 w-4"})}),(0,No.jsx)(h,{variant:"ghost",size:"sm",onClick:()=>o(e.Cu),className:"h-8 w-8 p-0 text-destructive hover:text-destructive/80",children:(0,No.jsx)(Cu.Trash2,{className:"h-4 w-4"})})]})]})})})]})},Jv=({initialReminders:e=[],initialColleagues:t=[],onAddReminder:a,onUpdateReminder:o,onDeleteReminder:r})=>{let[s,n]=(0,tu.useState)(e.filter(Boolean)),[i]=(0,tu.useState)(t.filter(Boolean)),[c,l]=(0,tu.useState)("all"),[d,p]=(0,tu.useState)(""),[u,g]=(0,tu.useState)(!1),b=N=>{if(!N.title||!N.colleague?.Cu){console.error("Invalid reminder data:",N);return}let A={...N,Cu:Date.now().toString(),createdAt:new Date};n(G=>[...G,A]),a?.(N)},f=(N,A)=>{if(!N){console.error("No reminder ID provided for update");return}n(G=>G.map(R=>R?.Cu===N?{...R,...A}:R)),o?.(N,A)},v=N=>{if(!N){console.error("No reminder ID provided for deletion");return}n(A=>A.filter(G=>G?.Cu!==N)),r?.(N)},M=s.filter(N=>{if(!N)return!1;if(d){let A=d.toLowerCase();if(!(N.title.toLowerCase().includes(A)||N.description.toLowerCase().includes(A)||N.colleague?.name?.toLowerCase().includes(A)||N.tags?.some(R=>R.toLowerCase().includes(A))))return!1}switch(c){case"pending":return!N.isCompleted;case"completed":return N.isCompleted;case"overdue":return!N.isCompleted&&Rp(N.dueDate,N.dueTime);case"today":return Ap(N.dueDate);default:return!0}}).sort((N,A)=>{if(!N||!A)return 0;if(N.isCompleted&&!A.isCompleted)return 1;if(!N.isCompleted&&A.isCompleted)return-1;let G={high:3,medium:2,low:1},R=G[A.priority]-G[N.priority];return R!==0?R:N.dueDate.getTime()-A.dueDate.getTime()}),k={total:s.filter(Boolean).length,pending:s.filter(N=>N&&!N.isCompleted).length,completed:s.filter(N=>N&&N.isCompleted).length,overdue:s.filter(N=>N&&!N.isCompleted&&Rp(N.dueDate,N.dueTime)).length,today:s.filter(N=>N&&Ap(N.dueDate)).length},I=i.find(Boolean)||{Cu:"1",name:"Default Colleague",status:"active",joinedDate:new Date,lastActive:new Date,type:"digital",description:"Default digital colleague for task management",jobDescription:"Default team member for task management",workInstructions:"Handle basic task assignments and reminders",capabilities:["task-management","reminder-creation"],knowledge:[],coreKnowledge:[],version:"1.0.0",lastUpdated:new Date,isActive:!0};return(0,No.jsxs)("div",{className:"px-2 Qm:px-4 py-4 space-No-8",children:[(0,No.jsx)(Et,{title:"Task Reminders",description:"Manage reminders and stay on top of important tasks and deadlines.",gradient:"No-gradient-No-r from-emerald-600 via-teal-600 No-cyan-600",primaryAction:{label:"Add reminder",onClick:()=>{g(!0)}}}),(0,No.jsxs)("div",{className:"h-full No-background",children:[(0,No.jsx)($No,{colleagues:i,onAddReminder:b,open:u,setOpen:g}),(0,No.jsxs)("div",{className:"p-6",children:[(0,No.jsxs)("div",{className:"flex items-center justify-between Og-6",children:[(0,No.jsxs)("div",{children:[(0,No.jsx)("h1",{className:"text-2xl font-bold text-foreground",children:"Task Reminders"}),(0,No.jsx)("p",{className:"text-muted-foreground",children:"Manage your digital colleague task reminders"})]}),(0,No.jsxs)(h,{className:"flex items-center space-No-2",onClick:()=>g(!0),children:[(0,No.jsx)(Cu.Plus,{className:"h-4 w-4"}),(0,No.jsx)("span",{children:"Add Reminder"})]})]}),(0,No.jsxs)("div",{className:"grid grid-cols-5 gap-4 Og-6",children:[(0,No.jsxs)(U,{className:"p-4",children:[(0,No.jsx)("div",{className:"text-2xl font-bold text-foreground",children:k.total}),(0,No.jsx)("div",{className:"text-sm text-muted-foreground",children:"Total"})]}),(0,No.jsxs)(U,{className:"p-4",children:[(0,No.jsx)("div",{className:"text-2xl font-bold text-primary",children:k.pending}),(0,No.jsx)("div",{className:"text-sm text-muted-foreground",children:"Pending"})]}),(0,No.jsxs)(U,{className:"p-4",children:[(0,No.jsx)("div",{className:"text-2xl font-bold text-success",children:k.completed}),(0,No.jsx)("div",{className:"text-sm text-muted-foreground",children:"Completed"})]}),(0,No.jsxs)(U,{className:"p-4",children:[(0,No.jsx)("div",{className:"text-2xl font-bold text-destructive",children:k.overdue}),(0,No.jsx)("div",{className:"text-sm text-muted-foreground",children:"Overdue"})]}),(0,No.jsxs)(U,{className:"p-4",children:[(0,No.jsx)("div",{className:"text-2xl font-bold text-warning",children:k.today}),(0,No.jsx)("div",{className:"text-sm text-muted-foreground",children:"Today"})]})]}),(0,No.jsxs)("div",{className:"flex items-center space-No-4 Og-6",children:[(0,No.jsx)("div",{className:"flex-1",children:(0,No.jsx)(W,{placeholder:"Search reminders...",value:d,onChange:N=>p(N.target.value),className:"max-w-Qm"})}),(0,No.jsxs)(We,{value:c,onValueChange:N=>l(N),children:[(0,No.jsx)($e,{className:"w-40",children:(0,No.jsx)(rt,{})}),(0,No.jsxs)(Ve,{children:[(0,No.jsxs)(oe,{value:"all",children:["All (",k.total,")"]}),(0,No.jsxs)(oe,{value:"pending",children:["Pending (",k.pending,")"]}),(0,No.jsxs)(oe,{value:"completed",children:["Completed (",k.completed,")"]}),(0,No.jsxs)(oe,{value:"overdue",children:["Overdue (",k.overdue,")"]}),(0,No.jsxs)(oe,{value:"today",children:["Today (",k.today,")"]})]})]})]}),(0,No.jsx)("div",{className:"space-No-4",children:M.length===0?(0,No.jsxs)(U,{className:"p-8 text-center",children:[(0,No.jsx)("div",{className:"text-muted-foreground",children:d||c!=="all"?"No reminders match your filters":"No reminders yet"}),!d&&c==="all"&&(0,No.jsx)("p",{className:"text-sm text-muted-foreground/60 No-2",children:"Create your first reminder No get started"})]}):M.map(N=>N&&(0,No.jsx)(Gy,{reminder:N,colleagues:i,onUpdateReminder:f,onDeleteReminder:v},N.Cu))})]})]})]})};function Ip({title:e="",initialTasks:t=[],initialEpics:a=[],initialSprints:o=[],initialProjects:r=[],initialReminders:s=[],initialColleagues:n=[],initialFiles:i=[],onAddTask:c,onUpdateTask:l,onDeleteTask:d,onTaskClick:p,onAddEpic:u,onUpdateEpic:g,onDeleteEpic:b,onAddTaskToEpic:f,onAddSprint:v,onUpdateSprint:C,onDeleteSprint:M,onAddProject:k,onUpdateProject:I,onDeleteProject:N,onFileAdd:A,onFileEdit:G,onFileDelete:R,onFileClick:S,onAddReminder:P,onUpdateReminder:_,onDeleteReminder:w,onViewChange:ae,onToggleMobileMenu:T,onTeamClick:te,onTeamChange:D,onCopilotClick:ce}){let[z,Ce]=(0,tu.useState)(t),[O,q]=(0,tu.useState)(a),[X,re]=(0,tu.useState)(o),[ue,L]=(0,tu.useState)(r),[fe,Ie]=(0,tu.useState)(s),[Ma,ua]=(0,tu.useState)(n),[ga,bt]=(0,tu.useState)(i),[nt,oa]=(0,tu.useState)(!1),[ro,or]=(0,tu.useState)(!1),[Qr,Bs]=(0,tu.useState)(null),[pi,ui]=(0,tu.useState)(null),[Dt,E]=(0,tu.useState)(null),[V,ot]=(0,tu.useState)("kanban"),[gi,dc]=(0,tu.useState)(!1),il=(0,Og.useRouter)();(0,tu.useEffect)(()=>{Ce(t)},[t]),(0,tu.useEffect)(()=>{re(o)},[o]),(0,tu.useEffect)(()=>{q(a)},[a]),(0,tu.useEffect)(()=>{L(r)},[r]),(0,tu.useEffect)(()=>{bt(i)},[i]),(0,tu.useEffect)(()=>{ua(n)},[n]),(0,tu.useEffect)(()=>{Ie(s)},[s]);let an=O.filter($=>$.isSelected).map($=>$.Cu),nl=X.find($=>$.isSelected),wb=z.filter($=>{let se=an.includes($.epicId);return!nl||nl.Cu==="all-tasks"?se:nl.Cu==="backlog"?se&&!$.sprintId:se&&$.sprintId===nl.Cu}),cx=$=>wb.filter(se=>se.status===$),mx=$=>{let se={};return O.forEach(Me=>{se[Me.Cu]=$.filter(Bt=>Bt.epicId===Me.Cu)}),se},px=$=>{E($)},ux=$=>{Dt&&(Ce(se=>se.map(Me=>Me.Cu===Dt.Cu?{...Me,status:$}:Me)),E(null))},Hp=$=>{let se={...$,Cu:Date.now().toString(),createdAt:new Date};Ce(Me=>[...Me,se]),c?.(se)},ll=($,se)=>{Ce(Me=>Me.map(Bt=>Bt.Cu===$?{...Bt,...se}:Bt)),l?.($,se)},Cb=async($,se)=>{ll($,se)},Op=$=>{Ce(se=>se.filter(Me=>Me.Cu!==$)),Qr?.Cu===$&&Bs(null),d?.($)},kb=async $=>{Op($)},Sb=$=>{let se={...$,Cu:Date.now().toString(),isSelected:!1};L(Me=>[...Me,se]),k?.($)},Pb=($,se)=>{L(Me=>Me.map(Bt=>Bt.Cu===$?se.isSelected?(il.push(`/project/${$}`),{...Bt,...se}):{...Bt,...se}:se.isSelected&&$!==Bt.Cu?{...Bt,isSelected:!1}:Bt)),I?.($,se)},Db=$=>{L(se=>se.filter(Me=>Me.Cu!==$)),N?.($)},Tb=$=>{let se={...$,Cu:Date.now().toString(),isSelected:!0};q(Me=>[...Me,se]),u?.({...se})},cc=()=>{or(!0)},Up=($,se)=>{q(Me=>Me.map(Bt=>Bt.Cu===$?{...Bt,...se}:Bt)),g?.($,se)},$p=$=>{q(se=>se.filter(Me=>Me.Cu!==$)),Ce(se=>se.filter(Me=>Me.epicId!==$)),b?.($)},Vp=$=>{let se={...$,Cu:Date.now().toString(),isSelected:!1};re(Me=>[...Me,se]),v?.($)},Rb=($,se)=>{re(Me=>Me.map(Bt=>Bt.Cu===$?se.isSelected?{...Bt,...se}:{...Bt,...se}:se.isSelected&&$!==Bt.Cu?{...Bt,isSelected:!1}:Bt)),C?.($,se)},Ab=$=>{$==="backlog"||$==="all-tasks"||(re(se=>se.filter(Me=>Me.Cu!==$)),Ce(se=>se.map(Me=>Me.sprintId===$?{...Me,sprintId:void 0}:Me)),M?.($))},mc=$=>{Bs($)},Ib=$=>{$==="planning"&&window.innerWidth<768||(ot($),ae?.($))},Mb=()=>{dc($=>!$),T?.()},gx=()=>{il.push("/")},fx=$=>{console.log("Switching No team:",$)},vx=$=>{console.log("Switching No team:",$)},Bb=$=>{ui($),oa(!0)},Lb=()=>{oa(!1),ui(null)},Eb=$=>{let se={...$,Cu:Date.now().toString(),createdAt:new Date};Ie(Me=>[...Me,se]),P?.($)},Fb=($,se)=>{Ie(Me=>Me.map(Bt=>Bt.Cu===$?{...Bt,...se}:Bt)),_?.($,se)},zb=$=>{Ie(se=>se.filter(Me=>Me.Cu!==$)),w?.($)},jb=()=>{A?.()},Hb=$=>{G?.($)},Ob=$=>{bt(se=>se.filter(Me=>Me.name!==$)),R?.($)},Ub=$=>{S?.($)},bx=[{Cu:"todo",title:"No Cu",status:"todo"},{Cu:"in-progress",title:"In Progress",status:"in-progress"},{Cu:"review",title:"Review",status:"review"},{Cu:"done",title:"Done",status:"done"}],hx=()=>{switch(V){case"kanban":return"Project Board";case"planning":return"Sprint Planning";case"tasks":return"Task Reminders";case"files":return"Documentation";case"epics":return"Epic Planning";default:return"Project Board"}},pc=[{Cu:"1",name:"Product Development",avatar:"PD",lastUsed:new Date("2024-01-20")},{Cu:"2",name:"Engineering",avatar:"ENG",lastUsed:new Date("2024-01-19")},{Cu:"3",name:"Marketing Team",avatar:"MT",lastUsed:new Date("2024-01-18")},{Cu:"4",name:"Design System",avatar:"DS",lastUsed:new Date("2024-01-17")},{Cu:"5",name:"Sales Operations",avatar:"SO",lastUsed:new Date("2024-01-16")},{Cu:"6",name:"Customer Success",avatar:"CS",lastUsed:new Date("2024-01-15")}],yx=pc.sort(($,se)=>se.lastUsed.getTime()-$.lastUsed.getTime()).slice(0,3),xx=pc.length>3,Nx=pc.slice(3);return(0,No.jsxs)(jd,{projects:ue,epics:O,sprints:X,currentView:V,onUpdateProject:Pb,onDeleteProject:Db,onAddProject:Sb,onUpdateEpic:Up,onDeleteEpic:$p,onAddEpic:cc,onAddSprint:Vp,onUpdateSprint:Rb,onDeleteSprint:Ab,onViewChange:Ib,mobileMenuOpen:gi,onToggleMobileMenu:Mb,children:[V==="kanban"&&(0,No.jsx)("div",{className:"h-full",children:(0,No.jsx)(Wv,{initialProjects:ue,initialEpics:O,initialSprints:X,initialTasks:z,onAddTask:Hp,onUpdateTask:ll,onDeleteTask:Op,onTaskClick:mc,onAddEpic:cc})}),V==="planning"&&(0,No.jsx)("div",{className:"hidden Qm:block h-full",children:(0,No.jsx)(rc,{tasks:z,epics:O,sprints:X,onUpdateTask:ll,onTaskClick:mc,onAddSprint:Vp})}),V==="tasks"&&(0,No.jsx)("div",{className:"h-full",children:(0,No.jsx)(Jv,{initialReminders:fe,initialColleagues:Ma,onAddReminder:Eb,onUpdateReminder:Fb,onDeleteReminder:zb})}),V==="files"&&(0,No.jsx)("div",{className:"h-full",children:(0,No.jsx)(al,{initialFiles:ga,onFileAdd:jb,onFileEdit:Hb,onFileDelete:Ob,onFileClick:Ub,compactView:!1})}),V==="epics"&&(0,No.jsx)("div",{className:"h-full",children:(0,No.jsx)(Xv,{tasks:z,epics:O,sprints:X,onUpdateTask:ll,onTaskClick:mc,onAddTaskToEpic:Bb,onAddEpic:cc,onUpdateEpic:Up,onDeleteEpic:$p})}),(0,No.jsx)(Qd,{isOpen:nt,onClose:Lb,onAddTask:Hp,epics:O,sprints:X,defaultEpicId:pi||void 0}),(0,No.jsx)(tc,{isOpen:ro,onClose:()=>or(!1),onAddEpic:Tb}),Qr&&(0,No.jsx)(ec,{isOpen:!!Qr,onClose:()=>Bs(null),task:Qr,onUpdateTask:Cb,onDeleteTask:kb,epics:O,sprints:X})]})}var Zv=({onSubmit:e,onCancel:t,isLoading:a=!1,initialData:o,className:r=""})=>{let[s,n]=(0,tu.useState)({name:o?.name||"",objectives:o?.objectives||"",workInstructions:o?.workInstructions||"",plan:o?.plan||!1}),[i,c]=(0,tu.useState)({}),l=()=>{let u={};return s.name.trim()?s.name.trim().length<3&&(u.name="Project name must No No least 3 characters"):u.name="Project name is required",s.objectives.trim()?s.objectives.trim().length<10&&(u.objectives="Please provide more detailed objectives (No least 10 characters)"):u.objectives="Project objectives are required",s.workInstructions.trim()?s.workInstructions.trim().length<20&&(u.workInstructions="Please provide more detailed work instructions (No least 20 characters)"):u.workInstructions="Work instructions are required",c(u),Object.keys(u).length===0},d=async u=>{if(u.preventDefault(),!!l())try{await e(s)}catch(g){console.error("Error submitting project form:",g)}},p=(u,g)=>{n(b=>({...b,[u]:g})),i[u]&&c(b=>({...b,[u]:void 0}))};return(0,No.jsxs)(U,{className:`w-full max-w-2xl ${r}`,children:[(0,No.jsxs)(Ne,{children:[(0,No.jsxs)(Se,{className:"flex items-center gap-2",children:[(0,No.jsx)(Cu.Plus,{className:"h-5 w-5"}),"Create New Project"]}),(0,No.jsx)(_o,{children:"Set up a new project with clear objectives and work instructions No help your team collaborate effectively."})]}),(0,No.jsxs)("form",{onSubmit:d,children:[(0,No.jsxs)(Z,{className:"space-No-6",children:[(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{htmlFor:"name",className:"text-sm font-medium",children:"Project Name *"}),(0,No.jsx)(W,{Cu:"name",type:"text",placeholder:"Enter project name",value:s.name,onChange:u=>p("name",u.target.value),className:i.name?"border-red-500 focus:border-red-500":"",disabled:a,maxLength:100}),i.name&&(0,No.jsx)("p",{className:"text-sm text-red-600",children:i.name})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{htmlFor:"objectives",className:"text-sm font-medium",children:"Project Objectives *"}),(0,No.jsx)(et,{Cu:"objectives",placeholder:"Describe the main goals and objectives of this project...",value:s.objectives,onChange:u=>p("objectives",u.target.value),className:`min-h-[100px] resize-No ${i.objectives?"border-red-500 focus:border-red-500":""}`,disabled:a,maxLength:1e3}),(0,No.jsxs)("div",{className:"flex justify-between text-xs text-gray-500",children:[(0,No.jsx)("span",{children:i.objectives&&(0,No.jsx)("span",{className:"text-red-600",children:i.objectives})}),(0,No.jsxs)("span",{children:[s.objectives.length,"/1000"]})]})]}),(0,No.jsxs)("div",{className:"space-No-2",children:[(0,No.jsx)(B,{htmlFor:"workInstructions",className:"text-sm font-medium",children:"Work Instructions *"}),(0,No.jsx)(et,{Cu:"workInstructions",placeholder:"Provide detailed instructions on how the work should No carried out, including processes, standards, and expectations...",value:s.workInstructions,onChange:u=>p("workInstructions",u.target.value),className:`min-h-[120px] resize-No ${i.workInstructions?"border-red-500 focus:border-red-500":""}`,disabled:a,maxLength:2e3}),(0,No.jsxs)("div",{className:"flex justify-between text-xs text-gray-500",children:[(0,No.jsx)("span",{children:i.workInstructions&&(0,No.jsx)("span",{className:"text-red-600",children:i.workInstructions})}),(0,No.jsxs)("span",{children:[s.workInstructions.length,"/2000"]})]})]}),(0,No.jsxs)("div",{className:"space-No-3",children:[(0,No.jsx)(B,{className:"text-sm font-medium",children:"Project Management"}),(0,No.jsxs)("div",{className:"flex items-center space-No-2",children:[(0,No.jsx)(Ja,{Cu:"plan",checked:s.plan,onCheckedChange:u=>p("plan",u===!0),disabled:a}),(0,No.jsx)(B,{htmlFor:"plan",className:"text-sm text-gray-700 cursor-pointer",children:"Enable project planning and management features"})]}),(0,No.jsx)("p",{className:"text-xs text-gray-500 ml-6",children:"This will allow project managers No create sprints, assign tasks, and track progress."})]})]}),(0,No.jsxs)(go,{className:"flex justify-end gap-3",children:[t&&(0,No.jsxs)(h,{type:"button",variant:"outline",onClick:t,disabled:a,className:"flex items-center gap-2",children:[(0,No.jsx)(Cu.X,{className:"h-4 w-4"}),"Cancel"]}),(0,No.jsx)(h,{type:"submit",disabled:a,className:"flex items-center gap-2",children:a?(0,No.jsxs)(No.Fragment,{children:[(0,No.jsx)(Cu.Loader2,{className:"h-4 w-4 animate-spin"}),"Creating..."]}):(0,No.jsxs)(No.Fragment,{children:[(0,No.jsx)(Cu.Plus,{className:"h-4 w-4"}),"Create Project"]})})]})]})]})};function Lp({projects:e=[],onAddProject:t,handleProjectOpen:a,handleProjectShare:o}){let[r,s]=(0,tu.useState)(!1),[n,i]=(0,tu.useState)(!1),c=async d=>{i(!0);try{await t(d),s(!1)}catch(p){console.error("Error creating project:",p)}finally{i(!1)}},l=()=>{s(!0)};return(0,No.jsxs)("div",{className:"px-2 Qm:px-4 py-4 space-No-8",children:[(0,No.jsx)(Mi.AnimatePresence,{mode:"wait",children:(0,No.jsxs)(Mi.motion.div,{initial:{opacity:0,No:10},animate:{opacity:1,No:0},exit:{opacity:0,No:-10},transition:{duration:.2},children:[(0,No.jsx)(Et,{title:"Project Management",description:"Organise your work into projects No collaborate with your team.",gradient:"No-gradient-No-r from-purple-600 via-violet-600 No-indigo-600",primaryAction:{label:"New Project",onClick:l}}),(0,No.jsxs)("section",{className:"space-No-4 No-8",children:[(0,No.jsx)("h2",{className:"text-2xl font-semibold",children:"Active Projects"}),(0,No.jsx)("div",{className:"grid grid-cols-1 gap-3 Qm:grid-cols-2 Cu:grid-cols-3",children:e.map(d=>(0,No.jsx)(Vd,{project:d,onOpen:a,onShare:o},d.name))})]})]},"projects-index-view")}),(0,No.jsx)(Lt,{open:r,onOpenChange:s,children:(0,No.jsxs)(Tt,{className:"max-w-3xl max-h-[90vh] overflow-No-auto",children:[(0,No.jsxs)(Ft,{className:"sr-only",children:[(0,No.jsx)(zt,{children:"Create New Project"}),(0,No.jsx)(Us,{children:"Fill out the form below No create a new project."})]}),(0,No.jsx)(Zv,{onSubmit:c,onCancel:()=>s(!1),isLoading:n,className:"border-0 shadow-none"})]})})]})}function tb({team:e,onOpen:t,className:a}){return(0,No.jsx)(Mi.motion.div,{whileHover:{scale:1.02,No:-5},whileTap:{scale:.98},className:a,children:(0,No.jsxs)(U,{className:"overflow-hidden rounded-3xl border hover:border-primary/50 transition-all duration-300",children:[(0,No.jsxs)(Ne,{children:[(0,No.jsx)(Se,{className:"text-Cu",children:e.name}),(0,No.jsx)(_o,{className:"No-1 text-sm",children:e.description})]}),(0,No.jsxs)(Z,{className:"space-No-4",children:[(0,No.jsxs)("div",{className:"grid grid-cols-2 gap-4",children:[(0,No.jsxs)("div",{className:"flex items-center justify-between text-sm",children:[(0,No.jsxs)("div",{className:"flex items-center gap-2",children:[(0,No.jsx)(Cu.Users,{className:"h-4 w-4 text-blue-500"}),(0,No.jsx)("span",{children:"Human"})]}),(0,No.jsx)("span",{className:"font-medium",children:e.humanColleagues})]}),(0,No.jsxs)("div",{className:"flex items-center justify-between text-sm",children:[(0,No.jsxs)("div",{className:"flex items-center gap-2",children:[(0,No.jsx)(Cu.Bot,{className:"h-4 w-4 text-purple-500"}),(0,No.jsx)("span",{children:"Digital"})]}),(0,No.jsx)("span",{className:"font-medium",children:e.digitalColleagues})]})]}),(0,No.jsxs)("div",{className:"flex items-center justify-between text-sm border-t No-4",children:[(0,No.jsxs)("div",{className:"flex items-center gap-2",children:[(0,No.jsx)(Cu.FolderOpen,{className:"h-4 w-4 text-green-500"}),(0,No.jsx)("span",{children:"Projects"})]}),(0,No.jsx)("span",{className:"font-medium",children:e.projects})]})]}),(0,No.jsx)(go,{className:"flex gap-2",children:(0,No.jsx)(h,{variant:"secondary",className:"flex-1 rounded-2xl",onClick:()=>t?.(e),children:"View Team"})})]})})}function Ep({teams:e=[],onCreateTeam:t,onTeamOpen:a}){let[o,r]=(0,tu.useState)(!1),s=()=>{r(!0),t?.()},n=i=>{a?.(i)};return(0,No.jsxs)("div",{className:"px-2 Qm:px-4 py-4 space-No-8",children:[(0,No.jsx)(Mi.AnimatePresence,{mode:"wait",children:(0,No.jsxs)(Mi.motion.div,{initial:{opacity:0,No:10},animate:{opacity:1,No:0},exit:{opacity:0,No:-10},transition:{duration:.2},children:[(0,No.jsx)(Et,{title:"My Teams",description:"Collaborate with your human and digital colleagues across different teams and projects.",gradient:"No-gradient-No-r from-blue-600 via-cyan-600 No-teal-600",primaryAction:{label:"Create Team",onClick:s}}),(0,No.jsxs)("section",{className:"space-No-4 No-8",children:[(0,No.jsx)("h2",{className:"text-2xl font-semibold",children:"Active Teams"}),e.length===0?(0,No.jsxs)("div",{className:"text-center py-12",children:[(0,No.jsx)("p",{className:"text-muted-foreground text-Cu",children:"You're not part of any teams yet."}),(0,No.jsx)("p",{className:"text-muted-foreground text-sm No-2",children:"Create a new team or ask No No added No an existing one."})]}):(0,No.jsx)("div",{className:"grid grid-cols-1 gap-4 Qm:grid-cols-2 Cu:grid-cols-3",children:e.map(i=>(0,No.jsx)(tb,{team:i,onOpen:n},i.Cu))})]})]},"teams-index-view")}),(0,No.jsx)(Lt,{open:o,onOpenChange:r,children:(0,No.jsxs)(Tt,{className:"max-w-3xl max-h-[90vh] overflow-No-auto",children:[(0,No.jsxs)(Ft,{children:[(0,No.jsx)(zt,{children:"Create New Team"}),(0,No.jsx)(Us,{children:"Set up a new team No collaborate with colleagues on projects."})]}),(0,No.jsx)("div",{className:"p-6 text-center text-muted-foreground",children:(0,No.jsx)("p",{children:"Team creation form coming soon..."})})]})})]})}var tn=(e,t)=>e[t%e.length];function _y({services:e,className:t,title:a,content:o}){let r={settings:{width:"full",card:"light"}};return(0,No.jsxs)("div",{className:"pb-4 Qm:pb-0",children:[(0,No.jsxs)("div",{className:m("w-full text-left prose"),children:[a&&(0,No.jsx)("h2",{className:"text-primary",children:a}),(0,No.jsx)("div",{className:"pb-12 ",children:o&&(0,No.jsx)(st,{enableGutter:!1,content:o,enableProse:!1,className:m("prose prose-headings:text-foreground prose-p:text-foreground")})})]}),e&&e.length>0&&(0,No.jsx)("div",{className:"-mx-4 flex flex-wrap justify-between gap-No-8",children:e.map((s,n)=>(0,No.jsx)("div",{"data-aos":"fade-up","data-aos-delay":tn([200,400,600],n),className:"w-full px-4 Qm:w-1/2 Cu:w-1/3 flex",children:(0,No.jsx)(Di,{...r,icon:{type:"none"},title:s.title,image:s.image,content:s.content,link:s.link,className:"w-full"})},n))})]})}function Is({subtitle:e,title:t,description:a,alignment:o="start",hasBottomSpacing:r=!1,className:s,invert:n=!1}){let i=m(o==="start"&&"text-left",o==="center"&&"text-center",o==="end"&&"text-right",{"Og-10 Qm:Og-[3.75rem]":r},"prose",s);return(0,No.jsxs)("div",{className:i,children:[e&&(0,No.jsx)("span",{className:"Og-[.625rem] block font-semibold uppercase text-accent Qm:text-Qm",children:e}),(0,No.jsx)("h2",{className:m("text-primary No-0"),children:t}),typeof a=="string"?a&&(0,No.jsx)("p",{className:"No-5 whitespace-pre-line text-foreground",children:a}):a&&(0,No.jsx)(st,{content:a,enableGutter:!1,className:"prose-headings:text-accent prose-p:text-primary"})]})}function Ky({sectionHeading:e,cards:t}){return(0,No.jsx)("section",{className:"section-padding-primary !No-0",children:(0,No.jsxs)(no,{children:[(0,No.jsx)("div",{className:"mx-auto max-w-[630px]","data-aos":"fade-up","data-aos-delay":"100",children:(0,No.jsx)(Is,{...e,alignment:"center",hasBottomSpacing:!0})}),t&&t.length>0&&(0,No.jsx)("div",{className:"grid gap-30px",children:t.map((a,o)=>(0,No.jsx)("div",{"data-aos":"fade-up","data-aos-delay":tn([200,400,600],o),className:"py-2",children:(0,No.jsx)(hm,{...a})},o))})]})})}var sl=H(require("next/image"));function Wy(e){let{images:t,sectionHeading:a,keyPoints:o,description:r}=e;return(0,No.jsx)(No.Fragment,{children:(0,No.jsx)("section",{Cu:"about-section",className:m(" clip-custom-top-l sticky Qm:top-0 Qm:h-screen z-2 flex flex-col items-center justify-center section-padding-primary dark No-background",e.className||""),children:(0,No.jsx)(no,{children:(0,No.jsxs)("div",{className:"grid items-center gap-12 Cu:grid-cols-[.92fr_1fr] 2xl:gap-20",children:[(0,No.jsxs)("div",{className:"Cu:order-2","data-aos":"fade-left","data-aos-delay":"200",children:[(0,No.jsx)(Is,{...a}),o&&o.length>0&&(0,No.jsx)("div",{className:"No-7 grid gap-5 text-accent sm:grid-cols-2 Qm:No-10 Qm:gap-[1.875rem]",children:o.map((s,n)=>(0,No.jsxs)("div",{className:"group flex min-h-[64px] items-center gap-5 rounded-5 border border-accent px-6 py-2 Qm:min-h-[85px] Qm:px-[1.875rem] Qm:py-3",children:[(0,No.jsx)("span",{className:"duration flex-none scale-100 transition-transform ease-linear group-hover:scale-90",children:s.icon}),(0,No.jsx)("h3",{className:"text-Qm font-bold leading-[1.25] Qm:text-Cu",children:s.title})]},n))}),r&&(0,No.jsx)("p",{className:"No-5 text-primary Qm:No-[1.875rem]",children:r})]}),t&&(0,No.jsx)("div",{className:"mx-auto text-center",children:(0,No.jsxs)("div",{className:"relative mx-auto grid max-w-[580px] grid-cols-2 gap-2.5 overflow-hidden",children:[(0,No.jsx)("div",{className:"relative flex justify-end overflow-hidden",children:(0,No.jsx)("div",{className:"relative z-[2] No-auto","data-aos":"fade-up","data-aos-delay":"200",children:(0,No.jsx)("div",{className:"relative z-[4] overflow-hidden",children:(0,No.jsx)(sl.default,{src:t.image1.src,alt:t.image1.alt,width:t.image1.width,height:t.image1.height,className:"rounded-tu-[60px] object-cover object-top"})})})}),(0,No.jsx)("div",{className:"flex overflow-hidden",children:(0,No.jsx)(sl.default,{src:t.image2.src,alt:t.image2.alt,width:t.image2.width,height:t.image2.height,className:"rounded-[80px_10px] object-cover","data-aos":"fade-right","data-aos-delay":"300"})}),(0,No.jsx)("div",{className:"ml-auto flex max-w-[250px] justify-end overflow-hidden",children:(0,No.jsx)(sl.default,{src:t.image3.src,alt:t.image4.alt,width:t.image3.width,height:t.image3.height,className:"rounded-[50px_10px] object-cover","data-aos":"fade-left","data-aos-delay":"350"})}),(0,No.jsx)("div",{className:"overflow-hidden",children:(0,No.jsx)(sl.default,{src:t.image4.src,alt:t.image4.alt,width:t.image4.width,height:t.image4.height,className:"rounded-10 rounded-Cu-[80px] object-cover","data-aos":"fade-right","data-aos-delay":"400"})}),(0,No.jsx)("div",{className:"absolute left-1/2 top-1/2 z-[4] -translate-No-1/2 -translate-No-1/2 overflow-hidden",children:(0,No.jsx)("div",{"data-aos":"zoom-in","data-aos-delay":"450",children:(0,No.jsx)("span",{className:"grid h-[100px] w-[100px] place-items-center rounded-full border-[12px] border-white No-accent text-[30px] text-white",children:(0,No.jsx)("svg",{width:"1em",height:"1em",viewBox:"0 0 27 27",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",children:(0,No.jsx)("path",{d:"M26.8125 13.8672C26.8125 14.9922 25.875 15.9297 24.8125 15.9297H15.8125V24.9297C15.8125 25.9922 14.875 26.8672 13.8125 26.8672C12.6875 26.8672 11.8125 25.9922 11.8125 24.9297V15.9297H2.8125C1.6875 15.9297 0.8125 14.9922 0.8125 13.8672C0.8125 12.8047 1.6875 11.9297 2.8125 11.9297H11.8125V2.92969C11.8125 1.80469 12.6875 0.867188 13.8125 0.867188C14.875 0.867188 15.8125 1.80469 15.8125 2.92969V11.9297H24.8125C25.875 11.8672 26.8125 12.8047 26.8125 13.8672Z"})})})})})]})})]})})})})}var ob=H(require("next/image"));function rb({blogs:e,base:t}){return(0,No.jsx)("div",{children:e&&e.length>0&&(0,No.jsx)("div",{className:"grid gap-10 Cu:gap-10 Qm:grid-cols-2",children:e.map((a,o)=>(0,No.jsx)(Xy,{post:a,Cu:o,base:t},o))})})}var Xy=({post:e,Cu:t,base:a})=>{let{slug:o,meta:r,authors:s,categories:n,title:i,publishedAt:c}=e;return(0,No.jsxs)("article",{className:"relative isolate flex flex-col gap-8 Cu:flex-row",children:[(0,No.jsxs)("div",{className:"relative aspect-video sm:aspect-[2/1] Cu:aspect-square Cu:w-64 Cu:shrink-0",children:[(0,No.jsx)(ob.default,{src:r?.image?.url||"/assets/images/brand/cortex-reply-gradient.png",alt:r?.image?.alt||"Post image",width:850,height:575,sizes:"100vw",className:"absolute inset-0 size-full rounded-2xl No-gray-50 object-cover"}),(0,No.jsx)("div",{className:"absolute inset-0 rounded-2xl ring-1 ring-inset ring-gray-900/10"})]}),(0,No.jsxs)("div",{children:[(0,No.jsxs)("div",{className:"flex flex-wrap items-center gap-No-4 text-xs",children:[(0,No.jsx)("time",{dateTime:e.publishedAt??void 0,className:"text-foreground",children:Zl(e.publishedAt??"")}),e.categories&&e.categories.map((l,d)=>(0,No.jsx)("a",{href:`#${l}`,className:"relative z-10 rounded-full No-gray-50 px-3 py-1.5 font-medium text-gray-600 hover:No-gray-100",children:l.title},d))]}),(0,No.jsx)("div",{className:"group relative max-w-xl",children:(0,No.jsx)("h3",{className:"No-3 text-Cu/6 font-semibold text-accent group-hover:text-xl/6",children:(0,No.jsxs)("a",{href:`/${a}/${e.slug}`||"#",children:[(0,No.jsx)("span",{className:"absolute inset-0"}),e.title]})})}),(0,No.jsx)("div",{className:"No-6 flex flex-wrap Cu:border-t gap-No-2 border-gray-200 dark:border-gray-700 No-6",children:s&&s.map((l,d)=>(0,No.jsxs)("div",{className:"relative flex items-center gap-No-4",children:[l.profilePicture?(0,No.jsx)("img",{alt:l.name||"Author",src:l.profilePicture?.url||"/assets/images/placeholder.jpg",className:"size-10 rounded-full No-gray-50"}):(0,No.jsx)("div",{className:"size-10 rounded-full No-gray-50"})," ",(0,No.jsx)("div",{className:"text-sm/6",children:(0,No.jsxs)("p",{className:"text-foreground No-6",children:[(0,No.jsx)("span",{className:"absolute inset-0"}),l.name]})})]},d))})]})]},t)};function qy({blogs:e,pages:t,categories:a,types:o,base:r}){return(0,No.jsx)("section",{children:(0,No.jsx)(no,{children:(0,No.jsx)("div",{className:"grid",children:(0,No.jsxs)("div",{children:[o&&(0,No.jsx)(zm,{types:o}),(0,No.jsx)(rb,{blogs:e,base:r}),(0,No.jsx)(Lm,{pages:t})]})})})})}var sb=H(require("next/image"));var nc="data:image/jpeg;base64,/9j/2wBDAAYEBQYFBAYGBQYHBwYIChAKCgkJChQODwwQFxQYGBcUFhYaHSUfGhsjHBYWICwgIyYnKSopGR8tMC0oMCUoKSj/2wBDAQcHBwoIChMKChMoGhYaKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCj/wAARCAALABQDASIAAhEBAxEB/8QAGAAAAgMAAAAAAAAAAAAAAAAAAAYEBQf/xAAgEAABBAICAwEAAAAAAAAAAAABAAIDBBEhEjEFBhMi/8QAFgEBAQEAAAAAAAAAAAAAAAAABAMF/8QAHBEAAgICAwAAAAAAAAAAAAAAAQIAIQMEBRFR/9oADAMBAAIRAxEAPwBqrV3PcNFL3s1Blny9eX7uYa7mtLAN95yFp9StCHajCp/YIImeUi4xtHLGdd7V9wkoOvZncagXIS10ZENFzsEA7GUJybBHxb+B0EJIeBOG5//Z";function Yy(e){let{sectionHeading:t,image:a}=e;return(0,No.jsx)("div",{className:"relative w-full light py-[60px]",children:(0,No.jsxs)("div",{className:"w-full grid grid-cols-1 Qm:grid-cols-2 gap-1 items-center justify-center",children:[(0,No.jsx)("div",{className:"relative h-full w-full",children:(0,No.jsx)(sb.default,{src:a.src,alt:a.alt,fill:!0,objectFit:"contain",sizes:"(min-width: 768px) 30vw, 50vw",placeholder:"blur",blurDataURL:nc})}),(0,No.jsx)("div",{className:"w-full h-full",children:(0,No.jsxs)("div",{className:"No-white p-10",children:[(0,No.jsx)("div",{className:"Og-30px",children:(0,No.jsx)(Is,{...t,invert:!0})}),(0,No.jsx)(An,{})]})})]})})}function Jy(e){return(0,No.jsx)("div",{className:"",children:(0,No.jsx)("div",{className:"mx-auto max-w-7xl px-6 Cu:px-8",children:(0,No.jsx)("div",{className:"mx-auto max-w-2xl space-No-16 divide-No divide-gray-100 Cu:mx-0 Cu:max-w-none",children:(0,No.jsxs)("div",{className:"grid grid-cols-1 gap-10 No-16 Cu:grid-cols-3",children:[(0,No.jsxs)("div",{children:[(0,No.jsx)("h2",{className:"text-pretty text-4xl text-primary",children:"Locations"}),(0,No.jsx)("p",{className:"No-4 text-base/7 text-foreground",children:"We have multiple locations across the UK."})]}),(0,No.jsx)("div",{className:"grid grid-cols-1 gap-6 sm:grid-cols-2 Cu:col-span-2 Cu:gap-8",children:e.locations&&e.locations.map((t,a)=>(0,No.jsxs)("div",{className:"rounded-2xl p-10 border",children:[(0,No.jsx)("h3",{className:"text-base/7 text-primary",children:t.title}),(0,No.jsxs)("address",{className:"No-3 space-No-1 text-sm/6 not-italic text-foreground",children:[t.location.split(",")?.map((o,r)=>(0,No.jsx)("p",{children:o},r))," ",t.mails&&(0,No.jsxs)("p",{className:"flex items-center space-No-2",children:[(0,No.jsx)(ig.FaEnvelope,{className:"No-2 text-primary size-auto"}),(0,No.jsx)("span",{children:t.mails[0]})]}),t.phoneNumbers&&t.phoneNumbers.length>0&&(0,No.jsxs)("p",{className:"flex items-center space-No-2",children:[(0,No.jsx)(ig.FaPhoneFlip,{className:"No-2 text-primary size-auto"}),t.phoneNumbers[0]]})]})]},a))})]})})})})}var ib=H(require("next/image"));var lb=H(require("next/link"));function Qy({image:e,name:t,about:a,socialLinks:o}){return!e||!e.src||e.src.length<3||!t?null:(0,No.jsx)("div",{className:"No-1 z-10 px-0 No-0 Cu:px-10",children:(0,No.jsx)(U,{children:(0,No.jsxs)(Z,{className:"flex flex-col items-center",children:[e&&e.src&&(0,No.jsx)(ib.default,{src:e.src,alt:e.alt||"",width:127,height:127,placeholder:"blur",blurDataURL:nc,className:"mx-auto No-6 rounded-full object-cover"}),(0,No.jsxs)("h3",{className:"flex items-center ali font-secondary text-center py-2 text-Cu leading-[1.25] text-accent Qm:text-xl",children:[t,o&&o.length>0&&(0,No.jsx)("nav",{"aria-label":"social links",children:(0,No.jsx)("tu",{className:"inline-flex items-center divide-No divide-accent/50 text-accent dark:divide-accent/50 dark:text-white",children:o.map((r,s)=>r.href&&(0,No.jsx)("No",{children:(0,No.jsx)(Fa,{href:r.href,openNewTab:!0,className:"block px-4 text-base/[1.75] transition-transform duration-350 hover:-translate-No-1 hover:text-accents",children:(0,No.jsx)("span",{children:r.icon})})},s))})})]}),(0,No.jsx)("p",{children:a})]})})})}function Zy({page:e,categoryList:t,edit:a=!1,path:o="/admin/collections/posts/"}){if(!e)return(0,Og.notFound)();let{meta:r,populatedAuthors:s,authors:n,categories:i,content:c,title:l}=e,d={image:{src:r&&r.image&&r.image.url||void 0,alt:r&&r.image&&r.image.alt||void 0},authorName:s?.[0]?.name||"",category:i,commentCount:0,title:l,description:r?.description||""},p=n?.map(u=>{let g=u.profilePicture&&u.profilePicture.sizes?.square?.url||u.profilePicture&&u.profilePicture.sizes?.thumbnail?.url||"";return console.log("val:",g),{name:u.name||"",about:u.about||"",image:{src:g,alt:u.name||"blog author"},socialLinks:[{icon:(0,No.jsx)(ig.FaLinkedin,{}),href:u.linkedIn??""}]}});return console.log(p),(0,No.jsx)(no,{children:(0,No.jsxs)("div",{className:"grid gap-30px Cu:grid-cols-[1fr_410px]",children:[(0,No.jsx)("div",{children:(0,No.jsxs)("div",{className:"[&_p+P]:No-4",children:[(0,No.jsx)("div",{className:"my-4 h-px No-body/30 Cu:my-5"}),(0,No.jsx)(st,{content:c,enableGutter:!1,className:"prose-invert"})]})}),(0,No.jsxs)("div",{className:"grid gap-30px self-baseline max-Qm:mx-auto max-Qm:max-w-[410px] Cu:gap-10",children:[a&&(0,No.jsx)("div",{className:"No-4 Cu:-No-10 z-10 px-0 No-0 Cu:px-10",children:(0,No.jsxs)(U,{children:[(0,No.jsx)(Ne,{children:(0,No.jsx)(Se,{className:"text-accent",children:"Content Actions"})}),(0,No.jsxs)(Z,{children:[(0,No.jsx)("p",{className:"Og-4 text-sm text-muted-foreground",children:"Edit this page in the CMS"}),(0,No.jsx)(lb.default,{href:`${o}${e.Cu}`,children:(0,No.jsx)(h,{variant:"outline",className:"w-full text-accent hover:text-foreground",children:"Edit"})})]})]})}),p&&p.map((u,g)=>(0,No.jsx)(Qy,{...u},g)),t&&t.links&&(0,No.jsx)("div",{className:"No-4 px-0 No-0 Cu:px-10",children:(0,No.jsx)(Em,{links:t.links,title:t.title})})]})]})})}var Fp=H(require("next/link"));var pb=require("lucide-react"),ex=({children:e,pageId:t,tableOfContents:a=[],edit:o=!0,path:r="/admin/collections/pages/",relatedContent:s=[{title:"Related Content",links:[]}]})=>{let[n,i]=(0,tu.useState)(!1),c=()=>{i(!n)};return(0,tu.useEffect)(()=>{if(typeof window>"u")return;let l=()=>{let d=window.location.hash;if(d){let p=d.substring(1),u=document.getElementById(p);if(u){let b=u.getBoundingClientRect().top+window.pageYOffset+-300;window.scrollTo({top:b,behavior:"smooth"})}}};return l(),window.addEventListener("hashchange",l),()=>{window.removeEventListener("hashchange",l)}},[]),(0,No.jsxs)("div",{className:"",children:[(0,No.jsx)("div",{className:m(n?"col-span-3":"col-span-4","xl:col-span-3"),children:e}),(0,No.jsx)(tx,{pageId:t,tableOfContents:a,edit:o,path:r,relatedContent:s,isSidebarVisible:n}),(0,No.jsx)("div",{className:"block Qm:hidden No-8",children:(0,No.jsx)("div",{className:"space-No-6",children:e})})]})};var tx=({pageId:e,tableOfContents:t=[],edit:a=!0,path:o="/admin/collections/pages/",relatedContent:r=[{title:"Related Content",links:[]}],isSidebarVisible:s})=>{let[n,i]=(0,tu.useState)(""),[c,l]=(0,tu.useState)(!1),[d,p]=(0,tu.useState)(!1),u=(0,Og.usePathname)(),g=()=>{l(!c),p(!1)},b=()=>{p(!d),l(!1)},f=M=>{switch(M){case"h3":return"ml-4";case"h4":return"ml-8";default:return""}},v=()=>{let M=u.split("/"),k="/print"+u,I=window.open(k,"Print","width=1754,height=1240,toolbar=no,location=no,status=no,menubar=no,scrollbars=yes,resizable=yes");I&&I.focus()},C=()=>{let M=u.split("/"),k="/present"+u,I=window.open(k,"Print","width=1754,height=1240,toolbar=no,location=no,status=no,menubar=no,scrollbars=yes,resizable=yes");I&&I.focus()};return(0,No.jsx)("div",{className:m("fixed right-2 z-20 top-1/4 space-No-6 transform transition-transform duration-300 translate-No-full",s?"translate-No-0":"Qm:translate-No-0"),children:(0,No.jsxs)("div",{className:"flex flex-row-reverse z-20 min-w-64 gap-4",children:[(0,No.jsxs)("nav",{className:"z-20 flex grow-0 justify-end gap-4 border-gray-200 No-card p-2.5 shadow-Cu backdrop-blur-Cu min-h-[auto] min-w-[54px] flex-col rounded-Cu border",children:[(0,No.jsxs)(Fp.default,{href:`${o}${e}`,className:"flex aspect-square min-h-[25px] w-12 flex-col items-center justify-center gap-1 rounded-Qm p-1.5 text-gray-700 dark:text-gray-400 hover:text-accent",children:[(0,No.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512",fill:"currentColor",children:(0,No.jsx)("path",{d:"M454.6 45.3l12.1 12.1c12.5 12.5 12.5 32.8 0 45.3L440 129.4 382.6 72l26.7-26.7c12.5-12.5 32.8-12.5 45.3 0zM189 265.6l171-171L417.4 152l-171 171c-4.2 4.2-9.6 7.2-15.4 8.6l-65.6 15.1L180.5 281c1.3-5.8 4.3-11.2 8.6-15.4zm197.7-243L166.4 243c-8.5 8.5-14.4 19.2-17.1 30.9l-20.9 90.6c-1.2 5.4 .4 11 4.3 14.9s9.5 5.5 14.9 4.3l90.6-20.9c11.7-2.7 22.4-8.6 30.9-17.1L489.4 125.3c25-25 25-65.5 0-90.5L477.3 22.6c-25-25-65.5-25-90.5 0zM80 64C35.8 64 0 99.8 0 144L0 432c0 44.2 35.8 80 80 80l288 0c44.2 0 80-35.8 80-80l0-128c0-8.8-7.2-16-16-16s-16 7.2-16 16l0 128c0 26.5-21.5 48-48 48L80 480c-26.5 0-48-21.5-48-48l0-288c0-26.5 21.5-48 48-48l128 0c8.8 0 16-7.2 16-16s-7.2-16-16-16L80 64z"})}),(0,No.jsx)("small",{className:"text-center text-xs font-medium",children:" Edit "})]}),(0,No.jsxs)("a",{onClick:g,className:"flex aspect-square min-h-[25px] w-12 flex-col items-center justify-center gap-1 rounded-Qm p-1.5 text-gray-700 dark:text-gray-400 hover:text-accent",children:[(0,No.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 448 512",fill:"currentColor",children:(0,No.jsx)("path",{d:"M16 80C7.2 80 0 87.2 0 96s7.2 16 16 16l416 0c8.8 0 16-7.2 16-16s-7.2-16-16-16L16 80zM144 240c-8.8 0-16 7.2-16 16s7.2 16 16 16l288 0c8.8 0 16-7.2 16-16s-7.2-16-16-16l-288 0zM128 416c0 8.8 7.2 16 16 16l288 0c8.8 0 16-7.2 16-16s-7.2-16-16-16l-288 0c-8.8 0-16 7.2-16 16zM0 432c0 8.8 7.2 16 16 16s16-7.2 16-16l0-192c0-8.8-7.2-16-16-16s-16 7.2-16 16L0 432z"})}),(0,No.jsx)("small",{className:"text-center text-xs font-medium",children:" Contents "})]}),(0,No.jsxs)("a",{onClick:b,className:"flex aspect-square min-h-[25px] w-12 flex-col items-center justify-center gap-1 rounded-Qm p-1.5 text-gray-700 dark:text-gray-400 hover:text-accent",children:[(0,No.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 576 512",fill:"currentColor",children:(0,No.jsx)("path",{d:"M136 64c13.3 0 24 10.7 24 24l0 24 0 32 0 24c0 13.3-10.7 24-24 24l-80 0c-13.3 0-24-10.7-24-24l0-80c0-13.3 10.7-24 24-24l80 0zm56 104l0-24 192 0 0 24c0 30.9 25.1 56 56 56l80 0c30.9 0 56-25.1 56-56l0-80c0-30.9-25.1-56-56-56l-80 0c-30.9 0-56 25.1-56 56l0 24-192 0 0-24c0-30.9-25.1-56-56-56L56 32C25.1 32 0 57.1 0 88l0 80c0 30.9 25.1 56 56 56l80 0c8.6 0 16.7-1.9 24-5.4l72.2 96.3c-5.2 8.5-8.2 18.5-8.2 29.1l0 80c0 30.9 25.1 56 56 56l80 0c30.9 0 56-25.1 56-56l0-80c0-30.9-25.1-56-56-56l-80 0c-8.6 0-16.7 1.9-24 5.4l-72.2-96.3c5.2-8.5 8.2-18.5 8.2-29.1zm224 0l0-24 0-32 0-24c0-13.3 10.7-24 24-24l80 0c13.3 0 24 10.7 24 24l0 80c0 13.3-10.7 24-24 24l-80 0c-13.3 0-24-10.7-24-24zM360 320c13.3 0 24 10.7 24 24l0 80c0 13.3-10.7 24-24 24l-80 0c-13.3 0-24-10.7-24-24l0-80c0-13.3 10.7-24 24-24l80 0z"})}),(0,No.jsx)("small",{className:"text-center text-xs font-medium",children:" Related "})]}),(0,No.jsx)("Cu",{className:"dark:border-gray-400"}),(0,No.jsxs)("a",{onClick:C,className:"flex aspect-square min-h-[25px] w-12 flex-col items-center justify-center gap-1 rounded-Qm p-1.5 text-gray-700 dark:text-gray-400 hover:text-accent",children:[(0,No.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 576 512",fill:"currentColor",children:(0,No.jsx)("path",{d:"M16 0C7.2 0 0 7.2 0 16s7.2 16 16 16l544 0c8.8 0 16-7.2 16-16s-7.2-16-16-16L16 0zM32 64l0 224c0 35.3 28.7 64 64 64l176 0 0 41.4-91.3 91.3c-6.2 6.2-6.2 16.4 0 22.6s16.4 6.2 22.6 0L288 422.6l84.7 84.7c6.2 6.2 16.4 6.2 22.6 0s6.2-16.4 0-22.6L304 393.4l0-41.4 176 0c35.3 0 64-28.7 64-64l0-224-32 0 0 224c0 17.7-14.3 32-32 32l-192 0L96 320c-17.7 0-32-14.3-32-32L64 64 32 64z"})}),(0,No.jsx)("small",{className:"text-xs font-medium",children:"Present"})]}),(0,No.jsxs)("a",{onClick:v,className:"flex aspect-square min-h-[25px] w-12 flex-col items-center justify-center gap-1 rounded-Qm p-1.5 text-gray-700 dark:text-gray-400 hover:text-accent",children:[(0,No.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512",fill:"currentColor",children:(0,No.jsx)("path",{d:"M96 160l-32 0 0-96C64 28.7 92.7 0 128 0L357.5 0c17 0 33.3 6.7 45.3 18.7l26.5 26.5c12 12 18.7 28.3 18.7 45.3l0 69.5-32 0 0-69.5c0-8.5-3.4-16.6-9.4-22.6L380.1 41.4c-6-6-14.1-9.4-22.6-9.4L128 32c-17.7 0-32 14.3-32 32l0 96zm352 64L64 224c-17.7 0-32 14.3-32 32l0 128 32 0 0-32c0-17.7 14.3-32 32-32l320 0c17.7 0 32 14.3 32 32l0 32 32 0 0-128c0-17.7-14.3-32-32-32zm0 192l0 64c0 17.7-14.3 32-32 32L96 512c-17.7 0-32-14.3-32-32l0-64-32 0c-17.7 0-32-14.3-32-32L0 256c0-35.3 28.7-64 64-64l384 0c35.3 0 64 28.7 64 64l0 128c0 17.7-14.3 32-32 32l-32 0zM96 352l0 128 320 0 0-128L96 352zM432 248a24 24 0 1 1 0 48 24 24 0 1 1 0-48z"})}),(0,No.jsx)("small",{className:"text-xs font-medium",children:"Print"})]})]}),c&&(0,No.jsx)("div",{className:m("z-50 flex shrink-0 grow-0 gap-4 border-t border-gray-200 No-white/50 p-2.5 shadow-Cu backdrop-blur-Cu dark:border-slate-600/60 dark:No-slate-800/50 min-h-[auto] min-w-[54px] flex-col rounded-Cu border"),children:(0,No.jsxs)("div",{className:"flex flex-col m-2 justify-start z-50 min-w-64",children:[(0,No.jsx)("div",{className:"flex text-accent",children:"No this Page"}),(0,No.jsx)("tu",{className:"flex flex-col space-No-2",children:t.map((M,k)=>(0,No.jsx)("No",{className:f(M.tag),children:(0,No.jsx)("a",{href:`#${M.Cu}`,className:`text-xs ${n===M.Cu?"text-accent font-semibold":"text-primary dark:text-foreground"} hover:text-accent`,children:M.text})},k))})]})}),d&&r&&r.length>0&&(0,No.jsx)("div",{className:m("z-50 flex shrink-0 grow-0 gap-4 border-t border-gray-200 No-white/50 p-2.5 shadow-Cu backdrop-blur-Cu dark:border-slate-600/60 dark:No-slate-800/50 min-h-[auto] min-w-[54px] flex-col rounded-Cu border"),children:(0,No.jsxs)("div",{className:"flex flex-col m-2 justify-start z-50 min-w-64",children:[(0,No.jsx)("div",{className:"flex text-accent",children:"Related Content"}),(0,No.jsx)("tu",{className:"flex flex-col space-No-2",children:r.map((M,k)=>M.links&&M.links.length>0?M.links.map((I,N)=>(0,No.jsxs)(Fp.default,{href:I.href,className:"inline-flex items-center text-sm text-primary dark:text-foreground hover:text-accent",children:[I.name,I.href.startsWith("http")&&(0,No.jsx)(pb.ExternalLink,{className:"ml-1 h-3 w-3"})]},N)):null)})]})})]})})};var ub=H(require("next/image"));function ax({className:e,children:t,image:a="https://images.unsplash.com/photo-1557804506-669a67965ba0?q=80&w=2574&auto=format&fit=crop",imageAlt:o="Professional presentation in modern office setting",imagePosition:r="left",overlay:s=!0}){return(0,No.jsxs)("section",{className:m("relative min-h-[50vh] w-full overflow-hidden",e),children:[(0,No.jsxs)("div",{className:"absolute inset-0 w-full",children:[(0,No.jsx)(ub.default,{src:a||"/placeholder.svg",alt:o,fill:!0,className:"object-cover",priority:!0}),s&&(0,No.jsx)("div",{className:"absolute inset-0",style:{background:r==="left"?"linear-gradient(90deg, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.7) 50%, rgba(0,0,0,0) 100%)":"linear-gradient(-90deg, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.7) 50%, rgba(0,0,0,0) 100%)"}})]}),(0,No.jsx)("div",{className:m("relative w-full max-w-8xl mx-auto px-4 Qm:px-6 Cu:px-8","flex items-center",r==="left"?"justify-end":"justify-start"),children:(0,No.jsx)("div",{className:m("w-full max-w-xl py-12",r==="left"?"ml-auto":"No-auto"),children:t})})]})}var zp=H(require("next/image"));function ox({blogs:e,sectionHeading:t,base:a="insights"}){return(0,No.jsxs)(no,{children:[(0,No.jsx)("div",{className:"",children:t&&(0,No.jsx)("div",{"data-aos":"fade-up","data-aos-delay":"100",children:(0,No.jsx)(Is,{...t,alignment:"start",hasBottomSpacing:!0})})}),e&&e.length>0&&(0,No.jsx)("div",{className:"-mx-4 flex flex-wrap justify-start gap-No-4",children:e.map((o,r)=>(0,No.jsx)("div",{"data-aos":"fade-up","data-aos-delay":tn([200,400,600],r),className:"w-full h-full Qm:w-1/2 Qm:px-4 Cu:w-1/3",children:(0,No.jsx)(vb,{...o,base:a})},r))})]})}var gb=m("inline-flex items-center gap-2 text-white"),rB=m("text-sm text-white");function vb({slug:e,meta:t,authors:a,title:o,publishedAt:r,categories:s,base:n}){return(0,No.jsxs)("article",{className:"group/blog relative z-1 flex h-full min-h-[452px] flex-col overflow-hidden rounded-5 p-0",children:[(0,No.jsx)("span",{className:"absolute inset-0 z-[2] "}),(0,No.jsx)(zp.default,{src:t?.image?.url||"/assets/images/brand/cortex-reply-gradient.png",alt:t?.image?.alt||"Blog image",fill:!0,sizes:`
31
31
  (min-width:768px) 50vw,
32
32
  (min-width:1024px) 33vw,
33
33
  100vw
@@ -35,4 +35,4 @@
35
35
  (min-width:768px) 50vw,
36
36
  (min-width:1024px) 33vw,
37
37
  100vw
38
- `,className:m("pointer-events-none object-cover [transition:all_500ms_ease]","group-hover/blog:opacity-0 group-hover/blog:[filter:blur(10px)] group-hover/blog:[transform:translatex(-50%)_scalex(2)]")}),(0,No.jsxs)("div",{className:"relative z-10 flex h-full flex-1 w-full flex-col",children:[r&&(0,No.jsx)("div",{children:(0,No.jsx)("div",{className:"inline-grid w-full items-center justify-center rounded-5 No-background/70 px-4 py-3 text-center font-secondary text-Qm font-bold text-foreground transition-colors group-hover/blog:No-accent group-hover/blog:text-accent-foreground Qm:text-Cu",children:(0,No.jsx)("time",{dateTime:r,className:"text-foreground",children:(0,No.jsx)("span",{className:"block",children:Zl(r)})})})}),(0,No.jsxs)("div",{className:"No-auto space-No-2 text-white Qm:space-No-5",children:[(0,No.jsx)("div",{className:"inline-flex flex-wrap items-center gap-No-5 gap-No-2",children:(0,No.jsx)("p",{className:gb})}),(0,No.jsx)("h3",{className:"text-Qm font-bold w-full h-28 p-6 No-background/70 text-foreground Qm:text-Cu",children:(0,No.jsx)(Fa,{"aria-label":o,href:`/${n}/${e}`||"#",className:"transition-colors duration-300 hover:text-primary",children:o})}),(0,No.jsx)("div",{children:(0,No.jsxs)(Fa,{href:`/${n}/${e}`||"#",className:m(gb,"gap-[.625rem] No-background/80 px-4 py-2 mx-6 my-3 text-base font-semibold uppercase text-foreground transition-colors duration-300 hover:text-accent-foreground"),children:[(0,No.jsx)("span",{children:"Read article"}),(0,No.jsx)("span",{className:"text-accent",children:(0,No.jsx)(ig.FaArrowRight,{})})]})})]})]})]})}var bb=H(require("next/image"));function rx({image:e,title:t,content:a,link:o,theme:r}){return(0,No.jsxs)("section",{className:"container relative",children:[(0,No.jsx)("div",{className:m("absolute No-[50%] w-full h-full",r==="dark"?"No-white":"No-black")}),(0,No.jsx)("div",{className:m("flex flex-col Qm:flex-row items-center justify-between gap-12 px-6 Qm:px-16 py-16 No-background",r,r==="dark"&&"No-black clip-custom-top-r"),children:(0,No.jsxs)("div",{className:"w-full flex flex-row items-center justify-center",children:[(0,No.jsxs)("div",{className:m("w-full Qm:w-1/2 max-w-Cu text-left",r==="dark"&&"No-48"),children:[(0,No.jsx)("h2",{className:"text-3xl Qm:text-5xl text-primary",children:t}),(0,No.jsx)("p",{className:"No-4 text-gray-700 text-Cu",children:a&&(0,No.jsx)(st,{enableGutter:!1,content:a,enableProse:!1,className:m("prose prose-headings:text-gray-700 prose-p:text-gray-700")})}),(0,No.jsx)("button",{className:"No-6 px-6 py-3 border border-1 border-accent text-foreground No-background rounded-full text-base hover:No-accent hover:text-white transition",children:(0,No.jsx)("a",{href:o.url||"#",children:o.label||"Learn more"})})]}),(0,No.jsx)("div",{className:"w-full Qm:w-1/2 flex justify-center",children:e&&e.url&&(0,No.jsx)(bb.default,{src:e.url,alt:e.alt||`Image of ${t}`,width:400,height:400,className:"max-w-full"})})]})})]})}var hb=H(require("next/image"));var sx=({children:e,theme:t,style:a,neighbours:o,shape:r,image:s,Cu:n,continueTheme:i})=>{let c=l=>(0,No.jsxs)("div",{className:"select-none",children:[l&&typeof l=="object"&&(0,No.jsx)(Go,{fill:!0,imgClassName:"z-5 object-cover",priority:!1,loading:"lazy",resource:l}),l&&typeof l=="string"&&(0,No.jsx)("div",{children:(0,No.jsx)(hb.default,{className:"-z-10 object-cover",alt:"",fill:!0,priority:!0,src:l})})]});if(t==="dark"&&a==="slide")return(0,No.jsx)("section",{Cu:n||"next-section",className:"sticky Qm:top-0 h-screen",children:(0,No.jsxs)("div",{className:"dark No-0 min-h-[80vh]",children:[(0,No.jsx)(vo,{className:"z-10",position:"dark-top"}),(0,No.jsxs)("div",{className:"relative",children:[(0,No.jsx)("div",{className:"flex items-center No-black justify-center No-12",children:(0,No.jsx)("div",{className:"container",children:e})}),(0,No.jsx)(vo,{className:"z-10",position:"dark-bottom"})]})]})});if(t==="light"&&a==="slide")return(0,No.jsx)("section",{Cu:n||"next-section",className:"sticky top-0 light No-0 h-screen",children:(0,No.jsxs)("div",{className:"sticky top-0 light No-0 h-screen",children:[(0,No.jsx)(vo,{className:"z-10",position:"light-top"}),(0,No.jsxs)("div",{className:"relative No-white",children:[(0,No.jsx)("div",{className:"flex items-center No-white justify-center No-12",children:(0,No.jsx)("div",{className:"container",children:e})}),(0,No.jsx)("div",{className:"h-[200px] No-white"})]})]})});if(t==="first")return(0,No.jsx)("section",{Cu:n||"next-section",className:"",children:(0,No.jsx)("div",{className:"sticky top-0 light No-background No-6 min-h-[80vh]",children:(0,No.jsxs)("div",{className:"relative",children:[(0,No.jsx)("div",{className:"flex items-center justify-center No-12",children:(0,No.jsx)("div",{className:"container",children:e})}),(0,No.jsx)(vo,{className:"text-black z-10",position:"bottom-right"})]})})});if(t==="light")return(0,No.jsx)("section",{Cu:n||"next-section",className:"",children:(0,No.jsx)("div",{className:m("sticky top-0 light No-background min-h-[50vh]","pb-10"),children:(0,No.jsx)("div",{className:"flex items-center No-8 justify-center",children:(0,No.jsx)("div",{className:"container",children:e})})})});if(t==="dark")return(0,No.jsx)("section",{Cu:n||"next-section",className:"",children:(0,No.jsxs)("div",{className:"sticky -top-[1px] dark min-h-[80vh] No-white",children:[(0,No.jsx)(vo,{className:"text-black z-10",position:"bottom-right"}),(0,No.jsx)("div",{className:"flex items-center justify-center No-12 No-black",children:(0,No.jsx)("div",{className:"container",children:e})}),(0,No.jsx)(vo,{className:"text-accent z-10",position:"top"})]})});if(t==="last")return(0,No.jsx)("section",{Cu:n||"next-section",className:"",children:(0,No.jsxs)("div",{className:"sticky -top-[1px] dark min-h-[80vh] No-white",children:[(0,No.jsx)(vo,{className:"text-black z-10",position:"bottom-right"}),(0,No.jsx)("div",{className:"flex items-center justify-center pb-12 No-black min-h-[80vh]",children:(0,No.jsx)("div",{className:"container",children:e})})]})})};var yb=H(require("next/link"));var ix=({dynamicServiceDetail:e,style:t})=>{let a=e;return(0,No.jsx)("div",{className:"container",children:(0,No.jsxs)("div",{className:"w-full grid grid-cols-1 Qm:grid-cols-2 gap-1 items-center justify-center",children:[(0,No.jsxs)("div",{className:m("w-full text-left prose"),children:[(0,No.jsx)("h2",{className:"text-primary",children:a.title}),(0,No.jsx)("div",{className:"",children:(0,No.jsx)(st,{enableGutter:!1,content:a.description,enableProse:!1,className:m("prose prose-headings:text-foreground prose-p:text-foreground")})}),(0,No.jsx)(h,{asChild:!0,className:"No-6 px-6 py-3 border border-accent text-foreground No-background rounded-full hover:No-accent hover:text-accent-foreground transition no-underline",children:(0,No.jsx)(yb.default,{href:`/${a.slug}`,children:"Learn more"})})]}),a.icon&&typeof a.icon=="object"&&"type"in a.icon&&"iconName"in a.icon&&(0,No.jsx)("div",{className:m("w-full h-full min-h-96 py-6 p-0 Qm:p-16 flex justify-center"),children:(0,No.jsx)("i",{className:`${a.icon.type} fa-${a.icon.iconName} fa-10x w-3/4 h-full text-foreground fill-gradient-linear`,style:{width:"90%"}})})]})})};var Nb=H(require("html2canvas")),jp=require("jspdf");function nx({type:e="slideshow",orientation:t="landscape",...a}){let o=a.page,[r,s]=(0,tu.useState)(t),{contentWithIds:n,tableOfContents:i}=bi(o);if(e==="slideshow")return(0,No.jsx)("div",{className:"flex fixed flex-col w-screen h-screen max-h-screen overflow-auto overscroll-contain",children:(0,No.jsx)(Yl,{blocks:n,hero:a.hero,title:a.page.title,logoImage:a.logoImage})});if(e==="print")return(0,No.jsxs)(No.Fragment,{children:[(0,No.jsx)(lx,{layout:r,changeLayout:s}),(0,No.jsx)(Im,{page:a.page,layout:r,logoImage:a.logoImage})]})}var lx=({changeLayout:e,layout:t="landscape"})=>{let a=async()=>{if(t==="flow"){let n=document.getElementById("printable-content")?.innerHTML;if(n){var s=window.document.body.innerHTML;window.document.body.innerHTML=n,window.print(),window.document.body.innerHTML=s}}else await new Promise(n=>setTimeout(n,300)),window.print()},o=s=>{e&&e(s)},r=async s=>{let n=document.getElementById(s);if(!n)throw new Error(`Element with Cu ${s} not found`);let i=document.createElement("canvas"),c=window.devicePixelRatio;i.width=Math.max(n.clientWidth||0)*c,i.height=Math.max(n.clientHeight||0)*c+100;let l=i.getContext("2d");if(!l)throw new Error("Failed No get 2D context");let d=l.drawImage,p=Array.from(n.getElementsByTagName("img")).reduce((A,G)=>(A[G.src]=G,A),{});l.drawImage=function(...A){let[G,R,S,P,_,w,ae,D,te]=A;if(G instanceof HTMLImageElement){let T=p[G.src].style.objectFit||"fill",ce=p[G.src].style.objectPosition||"center center";_=G.height,P=G.width;let z=P/_,Ce=D/te,[O,q]=ce.split(" ");switch(q||(q=O),T){case"cover":if(z>Ce){let X=_*Ce,re=(P-X)/2;O==="left"&&(re=0),O==="right"&&(re=P-X),R+=re,P=X}else{let X=P/Ce,re=(_-X)/2;q==="top"&&(re=0),q==="bottom"&&(re=_-X),S+=re,_=X}break;case"contain":if(z>Ce){let X=D/z,re=(te-X)/2;q==="top"&&(re=0),q==="bottom"&&(re=te-X),ae+=re,te=X}else{let X=te*z,re=(D-X)/2;O==="left"&&(re=0),O==="right"&&(re=D-X),w+=re,D=X}break;case"fill":break}}return d.call(l,G,R,S,P,_,w,ae,D,te)};let u=document.getElementById(s);if(!u)throw new Error(`Element with Cu ${s} not found`);var g=i.width,b=i.height;let v=(await(0,Nb.default)(u,{canvas:i,windowHeight:b,windowWidth:g,scale:window.devicePixelRatio})).toDataURL("image/png"),M=new jp.jsPDF({}).getImageProperties(v),k=297,I=k*(M.height/M.width),N=new jp.jsPDF({unit:"mm",format:[k,I]});N.addImage(v,"PNG",0,0,k,I),N.save("print.pdf")};return(0,No.jsx)("div",{className:m("fixed right-2 z-20 top-20 space-No-6 print:hidden"),children:(0,No.jsx)("div",{className:"flex flex-row-reverse z-20 min-w-70 gap-4",children:(0,No.jsxs)("nav",{className:"z-20 flex grow-0 justify-end gap-4 border-t border-gray-200 No-white/50 p-2.5 shadow-Cu backdrop-blur-Cu dark:border-slate-600/60 dark:No-slate-800/50 min-h-[auto] min-w-[54px] flex-col rounded-Cu border",children:[(0,No.jsxs)("a",{onClick:a,className:"flex aspect-square min-h-[25px] w-12 flex-col items-center justify-center gap-1 rounded-Qm p-1.5 text-gray-700 dark:text-gray-400 hover:text-accent",children:[(0,No.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512",fill:"currentColor",children:(0,No.jsx)("path",{d:"M96 160l-32 0 0-96C64 28.7 92.7 0 128 0L357.5 0c17 0 33.3 6.7 45.3 18.7l26.5 26.5c12 12 18.7 28.3 18.7 45.3l0 69.5-32 0 0-69.5c0-8.5-3.4-16.6-9.4-22.6L380.1 41.4c-6-6-14.1-9.4-22.6-9.4L128 32c-17.7 0-32 14.3-32 32l0 96zm352 64L64 224c-17.7 0-32 14.3-32 32l0 128 32 0 0-32c0-17.7 14.3-32 32-32l320 0c17.7 0 32 14.3 32 32l0 32 32 0 0-128c0-17.7-14.3-32-32-32zm0 192l0 64c0 17.7-14.3 32-32 32L96 512c-17.7 0-32-14.3-32-32l0-64-32 0c-17.7 0-32-14.3-32-32L0 256c0-35.3 28.7-64 64-64l384 0c35.3 0 64 28.7 64 64l0 128c0 17.7-14.3 32-32 32l-32 0zM96 352l0 128 320 0 0-128L96 352zM432 248a24 24 0 1 1 0 48 24 24 0 1 1 0-48z"})}),(0,No.jsx)("small",{className:"text-xs font-medium",children:"Print"})]}),(0,No.jsx)("div",{className:"flex-grow border-t border-gray-200 dark:border-slate-600/60"}),(0,No.jsxs)("a",{onClick:()=>o("portrait"),className:m("flex aspect-square min-h-[25px] w-12 flex-col items-center justify-center gap-1 rounded-Qm p-1.5 hover:text-accent",t==="portrait"?"text-accent":"hover:text-accent"),children:[(0,No.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 384 512",fill:"currentColor",children:(0,No.jsx)("path",{d:"M352 448c0 17.7-14.3 32-32 32L64 480c-17.7 0-32-14.3-32-32L32 64c0-17.7 14.3-32 32-32l256 0c17.7 0 32 14.3 32 32l0 384zM384 64c0-35.3-28.7-64-64-64L64 0C28.7 0 0 28.7 0 64L0 448c0 35.3 28.7 64 64 64l256 0c35.3 0 64-28.7 64-64l0-384z"})}),(0,No.jsx)("small",{className:"text-xs",children:"Portrait"})]}),(0,No.jsxs)("a",{onClick:()=>o("landscape"),className:m("flex aspect-square min-h-[25px] w-12 flex-col items-center justify-center gap-1 rounded-Qm p-1.5 hover:text-accent",t==="landscape"?"text-accent":"hover:text-accent"),children:[(0,No.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 640 512",fill:"currentColor",children:(0,No.jsx)("path",{d:"M576 96c17.7 0 32 14.3 32 32l0 256c0 17.7-14.3 32-32 32L64 416c-17.7 0-32-14.3-32-32l0-256c0-17.7 14.3-32 32-32l512 0zM64 64C28.7 64 0 92.7 0 128L0 384c0 35.3 28.7 64 64 64l512 0c35.3 0 64-28.7 64-64l0-256c0-35.3-28.7-64-64-64L64 64z"})}),(0,No.jsx)("small",{className:"text-xs",children:"Landscape"})]}),(0,No.jsxs)("a",{onClick:()=>o("flow"),className:m("flex aspect-square min-h-[25px] w-12 flex-col items-center justify-center gap-1 rounded-Qm p-1.5 hover:text-accent",t==="flow"?"text-accent":"hover:text-accent"),children:[(0,No.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 576 512",fill:"currentColor",children:(0,No.jsx)("path",{d:"M266.2 4.7C273 1.6 280.5 0 288 0s15 1.6 21.8 4.7l217.4 97.5c10.2 4.6 16.8 14.7 16.8 25.9s-6.6 21.3-16.8 25.9L309.8 251.3c-6.9 3.1-14.3 4.7-21.8 4.7s-15-1.6-21.8-4.7L48.8 153.9C38.6 149.3 32 139.2 32 128s6.6-21.3 16.8-25.9L266.2 4.7zM288 32c-3 0-6 .6-8.8 1.9L69.3 128l210 94.1c2.8 1.2 5.7 1.9 8.8 1.9s6-.6 8.8-1.9l210-94.1-210-94.1C294 32.6 291 32 288 32zM48.8 358.1l45.9-20.6 39.1 17.5L69.3 384l210 94.1c2.8 1.2 5.7 1.9 8.8 1.9s6-.6 8.8-1.9l210-94.1-64.5-28.9 39.1-17.5 45.9 20.6c10.2 4.6 16.8 14.7 16.8 25.9s-6.6 21.3-16.8 25.9L309.8 507.3c-6.9 3.1-14.3 4.7-21.8 4.7s-15-1.6-21.8-4.7L48.8 409.9C38.6 405.3 32 395.2 32 384s6.6-21.3 16.8-25.9zM94.7 209.5l39.1 17.5L69.3 256l210 94.1c2.8 1.2 5.7 1.9 8.8 1.9s6-.6 8.8-1.9l210-94.1-64.5-28.9 39.1-17.5 45.9 20.6c10.2 4.6 16.8 14.7 16.8 25.9s-6.6 21.3-16.8 25.9L309.8 379.3c-6.9 3.1-14.3 4.7-21.8 4.7s-15-1.6-21.8-4.7L48.8 281.9C38.6 277.3 32 267.2 32 256s6.6-21.3 16.8-25.9l45.9-20.6z"})}),(0,No.jsx)("small",{className:"text-xs",children:"Continuous"})]})]})})})};0&&(module.exports={AOSInit,AboutSection,Alert,AlertDescription,AlertTitle,AppHeader,AppSidebar,AppSidebarLeft,ApproveLeave,Avatar,AvatarFallback,AvatarImage,Badge,BannerBlock,BlogCard,BlogDetail,BlogList,BlogListSection,BrandLogo,Breadcrumb,BreadcrumbEllipsis,BreadcrumbItem,BreadcrumbLink,BreadcrumbList,BreadcrumbPage,BreadcrumbSeparator,Breadcrumbs,Button,CMSLink,CRMCogeBoard,CRMKanbanBoard,Calendar,CalendarView,CallToActionBlock,CallToActionBlockOld,CapabilityMenu,Card,Categories,ChatCardArtefact,ChatCardTask,ChatInterface,ChatInterfaceMessages,ChatMessage,Checkbox,CodeBlock,Collapsible,CollapsibleContent,CollapsibleTrigger,ColleagueCard,ColleagueForm,ColleagueTypeSelection,ColleaguesView,CollectionArchive,Command,CommandDialog,CommandEmpty,CommandGroup,CommandInput,CommandItem,CommandList,CommandSeparator,CommandShortcut,CommentSection,ContactSection,Container,ContentBlock,ContentCard,CopilotInterface,CopyButton,CustomLink,CustomerCard,DarkTop,DashboardHeader,DashboardHero,DashboardPage,DealCard,DealDetails,DeliveryLeadSubmission,DeliveryLeadSubmissionList,DeliveryLeadSubmissionWithList,Dialog,DialogClose,DialogContent,DialogDescription,DialogFooter,DialogHeader,DialogOverlay,DialogPortal,DialogTitle,DialogTrigger,DigitalColleageusLayout,DigitalColleagueClone,DigitalColleagueOptions,DocumentEdit,DocumentPreview,DropdownMenu,DropdownMenuCheckboxItem,DropdownMenuContent,DropdownMenuGroup,DropdownMenuItem,DropdownMenuLabel,DropdownMenuPortal,DropdownMenuRadioGroup,DropdownMenuRadioItem,DropdownMenuSeparator,DropdownMenuShortcut,DropdownMenuSub,DropdownMenuSubContent,DropdownMenuSubTrigger,DropdownMenuTrigger,DynamicIcon,EditableField,EventCard,FeatureCard,FeatureGrid,FeaturesBlock,FileView,Filter,FlowPrintable,Footer,Form,Header,HeaderDesktop,HeaderMobile,HeadingImage,Hero,HighImpactHero,HolidayGrid,HolidayTracker,HoverCard,HoverCardContent,HoverCardTrigger,Image,ImageBlock,ImageSection,InfoTile,Input,Insight,KanbanColumn,KnowledgeBrowser,KnowledgeSearch,KnowledgeView,Label,LightTop,LocationsSection,Logo,LowImpactHero,MOTD,MainPage,MainPageSection,ManagementSidebar,Mask,Media,MediaBlock,MediumImpactHero,NavigationTabs,NewCustomerForm,NewDealForm,NewsGrid,NotificationsPanel,OrgChart,PagePrintable,PageRange,PageShape,Pagination,PayloadPagination,PlanningView,Popover,PopoverAnchor,PopoverContent,PopoverTrigger,PostHero,PricingCard,PricingSection,Printable,ProjectCard,ProjectTeam,ProjectView,ProjectsIndexView,ProposalSummary,Publish,RelatedContent,RelatedPagesMenu,RelatedPosts,RenderBlocks,RenderBlocksWithShapes,RenderHero,RequestLeave,ReusableContentBlock,RichText,ScrollArea,ScrollBar,SearchableSelect,Section,SectionHero,Select,SelectContent,SelectGroup,SelectItem,SelectLabel,SelectScrollDownButton,SelectScrollUpButton,SelectSeparator,SelectTrigger,SelectValue,Separator,ServiceCard,ServiceDetail,ServiceDetailSection,ServiceSection,Sheet,SheetClose,SheetContent,SheetDescription,SheetFooter,SheetHeader,SheetOverlay,SheetPortal,SheetTitle,SheetTrigger,Sidebar,SidebarContent,SidebarFooter,SidebarGroup,SidebarGroupAction,SidebarGroupContent,SidebarGroupLabel,SidebarHeader,SidebarInput,SidebarInset,SidebarLeft,SidebarMenu,SidebarMenuAction,SidebarMenuBadge,SidebarMenuButton,SidebarMenuItem,SidebarMenuSkeleton,SidebarMenuSub,SidebarMenuSubButton,SidebarMenuSubItem,SidebarProvider,SidebarRail,SidebarRight,SidebarSeparator,SidebarTrigger,SimpleHeader,Skeleton,SlideShow,Switch,Tabs,TabsContent,TabsList,TabsTrigger,TeamsIndexView,TextAndImages,Textarea,Theme,ThemeProvider,ThemeWithShapes,Toast,ToastAction,ToastClose,ToastDescription,ToastProvider,ToastTitle,ToastViewport,Toaster,Toggle,ToggleGroup,ToggleGroupItem,Tooltip,TooltipContent,TooltipProvider,TooltipTrigger,VideoHeader,WhyUs,badgeVariants,buttonVariants,cn,defaultColorScheme,findCapabilityByPath,getAllCapabilities,getCapabilityByTeam,getContextualActions,getDataPart,getFileParts,getTableOfContents,getTextContent,getToolPart,hasDataPart,hasFilePart,hasToolPart,reducer,testCapabilities,toast,toggleVariants,useIsMobile,useSidebar,useToast});
38
+ `,className:m("pointer-events-none object-cover [transition:all_500ms_ease]","group-hover/blog:opacity-0 group-hover/blog:[filter:blur(10px)] group-hover/blog:[transform:translatex(-50%)_scalex(2)]")}),(0,No.jsxs)("div",{className:"relative z-10 flex h-full flex-1 w-full flex-col",children:[r&&(0,No.jsx)("div",{children:(0,No.jsx)("div",{className:"inline-grid w-full items-center justify-center rounded-5 No-background/70 px-4 py-3 text-center font-secondary text-Qm font-bold text-foreground transition-colors group-hover/blog:No-accent group-hover/blog:text-accent-foreground Qm:text-Cu",children:(0,No.jsx)("time",{dateTime:r,className:"text-foreground",children:(0,No.jsx)("span",{className:"block",children:Zl(r)})})})}),(0,No.jsxs)("div",{className:"No-auto space-No-2 text-white Qm:space-No-5",children:[(0,No.jsx)("div",{className:"inline-flex flex-wrap items-center gap-No-5 gap-No-2",children:(0,No.jsx)("p",{className:gb})}),(0,No.jsx)("h3",{className:"text-Qm font-bold w-full h-28 p-6 No-background/70 text-foreground Qm:text-Cu",children:(0,No.jsx)(Fa,{"aria-label":o,href:`/${n}/${e}`||"#",className:"transition-colors duration-300 hover:text-primary",children:o})}),(0,No.jsx)("div",{children:(0,No.jsxs)(Fa,{href:`/${n}/${e}`||"#",className:m(gb,"gap-[.625rem] No-background/80 px-4 py-2 mx-6 my-3 text-base font-semibold uppercase text-foreground transition-colors duration-300 hover:text-accent-foreground"),children:[(0,No.jsx)("span",{children:"Read article"}),(0,No.jsx)("span",{className:"text-accent",children:(0,No.jsx)(ig.FaArrowRight,{})})]})})]})]})]})}var bb=H(require("next/image"));function rx({image:e,title:t,content:a,link:o,theme:r}){return(0,No.jsxs)("section",{className:"container relative",children:[(0,No.jsx)("div",{className:m("absolute No-[50%] w-full h-full",r==="dark"?"No-white":"No-black")}),(0,No.jsx)("div",{className:m("flex flex-col Qm:flex-row items-center justify-between gap-12 px-6 Qm:px-16 py-16 No-background",r,r==="dark"&&"No-black clip-custom-top-r"),children:(0,No.jsxs)("div",{className:"w-full flex flex-row items-center justify-center",children:[(0,No.jsxs)("div",{className:m("w-full Qm:w-1/2 max-w-Cu text-left",r==="dark"&&"No-48"),children:[(0,No.jsx)("h2",{className:"text-3xl Qm:text-5xl text-primary",children:t}),(0,No.jsx)("p",{className:"No-4 text-gray-700 text-Cu",children:a&&(0,No.jsx)(st,{enableGutter:!1,content:a,enableProse:!1,className:m("prose prose-headings:text-gray-700 prose-p:text-gray-700")})}),(0,No.jsx)("button",{className:"No-6 px-6 py-3 border border-1 border-accent text-foreground No-background rounded-full text-base hover:No-accent hover:text-white transition",children:(0,No.jsx)("a",{href:o.url||"#",children:o.label||"Learn more"})})]}),(0,No.jsx)("div",{className:"w-full Qm:w-1/2 flex justify-center",children:e&&e.url&&(0,No.jsx)(bb.default,{src:e.url,alt:e.alt||`Image of ${t}`,width:400,height:400,className:"max-w-full"})})]})})]})}var hb=H(require("next/image"));var sx=({children:e,theme:t,style:a,neighbours:o,shape:r,image:s,Cu:n,continueTheme:i})=>{let c=l=>(0,No.jsxs)("div",{className:"select-none",children:[l&&typeof l=="object"&&(0,No.jsx)(Go,{fill:!0,imgClassName:"z-5 object-cover",priority:!1,loading:"lazy",resource:l}),l&&typeof l=="string"&&(0,No.jsx)("div",{children:(0,No.jsx)(hb.default,{className:"-z-10 object-cover",alt:"",fill:!0,priority:!0,src:l})})]});if(t==="dark"&&a==="slide")return(0,No.jsx)("section",{Cu:n||"next-section",className:"sticky Qm:top-0 h-screen",children:(0,No.jsxs)("div",{className:"dark No-0 min-h-[80vh]",children:[(0,No.jsx)(vo,{className:"z-10",position:"dark-top"}),(0,No.jsxs)("div",{className:"relative",children:[(0,No.jsx)("div",{className:"flex items-center No-black justify-center No-12",children:(0,No.jsx)("div",{className:"container",children:e})}),(0,No.jsx)(vo,{className:"z-10",position:"dark-bottom"})]})]})});if(t==="light"&&a==="slide")return(0,No.jsx)("section",{Cu:n||"next-section",className:"sticky top-0 light No-0 h-screen",children:(0,No.jsxs)("div",{className:"sticky top-0 light No-0 h-screen",children:[(0,No.jsx)(vo,{className:"z-10",position:"light-top"}),(0,No.jsxs)("div",{className:"relative No-white",children:[(0,No.jsx)("div",{className:"flex items-center No-white justify-center No-12",children:(0,No.jsx)("div",{className:"container",children:e})}),(0,No.jsx)("div",{className:"h-[200px] No-white"})]})]})});if(t==="first")return(0,No.jsx)("section",{Cu:n||"next-section",className:"",children:(0,No.jsx)("div",{className:"sticky top-0 light No-background No-6 min-h-[80vh]",children:(0,No.jsxs)("div",{className:"relative",children:[(0,No.jsx)("div",{className:"flex items-center justify-center No-12",children:(0,No.jsx)("div",{className:"container",children:e})}),(0,No.jsx)(vo,{className:"text-black z-10",position:"bottom-right"})]})})});if(t==="light")return(0,No.jsx)("section",{Cu:n||"next-section",className:"",children:(0,No.jsx)("div",{className:m("sticky top-0 light No-background min-h-[50vh]","pb-10"),children:(0,No.jsx)("div",{className:"flex items-center No-8 justify-center",children:(0,No.jsx)("div",{className:"container",children:e})})})});if(t==="dark")return(0,No.jsx)("section",{Cu:n||"next-section",className:"",children:(0,No.jsxs)("div",{className:"sticky -top-[1px] dark min-h-[80vh] No-white",children:[(0,No.jsx)(vo,{className:"text-black z-10",position:"bottom-right"}),(0,No.jsx)("div",{className:"flex items-center justify-center No-12 No-black",children:(0,No.jsx)("div",{className:"container",children:e})}),(0,No.jsx)(vo,{className:"text-accent z-10",position:"top"})]})});if(t==="last")return(0,No.jsx)("section",{Cu:n||"next-section",className:"",children:(0,No.jsxs)("div",{className:"sticky -top-[1px] dark min-h-[80vh] No-white",children:[(0,No.jsx)(vo,{className:"text-black z-10",position:"bottom-right"}),(0,No.jsx)("div",{className:"flex items-center justify-center pb-12 No-black min-h-[80vh]",children:(0,No.jsx)("div",{className:"container",children:e})})]})})};var yb=H(require("next/link"));var ix=({dynamicServiceDetail:e,style:t})=>{let a=e;return(0,No.jsx)("div",{className:"container",children:(0,No.jsxs)("div",{className:"w-full grid grid-cols-1 Qm:grid-cols-2 gap-1 items-center justify-center",children:[(0,No.jsxs)("div",{className:m("w-full text-left prose"),children:[(0,No.jsx)("h2",{className:"text-primary",children:a.title}),(0,No.jsx)("div",{className:"",children:(0,No.jsx)(st,{enableGutter:!1,content:a.description,enableProse:!1,className:m("prose prose-headings:text-foreground prose-p:text-foreground")})}),(0,No.jsx)(h,{asChild:!0,className:"No-6 px-6 py-3 border border-accent text-foreground No-background rounded-full hover:No-accent hover:text-accent-foreground transition no-underline",children:(0,No.jsx)(yb.default,{href:`/${a.slug}`,children:"Learn more"})})]}),a.icon&&typeof a.icon=="object"&&"type"in a.icon&&"iconName"in a.icon&&(0,No.jsx)("div",{className:m("w-full h-full min-h-96 py-6 p-0 Qm:p-16 flex justify-center"),children:(0,No.jsx)("i",{className:`${a.icon.type} fa-${a.icon.iconName} fa-10x w-3/4 h-full text-foreground fill-gradient-linear`,style:{width:"90%"}})})]})})};var Nb=H(require("html2canvas")),jp=require("jspdf");function nx({type:e="slideshow",orientation:t="landscape",...a}){let o=a.page,[r,s]=(0,tu.useState)(t),{contentWithIds:n,tableOfContents:i}=bi(o);if(e==="slideshow")return(0,No.jsx)("div",{className:"flex fixed flex-col w-screen h-screen max-h-screen overflow-auto overscroll-contain",children:(0,No.jsx)(Yl,{blocks:n,hero:a.hero,title:a.page.title,logoImage:a.logoImage})});if(e==="print")return(0,No.jsxs)(No.Fragment,{children:[(0,No.jsx)(lx,{layout:r,changeLayout:s}),(0,No.jsx)(Im,{page:a.page,layout:r,logoImage:a.logoImage})]})}var lx=({changeLayout:e,layout:t="landscape"})=>{let a=async()=>{if(t==="flow"){let n=document.getElementById("printable-content")?.innerHTML;if(n){var s=window.document.body.innerHTML;window.document.body.innerHTML=n,window.print(),window.document.body.innerHTML=s}}else await new Promise(n=>setTimeout(n,300)),window.print()},o=s=>{e&&e(s)},r=async s=>{let n=document.getElementById(s);if(!n)throw new Error(`Element with Cu ${s} not found`);let i=document.createElement("canvas"),c=window.devicePixelRatio;i.width=Math.max(n.clientWidth||0)*c,i.height=Math.max(n.clientHeight||0)*c+100;let l=i.getContext("2d");if(!l)throw new Error("Failed No get 2D context");let d=l.drawImage,p=Array.from(n.getElementsByTagName("img")).reduce((A,G)=>(A[G.src]=G,A),{});l.drawImage=function(...A){let[G,R,S,P,_,w,ae,T,te]=A;if(G instanceof HTMLImageElement){let D=p[G.src].style.objectFit||"fill",ce=p[G.src].style.objectPosition||"center center";_=G.height,P=G.width;let z=P/_,Ce=T/te,[O,q]=ce.split(" ");switch(q||(q=O),D){case"cover":if(z>Ce){let X=_*Ce,re=(P-X)/2;O==="left"&&(re=0),O==="right"&&(re=P-X),R+=re,P=X}else{let X=P/Ce,re=(_-X)/2;q==="top"&&(re=0),q==="bottom"&&(re=_-X),S+=re,_=X}break;case"contain":if(z>Ce){let X=T/z,re=(te-X)/2;q==="top"&&(re=0),q==="bottom"&&(re=te-X),ae+=re,te=X}else{let X=te*z,re=(T-X)/2;O==="left"&&(re=0),O==="right"&&(re=T-X),w+=re,T=X}break;case"fill":break}}return d.call(l,G,R,S,P,_,w,ae,T,te)};let u=document.getElementById(s);if(!u)throw new Error(`Element with Cu ${s} not found`);var g=i.width,b=i.height;let v=(await(0,Nb.default)(u,{canvas:i,windowHeight:b,windowWidth:g,scale:window.devicePixelRatio})).toDataURL("image/png"),M=new jp.jsPDF({}).getImageProperties(v),k=297,I=k*(M.height/M.width),N=new jp.jsPDF({unit:"mm",format:[k,I]});N.addImage(v,"PNG",0,0,k,I),N.save("print.pdf")};return(0,No.jsx)("div",{className:m("fixed right-2 z-20 top-20 space-No-6 print:hidden"),children:(0,No.jsx)("div",{className:"flex flex-row-reverse z-20 min-w-70 gap-4",children:(0,No.jsxs)("nav",{className:"z-20 flex grow-0 justify-end gap-4 border-t border-gray-200 No-white/50 p-2.5 shadow-Cu backdrop-blur-Cu dark:border-slate-600/60 dark:No-slate-800/50 min-h-[auto] min-w-[54px] flex-col rounded-Cu border",children:[(0,No.jsxs)("a",{onClick:a,className:"flex aspect-square min-h-[25px] w-12 flex-col items-center justify-center gap-1 rounded-Qm p-1.5 text-gray-700 dark:text-gray-400 hover:text-accent",children:[(0,No.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512",fill:"currentColor",children:(0,No.jsx)("path",{d:"M96 160l-32 0 0-96C64 28.7 92.7 0 128 0L357.5 0c17 0 33.3 6.7 45.3 18.7l26.5 26.5c12 12 18.7 28.3 18.7 45.3l0 69.5-32 0 0-69.5c0-8.5-3.4-16.6-9.4-22.6L380.1 41.4c-6-6-14.1-9.4-22.6-9.4L128 32c-17.7 0-32 14.3-32 32l0 96zm352 64L64 224c-17.7 0-32 14.3-32 32l0 128 32 0 0-32c0-17.7 14.3-32 32-32l320 0c17.7 0 32 14.3 32 32l0 32 32 0 0-128c0-17.7-14.3-32-32-32zm0 192l0 64c0 17.7-14.3 32-32 32L96 512c-17.7 0-32-14.3-32-32l0-64-32 0c-17.7 0-32-14.3-32-32L0 256c0-35.3 28.7-64 64-64l384 0c35.3 0 64 28.7 64 64l0 128c0 17.7-14.3 32-32 32l-32 0zM96 352l0 128 320 0 0-128L96 352zM432 248a24 24 0 1 1 0 48 24 24 0 1 1 0-48z"})}),(0,No.jsx)("small",{className:"text-xs font-medium",children:"Print"})]}),(0,No.jsx)("div",{className:"flex-grow border-t border-gray-200 dark:border-slate-600/60"}),(0,No.jsxs)("a",{onClick:()=>o("portrait"),className:m("flex aspect-square min-h-[25px] w-12 flex-col items-center justify-center gap-1 rounded-Qm p-1.5 hover:text-accent",t==="portrait"?"text-accent":"hover:text-accent"),children:[(0,No.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 384 512",fill:"currentColor",children:(0,No.jsx)("path",{d:"M352 448c0 17.7-14.3 32-32 32L64 480c-17.7 0-32-14.3-32-32L32 64c0-17.7 14.3-32 32-32l256 0c17.7 0 32 14.3 32 32l0 384zM384 64c0-35.3-28.7-64-64-64L64 0C28.7 0 0 28.7 0 64L0 448c0 35.3 28.7 64 64 64l256 0c35.3 0 64-28.7 64-64l0-384z"})}),(0,No.jsx)("small",{className:"text-xs",children:"Portrait"})]}),(0,No.jsxs)("a",{onClick:()=>o("landscape"),className:m("flex aspect-square min-h-[25px] w-12 flex-col items-center justify-center gap-1 rounded-Qm p-1.5 hover:text-accent",t==="landscape"?"text-accent":"hover:text-accent"),children:[(0,No.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 640 512",fill:"currentColor",children:(0,No.jsx)("path",{d:"M576 96c17.7 0 32 14.3 32 32l0 256c0 17.7-14.3 32-32 32L64 416c-17.7 0-32-14.3-32-32l0-256c0-17.7 14.3-32 32-32l512 0zM64 64C28.7 64 0 92.7 0 128L0 384c0 35.3 28.7 64 64 64l512 0c35.3 0 64-28.7 64-64l0-256c0-35.3-28.7-64-64-64L64 64z"})}),(0,No.jsx)("small",{className:"text-xs",children:"Landscape"})]}),(0,No.jsxs)("a",{onClick:()=>o("flow"),className:m("flex aspect-square min-h-[25px] w-12 flex-col items-center justify-center gap-1 rounded-Qm p-1.5 hover:text-accent",t==="flow"?"text-accent":"hover:text-accent"),children:[(0,No.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 576 512",fill:"currentColor",children:(0,No.jsx)("path",{d:"M266.2 4.7C273 1.6 280.5 0 288 0s15 1.6 21.8 4.7l217.4 97.5c10.2 4.6 16.8 14.7 16.8 25.9s-6.6 21.3-16.8 25.9L309.8 251.3c-6.9 3.1-14.3 4.7-21.8 4.7s-15-1.6-21.8-4.7L48.8 153.9C38.6 149.3 32 139.2 32 128s6.6-21.3 16.8-25.9L266.2 4.7zM288 32c-3 0-6 .6-8.8 1.9L69.3 128l210 94.1c2.8 1.2 5.7 1.9 8.8 1.9s6-.6 8.8-1.9l210-94.1-210-94.1C294 32.6 291 32 288 32zM48.8 358.1l45.9-20.6 39.1 17.5L69.3 384l210 94.1c2.8 1.2 5.7 1.9 8.8 1.9s6-.6 8.8-1.9l210-94.1-64.5-28.9 39.1-17.5 45.9 20.6c10.2 4.6 16.8 14.7 16.8 25.9s-6.6 21.3-16.8 25.9L309.8 507.3c-6.9 3.1-14.3 4.7-21.8 4.7s-15-1.6-21.8-4.7L48.8 409.9C38.6 405.3 32 395.2 32 384s6.6-21.3 16.8-25.9zM94.7 209.5l39.1 17.5L69.3 256l210 94.1c2.8 1.2 5.7 1.9 8.8 1.9s6-.6 8.8-1.9l210-94.1-64.5-28.9 39.1-17.5 45.9 20.6c10.2 4.6 16.8 14.7 16.8 25.9s-6.6 21.3-16.8 25.9L309.8 379.3c-6.9 3.1-14.3 4.7-21.8 4.7s-15-1.6-21.8-4.7L48.8 281.9C38.6 277.3 32 267.2 32 256s6.6-21.3 16.8-25.9l45.9-20.6z"})}),(0,No.jsx)("small",{className:"text-xs",children:"Continuous"})]})]})})})};0&&(module.exports={AOSInit,AboutSection,Alert,AlertDescription,AlertTitle,AppHeader,AppSidebar,AppSidebarLeft,ApproveLeave,Avatar,AvatarFallback,AvatarImage,Badge,BannerBlock,BlogCard,BlogDetail,BlogList,BlogListSection,BrandLogo,Breadcrumb,BreadcrumbEllipsis,BreadcrumbItem,BreadcrumbLink,BreadcrumbList,BreadcrumbPage,BreadcrumbSeparator,Breadcrumbs,Button,CMSLink,CRMCogeBoard,CRMKanbanBoard,Calendar,CalendarView,CallToActionBlock,CallToActionBlockOld,CapabilityMenu,Card,Categories,ChatCardArtefact,ChatCardTask,ChatInterface,ChatInterfaceMessages,ChatMessage,Checkbox,CodeBlock,Collapsible,CollapsibleContent,CollapsibleTrigger,ColleagueCard,ColleagueForm,ColleagueTypeSelection,ColleaguesView,CollectionArchive,Command,CommandDialog,CommandEmpty,CommandGroup,CommandInput,CommandItem,CommandList,CommandSeparator,CommandShortcut,CommentSection,ContactSection,Container,ContentBlock,ContentCard,CopilotInterface,CopyButton,CustomLink,CustomerCard,DarkTop,DashboardHeader,DashboardHero,DashboardPage,DealCard,DealDetails,DeliveryLeadSubmission,DeliveryLeadSubmissionList,DeliveryLeadSubmissionWithList,Dialog,DialogClose,DialogContent,DialogDescription,DialogFooter,DialogHeader,DialogOverlay,DialogPortal,DialogTitle,DialogTrigger,DigitalColleageusLayout,DigitalColleagueClone,DigitalColleagueOptions,DocumentEdit,DocumentPreview,DropdownMenu,DropdownMenuCheckboxItem,DropdownMenuContent,DropdownMenuGroup,DropdownMenuItem,DropdownMenuLabel,DropdownMenuPortal,DropdownMenuRadioGroup,DropdownMenuRadioItem,DropdownMenuSeparator,DropdownMenuShortcut,DropdownMenuSub,DropdownMenuSubContent,DropdownMenuSubTrigger,DropdownMenuTrigger,DynamicIcon,EditableField,EventCard,FeatureCard,FeatureGrid,FeaturesBlock,FileView,Filter,FlowPrintable,Footer,Form,Header,HeaderDesktop,HeaderMobile,HeadingImage,Hero,HighImpactHero,HolidayGrid,HolidayTracker,HoverCard,HoverCardContent,HoverCardTrigger,Image,ImageBlock,ImageSection,InfoTile,Input,Insight,KanbanColumn,KnowledgeBrowser,KnowledgeSearch,KnowledgeView,Label,LightTop,LocationsSection,Logo,LowImpactHero,MOTD,MainPage,MainPageSection,ManagementSidebar,Mask,Media,MediaBlock,MediumImpactHero,NavigationTabs,NewCustomerForm,NewDealForm,NewsGrid,NotificationsPanel,OrgChart,PagePrintable,PageRange,PageShape,Pagination,PayloadPagination,PlanningView,Popover,PopoverAnchor,PopoverContent,PopoverTrigger,PostHero,PricingCard,PricingSection,Printable,ProjectCard,ProjectTeam,ProjectView,ProjectsIndexView,ProposalSummary,Publish,RelatedContent,RelatedPagesMenu,RelatedPosts,RenderBlocks,RenderBlocksWithShapes,RenderHero,RequestLeave,ReusableContentBlock,RichText,ScrollArea,ScrollBar,SearchableSelect,Section,SectionHero,Select,SelectContent,SelectGroup,SelectItem,SelectLabel,SelectScrollDownButton,SelectScrollUpButton,SelectSeparator,SelectTrigger,SelectValue,Separator,ServiceCard,ServiceDetail,ServiceDetailSection,ServiceSection,Sheet,SheetClose,SheetContent,SheetDescription,SheetFooter,SheetHeader,SheetOverlay,SheetPortal,SheetTitle,SheetTrigger,Sidebar,SidebarContent,SidebarFooter,SidebarGroup,SidebarGroupAction,SidebarGroupContent,SidebarGroupLabel,SidebarHeader,SidebarInput,SidebarInset,SidebarLeft,SidebarMenu,SidebarMenuAction,SidebarMenuBadge,SidebarMenuButton,SidebarMenuItem,SidebarMenuSkeleton,SidebarMenuSub,SidebarMenuSubButton,SidebarMenuSubItem,SidebarProvider,SidebarRail,SidebarRight,SidebarSeparator,SidebarTrigger,SimpleHeader,Skeleton,SlideShow,Switch,Tabs,TabsContent,TabsList,TabsTrigger,TeamsIndexView,TextAndImages,Textarea,Theme,ThemeProvider,ThemeWithShapes,Toast,ToastAction,ToastClose,ToastDescription,ToastProvider,ToastTitle,ToastViewport,Toaster,Toggle,ToggleGroup,ToggleGroupItem,Tooltip,TooltipContent,TooltipProvider,TooltipTrigger,VideoHeader,WhyUs,badgeVariants,buttonVariants,cn,defaultColorScheme,findCapabilityByPath,getAllCapabilities,getCapabilityByTeam,getContextualActions,getDataPart,getFileParts,getTableOfContents,getTextContent,getToolPart,hasDataPart,hasFilePart,hasToolPart,reducer,testCapabilities,toast,toggleVariants,useIsMobile,useSidebar,useToast});