"use strict";(self.webpackChunkfrontend=self.webpackChunkfrontend||[]).push([[334],{1334:(e,t,n)=>{n.r(t),n.d(t,{default:()=>ie});var a=n(89379),r=n(65043),s=n(30502),o=n(44093),i=n(22107),l=n(5371),c=n(96148),d=n(25011),m=n(39081),p=n(87139),h=n(99956),u=n(42703),x=n(82459),g=n(98662),b=n(10202),y=n(22205),f=n(28846),v=n(73212),j=n(35699),w=n(85369),S=n(1009),z=n(47021),k=n(46291);const C=(e,t)=>{try{return!e.contains(t)&&(e.appendChild(t),!0)}catch(n){return console.warn("Failed to append child:",n),!1}},E=(e,t)=>{try{return!!e.contains(t)&&(e.removeChild(t),!0)}catch(n){return console.warn("Failed to remove child:",n),!1}},T=(e,t,n)=>{try{return!!e.contains(n)&&(e.replaceChild(t,n),!0)}catch(a){return console.warn("Failed to replace child:",a),!1}},A=e=>{try{return document.querySelector(e)}catch(t){return console.warn("Invalid selector:",e,t),null}},_=e=>{try{return Array.from(document.querySelectorAll(e))}catch(t){return console.warn("Invalid selector:",e,t),[]}};var P=n(29066),N=n(78801),R=n(3109),I=n(31411),M=n(14566),L=n(51794),F=n(10227),O=n(73225),D=n(76668),W=n(61724),K=n(97569),B=n(7360),Z=n(98481),G=n(88787),V=n(85871),U=n(19077),H=n(91751),J=n(76659),$=n(31629);const Y={hero:{tsx:'\n
\n {/* variant: grid | scroller | swiper | swiper_full */}\n \n
\n
\n
Aktuality
\n

Nadpis

\n
\n
\n \n \n
\n'.trim(),selectors:[".hero-grid",".hero-card",".bg",".meta",".tag",".title"],notes:"Full-bleed variants may use negative margins and viewport width tricks."},matches:{tsx:'\n
\n
\n'.trim(),selectors:[".next-match",".team",".logo",".countdown",".nav.prev",".nav.next"],notes:"Center content, strong contrast on countdown. Keep buttons accessible."},"matches-slider":{tsx:'\n
\n
\n

Z\xe1pasy

\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n'.trim(),selectors:[".matches-slider",".section-head",".see-all",".matches-grid",".matches-track",".match-card",".match-meta",".teams",".team",".score",".matches-tabs"],notes:"Horizontal scrolling track with cards; consider responsive card widths and gaps."},news:{tsx:'\n
\n

Dal\u0161\xed aktuality

\n
\n \n
\n

Title

\n
\n
\n
Zobrazit v\u0161echny aktuality
\n
\n'.trim(),selectors:[".news-list",".section-head",".blog-list",".card",".thumb",".btn"]},table:{tsx:'\n
\n
\n
\n

Tabulky

\n \n
\n
\n \n \n \n
#T\xfdmZVRPSk\xf3reBody
#1T\xfdm\u2026
\n
\n
\n
\n'.trim(),selectors:[".standings",".table-card",".section-head",".standings-table-wrapper",".standings-table-compact",".see-all"],notes:"Compact table; mind overflow-x on small screens."},sponsors:{tsx:'\n
\n

Sponzo\u0159i

\n
\n
\n'.trim(),selectors:[".sponsors",".section-head",".sponsors-grid",".sponsor-tile"]}};var q=n(70579);const Q=e=>{let{elementName:t,onCSSChange:n,currentCSS:a="",currentStyles:l={},theme:d={}}=e;const[p,h]=(0,r.useState)(a),[u,y]=(0,r.useState)(!0),[f,v]=(0,r.useState)(!1),[j,w]=(0,r.useState)("Zv\xfdrazni tento blok: modern\xed vzhled, zaoblen\xe9 rohy, st\xedn, lep\u0161\xed hover efekt; respektuj klubov\xe9 barvy a responzivitu."),[z,k]=(0,r.useState)(!1),C=(0,s.d)(),E=((0,o.dU)("white","gray.800"),(0,o.dU)("gray.200","gray.600"));(0,r.useEffect)(()=>{h(a)},[a]);const T=e=>{try{const t='[data-element="'.concat(e,'"]'),n=document.querySelector(t),a=document.querySelector(".myuibrix-viewport-wrapper")||document.querySelector(".container")||null,r=(()=>{const e=getComputedStyle(document.documentElement),t={};return["--primary","--primary-light","--secondary","--text","--bg","--bg-soft","--club-primary","--club-text-on-primary"].forEach(n=>{const a=e.getPropertyValue(n);a&&(t[n]=a.trim())}),t})(),s=n?getComputedStyle(n):null,o=s?{display:s.display,gridTemplateColumns:s.gridTemplateColumns,gridTemplateRows:s.gridTemplateRows,gap:s.gap,justifyItems:s.justifyItems,alignItems:s.alignItems,color:s.color,backgroundColor:s.backgroundColor,padding:"".concat(s.paddingTop," ").concat(s.paddingRight," ").concat(s.paddingBottom," ").concat(s.paddingLeft),margin:"".concat(s.marginTop," ").concat(s.marginRight," ").concat(s.marginBottom," ").concat(s.marginLeft),fontFamily:s.fontFamily,fontSize:s.fontSize}:{},i=n?n.getBoundingClientRect():null,l=(()=>{try{const t=Array.from((a||document).querySelectorAll("[data-element]")).map(e=>e.getAttribute("data-element")),n=t.findIndex(t=>t===e),r=n>0?t[n-1]:null,s=n>=0&&n({name:e.name,value:e.value})):[],rect:i?{width:i.width,height:i.height}:void 0,computed:o,root_html_snapshot:m},container:d,neighbors:l,css_variables:r,tsx_snippet:p.tsx||void 0,known_selectors:p.selectors||void 0,design_notes:p.notes||void 0}}catch(t){return{}}},A=e=>{const n=document.getElementById("custom-css-".concat(t));if(n&&n.remove(),e.trim()){const n=document.createElement("style");n.id="custom-css-".concat(t);if(/\{[^}]*\}|@media|@keyframes/.test(e))n.textContent=e;else{const a=e.split(";").map(e=>e.trim()).filter(Boolean).map(e=>/!important\s*$/.test(e)?e:"".concat(e," !important")).join(";\n ");n.textContent='\n [data-element="'.concat(t,'"] {\n ').concat(a,";\n }\n ")}document.head.appendChild(n)}};return(0,q.jsx)(i.a,{width:"100%",height:"100%",children:(0,q.jsxs)(R.t,{size:"sm",variant:"enclosed",colorScheme:"purple",children:[(0,q.jsxs)(I.w,{children:[(0,q.jsx)(M.o,{children:(0,q.jsxs)(c.z,{spacing:2,children:[(0,q.jsx)(S.PjK,{}),(0,q.jsx)(m.E,{children:"CSS Editor"})]})}),(0,q.jsx)(M.o,{children:(0,q.jsxs)(c.z,{spacing:2,children:[(0,q.jsx)(S.Vap,{}),(0,q.jsx)(m.E,{children:"Examples"})]})}),(0,q.jsx)(M.o,{children:(0,q.jsxs)(c.z,{spacing:2,children:[(0,q.jsx)(S.FrA,{}),(0,q.jsx)(m.E,{children:"AI (beta)"})]})})]}),(0,q.jsxs)(L.T,{children:[(0,q.jsx)(F.K,{p:0,children:(0,q.jsxs)(b.T,{align:"stretch",spacing:3,p:4,children:[(0,q.jsxs)(c.z,{justify:"space-between",children:[(0,q.jsxs)(m.E,{fontSize:"xs",fontWeight:"bold",color:"gray.500",textTransform:"uppercase",children:["Custom CSS for ",t]}),(0,q.jsxs)(c.z,{spacing:2,children:[(0,q.jsx)(g.$,{size:"xs",leftIcon:(0,q.jsx)(S.Vap,{}),variant:f?"solid":"outline",colorScheme:f?"blue":"gray",onClick:()=>{v(!f),!f&&u&&A(p)},children:"Preview"}),(0,q.jsx)(g.$,{size:"xs",leftIcon:(0,q.jsx)(S.jTZ,{}),variant:"ghost",onClick:()=>{h("");const e=document.getElementById("custom-css-".concat(t));e&&e.remove(),n("")},children:"Reset"})]})]}),!u&&(0,q.jsxs)(G.F,{status:"error",borderRadius:"md",fontSize:"sm",children:[(0,q.jsx)(V._,{}),"Invalid CSS syntax. Check for missing braces or semicolons."]}),(0,q.jsx)(U.T,{value:p,onChange:e=>(e=>{h(e);const t=(e=>{try{return!e.trim()||(e.match(/{/g)||[]).length===(e.match(/}/g)||[]).length}catch(t){return!1}})(e);y(t),t&&f&&A(e)})(e.target.value),placeholder:"/* Enter custom CSS properties */\nbackground: #f0f0f0;\npadding: 20px;\nborder-radius: 10px;",fontFamily:"monospace",fontSize:"sm",minHeight:"300px",bg:(0,o.dU)("gray.50","gray.900"),borderColor:u?E:"red.300",_focus:{borderColor:u?"purple.400":"red.400",boxShadow:u?"0 0 0 1px var(--chakra-colors-purple-400)":"0 0 0 1px var(--chakra-colors-red-400)"}}),(0,q.jsx)(x.c,{}),(0,q.jsxs)(G.F,{status:"info",borderRadius:"md",fontSize:"xs",children:[(0,q.jsx)(V._,{}),(0,q.jsxs)(i.a,{children:[(0,q.jsx)(m.E,{fontWeight:"bold",children:"Pro tip:"}),(0,q.jsx)(m.E,{children:"Use standard CSS properties. Avoid selectors - styles apply to the element automatically."})]})]}),(0,q.jsx)(g.$,{leftIcon:(0,q.jsx)(S.Bc_,{}),colorScheme:"purple",size:"sm",onClick:()=>{u?(A(p),n(p),C({title:"CSS Applied",description:"Custom styles have been applied",status:"success",duration:2e3})):C({title:"Invalid CSS",description:"Please fix CSS errors before saving",status:"error",duration:3e3})},isDisabled:!u,children:"Apply CSS"})]})}),(0,q.jsx)(F.K,{children:(0,q.jsxs)(b.T,{align:"stretch",spacing:3,p:4,children:[(0,q.jsx)(m.E,{fontSize:"xs",fontWeight:"bold",color:"gray.500",textTransform:"uppercase",children:"Quick CSS Examples"}),[{label:"Background Gradient",code:"background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);\ncolor: white;"},{label:"Shadow & Hover",code:"box-shadow: 0 10px 25px rgba(0,0,0,0.1);\ntransition: transform 0.3s;\n\n&:hover {\n transform: translateY(-5px);\n}"},{label:"Border Radius",code:"border-radius: 20px;\noverflow: hidden;"},{label:"Animation",code:"animation: fadeIn 1s ease-in;\n\n@keyframes fadeIn {\n from { opacity: 0; }\n to { opacity: 1; }\n}"}].map((e,t)=>(0,q.jsxs)(i.a,{p:3,borderRadius:"md",border:"1px",borderColor:E,cursor:"pointer",transition:"all 0.2s",_hover:{borderColor:"purple.400",transform:"translateX(4px)"},onClick:()=>h(e.code),children:[(0,q.jsx)(m.E,{fontWeight:"bold",fontSize:"sm",mb:2,children:e.label}),(0,q.jsx)(H.C,{fontSize:"xs",display:"block",whiteSpace:"pre",p:2,borderRadius:"sm",bg:(0,o.dU)("gray.100","gray.900"),children:e.code})]},t))]})}),(0,q.jsx)(F.K,{children:(0,q.jsxs)(b.T,{align:"stretch",spacing:3,p:4,children:[(0,q.jsx)(m.E,{fontSize:"xs",fontWeight:"bold",color:"gray.500",textTransform:"uppercase",children:"Vygenerovat CSS pomoc\xed AI"}),(0,q.jsx)(U.T,{value:j,onChange:e=>w(e.target.value),placeholder:"Popi\u0161te, jak m\xe1 dan\xfd blok vypadat (\u010desky). Nap\u0159.: Tmav\xe9 pozad\xed, sv\u011btl\xfd text, zaoblen\xe9 rohy, 2-sloupcov\xfd layout na desktopu, jeden sloupec na mobilu.",fontSize:"sm",minHeight:"120px",bg:(0,o.dU)("gray.50","gray.900"),borderColor:E}),(0,q.jsx)(c.z,{spacing:2,flexWrap:"wrap",children:["Tmav\xe9 pozad\xed a sv\u011btl\xfd text","Sklen\u011bn\xfd efekt (glassmorphism)","Zaoblen\xe9 rohy a m\u011bkk\xfd st\xedn","Dvou-sloupcov\xfd grid, mobil 1 sloupec","Akcent klubov\xfdch barev"].map((e,t)=>(0,q.jsx)(g.$,{size:"xs",variant:"outline",onClick:()=>w(t=>"".concat(t," ").concat(e,".")),children:e},t))}),(0,q.jsxs)(c.z,{children:[(0,q.jsx)(g.$,{leftIcon:z?(0,q.jsx)(J.y,{size:"xs"}):(0,q.jsx)(S.FrA,{}),colorScheme:"purple",size:"sm",isLoading:z,onClick:async()=>{try{k(!0);const e={prompt:j,element_name:t,root_selector:'[data-element="'.concat(t,'"]'),current_css:p,current_styles:l||{},theme:d||{},breakpoints:[640,960,1200],context:T(t)},a=await(0,$.Pi)(e),r=((null===a||void 0===a?void 0:a.css)||"").trim();if(!r)return void C({title:"AI nevr\xe1tila CSS",status:"warning",duration:2500});h(r),y(!0),v(!0),A(r),n(r),C({title:"CSS vygenerov\xe1no",status:"success",duration:1500})}catch(e){C({title:"Chyba p\u0159i generov\xe1n\xed CSS",description:(null===e||void 0===e?void 0:e.message)||"Zkuste to znovu",status:"error",duration:3e3})}finally{k(!1)}},children:"Vygenerovat CSS"}),(0,q.jsx)(g.$,{size:"sm",variant:"ghost",onClick:()=>w(""),children:"Vymazat zad\xe1n\xed"})]}),(0,q.jsxs)(G.F,{status:"info",borderRadius:"md",fontSize:"xs",children:[(0,q.jsx)(V._,{}),'AI v\xfdstup je automaticky scope-nut\xfd pod `[data-element="n\xe1zev"]`. Po vygenerov\xe1n\xed se CSS p\u0159edvypln\xed do editoru a lze ho d\xe1l upravovat.']})]})})]})]})})};var X=n(7189);const ee=e=>{let{elementName:t}=e;const n=(0,o.dU)("blue.50","blue.900"),a=(0,o.dU)("blue.200","blue.700"),r=(s=t,{hero:[{label:"Manage Articles",url:"/admin/articles",icon:S.jH2,description:"Edit featured articles"},{label:"Upload Images",url:"/admin/soubory",icon:S.fZZ,description:"Manage hero images"}],news:[{label:"Manage Articles",url:"/admin/articles",icon:S.jH2,description:"Create and edit news"},{label:"Categories",url:"/admin/categories",icon:S.cnX,description:"Organize article categories"},{label:"Article Settings",url:"/admin/settings/articles",icon:S.VSk,description:"Configure display options"}],matches:[{label:"Manage Matches",url:"/admin/matches",icon:S.wIk,description:"Schedule and edit matches"},{label:"Match Settings",url:"/admin/settings/matches",icon:S.VSk,description:"Configure match display"}],table:[{label:"Update Table",url:"/admin/table",icon:S.VSk,description:"Refresh league standings"},{label:"Team Settings",url:"/admin/settings/team",icon:S.VSk}],team:[{label:"Manage Players",url:"/admin/team/players",icon:S.cfS,description:"Add and edit players"},{label:"Team Settings",url:"/admin/settings/team",icon:S.VSk,description:"Configure team display"}],videos:[{label:"Manage Videos",url:"/admin/videos",icon:S.pVQ,description:"Add YouTube videos"},{label:"Video Settings",url:"/admin/settings/videos",icon:S.VSk,description:"Configure video player"}],gallery:[{label:"Gallery Settings",url:"/admin/settings/gallery",icon:S.fZZ,description:"Set gallery URL"}],merch:[{label:"Fanshop Settings",url:"/admin/settings/fanshop",icon:S.iHs,description:"Configure merchandise"}],newsletter:[{label:"Newsletter Settings",url:"/admin/settings/newsletter",icon:S.pHD,description:"Email configuration"},{label:"Subscribers",url:"/admin/newsletter/subscribers",icon:S.cfS,description:"View subscribers"}],sponsors:[{label:"Manage Sponsors",url:"/admin/sponsors",icon:S.fZZ,description:"Add and edit sponsors"}]}[s]||[{label:"Administrace",url:"/admin",icon:S.VSk,description:"P\u0159ej\xedt do administrace"}]);var s;return(0,q.jsx)(i.a,{children:(0,q.jsxs)(b.T,{align:"stretch",spacing:3,children:[(0,q.jsxs)(c.z,{children:[(0,q.jsx)(d.I,{as:S.HaR,color:"blue.500"}),(0,q.jsx)(m.E,{fontSize:"xs",fontWeight:"bold",color:"gray.500",textTransform:"uppercase",children:"Rychl\xe9 odkazy administrace"})]}),(0,q.jsx)(i.a,{p:3,borderRadius:"md",bg:n,border:"1px",borderColor:a,children:(0,q.jsx)(b.T,{align:"stretch",spacing:2,divider:(0,q.jsx)(x.c,{}),children:r.map((e,t)=>(0,q.jsx)(X.N,{href:e.url,_hover:{textDecoration:"none"},isExternal:!0,children:(0,q.jsxs)(c.z,{p:2,borderRadius:"md",transition:"all 0.2s",_hover:{bg:(0,o.dU)("white","gray.800"),transform:"translateX(4px)"},justify:"space-between",children:[(0,q.jsxs)(c.z,{spacing:3,flex:1,children:[(0,q.jsx)(d.I,{as:e.icon,boxSize:4,color:"blue.500"}),(0,q.jsxs)(b.T,{align:"start",spacing:0,flex:1,children:[(0,q.jsx)(m.E,{fontSize:"sm",fontWeight:"medium",children:e.label}),e.description&&(0,q.jsx)(m.E,{fontSize:"xs",color:"gray.500",children:e.description})]})]}),e.badge&&(0,q.jsx)(p.E,{colorScheme:"green",fontSize:"xs",children:e.badge}),(0,q.jsx)(d.I,{as:S.HaR,boxSize:3,color:"gray.400"})]})},t))})}),(0,q.jsx)(m.E,{fontSize:"xs",color:"gray.500",textAlign:"center",children:"\ud83d\udca1 Tyto odkazy v\xe1m pomohou spravovat obsah t\xe9to sekce"})]})})};var te=n(49483),ne=n(52976);const ae=e=>{var t;let{elementName:n,onStyleChange:s,currentStyles:l={}}=e;const d=(0,o.dU)("white","gray.800"),p=((0,o.dU)("gray.200","gray.600"),(0,N.N)()),h=p.primary||"#0b5cff",[u,y]=(0,r.useState)((0,a.A)({fontFamily:l.fontFamily||"Inter",fontSize:l.fontSize||16,fontWeight:l.fontWeight||400,lineHeight:l.lineHeight||1.5,letterSpacing:l.letterSpacing||0,textTransform:l.textTransform||"none",color:l.color||"#000000",backgroundColor:l.backgroundColor||"#ffffff",paddingTop:l.paddingTop||0,paddingRight:l.paddingRight||0,paddingBottom:l.paddingBottom||0,paddingLeft:l.paddingLeft||0,marginTop:l.marginTop||0,marginRight:l.marginRight||0,marginBottom:l.marginBottom||0,marginLeft:l.marginLeft||0,width:l.width||"auto",height:l.height||"auto",display:l.display||"block",gridTemplateColumns:l.gridTemplateColumns||"repeat(3, 1fr)",gridTemplateRows:l.gridTemplateRows||"auto",gridColumnGap:l.gridColumnGap||16,gridRowGap:l.gridRowGap||16,gridAutoFlow:l.gridAutoFlow||"row",alignItems:l.alignItems||"stretch",justifyItems:l.justifyItems||"stretch",customCSS:l.customCSS||""},l));(0,r.useEffect)(()=>{y((0,a.A)({fontFamily:l.fontFamily||"Inter",fontSize:l.fontSize||16,fontWeight:l.fontWeight||400,lineHeight:l.lineHeight||1.5,letterSpacing:l.letterSpacing||0,textTransform:l.textTransform||"none",color:l.color||"#000000",backgroundColor:l.backgroundColor||"#ffffff",paddingTop:l.paddingTop||0,paddingRight:l.paddingRight||0,paddingBottom:l.paddingBottom||0,paddingLeft:l.paddingLeft||0,marginTop:l.marginTop||0,marginRight:l.marginRight||0,marginBottom:l.marginBottom||0,marginLeft:l.marginLeft||0,width:l.width||"auto",height:l.height||"auto",display:l.display||"block",gridTemplateColumns:l.gridTemplateColumns||"repeat(3, 1fr)",gridTemplateRows:l.gridTemplateRows||"auto",gridColumnGap:l.gridColumnGap||16,gridRowGap:l.gridRowGap||16,gridAutoFlow:l.gridAutoFlow||"row",alignItems:l.alignItems||"stretch",justifyItems:l.justifyItems||"stretch",customCSS:l.customCSS||""},l))},[n,l]);const f=(e,t)=>{const n=(0,a.A)((0,a.A)({},u),{},{[e]:t});y(n),s(n)},[v,z]=(0,r.useState)((null===(t=te.qE[0])||void 0===t?void 0:t.id)||""),k=(0,r.useMemo)(()=>te.qE.find(e=>e.id===v)||te.qE[0],[v]),C=(0,r.useMemo)(()=>{const e=new Map;return te.qE.forEach(t=>{e.set(t.heading,{name:t.heading,googleFontsUrl:t.googleFontsUrl}),e.set(t.body,{name:t.body,googleFontsUrl:t.googleFontsUrl})}),Array.from(e.values())},[]);return(0,q.jsx)(i.a,{width:"280px",bg:d,borderRight:"1px",borderColor:h,height:"100vh",overflowY:"auto",pt:"60px",children:(0,q.jsxs)(R.t,{size:"sm",colorScheme:"blue",children:[(0,q.jsxs)(I.w,{px:2,flexWrap:"wrap",children:[(0,q.jsxs)(M.o,{children:[(0,q.jsx)(S.MRc,{})," ",(0,q.jsx)(m.E,{ml:1,children:"Obsah"})]}),(0,q.jsxs)(M.o,{children:[(0,q.jsx)(S.Iy6,{})," ",(0,q.jsx)(m.E,{ml:1,children:"Styl"})]}),(0,q.jsxs)(M.o,{children:[(0,q.jsx)(S.Dw7,{})," ",(0,q.jsx)(m.E,{ml:1,children:"Rozvr\u017een\xed"})]}),(0,q.jsxs)(M.o,{children:[(0,q.jsx)(S.PjK,{})," ",(0,q.jsx)(m.E,{ml:1,children:"CSS"})]}),(0,q.jsxs)(M.o,{children:[(0,q.jsx)(S.HaR,{})," ",(0,q.jsx)(m.E,{ml:1,children:"Admin"})]})]}),(0,q.jsxs)(L.T,{children:[(0,q.jsx)(F.K,{children:(0,q.jsxs)(b.T,{align:"stretch",spacing:4,children:[(0,q.jsx)(m.E,{fontWeight:"bold",fontSize:"sm",textTransform:"uppercase",color:"gray.500",children:"Typografie"}),(0,q.jsxs)(O.MJ,{children:[(0,q.jsx)(D.l,{fontSize:"xs",children:"P\xe1rov\xe1n\xed font\u016f (Setup)"}),(0,q.jsx)(c.z,{children:(0,q.jsx)(W.l,{size:"sm",value:v,onChange:e=>{const t=e.target.value;z(t);const n=te.qE.find(e=>e.id===t);n&&(0,te.Fd)(n.googleFontsUrl)},children:te.qE.map(e=>(0,q.jsx)("option",{value:e.id,children:e.name},e.id))})}),(0,q.jsxs)(c.z,{spacing:2,mt:2,children:[(0,q.jsx)(g.$,{size:"xs",variant:"outline",onClick:()=>{k&&((0,te.Fd)(k.googleFontsUrl),f("fontFamily",k.cssHeading))},children:"Pou\u017e\xedt nadpisov\xfd"}),(0,q.jsx)(g.$,{size:"xs",variant:"outline",onClick:()=>{k&&((0,te.Fd)(k.googleFontsUrl),f("fontFamily",k.cssBody))},children:"Pou\u017e\xedt textov\xfd"})]})]}),(0,q.jsxs)(O.MJ,{children:[(0,q.jsx)(D.l,{fontSize:"xs",children:"Dostupn\xe9 fonty (Setup)"}),(0,q.jsx)(W.l,{size:"sm",value:u.fontFamily,onChange:e=>{const t=e.target.value;f("fontFamily",t);const n=te.qE.find(e=>e.cssHeading===t||e.cssBody===t);n&&(0,te.Fd)(n.googleFontsUrl)},children:C.map(e=>(0,q.jsx)("option",{value:e.name,children:e.name},e.name))})]}),(0,q.jsxs)(O.MJ,{children:[(0,q.jsx)(D.l,{fontSize:"xs",children:"P\xedsmo"}),(0,q.jsxs)(W.l,{size:"sm",value:u.fontFamily,onChange:e=>f("fontFamily",e.target.value),children:[(0,q.jsx)("option",{value:"Inter",children:"Inter"}),(0,q.jsx)("option",{value:"Roboto",children:"Roboto"}),(0,q.jsx)("option",{value:"Open Sans",children:"Open Sans"}),(0,q.jsx)("option",{value:"Lato",children:"Lato"}),(0,q.jsx)("option",{value:"Montserrat",children:"Montserrat"}),(0,q.jsx)("option",{value:"Poppins",children:"Poppins"}),(0,q.jsx)("option",{value:"Georgia",children:"Georgia"}),(0,q.jsx)("option",{value:"Times New Roman",children:"Times New Roman"})]})]}),(0,q.jsxs)(O.MJ,{children:[(0,q.jsx)(D.l,{fontSize:"xs",children:"Velikost (px)"}),(0,q.jsx)(c.z,{children:(0,q.jsxs)(K.Q7,{size:"sm",value:u.fontSize,min:8,max:128,onChange:(e,t)=>f("fontSize",t),flex:1,children:[(0,q.jsx)(K.OO,{}),(0,q.jsxs)(K.lw,{children:[(0,q.jsx)(K.Q0,{}),(0,q.jsx)(K.Sh,{})]})]})})]}),(0,q.jsxs)(O.MJ,{children:[(0,q.jsx)(D.l,{fontSize:"xs",children:"Tlou\u0161\u0165ka"}),(0,q.jsxs)(c.z,{spacing:2,children:[(0,q.jsxs)(B.Ap,{value:u.fontWeight,min:100,max:900,step:100,onChange:e=>f("fontWeight",e),flex:1,children:[(0,q.jsx)(B.hB,{children:(0,q.jsx)(B.hJ,{bg:h})}),(0,q.jsx)(B.OQ,{})]}),(0,q.jsx)(m.E,{fontSize:"xs",minW:"40px",children:u.fontWeight})]})]}),(0,q.jsxs)(O.MJ,{children:[(0,q.jsx)(D.l,{fontSize:"xs",children:"\u0158\xe1dkov\xe1n\xed"}),(0,q.jsxs)(c.z,{spacing:2,children:[(0,q.jsxs)(B.Ap,{value:u.lineHeight,min:.5,max:3,step:.1,onChange:e=>f("lineHeight",e),flex:1,children:[(0,q.jsx)(B.hB,{children:(0,q.jsx)(B.hJ,{bg:h})}),(0,q.jsx)(B.OQ,{})]}),(0,q.jsx)(m.E,{fontSize:"xs",minW:"40px",children:u.lineHeight.toFixed(1)})]})]}),(0,q.jsxs)(O.MJ,{children:[(0,q.jsx)(D.l,{fontSize:"xs",children:"Mezera mezi p\xedsmeny (px)"}),(0,q.jsxs)(c.z,{spacing:2,children:[(0,q.jsxs)(B.Ap,{value:u.letterSpacing,min:-5,max:10,step:.1,onChange:e=>f("letterSpacing",e),flex:1,children:[(0,q.jsx)(B.hB,{children:(0,q.jsx)(B.hJ,{bg:h})}),(0,q.jsx)(B.OQ,{})]}),(0,q.jsx)(m.E,{fontSize:"xs",minW:"40px",children:u.letterSpacing.toFixed(1)})]})]}),(0,q.jsxs)(O.MJ,{children:[(0,q.jsx)(D.l,{fontSize:"xs",children:"Transformace"}),(0,q.jsxs)(W.l,{size:"sm",value:u.textTransform,onChange:e=>f("textTransform",e.target.value),children:[(0,q.jsx)("option",{value:"none",children:"\u017d\xe1dn\xe9"}),(0,q.jsx)("option",{value:"uppercase",children:"VELK\xc1 P\xcdSMENA"}),(0,q.jsx)("option",{value:"lowercase",children:"mal\xe1 p\xedsmena"}),(0,q.jsx)("option",{value:"capitalize",children:"Prvn\xed p\xedsmena velk\xe1"})]})]})]})}),(0,q.jsx)(F.K,{children:(0,q.jsxs)(b.T,{align:"stretch",spacing:4,children:[(0,q.jsx)(m.E,{fontWeight:"bold",fontSize:"sm",textTransform:"uppercase",color:"gray.500",children:"Barvy"}),(0,q.jsxs)(O.MJ,{children:[(0,q.jsx)(D.l,{fontSize:"xs",children:"Barva textu"}),(0,q.jsx)(ne.A,{value:u.color,onChange:e=>f("color",e),recentStorageKey:"editor-text-".concat(n)})]}),(0,q.jsxs)(O.MJ,{children:[(0,q.jsx)(D.l,{fontSize:"xs",children:"Barva pozad\xed"}),(0,q.jsx)(ne.A,{value:u.backgroundColor,onChange:e=>f("backgroundColor",e),recentStorageKey:"editor-bg-".concat(n)})]}),(0,q.jsx)(x.c,{my:2}),(0,q.jsx)(m.E,{fontWeight:"bold",fontSize:"sm",textTransform:"uppercase",color:"gray.500",children:"Odsazen\xed a okraje"}),(0,q.jsxs)(O.MJ,{children:[(0,q.jsx)(D.l,{fontSize:"xs",children:"Vnit\u0159n\xed odsazen\xed (px)"}),(0,q.jsxs)(b.T,{spacing:2,children:[(0,q.jsxs)(c.z,{width:"100%",children:[(0,q.jsx)(m.E,{fontSize:"xs",minW:"20px",children:"N"}),(0,q.jsx)(K.Q7,{size:"xs",value:u.paddingTop,min:0,onChange:(e,t)=>f("paddingTop",t),flex:1,children:(0,q.jsx)(K.OO,{})})]}),(0,q.jsxs)(c.z,{width:"100%",children:[(0,q.jsx)(m.E,{fontSize:"xs",minW:"20px",children:"P"}),(0,q.jsx)(K.Q7,{size:"xs",value:u.paddingRight,min:0,onChange:(e,t)=>f("paddingRight",t),flex:1,children:(0,q.jsx)(K.OO,{})})]}),(0,q.jsxs)(c.z,{width:"100%",children:[(0,q.jsx)(m.E,{fontSize:"xs",minW:"20px",children:"D"}),(0,q.jsx)(K.Q7,{size:"xs",value:u.paddingBottom,min:0,onChange:(e,t)=>f("paddingBottom",t),flex:1,children:(0,q.jsx)(K.OO,{})})]}),(0,q.jsxs)(c.z,{width:"100%",children:[(0,q.jsx)(m.E,{fontSize:"xs",minW:"20px",children:"L"}),(0,q.jsx)(K.Q7,{size:"xs",value:u.paddingLeft,min:0,onChange:(e,t)=>f("paddingLeft",t),flex:1,children:(0,q.jsx)(K.OO,{})})]})]})]}),(0,q.jsxs)(O.MJ,{children:[(0,q.jsx)(D.l,{fontSize:"xs",children:"Vn\u011bj\u0161\xed okraj (px)"}),(0,q.jsxs)(b.T,{spacing:2,children:[(0,q.jsxs)(c.z,{width:"100%",children:[(0,q.jsx)(m.E,{fontSize:"xs",minW:"20px",children:"N"}),(0,q.jsx)(K.Q7,{size:"xs",value:u.marginTop,onChange:(e,t)=>f("marginTop",t),flex:1,children:(0,q.jsx)(K.OO,{})})]}),(0,q.jsxs)(c.z,{width:"100%",children:[(0,q.jsx)(m.E,{fontSize:"xs",minW:"20px",children:"P"}),(0,q.jsx)(K.Q7,{size:"xs",value:u.marginRight,onChange:(e,t)=>f("marginRight",t),flex:1,children:(0,q.jsx)(K.OO,{})})]}),(0,q.jsxs)(c.z,{width:"100%",children:[(0,q.jsx)(m.E,{fontSize:"xs",minW:"20px",children:"D"}),(0,q.jsx)(K.Q7,{size:"xs",value:u.marginBottom,onChange:(e,t)=>f("marginBottom",t),flex:1,children:(0,q.jsx)(K.OO,{})})]}),(0,q.jsxs)(c.z,{width:"100%",children:[(0,q.jsx)(m.E,{fontSize:"xs",minW:"20px",children:"L"}),(0,q.jsx)(K.Q7,{size:"xs",value:u.marginLeft,onChange:(e,t)=>f("marginLeft",t),flex:1,children:(0,q.jsx)(K.OO,{})})]})]})]})]})}),(0,q.jsx)(F.K,{children:(0,q.jsxs)(b.T,{align:"stretch",spacing:4,children:[(0,q.jsx)(m.E,{fontWeight:"bold",fontSize:"sm",textTransform:"uppercase",color:"gray.500",children:"M\u0159\xed\u017ekov\xe9 rozlo\u017een\xed"}),(0,q.jsxs)(O.MJ,{display:"flex",alignItems:"center",children:[(0,q.jsx)(D.l,{fontSize:"xs",mb:0,flex:1,children:"Povolit m\u0159\xed\u017ekov\xe9 rozlo\u017een\xed"}),(0,q.jsx)(Z.d,{size:"sm",isChecked:"grid"===u.display,onChange:e=>f("display",e.target.checked?"grid":"block"),sx:{"span[data-checked]":{bg:h,borderColor:h}}})]}),"grid"===u.display&&(0,q.jsxs)(q.Fragment,{children:[(0,q.jsx)(x.c,{}),(0,q.jsxs)(O.MJ,{children:[(0,q.jsx)(D.l,{fontSize:"xs",fontWeight:"bold",children:"Rychl\xe9 \u0161ablony"}),(0,q.jsxs)(b.T,{spacing:2,children:[(0,q.jsx)(g.$,{size:"xs",width:"100%",variant:"outline",onClick:()=>f("gridTemplateColumns","1fr"),justifyContent:"flex-start",children:(0,q.jsxs)(c.z,{spacing:2,children:[(0,q.jsx)(S.PCV,{}),(0,q.jsx)(m.E,{children:"Jeden sloupec"})]})}),(0,q.jsx)(g.$,{size:"xs",width:"100%",variant:"outline",onClick:()=>f("gridTemplateColumns","1fr 1fr"),justifyContent:"flex-start",children:(0,q.jsxs)(c.z,{spacing:2,children:[(0,q.jsx)(w.vgu,{}),(0,q.jsx)(m.E,{children:"Dva stejn\xe9 (50 % / 50 %)"})]})}),(0,q.jsx)(g.$,{size:"xs",width:"100%",variant:"outline",onClick:()=>f("gridTemplateColumns","2fr 1fr"),justifyContent:"flex-start",children:(0,q.jsxs)(c.z,{spacing:2,children:[(0,q.jsx)(S.vQY,{}),(0,q.jsx)(m.E,{children:"Vlevo v\u011bt\u0161\xed (66 % / 33 %)"})]})}),(0,q.jsx)(g.$,{size:"xs",width:"100%",variant:"outline",onClick:()=>f("gridTemplateColumns","1fr 2fr"),justifyContent:"flex-start",children:(0,q.jsxs)(c.z,{spacing:2,children:[(0,q.jsx)(S.vQY,{style:{transform:"scaleX(-1)"}}),(0,q.jsx)(m.E,{children:"Vpravo v\u011bt\u0161\xed (33 % / 66 %)"})]})}),(0,q.jsx)(g.$,{size:"xs",width:"100%",variant:"outline",onClick:()=>f("gridTemplateColumns","1fr 1fr 1fr"),justifyContent:"flex-start",children:(0,q.jsxs)(c.z,{spacing:2,children:[(0,q.jsx)(S.QPV,{}),(0,q.jsx)(m.E,{children:"T\u0159i stejn\xe9 (33 % / 33 % / 33 %)"})]})}),(0,q.jsx)(g.$,{size:"xs",width:"100%",variant:"outline",onClick:()=>f("gridTemplateColumns","2fr 1fr 1fr"),justifyContent:"flex-start",children:(0,q.jsxs)(c.z,{spacing:2,children:[(0,q.jsx)(w.lSZ,{}),(0,q.jsx)(m.E,{children:"Zv\xfdrazn\u011bn\xfd + dva (50 % / 25 % / 25 %)"})]})}),(0,q.jsx)(g.$,{size:"xs",width:"100%",variant:"outline",onClick:()=>f("gridTemplateColumns","repeat(4, 1fr)"),justifyContent:"flex-start",children:(0,q.jsxs)(c.z,{spacing:2,children:[(0,q.jsx)(w.PVM,{}),(0,q.jsx)(m.E,{children:"\u010cty\u0159i stejn\xe9 (25 % ka\u017ed\xe1)"})]})}),(0,q.jsx)(g.$,{size:"xs",width:"100%",variant:"outline",onClick:()=>f("gridTemplateColumns","3fr 1fr"),justifyContent:"flex-start",children:(0,q.jsxs)(c.z,{spacing:2,children:[(0,q.jsx)(S.E19,{}),(0,q.jsx)(m.E,{children:"Hlavn\xed + postrann\xed (75 % / 25 %)"})]})})]})]}),(0,q.jsx)(x.c,{}),(0,q.jsxs)(O.MJ,{children:[(0,q.jsx)(D.l,{fontSize:"xs",children:"Sloupce m\u0159\xed\u017eky"}),(0,q.jsx)(j.p,{size:"sm",value:u.gridTemplateColumns,onChange:e=>f("gridTemplateColumns",e.target.value),placeholder:"nap\u0159. 1fr 2fr nebo 300px 1fr",fontFamily:"monospace",fontSize:"xs"}),(0,q.jsx)(m.E,{fontSize:"10px",color:"gray.500",mt:1,children:"P\u0159\xedklady: 1fr 1fr | 2fr 1fr | 200px 1fr | repeat(3, 1fr)"})]}),(0,q.jsxs)(O.MJ,{children:[(0,q.jsx)(D.l,{fontSize:"xs",children:"\u0158\xe1dky m\u0159\xed\u017eky"}),(0,q.jsx)(j.p,{size:"sm",value:u.gridTemplateRows,onChange:e=>f("gridTemplateRows",e.target.value),placeholder:"auto nebo 200px 1fr",fontFamily:"monospace",fontSize:"xs"})]}),(0,q.jsxs)(O.MJ,{children:[(0,q.jsx)(D.l,{fontSize:"xs",children:"Mezera mezi sloupci (px)"}),(0,q.jsxs)(c.z,{spacing:2,children:[(0,q.jsxs)(B.Ap,{value:u.gridColumnGap,min:0,max:100,step:4,onChange:e=>f("gridColumnGap",e),flex:1,children:[(0,q.jsx)(B.hB,{children:(0,q.jsx)(B.hJ,{bg:"purple.500"})}),(0,q.jsx)(B.OQ,{})]}),(0,q.jsxs)(m.E,{fontSize:"xs",minW:"40px",children:[u.gridColumnGap,"px"]})]})]}),(0,q.jsxs)(O.MJ,{children:[(0,q.jsx)(D.l,{fontSize:"xs",children:"Mezera mezi \u0159\xe1dky (px)"}),(0,q.jsxs)(c.z,{spacing:2,children:[(0,q.jsxs)(B.Ap,{value:u.gridRowGap,min:0,max:100,step:4,onChange:e=>f("gridRowGap",e),flex:1,children:[(0,q.jsx)(B.hB,{children:(0,q.jsx)(B.hJ,{bg:"purple.500"})}),(0,q.jsx)(B.OQ,{})]}),(0,q.jsxs)(m.E,{fontSize:"xs",minW:"40px",children:[u.gridRowGap,"px"]})]})]}),(0,q.jsx)(x.c,{}),(0,q.jsxs)(O.MJ,{children:[(0,q.jsx)(D.l,{fontSize:"xs",children:"Automatick\xe9 rozm\xedst\u011bn\xed"}),(0,q.jsxs)(W.l,{size:"sm",value:u.gridAutoFlow,onChange:e=>f("gridAutoFlow",e.target.value),children:[(0,q.jsx)("option",{value:"row",children:"\u0158\xe1dek (vodorovn\u011b)"}),(0,q.jsx)("option",{value:"column",children:"Sloupec (svisle)"}),(0,q.jsx)("option",{value:"row dense",children:"\u0158\xe1dek (zahu\u0161t\u011bn\xfd)"}),(0,q.jsx)("option",{value:"column dense",children:"Sloupec (zahu\u0161t\u011bn\xfd)"})]})]}),(0,q.jsxs)(O.MJ,{children:[(0,q.jsx)(D.l,{fontSize:"xs",children:"Zarovn\xe1n\xed prvk\u016f (vertik\xe1ln\u011b)"}),(0,q.jsxs)(W.l,{size:"sm",value:u.alignItems,onChange:e=>f("alignItems",e.target.value),children:[(0,q.jsx)("option",{value:"stretch",children:"Rozt\xe1hnout"}),(0,q.jsx)("option",{value:"start",children:"Za\u010d\xe1tek"}),(0,q.jsx)("option",{value:"center",children:"St\u0159ed"}),(0,q.jsx)("option",{value:"end",children:"Konec"}),(0,q.jsx)("option",{value:"baseline",children:"Z\xe1kladn\xed \u0159\xe1dek"})]})]}),(0,q.jsxs)(O.MJ,{children:[(0,q.jsx)(D.l,{fontSize:"xs",children:"Zarovn\xe1n\xed prvk\u016f (horizont\xe1ln\u011b)"}),(0,q.jsxs)(W.l,{size:"sm",value:u.justifyItems,onChange:e=>f("justifyItems",e.target.value),children:[(0,q.jsx)("option",{value:"stretch",children:"Rozt\xe1hnout"}),(0,q.jsx)("option",{value:"start",children:"Za\u010d\xe1tek"}),(0,q.jsx)("option",{value:"center",children:"St\u0159ed"}),(0,q.jsx)("option",{value:"end",children:"Konec"})]})]})]})]})}),(0,q.jsx)(F.K,{p:0,children:(0,q.jsx)(Q,{elementName:n,onCSSChange:e=>f("customCSS",e),currentCSS:u.customCSS||"",currentStyles:u,theme:{primary:p.primary,secondary:p.secondary,accent:p.accent}})}),(0,q.jsx)(F.K,{children:(0,q.jsx)(ee,{elementName:n})})]})]})})},re=["style-pack","container","header","hero-topbar","hero","news","matches","matches-slider","table","team","gallery","videos","merch","newsletter","poll","sponsors","banner"],se=[{page_type:"homepage",element_name:"style-pack",variant:"default",visible:!0,display_order:-1,settings:{}},{page_type:"homepage",element_name:"container",variant:"boxed",visible:!0,display_order:-1,settings:{}},{page_type:"homepage",element_name:"header",variant:"unified",visible:!0,display_order:0,settings:{}},{page_type:"homepage",element_name:"hero-topbar",variant:"brand",visible:!0,display_order:1,settings:{}},{page_type:"homepage",element_name:"hero",variant:"grid",visible:!0,display_order:1,settings:{}},{page_type:"homepage",element_name:"news",variant:"grid_one",visible:!0,display_order:11,settings:{}},{page_type:"homepage",element_name:"matches",variant:"compact",visible:!0,display_order:2,settings:{}},{page_type:"homepage",element_name:"matches-slider",variant:"carousel",visible:!0,display_order:4,settings:{}},{page_type:"homepage",element_name:"sponsors",variant:"grid",visible:!0,display_order:9,settings:{}},{page_type:"homepage",element_name:"gallery",variant:"grid",visible:!1,display_order:5,settings:{}},{page_type:"homepage",element_name:"videos",variant:"carousel",visible:!1,display_order:7,settings:{}},{page_type:"homepage",element_name:"team",variant:"grid",visible:!1,display_order:6,settings:{}},{page_type:"homepage",element_name:"merch",variant:"grid",visible:!0,display_order:8,settings:{}},{page_type:"homepage",element_name:"table",variant:"split_news",visible:!0,display_order:3,settings:{}},{page_type:"homepage",element_name:"banner",variant:"top",visible:!1,display_order:10,settings:{}},{page_type:"homepage",element_name:"newsletter",variant:"default",visible:!1,display_order:4,settings:{}},{page_type:"homepage",element_name:"poll",variant:"vertical",visible:!1,display_order:12,settings:{}}],oe={hero:["grid","scroller","swiper","swiper_full"],news:["grid_one","grid_two","grid","list","scroller"],matches:["compact"],sponsors:["grid","slider","scroller","logos3","pyramid"],gallery:["grid"],videos:["grid","carousel"],merch:["grid"],table:["split_news"],banner:["top"],sidebar:["right"],newsletter:["default"]},ie=e=>{var t;let{pageType:n,onConfigChange:R}=e;const{user:I}=(0,P.A)(),M="admin"===(null===I||void 0===I?void 0:I.role),L=(0,N.N)(),[F,O]=(0,r.useState)(!1),[D,W]=(0,r.useState)([]),[K,B]=(0,r.useState)({}),[Z,G]=(0,r.useState)(!1),[V,U]=(0,r.useState)(null),[H,J]=(0,r.useState)(null),[$,Y]=(0,r.useState)(null),[Q,X]=(0,r.useState)(!1),[ee,te]=(0,r.useState)(!1),[ne,ie]=(0,r.useState)(!1),[le,ce]=(0,r.useState)(new Set),[de,me]=(0,r.useState)([]),[pe,he]=(0,r.useState)(null),[ue,xe]=(0,r.useState)(null),[ge,be]=(0,r.useState)("desktop"),[ye,fe]=(0,r.useState)({}),[ve,je]=(0,r.useState)(!1),[we,Se]=(0,r.useState)(!1),[ze,ke]=(0,r.useState)(""),[Ce,Ee]=(0,r.useState)("all"),[Te,Ae]=(0,r.useState)(!0),[_e,Pe]=(0,r.useState)({variants:{},visible:new Set,order:[],css:{}}),Ne=(0,r.useRef)(null),Re=(0,r.useRef)(!1),[Ie,Me]=(0,r.useState)(!1),[Le,Fe]=(0,r.useState)(null),[Oe,De]=(0,r.useState)(0),We=(0,r.useRef)([]);(0,r.useEffect)(()=>{We.current=de},[de]);const Ke=(0,r.useRef)(()=>{}),[Be,Ze]=(0,r.useState)({stylePicker:{x:0,y:0,width:360,height:550},layersPanel:{x:0,y:0,width:320,height:600},visualStylePanel:{x:0,y:60,width:320,height:700},elementPicker:{x:0,y:0,width:600,height:600},elementsPanel:{x:0,y:72,width:420,height:700}}),[Ge,Ve]=(0,r.useState)(null),[Ue,He]=(0,r.useState)({x:0,y:0}),[Je,$e]=(0,r.useState)(null),Ye=(0,s.d)(),qe=((0,o.dU)("white","gray.800"),(0,o.dU)("gray.200","gray.600")),Qe=((0,o.dU)("blue.50","blue.900"),L.primary||"#0b5cff"),Xe=L.secondary||"#ffd200",et=Qe,tt=(0,r.useCallback)(e=>{const t=z.Ec[e]||[];if("homepage"===n){const n=oe[e];if(n&&n.length>0)return t.filter(e=>n.includes(e.value))}return t},[n]),nt=(0,r.useCallback)(e=>{const t=z.TD.find(t=>t.name===e),n=null===t||void 0===t?void 0:t.defaultVariant,a=tt(e);return 0===a.length?n||"default":n&&a.some(e=>e.value===n)?n:a[0].value},[tt]),at=(0,r.useCallback)((e,t)=>{const n=tt(e);return 0===n.length?t||nt(e):t&&n.some(e=>e.value===t)?t:nt(e)},[tt,nt]),rt=(0,r.useCallback)((e,t)=>{const n=t.target;if(!n.closest(".panel-header")&&!n.classList.contains("panel-header"))return;t.preventDefault(),t.stopPropagation();const a=t.currentTarget.getBoundingClientRect();Ve(e),He({x:t.clientX-a.left,y:t.clientY-a.top})},[]),st=(0,r.useCallback)(e=>{if(!Ge)return;const t=e.clientX-Ue.x,n=e.clientY-Ue.y;Ze(e=>(0,a.A)((0,a.A)({},e),{},{[Ge]:(0,a.A)((0,a.A)({},e[Ge]),{},{x:Math.max(0,Math.min(t,window.innerWidth-e[Ge].width)),y:Math.max(0,Math.min(n,window.innerHeight-e[Ge].height))})}))},[Ge,Ue]),ot=(0,r.useCallback)(()=>{Ve(null),$e(null)},[]);(0,r.useEffect)(()=>{if(Ge)return window.addEventListener("mousemove",st),window.addEventListener("mouseup",ot),()=>{window.removeEventListener("mousemove",st),window.removeEventListener("mouseup",ot)}},[Ge,st,ot]);const it=(0,r.useCallback)((e,t)=>{t.preventDefault(),t.stopPropagation(),$e(e),He({x:t.clientX,y:t.clientY})},[]),lt=(0,r.useCallback)(e=>{if(!Je)return;const t=e.clientX-Ue.x,n=e.clientY-Ue.y;Ze(e=>{const r=e[Je];return(0,a.A)((0,a.A)({},e),{},{[Je]:(0,a.A)((0,a.A)({},r),{},{width:Math.max(280,r.width+t),height:Math.max(300,r.height+n)})})}),He({x:e.clientX,y:e.clientY})},[Je,Ue]);(0,r.useEffect)(()=>{if(Je)return window.addEventListener("mousemove",lt),window.addEventListener("mouseup",ot),()=>{window.removeEventListener("mousemove",lt),window.removeEventListener("mouseup",ot)}},[Je,lt,ot]),(0,r.useEffect)(()=>{if("edit"===new URLSearchParams(window.location.search).get("myuibrix")){O(!0);const e=window.location.pathname;window.history.replaceState({},"",e),Ye({title:"MyUIbrix Editor",description:"Re\u017eim \xfaprav byl aktivov\xe1n. Klikn\u011bte na elementy pro jejich \xfapravu.",status:"info",duration:5e3,isClosable:!0})}},[]),(0,r.useEffect)(()=>{try{F?document.body.classList.add("myuibrix-edit-mode"):document.body.classList.remove("myuibrix-edit-mode")}catch(e){}return()=>{try{document.body.classList.remove("myuibrix-edit-mode")}catch(e){}}},[F]),(0,r.useEffect)(()=>{let e=null;try{F&&(e=document.createElement("style"),e.id="myuibrix-footer-editor-fixes",e.textContent='\n body.myuibrix-edit-mode [data-watermark="myclub"] { display: none !important; }\n body.myuibrix-edit-mode [data-element="footer"] { position: relative; z-index: 0; }\n ',document.head.appendChild(e))}catch(t){}return()=>{try{const e=document.getElementById("myuibrix-footer-editor-fixes");e&&e.remove()}catch(e){}}},[F]),(0,r.useEffect)(()=>{try{Ie?document.body.classList.add("myuibrix-cross-container-reorder"):document.body.classList.remove("myuibrix-cross-container-reorder")}catch(e){}return()=>{try{document.body.classList.remove("myuibrix-cross-container-reorder")}catch(e){}}},[Ie]),(0,r.useEffect)(()=>{F&&te(!1)},[F]),(0,r.useEffect)(()=>{try{const e=A(".container");if(!e)return void De(0);const t=window.getComputedStyle(e);if("grid"!==t.display)return void De(0);const n=t.gridTemplateColumns||"";let a=0;const r=n.match(/repeat\((\d+)/);r&&(a=parseInt(r[1],10)),a||(a=n.split(" ").filter(Boolean).length||2),De(a)}catch(e){De(0)}},[F,ye]),(0,r.useEffect)(()=>{if(F&&Te){const e=setTimeout(()=>{Ae(!1)},5e3);return()=>clearTimeout(e)}},[F,Te]),(0,r.useEffect)(()=>{(async()=>{try{const e=await(0,z.Lg)(n),t=(e.length>0?e:se).map(e=>(0,a.A)((0,a.A)({},e),{},{variant:at(e.element_name,e.variant)})),r={},s={};t.forEach(e=>{var t,n,a;const o=String((null===(t=e.settings)||void 0===t?void 0:t.customCSS)||(null===(n=e.settings)||void 0===n||null===(a=n.styles)||void 0===a?void 0:a.customCSS)||"");o&&(r[e.element_name]=o);const i=e.settings&&e.settings.styles||{};i&&"object"===typeof i&&Object.keys(i).length>0&&(s[e.element_name]=i)}),W(t);const o={},i=new Set,l=[...t].sort((e,t)=>(e.display_order||0)-(t.display_order||0)),c=[];l.forEach(e=>{o[e.element_name]=e.variant,!1!==e.visible&&i.add(e.element_name),c.push(e.element_name)}),B(o),ce(i),me(c),(Object.keys(s).length>0||Object.keys(r).length>0)&&(fe(e=>{const t=(0,a.A)({},e);return Object.entries(s).forEach(e=>{let[n,r]=e;t[n]=(0,a.A)((0,a.A)({},t[n]||{}),r)}),Object.entries(r).forEach(e=>{let[n,r]=e;t[n]=(0,a.A)((0,a.A)({},t[n]||{}),{},{customCSS:r})}),t}),Object.entries(r).forEach(e=>{let[t,n]=e;try{const e="custom-css-".concat(t),a=document.getElementById(e);a&&a.remove();const r=document.createElement("style");r.id=e;if(/\{[^}]*\}|@media|@keyframes/.test(n))r.textContent=n;else{const e=n.split(";").map(e=>e.trim()).filter(Boolean).map(e=>/!important\s*$/.test(e)?e:"".concat(e," !important")).join(";\n ");r.textContent='\n [data-element="'.concat(t,'"] {\n ').concat(e,";\n }\n ")}document.head.appendChild(r)}catch(a){}})),Pe({variants:(0,a.A)({},o),visible:new Set(i),order:[...c],css:r}),0===e.length&&(G(!0),Pe({variants:{},visible:new Set,order:[],css:{}}))}catch(e){console.error("Failed to load page element configs:",e);const t=se.map(e=>(0,a.A)((0,a.A)({},e),{},{variant:at(e.element_name,e.variant)})),n={},r=new Set,s=[];t.forEach(e=>{n[e.element_name]=e.variant,!1!==e.visible&&r.add(e.element_name),s.push(e.element_name)}),W(t),B(n),ce(r),me(s),G(!0),Pe({variants:{},visible:new Set,order:[],css:{}})}})()},[n,at]);const ct=(0,r.useMemo)(()=>{try{const e=_e||{variants:{},visible:new Set,order:[],css:{}},t=new Set([...Object.keys(K||{}),...Object.keys(e.variants||{}),...de,...e.order]),n=new Set;t.forEach(t=>{var a,r;(at(t,K[t])||"")!==(at(t,e.variants[t])||"")&&n.add(t);le.has(t)!==e.visible.has(t)&&n.add(t);String((null===(a=ye[t])||void 0===a?void 0:a.customCSS)||"").trim()!==String((null===(r=e.css)||void 0===r?void 0:r[t])||"").trim()&&n.add(t)});const a=de.length===e.order.length&&de.every((t,n)=>t===e.order[n]);return n.size+(a?0:1)}catch(e){return 0}},[K,le,de,_e,at]);(0,r.useEffect)(()=>{G(ct>0)},[ct]);const dt=(0,r.useRef)([]),mt=(0,r.useRef)(-1),pt=(0,r.useCallback)(()=>{try{const e={localChanges:(0,a.A)({},K),visible:Array.from(le),order:[...de],styles:JSON.parse(JSON.stringify(ye||{}))},t=dt.current.slice(0,mt.current+1);t.push(e),dt.current=t,mt.current=t.length-1}catch(e){}},[K,le,de,ye]),ht=()=>mt.current>0,ut=()=>mt.current>=0&&mt.current{const t=dt.current[e];if(t){B(t.localChanges),ce(new Set(t.visible)),me(t.order),fe(t.styles);try{F&&requestAnimationFrame(()=>{Ke.current(t.order),window.dispatchEvent(new CustomEvent("myuibrix-reorder",{detail:{order:t.order,previewMode:!0}}))})}catch(n){}}},[F]),gt=(0,r.useCallback)(()=>{ht()&&(mt.current-=1,xt(mt.current))},[xt]),bt=(0,r.useCallback)(()=>{ut()&&(mt.current+=1,xt(mt.current))},[xt]);(0,r.useEffect)(()=>{if(!F)return;const e=e=>{"Escape"===e.key&&(Q?X(!1):ee?te(!1):V?U(null):Lt()),(e.ctrlKey||e.metaKey)&&"s"===e.key&&Z&&(e.preventDefault(),Rt()),!e.ctrlKey&&!e.metaKey||e.shiftKey||"z"!==e.key&&"KeyZ"!==e.code||(e.preventDefault(),gt()),!e.ctrlKey&&!e.metaKey||!e.shiftKey||"z"!==e.key&&"KeyZ"!==e.code||(e.preventDefault(),bt()),"l"!==e.key||e.ctrlKey||e.metaKey||e.altKey||te(!ee),"a"!==e.key||e.ctrlKey||e.metaKey||e.altKey||X(!0),V&&("ArrowUp"!==e.key||e.shiftKey||(e.preventDefault(),kt(V)),"ArrowDown"!==e.key||e.shiftKey||(e.preventDefault(),Ct(V)),"Delete"!==e.key&&"Backspace"!==e.key||(e.preventDefault(),zt(V)))};return window.addEventListener("keydown",e),()=>window.removeEventListener("keydown",e)},[F,V,Q,ee,Z,gt,bt]),(0,r.useEffect)(()=>{if(!F){try{_(".elementor-overlay").forEach(e=>{try{e.replaceWith(e.cloneNode(!0))}catch(t){}try{e.remove()}catch(n){}})}catch(a){}return void U(null)}const e=e=>{const t='[data-element="'.concat(e,'"]');_(t).forEach(t=>{if(t.querySelector(".elementor-overlay"))return;const n=document.createElement("div");n.className="elementor-overlay",n.style.cssText="\n position: absolute;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n pointer-events: auto;\n border: 2px dashed transparent;\n transition: all 0.2s;\n z-index: 9998;\n cursor: move;\n user-select: none;\n -webkit-user-select: none;\n ";const a=document.createElement("div");a.className="elementor-badge",a.textContent=e.toUpperCase(),a.style.cssText="\n position: absolute;\n top: -1px;\n left: -1px;\n background: ".concat(Qe,";\n color: white;\n padding: 4px 12px;\n font-size: 11px;\n font-weight: 700;\n border-radius: 0 0 6px 0;\n opacity: 0;\n transition: opacity 0.2s;\n pointer-events: none;\n z-index: 9999;\n text-transform: uppercase;\n letter-spacing: 0.5px;\n ");const r=document.createElement("div");r.className="elementor-actions",r.style.cssText="\n position: absolute;\n top: 8px;\n right: 8px;\n display: flex;\n gap: 4px;\n opacity: 0;\n transition: opacity 0.2s;\n z-index: 10000;\n pointer-events: auto;\n ";const s=document.createElement("button");s.innerHTML="\u2699\ufe0f",s.title="Upravit styl",s.style.cssText="\n background: ".concat(Qe,";\n color: white;\n border: none;\n width: 32px;\n height: 32px;\n border-radius: 6px;\n cursor: pointer;\n font-size: 16px;\n display: flex;\n align-items: center;\n justify-content: center;\n box-shadow: 0 2px 8px rgba(0,0,0,0.2);\n transition: transform 0.2s;\n "),s.onmouseover=()=>s.style.transform="scale(1.1)",s.onmouseout=()=>s.style.transform="scale(1)";const o=document.createElement("button");o.innerHTML="\u2b06\ufe0f",o.title="P\u0159esunout nahoru",o.style.cssText=s.style.cssText,o.onmouseover=()=>o.style.transform="scale(1.1)",o.onmouseout=()=>o.style.transform="scale(1)";const i=document.createElement("button");i.innerHTML="\u2b07\ufe0f",i.title="P\u0159esunout dol\u016f",i.style.cssText=s.style.cssText,i.onmouseover=()=>i.style.transform="scale(1.1)",i.onmouseout=()=>i.style.transform="scale(1)";const l=document.createElement("button");l.innerHTML="\ud83d\uddd1\ufe0f",l.title="Odstranit element",l.style.cssText="\n background: #e53e3e;\n color: white;\n border: none;\n width: 32px;\n height: 32px;\n border-radius: 6px;\n cursor: pointer;\n font-size: 16px;\n display: flex;\n align-items: center;\n justify-content: center;\n box-shadow: 0 2px 8px rgba(0,0,0,0.2);\n transition: transform 0.2s;\n ",l.onmouseover=()=>l.style.transform="scale(1.1)",l.onmouseout=()=>l.style.transform="scale(1)";const c=document.createElement("button");c.innerHTML="\u2795",c.title="P\u0159idat p\u0159ed",c.style.cssText=s.style.cssText,c.onmouseover=()=>c.style.transform="scale(1.1)",c.onmouseout=()=>c.style.transform="scale(1)";const d=document.createElement("button");d.innerHTML="\u2795",d.title="P\u0159idat za",d.style.cssText=s.style.cssText,d.onmouseover=()=>d.style.transform="scale(1.1)",d.onmouseout=()=>d.style.transform="scale(1)";let m=null;if(Oe>1){m=document.createElement("div"),m.className="elementor-col-picker",m.style.cssText="\n display: flex;\n gap: 4px;\n ";for(let e=0;et.style.transform="scale(1.1)",t.onmouseout=()=>t.style.transform="scale(1)",t.addEventListener("click",t=>{t.stopPropagation();try{const t=Math.max(1,Oe||1),n=We.current.length;let a=0;for(let s=0;s1&&m&&C(r,m),C(r,l),C(n,a),C(n,r);"static"===window.getComputedStyle(t).position&&(t.style.position="relative"),C(t,n)?(n.addEventListener("click",n=>{if(n.target.closest(".elementor-actions"))return;n.stopPropagation();const a=t.getBoundingClientRect();Y({top:a.top,left:a.left,width:a.width,height:a.height}),U(e),je(!0)}),n.addEventListener("mouseenter",()=>{J(e),n.style.border="2px dashed ".concat(Qe),n.style.background="".concat(Qe,"15"),a.style.opacity="1",r.style.opacity="1"}),n.addEventListener("mouseleave",()=>{J(null),V!==e&&(n.style.border="2px dashed transparent",n.style.background="transparent",a.style.opacity="0",r.style.opacity="0")}),s.addEventListener("click",n=>{n.stopPropagation();const a=t.getBoundingClientRect();Y({top:a.top,left:a.left,width:a.width,height:a.height}),U(e),je(!0)}),o.addEventListener("click",t=>{t.stopPropagation(),kt(e)}),i.addEventListener("click",t=>{t.stopPropagation(),Ct(e)}),l.addEventListener("click",t=>{t.stopPropagation(),confirm('Opravdu chcete odstranit element "'.concat(e,'"?'))&&zt(e)}),c.addEventListener("click",t=>{t.stopPropagation();try{const t=We.current.indexOf(e);t>=0&&(Fe(t),X(!0))}catch(n){}}),d.addEventListener("click",t=>{t.stopPropagation();try{const t=We.current.indexOf(e);t>=0&&(Fe(t+1),X(!0))}catch(n){}}),n.draggable=!0,n.addEventListener("dragstart",t=>{t.stopPropagation();try{var a;null===(a=t.dataTransfer)||void 0===a||a.setData("text/plain",e)}catch(r){}he(e),n.style.opacity="0.5"}),n.addEventListener("dragend",e=>{e.stopPropagation(),n.style.opacity="1",he(null)}),n.addEventListener("dragover",t=>{t.preventDefault(),t.stopPropagation();try{t.dataTransfer.dropEffect="move"}catch(a){}pe&&pe!==e&&(n.style.border="3px solid ".concat(Xe),xe(e))}),n.addEventListener("dragleave",t=>{t.stopPropagation(),V!==e&&(n.style.border="2px dashed ".concat(Qe)),xe(null)}),n.addEventListener("drop",t=>{if(t.preventDefault(),t.stopPropagation(),pe&&pe!==e){const t=[...We.current],n=t.indexOf(pe),a=t.indexOf(e);-1!==n&&-1!==a&&(t.splice(n,1),t.splice(a,0,pe),me(t),G(!0),Ke.current(t))}n.style.border="2px dashed ".concat(Qe),xe(null)})):console.warn("Failed to add overlay to element: ".concat(e))})};try{const t=Array.from(_("[data-element]"));Array.from(new Set(t.map(e=>e.getAttribute("data-element")).filter(e=>!!e&&"container"!==e))).forEach(t=>e(t))}catch(r){("homepage"===n?re:Object.keys(z.Ec)).forEach(t=>{z.Ec[t]&&e(t)})}const t=e=>{"Escape"===e.key&&U(null)};return document.addEventListener("keydown",t),()=>{try{_(".elementor-overlay").forEach(e=>{try{const t=e.cloneNode(!1),n=e.parentElement;n&&T(n,t,e)&&E(n,t)}catch(t){console.warn("Failed to cleanup overlay:",t)}})}catch(e){console.error("Error during cleanup:",e)}try{document.removeEventListener("keydown",t)}catch(e){console.warn("Failed to remove event listener:",e)}vt.current&&clearTimeout(vt.current)}},[F,V,n,de,le]),(0,r.useEffect)(()=>{_(".elementor-overlay").forEach(e=>{const t=e.parentElement,n=null===t||void 0===t?void 0:t.getAttribute("data-element");if(n===V){e.style.border="3px solid ".concat(Qe),e.style.background="".concat(Qe,"1A");const t=e.querySelector(".elementor-badge");t&&(t.style.opacity="1",t.style.background=Qe)}else if(n===H){e.style.border="2px dashed ".concat(Qe),e.style.background="".concat(Qe,"15");const t=e.querySelector(".elementor-badge");t&&(t.style.opacity="1")}else{e.style.border="2px dashed transparent",e.style.background="transparent";const t=e.querySelector(".elementor-badge");t&&(t.style.opacity="0")}})},[V,H]);const yt=(0,r.useCallback)((e,t)=>{const n=tt(e);if(!n||0===n.length)return void console.warn('Invalid variant "'.concat(t,'" for element "').concat(e,'"'));const r=at(e,t),s=()=>{try{pt();const t=(0,a.A)((0,a.A)({},K),{},{[e]:r});B(t),G(!0),W(t=>{const n=t.findIndex(t=>t.element_name===e);if(-1!==n){const e=[...t];return e[n]=(0,a.A)((0,a.A)({},e[n]),{},{variant:r}),e}return t}),F&&requestAnimationFrame(()=>{window.dispatchEvent(new CustomEvent("myuibrix-change",{detail:{elementName:e,variant:r,visible:le.has(e),previewMode:!0}}))})}catch(t){console.error("Error applying variant change:",t),Ye({title:"Chyba p\u0159i aplikaci stylu",description:"Styl se nepoda\u0159ilo aplikovat. Zkuste to pros\xedm znovu.",status:"error",duration:3e3,isClosable:!0})}};if(Re.current){const e=()=>{Re.current?setTimeout(e,50):s()};return void setTimeout(e,50)}s()},[K,le,F,Ye,tt,at]),ft=(0,r.useCallback)(e=>{Re.current||(Re.current=!0,requestAnimationFrame(()=>{try{var t,n;if(Ie||"undefined"!==typeof document&&(null===(t=document.body)||void 0===t||null===(n=t.classList)||void 0===n?void 0:n.contains("myuibrix-cross-container-reorder"))){const t=A(".container")||A(".myuibrix-viewport-wrapper")||A("main")||null;t&&(e.forEach(e=>{const n=A('[data-element="'.concat(e,'"]'));n&&n.parentElement!==t&&C(t,n)}),e.forEach(e=>{const n=A('[data-element="'.concat(e,'"]'));if(n){try{n.style.order=""}catch(a){}C(t,n)}}))}else{const t=new Map;e.forEach(e=>{const n=A('[data-element="'.concat(e,'"]'));if(!n||!n.parentElement)return;const a=n.parentElement;t.has(a)||t.set(a,[]),t.get(a).push(n)}),t.forEach((t,n)=>{t.forEach(e=>{try{e.style.order=""}catch(t){}}),e.forEach(e=>{const t=A('[data-element="'.concat(e,'"]'));t&&t.parentElement===n&&C(n,t)})})}window.dispatchEvent(new CustomEvent("myuibrix-reorder",{detail:{order:e,previewMode:!0}})),setTimeout(()=>{Re.current=!1},50)}catch(a){console.error("Error during DOM reordering:",a),Re.current=!1}}))},[Ie]);Ke.current=ft;const vt=(0,r.useRef)(null),jt=(0,r.useCallback)((e,t)=>{fe(n=>(0,a.A)((0,a.A)({},n),{},{[e]:t})),G(!0),vt.current&&clearTimeout(vt.current),vt.current=setTimeout(()=>{F&&window.dispatchEvent(new CustomEvent("myuibrix-style-change",{detail:{elementName:e,styles:t,previewMode:!0}}))},100)},[F]),wt=(0,r.useCallback)(e=>{const t=Math.max(1,Oe||1),n=We.current.length;let a=0;for(let r=0;r{pt();const r=z.TD.find(t=>t.name===e),s=K[e],o=at(e,(null===r||void 0===r?void 0:r.defaultVariant)||"default"),i=at(e,s||o);K[e]||B(t=>(0,a.A)((0,a.A)({},t),{},{[e]:i})),ce(t=>{const n=new Set(t);return n.add(e),n}),W(t=>{const r=t.findIndex(t=>t.element_name===e);if(-1!==r){const e=[...t];return e[r]=(0,a.A)((0,a.A)({},e[r]),{},{variant:i,visible:!0}),e}return[...t,{page_type:n,element_name:e,variant:i,visible:!0,display_order:t.length}]}),G(!0),X(!1),ke(""),Ee("all"),me(n=>{const a="number"===typeof t?t:null!=Le?Le:void 0;if(n.includes(e)){try{Ye({title:"Duplicitn\xed element",description:"Tento element ji\u017e na str\xe1nce existuje. P\u0159esouv\xe1m existuj\xedc\xed na zvolen\xe9 m\xedsto.",status:"warning",duration:2500,isClosable:!0})}catch(s){}const t=n.indexOf(e);if("number"===typeof a&&a!==t){const r=[...n];return r.splice(t,1),r.splice(Math.min(a,r.length),0,e),F&&requestAnimationFrame(()=>{ft(r),window.dispatchEvent(new CustomEvent("myuibrix-reorder",{detail:{order:r,previewMode:!0}}))}),r}return F&&requestAnimationFrame(()=>{ft(n),window.dispatchEvent(new CustomEvent("myuibrix-reorder",{detail:{order:n,previewMode:!0}}))}),n}const r=[...n];return"number"===typeof a?r.splice(Math.min(a,r.length),0,e):r.push(e),F&&requestAnimationFrame(()=>{ft(r),window.dispatchEvent(new CustomEvent("myuibrix-reorder",{detail:{order:r,previewMode:!0}}))}),setTimeout(()=>{try{const t=A('[data-element="'.concat(e,'"]'));t&&(t.style.display="")}catch(t){}},0),r}),F&&window.dispatchEvent(new CustomEvent("myuibrix-change",{detail:{elementName:e,variant:i,visible:!0,previewMode:!0}})),Fe(null);try{U(e),setTimeout(()=>{const t=A('[data-element="'.concat(e,'"]'));if(t){const e=t.getBoundingClientRect();Y({top:e.top,left:e.left,width:e.width,height:e.height}),je(!0)}},0)}catch(l){}},[K,F,at,n,ft,Le]),zt=(0,r.useCallback)(e=>{pt();const t=new Set(le);t.delete(e),ce(t),G(!0),U(null),F&&window.dispatchEvent(new CustomEvent("myuibrix-change",{detail:{elementName:e,variant:K[e],visible:!1,previewMode:!0}})),setTimeout(()=>{const t=A('[data-element="'.concat(e,'"]'));t&&(t.style.display="none")},0)},[le,K,F]),kt=(0,r.useCallback)(e=>{pt();const t=de.indexOf(e);if(t<=0)return;const n=[...de];[n[t-1],n[t]]=[n[t],n[t-1]],me(n),G(!0),F&&(ft(n),window.dispatchEvent(new CustomEvent("myuibrix-reorder",{detail:{order:n,previewMode:!0}})))},[de,F,ft]),Ct=(0,r.useCallback)(e=>{pt();const t=de.indexOf(e);if(t<0||t>=de.length-1)return;const n=[...de];[n[t],n[t+1]]=[n[t+1],n[t]],me(n),G(!0),F&&(ft(n),window.dispatchEvent(new CustomEvent("myuibrix-reorder",{detail:{order:n,previewMode:!0}})))},[de,F,ft]),Et=(0,r.useCallback)((e,t)=>{t.dataTransfer.effectAllowed="move",t.dataTransfer.setData("text/html",e),he(e)},[]),Tt=(0,r.useCallback)((e,t)=>{e.preventDefault(),e.dataTransfer.dropEffect="move",pe!==t&&xe(t)},[pe]),At=(0,r.useCallback)(e=>{const t=e.relatedTarget;t&&e.currentTarget.contains(t)||xe(null)},[]),_t=(0,r.useCallback)(()=>{he(null),xe(null)},[]),Pt=(0,r.useCallback)((e,t)=>{if(e.preventDefault(),!pe||pe===t)return he(null),void xe(null);const n=[...de],a=n.indexOf(pe),r=n.indexOf(t);if(-1===a||-1===r)return he(null),void xe(null);n.splice(a,1),n.splice(r,0,pe),me(n),G(!0),he(null),xe(null),F&&(ft(n),window.dispatchEvent(new CustomEvent("myuibrix-reorder",{detail:{order:n,previewMode:!0}})))},[pe,de,F,ft]),Nt=(0,r.useCallback)(()=>{try{if(!confirm("Za\u010d\xedt s pr\xe1zdn\xfdm rozlo\u017een\xedm? V\u0161echny sekce (krom\u011b hlavi\u010dky a pati\u010dky) budou skryt\xe9."))return}catch(r){}const e=Array.from(le),t=new Set(["header","footer"]),n=e.filter(e=>!t.has(e)),a=new Set;e.forEach(e=>{t.has(e)&&a.add(e)}),ce(a),me(e=>e.filter(e=>t.has(e))),G(!0),F&&(n.forEach(e=>{try{window.dispatchEvent(new CustomEvent("myuibrix-change",{detail:{elementName:e,variant:K[e],visible:!1,previewMode:!0}}));const t=A('[data-element="'.concat(e,'"]'));t&&(t.style.display="none")}catch(t){}}),requestAnimationFrame(()=>{const e=Array.from(a).filter(e=>t.has(e));ft(e),window.dispatchEvent(new CustomEvent("myuibrix-reorder",{detail:{order:e,previewMode:!0}}))}));try{Ye({title:"Pr\xe1zdn\xe9 rozlo\u017een\xed",description:"V\u0161echny sekce byly skryty. M\u016f\u017eete za\u010d\xedt p\u0159id\xe1vat prvky.",status:"info",duration:2500,isClosable:!0})}catch(s){}X(!0)},[le,F,K,ft,Ye]),Rt=async()=>{try{const r=[...de],s=Array.from(new Set([...Object.keys(ye||{}),...Object.keys(K||{}),...Array.from(le||new Set)].filter(Boolean))).filter(e=>!r.includes(e)),o=[...r,...s].map((e,t)=>{var s,o,i,l,c,d,m,p;return{page_type:n,element_name:e,variant:K[e]||"default",visible:le.has(e)||"style-pack"===e||"container"===e,display_order:r.includes(e)?r.indexOf(e):t,settings:(0,a.A)((0,a.A)({},(null===(s=D.find(t=>t.element_name===e))||void 0===s?void 0:s.settings)||{}),{},{styles:ye[e]||(null===(o=D.find(t=>t.element_name===e))||void 0===o||null===(i=o.settings)||void 0===i?void 0:i.styles)||{},customCSS:null!==(l=null!==(c=null===(d=ye[e])||void 0===d?void 0:d.customCSS)&&void 0!==c?c:null===(m=D.find(t=>t.element_name===e))||void 0===m||null===(p=m.settings)||void 0===p?void 0:p.customCSS)&&void 0!==l?l:""})}});let i=!1;try{await(0,z.mj)(o),i=!0}catch(t){var e;const a=(null===t||void 0===t||null===(e=t.response)||void 0===e?void 0:e.status)||(null===t||void 0===t?void 0:t.status);if(401!==a&&403!==a)throw t;const r="".concat(n,"-autosave"),s=o.map(e=>{var t;return{element_name:e.element_name,variant:e.variant,visible:Boolean(e.visible),display_order:Number(e.display_order||0),custom_styles:(null===(t=e.settings)||void 0===t?void 0:t.styles)||{}}});await k.Ay.post("/editor/preview/".concat(encodeURIComponent(r),"/apply"),{page_type:n,elements:s}),i=!0}if(!i)return;Ye({title:"Zm\u011bny \xfasp\u011b\u0161n\u011b ulo\u017eeny!",description:"Zm\u011bny jsou nyn\xed viditeln\xe9 na produkci.",status:"success",duration:3e3,isClosable:!0}),Pe({variants:(0,a.A)({},K),visible:new Set(le),order:[...de],css:Object.fromEntries(Object.entries(ye).map(e=>{let[t,n]=e;return[t,String((null===n||void 0===n?void 0:n.customCSS)||"")]}))}),G(!1),setTimeout(()=>{window.location.reload()},1500)}catch(r){Ye({title:"Nepoda\u0159ilo se ulo\u017eit zm\u011bny",description:"Zkuste to pros\xedm znovu nebo kontaktujte podporu.",status:"error",duration:5e3,isClosable:!0})}},It=(0,r.useMemo)(()=>V?tt(V):[],[V,tt]),Mt=(0,r.useMemo)(()=>V?at(V,K[V]):null,[V,K,at]),Lt=(0,r.useCallback)(()=>{try{document.body.classList.remove("myuibrix-edit-mode")}catch(e){}O(!1),setTimeout(()=>{try{window.location.reload()}catch(e){}},120)},[]),Ft=(0,r.useCallback)(()=>({width:"100%",label:"Desktop (100%)"}),[]),Ot=(0,r.useMemo)(()=>Ft(),[Ft]);return(0,r.useEffect)(()=>{if(!F)return;const e=A(".myuibrix-viewport-wrapper");if(!e)return;e.style.width="100%",e.style.maxWidth="mobile"===ge?"420px":"tablet"===ge?"820px":"100%",e.style.transition="all 0.3s ease",e.style.margin="0 auto",e.style.transform="none",e.style.transformOrigin="","desktop"!==ge?(e.style.border="3px solid ".concat(Qe),e.style.boxShadow="0 0 0 9999px rgba(0,0,0,0.25), 0 8px 32px rgba(0,0,0,0.2)",e.style.marginTop="20px",e.style.marginBottom="20px",e.style.minHeight="calc(100vh - 100px)"):(e.style.border="none",e.style.boxShadow="none",e.style.marginTop="0",e.style.marginBottom="0",e.style.minHeight="100vh");const t="mobile"===ge?"\u0160\xed\u0159ka ~420px":"tablet"===ge?"\u0160\xed\u0159ka ~820px":"Zobrazen\xed na plnou \u0161\xed\u0159ku (100%)";Ye({title:"Viewport: ".concat("mobile"===ge?"Mobile":"tablet"===ge?"Tablet":"Desktop"),description:t,status:"info",duration:1500,isClosable:!0,position:"bottom-right"})},[F,ge,Qe,Ye,Ot]),(0,r.useEffect)(()=>{if(!F)return;const e=e=>{const t=e.target;if(t.closest(".myuibrix-panel")||t.closest(".myuibrix-toolbar")||t.closest(".elementor-overlay")||t.closest('[role="dialog"]')||t.closest(".chakra-portal")||t.closest(".chakra-modal")||t.classList.contains("elementor-overlay"))return;const n=A(".myuibrix-viewport-wrapper");n&&n.contains(t)&&(e.preventDefault(),e.stopPropagation(),e.stopImmediatePropagation())};return document.addEventListener("click",e,!0),document.addEventListener("mousedown",e,!0),()=>{document.removeEventListener("click",e,!0),document.removeEventListener("mousedown",e,!0)}},[F]),(0,r.useEffect)(()=>{if(F){document.body.style.paddingTop="60px",document.body.style.backgroundColor="#e2e8f0",document.body.style.userSelect="none";const l=A(".container");if(l){try{l.classList.add("myuibrix-viewport-wrapper")}catch(e){}try{l.setAttribute("data-myuibrix-wrapped","1")}catch(t){}try{l.style.width="100%"}catch(n){}try{l.style.maxWidth="100%"}catch(a){}try{l.style.transition="all 0.3s ease"}catch(r){}try{l.style.margin="0 auto"}catch(s){}try{l.style.transform="none"}catch(o){}try{l.style.transformOrigin=""}catch(i){}}}else{document.body.style.paddingTop="0",document.body.style.backgroundColor="",document.body.style.userSelect="";const e=A(".myuibrix-viewport-wrapper");if(e){try{e.classList.remove("myuibrix-viewport-wrapper")}catch(l){}try{e.removeAttribute("data-myuibrix-wrapped")}catch(c){}try{e.style.width=""}catch(d){}try{e.style.maxWidth=""}catch(m){}try{e.style.transition=""}catch(p){}try{e.style.margin=""}catch(h){}try{e.style.transform=""}catch(u){}try{e.style.transformOrigin=""}catch(x){}}}return()=>{document.body.style.paddingTop="0",document.body.style.backgroundColor="",document.body.style.userSelect="";const e=A(".myuibrix-viewport-wrapper");if(e){try{e.classList.remove("myuibrix-viewport-wrapper")}catch(t){}try{e.removeAttribute("data-myuibrix-wrapped")}catch(n){}try{e.style.width=""}catch(a){}try{e.style.maxWidth=""}catch(r){}try{e.style.transition=""}catch(s){}try{e.style.margin=""}catch(o){}try{e.style.transform=""}catch(i){}try{e.style.transformOrigin=""}catch(l){}}}},[F]),M?(0,q.jsxs)(q.Fragment,{children:[F&&(0,q.jsxs)(q.Fragment,{children:[(0,q.jsx)(i.a,{className:"myuibrix-toolbar",position:"fixed",top:0,left:0,right:0,bg:"rgba(17, 25, 40, 0.55)",color:"white",p:3,zIndex:1e4,boxShadow:"0 10px 30px rgba(0,0,0,0.2)",backdropFilter:"saturate(180%) blur(14px)",borderBottom:"1px solid rgba(255,255,255,0.12)",fontFamily:"var(--chakra-fonts-body)",children:(0,q.jsxs)(l.s,{align:"center",justify:"space-between",maxW:"100%",children:[(0,q.jsxs)(c.z,{spacing:3,children:[(0,q.jsx)(i.a,{bgGradient:"linear(135deg, ".concat(Xe,", ").concat(Xe,"dd)"),px:4,py:2,borderRadius:"xl",color:L.textOnSecondary||"black",boxShadow:"0 4px 12px rgba(0,0,0,0.2)",border:"2px solid rgba(255,255,255,0.2)",transition:"all 0.3s",_hover:{transform:"translateY(-1px)",boxShadow:"0 6px 16px rgba(0,0,0,0.25)"},children:(0,q.jsxs)(c.z,{spacing:2,align:"center",children:[(0,q.jsx)(d.I,{as:w.i0U,color:"white",boxSize:5}),(0,q.jsx)(m.E,{fontWeight:"800",fontSize:"md",color:"white",letterSpacing:"tight",children:"MyUIbrix"})]})}),(0,q.jsxs)(p.E,{bg:"orange.500",color:"white",fontSize:"xs",px:3,py:1.5,borderRadius:"full",fontWeight:"700",display:"flex",alignItems:"center",gap:1,boxShadow:"0 2px 8px rgba(237, 137, 54, 0.4)",border:"1px solid rgba(255,255,255,0.3)",sx:{"@keyframes pulseBadge":{"0%, 100%":{transform:"scale(1)",opacity:1},"50%":{transform:"scale(1.05)",opacity:.9}},animation:"pulseBadge 2s infinite"},children:[(0,q.jsx)(d.I,{as:S.F5$,boxSize:3}),"RE\u017dIM N\xc1HLEDU"]}),(0,q.jsx)(m.E,{fontSize:"sm",fontWeight:"600",color:"whiteAlpha.800",children:"Zm\u011bny vid\xedte pouze vy"})]}),(0,q.jsx)(m.E,{fontSize:"sm",fontWeight:"700",color:"whiteAlpha.900",children:"N\xe1hled: Desktop (100%)"}),(0,q.jsxs)(c.z,{spacing:2,children:[(0,q.jsx)(h.m,{label:"Mobiln\xed n\xe1hled",children:(0,q.jsx)(u.K,{"aria-label":"Mobile viewport",icon:(0,q.jsx)(S.PCV,{}),size:"sm",variant:"mobile"===ge?"solid":"ghost",colorScheme:"mobile"===ge?"blue":"whiteAlpha",onClick:()=>be("mobile")})}),(0,q.jsx)(h.m,{label:"Tablet n\xe1hled",children:(0,q.jsx)(u.K,{"aria-label":"Tablet viewport",icon:(0,q.jsx)(S.esJ,{}),size:"sm",variant:"tablet"===ge?"solid":"ghost",colorScheme:"tablet"===ge?"blue":"whiteAlpha",onClick:()=>be("tablet")})}),(0,q.jsx)(h.m,{label:"Desktop n\xe1hled",children:(0,q.jsx)(u.K,{"aria-label":"Desktop viewport",icon:(0,q.jsx)(S.ufi,{}),size:"sm",variant:"desktop"===ge?"solid":"ghost",colorScheme:"desktop"===ge?"blue":"whiteAlpha",onClick:()=>be("desktop")})}),(0,q.jsx)(x.c,{orientation:"vertical",borderColor:"whiteAlpha.400"}),(0,q.jsx)(h.m,{label:"Zp\u011bt (Ctrl+Z)",children:(0,q.jsx)(u.K,{"aria-label":"Undo",icon:(0,q.jsx)(w.EEI,{}),size:"sm",variant:"ghost",colorScheme:"whiteAlpha",onClick:gt,isDisabled:!ht()})}),(0,q.jsx)(h.m,{label:"Znovu (Ctrl+Shift+Z)",children:(0,q.jsx)(u.K,{"aria-label":"Redo",icon:(0,q.jsx)(w.Swo,{}),size:"sm",variant:"ghost",colorScheme:"whiteAlpha",onClick:bt,isDisabled:!ut()})}),(0,q.jsx)(g.$,{leftIcon:(0,q.jsx)(w.IFh,{}),size:"sm",variant:ve?"solid":"outline",colorScheme:ve?"blue":"whiteAlpha",onClick:()=>je(!ve),borderRadius:"xl",children:"Vizu\xe1ln\xed styly"}),(0,q.jsx)(h.m,{label:we?"Ukotvit vlevo":"Ukotvit vpravo",children:(0,q.jsx)(u.K,{"aria-label":"Dock panel",icon:we?(0,q.jsx)(w.ed2,{}):(0,q.jsx)(w.FDZ,{}),size:"sm",variant:"ghost",colorScheme:"whiteAlpha",onClick:()=>Se(!we)})}),(0,q.jsx)(g.$,{size:"sm",variant:"outline",colorScheme:"whiteAlpha",onClick:Nt,children:"Za\u010d\xedt s pr\xe1zdnou str\xe1nkou"}),ct>0&&(0,q.jsxs)(p.E,{bg:"yellow.400",color:"gray.900",fontSize:"sm",px:3,py:1.5,borderRadius:"full",fontWeight:"700",boxShadow:"0 2px 8px rgba(250, 204, 21, 0.4)",border:"1px solid rgba(255,255,255,0.5)",sx:{"@keyframes bounce":{"0%, 100%":{transform:"translateY(0)"},"50%":{transform:"translateY(-2px)"}},animation:"bounce 1s infinite"},children:[ct," neulo\u017een\xfdch zm\u011bn"]}),(0,q.jsx)(g.$,{leftIcon:(0,q.jsx)(S.Bc_,{}),bgGradient:"linear(135deg, ".concat(Xe,", ").concat(Xe,"dd)"),color:"white",size:"sm",onClick:Rt,isDisabled:!Z,fontWeight:"700",px:6,borderRadius:"xl",boxShadow:"0 4px 12px rgba(0,0,0,0.2)",border:"2px solid rgba(255,255,255,0.2)",_hover:{transform:"translateY(-2px)",boxShadow:"0 6px 16px rgba(0,0,0,0.25)"},_active:{transform:"translateY(0)"},transition:"all 0.2s",children:"Publikovat"}),(0,q.jsx)(u.K,{"aria-label":"Ukon\u010dit",icon:(0,q.jsx)(S.yGN,{}),size:"sm",variant:"ghost",colorScheme:"whiteAlpha",onClick:Lt})]})]})}),ve&&(0,q.jsxs)(i.a,{className:"myuibrix-panel",position:"fixed",left:we?void 0:0,right:we?0:void 0,top:"72px",bottom:0,width:"380px",zIndex:10002,overflow:"hidden",display:"flex",flexDirection:"column",fontFamily:"var(--chakra-fonts-body)",bg:"rgba(255, 255, 255, 0.95)",backdropFilter:"blur(12px) saturate(180%)",borderRadius:"0",boxShadow:"0 20px 60px rgba(0,0,0,0.3), 0 8px 24px rgba(0,0,0,0.2)",border:"1px solid rgba(255,255,255,0.3)",sx:{"@keyframes slideInLeft":{from:{opacity:0,transform:"translateX(-40px)"},to:{opacity:1,transform:"translateX(0)"}},animation:"slideInLeft 0.3s cubic-bezier(0.4, 0, 0.2, 1)"},children:[(0,q.jsxs)(i.a,{className:"panel-header",bgGradient:"linear(135deg, ".concat(Qe,", ").concat(Qe,"dd)"),color:"white",p:3,cursor:"default",display:"flex",alignItems:"center",justifyContent:"space-between",flexShrink:0,borderTopRadius:"0",boxShadow:"0 2px 8px rgba(0,0,0,0.1)",borderBottom:"1px solid rgba(255,255,255,0.2)",children:[(0,q.jsxs)(c.z,{children:[(0,q.jsx)(d.I,{as:w.IFh}),(0,q.jsx)(m.E,{fontWeight:"bold",fontSize:"sm",children:"Vizu\xe1ln\xed Styly"})]}),(0,q.jsx)(u.K,{"aria-label":"Zav\u0159\xedt",icon:(0,q.jsx)(S.yGN,{}),size:"xs",variant:"ghost",colorScheme:"whiteAlpha",onClick:()=>je(!1)})]}),(0,q.jsx)(i.a,{flex:"1",overflow:"auto",children:V?(0,q.jsx)(ae,{elementName:V,onStyleChange:e=>jt(V,e),currentStyles:ye[V]}):(0,q.jsxs)(i.a,{p:4,color:"gray.600",fontSize:"sm",children:[(0,q.jsx)(m.E,{fontWeight:"bold",mb:2,children:"Vyberte sekci"}),(0,q.jsx)(m.E,{children:"Vyberte sekci na str\xe1nce pro \xfapravu vizu\xe1ln\xedch styl\u016f. Klikn\u011bte na zv\xfdrazn\u011bn\xfd p\u0159ekryv sekce nebo vyberte ze seznamu vrstev."})]})})]})]}),(0,q.jsx)(i.a,{className:"myuibrix-toolbar",position:"fixed",left:4,bottom:4,zIndex:1e4,bg:F?"rgba(255,255,255,0.95)":Qe,borderRadius:"full",boxShadow:"0 12px 40px rgba(0,0,0,0.25), 0 4px 16px rgba(0,0,0,0.15)",border:"2px solid",borderColor:F?et:Qe,backdropFilter:"blur(12px)",transition:"all 0.3s cubic-bezier(0.4, 0, 0.2, 1)",_hover:{transform:"scale(1.05)",boxShadow:"0 16px 48px rgba(0,0,0,0.3), 0 6px 20px rgba(0,0,0,0.2)"},children:(0,q.jsxs)(b.T,{spacing:0,children:[(0,q.jsx)(h.m,{label:F?"Ukon\u010dit re\u017eim \xfaprav (ESC)":"Aktivovat MyUIbrix Editor",placement:"right",children:(0,q.jsx)(u.K,{"aria-label":"Toggle edit mode",icon:F?(0,q.jsx)(S.yGN,{}):(0,q.jsx)(S.SG1,{}),colorScheme:F?"red":"whiteAlpha",size:"lg",onClick:()=>{F?Lt():O(!0)},borderRadius:"full",variant:"solid",color:F?void 0:"white",_hover:{transform:"scale(1.1)",boxShadow:"lg"},transition:"all 0.2s"})}),F&&(0,q.jsxs)(q.Fragment,{children:[(0,q.jsx)(x.c,{my:1}),(0,q.jsx)(h.m,{label:"P\u0159idat element (A)",placement:"right",children:(0,q.jsx)(u.K,{"aria-label":"P\u0159idat element",icon:(0,q.jsx)(w.OiG,{}),bgGradient:"linear(135deg, ".concat(Qe,", ").concat(Qe,"dd)"),color:"white",_hover:{transform:"scale(1.15) rotate(90deg)",boxShadow:"lg"},size:"md",onClick:()=>X(!0),borderRadius:"full",boxShadow:"0 4px 12px rgba(0,0,0,0.2)",transition:"all 0.3s cubic-bezier(0.4, 0, 0.2, 1)"})}),(0,q.jsx)(x.c,{my:1}),(0,q.jsx)(h.m,{label:"Vrstvy element\u016f (L)",placement:"right",children:(0,q.jsx)(u.K,{"aria-label":"Zobrazit vrstvy",icon:(0,q.jsx)(S.PfQ,{}),bg:ee?Xe:void 0,color:ee?L.textOnSecondary||"black":void 0,_hover:{bg:Xe,color:L.textOnSecondary||"black"},size:"md",onClick:()=>te(!ee),borderRadius:"full",variant:ee?"solid":"ghost",sx:{"&:hover":{transform:"scale(1.1)",boxShadow:"md"}},transition:"all 0.2s"})}),Z&&(0,q.jsxs)(q.Fragment,{children:[(0,q.jsx)(x.c,{my:1}),(0,q.jsx)(h.m,{label:"Ulo\u017eit zm\u011bny (Ctrl+S)",placement:"right",children:(0,q.jsx)(u.K,{"aria-label":"Ulo\u017eit",icon:(0,q.jsx)(S.Bc_,{}),bgGradient:"linear(135deg, green.400, green.600)",color:"white",_hover:{transform:"scale(1.2)",bgGradient:"linear(135deg, green.500, green.700)"},size:"md",onClick:Rt,borderRadius:"full",boxShadow:"0 0 0 0 rgba(72, 187, 120, 0.4)",transition:"all 0.2s",sx:{"@keyframes pulseGreen":{"0%, 100%":{boxShadow:"0 0 0 0 rgba(72, 187, 120, 0.6), 0 4px 12px rgba(72, 187, 120, 0.4)"},"50%":{boxShadow:"0 0 0 10px rgba(72, 187, 120, 0), 0 6px 16px rgba(72, 187, 120, 0.2)"}},animation:"pulseGreen 2s infinite"}})})]})]})]})}),F&&V&&$&&(0,q.jsx)(y.Z,{children:(0,q.jsxs)(i.a,{className:"myuibrix-panel",ref:Ne,position:"fixed",top:0===Be.stylePicker.y?"".concat(Math.min($.top+$.height+10,window.innerHeight-450),"px"):"".concat(Be.stylePicker.y,"px"),left:0===Be.stylePicker.x?"".concat(Math.min($.left,window.innerWidth-380),"px"):"".concat(Be.stylePicker.x,"px"),width:"".concat(Be.stylePicker.width,"px"),height:"".concat(Be.stylePicker.height,"px"),bg:"rgba(255, 255, 255, 0.98)",backdropFilter:"blur(16px) saturate(180%)",borderRadius:"2xl",boxShadow:"0 24px 70px rgba(0,0,0,0.3), 0 10px 30px rgba(0,0,0,0.22), inset 0 1px 0 rgba(255,255,255,0.5)",border:"2px solid",borderColor:"rgba(255,255,255,0.4)",zIndex:10001,overflow:"hidden",onMouseDown:e=>rt("stylePicker",e),cursor:"stylePicker"===Ge?"grabbing":"default",fontFamily:"var(--chakra-fonts-body)",sx:{"@keyframes slideInBounce":{"0%":{opacity:0,transform:"translateY(-30px) scale(0.9)"},"60%":{opacity:1,transform:"translateY(5px) scale(1.02)"},"100%":{opacity:1,transform:"translateY(0) scale(1)"}},animation:"slideInBounce 0.4s cubic-bezier(0.34, 1.56, 0.64, 1)","&::before":{content:'""',position:"absolute",top:0,left:0,right:0,height:"2px",background:"linear-gradient(90deg, ".concat(et,", transparent)"),opacity:.6}},children:[(0,q.jsxs)(l.s,{className:"panel-header",bgGradient:"linear(135deg, ".concat(et,", ").concat(et,"dd)"),color:"white",p:4,align:"center",justify:"space-between",cursor:"move",borderTopRadius:"2xl",boxShadow:"0 4px 12px rgba(0,0,0,0.1)",borderBottom:"1px solid rgba(255,255,255,0.2)",children:[(0,q.jsxs)(c.z,{children:[(0,q.jsx)(S.VSk,{}),(0,q.jsx)(f.D,{size:"sm",textTransform:"uppercase",letterSpacing:"wider",fontWeight:"800",children:(null===(t=z.TD.find(e=>e.name===V))||void 0===t?void 0:t.label)||V})]}),(0,q.jsxs)(c.z,{spacing:1,children:[(0,q.jsx)(h.m,{label:"P\u0159esunout nahoru",children:(0,q.jsx)(u.K,{"aria-label":"P\u0159esunout nahoru",icon:(0,q.jsx)(S.wAb,{}),size:"sm",variant:"ghost",colorScheme:"whiteAlpha",onClick:()=>kt(V),isDisabled:0===de.indexOf(V)})}),(0,q.jsx)(h.m,{label:"P\u0159esunout dol\u016f",children:(0,q.jsx)(u.K,{"aria-label":"P\u0159esunout dol\u016f",icon:(0,q.jsx)(S.fK4,{}),size:"sm",variant:"ghost",colorScheme:"whiteAlpha",onClick:()=>Ct(V),isDisabled:de.indexOf(V)===de.length-1})}),(0,q.jsx)(x.c,{orientation:"vertical",h:"20px",borderColor:"whiteAlpha.400"}),(0,q.jsx)(h.m,{label:"Odebrat element",children:(0,q.jsx)(u.K,{"aria-label":"Odebrat element",icon:(0,q.jsx)(S.IXo,{}),size:"sm",variant:"ghost",colorScheme:"whiteAlpha",onClick:()=>zt(V)})}),(0,q.jsx)(u.K,{"aria-label":"Zav\u0159\xedt",icon:(0,q.jsx)(S.yGN,{}),size:"sm",variant:"ghost",colorScheme:"whiteAlpha",onClick:()=>U(null),borderRadius:"full"})]})]}),(0,q.jsxs)(b.T,{align:"stretch",p:4,spacing:3,maxH:"450px",overflowY:"auto",children:[(0,q.jsxs)(l.s,{justify:"space-between",align:"center",pb:2,children:[(0,q.jsxs)(c.z,{spacing:2,children:[(0,q.jsx)(S.PfQ,{size:14}),(0,q.jsxs)(m.E,{fontSize:"xs",fontWeight:"bold",color:"gray.500",textTransform:"uppercase",children:["Pozice ",de.indexOf(V)+1," z ",de.length]})]}),(0,q.jsxs)(c.z,{spacing:1,children:[(0,q.jsx)(u.K,{"aria-label":"P\u0159esunout nahoru",icon:(0,q.jsx)(S.wAb,{}),size:"xs",variant:"ghost",onClick:()=>kt(V),isDisabled:0===de.indexOf(V)}),(0,q.jsx)(u.K,{"aria-label":"P\u0159esunout dol\u016f",icon:(0,q.jsx)(S.fK4,{}),size:"xs",variant:"ghost",onClick:()=>Ct(V),isDisabled:de.indexOf(V)===de.length-1})]})]}),(0,q.jsx)(x.c,{}),(0,q.jsx)(m.E,{fontSize:"xs",fontWeight:"bold",color:"gray.500",textTransform:"uppercase",children:"Vyberte Styl"}),(0,q.jsx)(v.r,{columns:2,spacing:3,children:It.map(e=>{const t=Mt===e.value;return(0,q.jsxs)(i.a,{p:3,borderRadius:"lg",border:"2px",borderColor:t?et:qe,bg:t?(0,o.dU)("blue.50","blue.900"):"transparent",cursor:"pointer",transition:"all 0.3s cubic-bezier(0.4, 0, 0.2, 1)",_hover:{borderColor:et,transform:"translateY(-4px) scale(1.02)",boxShadow:"lg"},_active:{transform:"translateY(-2px) scale(0.98)"},onClick:()=>yt(V,e.value),position:"relative",children:[t&&(0,q.jsx)(p.E,{position:"absolute",top:1,right:1,colorScheme:"green",fontSize:"9px",children:"AKTIVN\xcd"}),(0,q.jsxs)(b.T,{align:"start",spacing:1,children:[(0,q.jsx)(m.E,{fontWeight:"bold",fontSize:"sm",children:e.label}),(0,q.jsx)(m.E,{fontSize:"xs",color:"gray.500",noOfLines:2,children:e.description})]})]},e.value)})}),(0,q.jsx)(x.c,{}),(0,q.jsxs)(c.z,{justify:"space-between",children:[(0,q.jsxs)(m.E,{fontSize:"xs",color:"gray.500",children:[It.length," dostupn\xfdch styl\u016f"]}),(0,q.jsx)(p.E,{colorScheme:Z?"orange":"gray",children:Z?"Zm\u011bn\u011bno":"Ulo\u017eeno"})]})]}),(0,q.jsx)(i.a,{position:"absolute",bottom:0,right:0,width:"24px",height:"24px",cursor:"nwse-resize",bgGradient:"linear(135deg, transparent, rgba(0,0,0,0.15))",opacity:.4,_hover:{opacity:1,bgGradient:"linear(135deg, transparent, rgba(0,0,0,0.25))"},onMouseDown:e=>it("stylePicker",e),sx:{clipPath:"polygon(100% 0, 100% 100%, 0 100%)"},transition:"all 0.2s"})]})}),!1,F&&Te&&!V&&(0,q.jsxs)(i.a,{position:"fixed",top:"50%",left:"50%",transform:"translate(-50%, -50%)",bg:"rgba(255, 255, 255, 0.98)",backdropFilter:"blur(20px) saturate(180%)",p:8,borderRadius:"3xl",boxShadow:"0 30px 90px rgba(0,0,0,0.3), 0 12px 40px rgba(0,0,0,0.22)",border:"2px solid",borderColor:"rgba(255,255,255,0.4)",zIndex:9999,maxW:"450px",textAlign:"center",fontFamily:"var(--chakra-fonts-body)",sx:{"@keyframes fadeInScale":{"0%":{opacity:0,transform:"translate(-50%, -50%) scale(0.8)"},"100%":{opacity:1,transform:"translate(-50%, -50%) scale(1)"}},animation:"fadeInScale 0.4s cubic-bezier(0.34, 1.56, 0.64, 1)"},children:[(0,q.jsx)(u.K,{"aria-label":"Zav\u0159\xedt n\xe1pov\u011bdu",icon:(0,q.jsx)(S.yGN,{}),size:"sm",position:"absolute",top:2,right:2,variant:"ghost",onClick:()=>Ae(!1)}),(0,q.jsxs)(b.T,{spacing:3,children:[(0,q.jsx)(i.a,{fontSize:"48px",children:"\ud83d\udc46"}),(0,q.jsx)(f.D,{size:"md",children:"Klikn\u011bte na element pro \xfapravu"}),(0,q.jsxs)(m.E,{color:"gray.500",fontSize:"sm",children:["\u2022 P\u0159ejet\xedm my\u0161i zv\xfdrazn\xedte sekce",(0,q.jsx)("br",{}),"\u2022 Klikn\u011bte p\u0159\xedmo na element pro \xfapravu stylu",(0,q.jsx)("br",{}),"\u2022 Pou\u017eijte tla\u010d\xedtka \u2b06\ufe0f\u2b07\ufe0f pro zm\u011bnu pozice",(0,q.jsx)("br",{}),"\u2022 Klikn\u011bte na \ud83d\uddd1\ufe0f pro odstran\u011bn\xed",(0,q.jsx)("br",{}),"\u2022 P\u0159epn\u011bte viewport pro test responzivity"]}),(0,q.jsx)(g.$,{size:"sm",colorScheme:"blue",onClick:()=>{Ae(!1),X(!0)},leftIcon:(0,q.jsx)(w.OiG,{}),children:"P\u0159idat nov\xfd element"})]})]}),Oe>1&&(0,q.jsx)(i.a,{p:4,borderBottom:"1px",borderColor:"gray.100",bg:"white",children:(0,q.jsxs)(b.T,{align:"stretch",spacing:2,children:[(0,q.jsx)(m.E,{fontSize:"sm",fontWeight:"bold",color:"gray.600",children:"Vlo\u017eit do sloupce"}),(0,q.jsxs)(c.z,{spacing:2,flexWrap:"wrap",children:[Array.from({length:Oe}).map((e,t)=>(0,q.jsxs)(g.$,{size:"sm",variant:null!=Le&&Le%Oe===t?"solid":"outline",colorScheme:null!=Le&&Le%Oe===t?"blue":"gray",onClick:e=>{e.stopPropagation();const n=wt(t);Fe(n),Ye({title:"Pozice zvolena",description:"Sloupec ".concat(t+1),status:"info",duration:1500})},children:["Sloupec ",t+1]},t)),(0,q.jsx)(g.$,{size:"sm",variant:"ghost",onClick:()=>Fe(null),children:"Zru\u0161it pozici"})]})]})}),F&&ee&&(0,q.jsxs)(i.a,{className:"myuibrix-panel",position:"fixed",left:0===Be.layersPanel.x?void 0:"".concat(Be.layersPanel.x,"px"),right:0===Be.layersPanel.x?4:void 0,top:0===Be.layersPanel.y?"72px":"".concat(Be.layersPanel.y,"px"),bottom:0===Be.layersPanel.y?4:void 0,transform:void 0,width:"".concat(Be.layersPanel.width,"px"),height:0===Be.layersPanel.y?"auto":"".concat(Be.layersPanel.height,"px"),bg:"rgba(255, 255, 255, 0.97)",backdropFilter:"blur(16px) saturate(180%)",borderRadius:"2xl",boxShadow:"0 24px 70px rgba(0,0,0,0.3), 0 10px 30px rgba(0,0,0,0.22)",border:"2px solid",borderColor:"rgba(255,255,255,0.4)",zIndex:10001,overflow:"hidden",onMouseDown:e=>rt("layersPanel",e),cursor:"layersPanel"===Ge?"grabbing":"default",fontFamily:"var(--chakra-fonts-body)",display:"flex",flexDirection:"column",sx:{"@keyframes slideInRight":{from:{opacity:0,transform:"translateX(40px)"},to:{opacity:1,transform:"translateX(0)"}},animation:"slideInRight 0.3s cubic-bezier(0.4, 0, 0.2, 1)"},children:[(0,q.jsxs)(l.s,{className:"panel-header",bgGradient:"linear(135deg, ".concat(Xe,", ").concat(Xe,"dd)"),color:"white",p:4,align:"center",justify:"space-between",cursor:"move",borderTopRadius:"2xl",boxShadow:"0 4px 12px rgba(0,0,0,0.15)",borderBottom:"1px solid rgba(255,255,255,0.2)",children:[(0,q.jsxs)(c.z,{children:[(0,q.jsx)(S.PfQ,{}),(0,q.jsx)(f.D,{size:"sm",fontWeight:"800",letterSpacing:"wide",children:"Vrstvy Element\u016f"})]}),(0,q.jsx)(u.K,{"aria-label":"Zav\u0159\xedt",icon:(0,q.jsx)(S.yGN,{}),size:"sm",variant:"ghost",colorScheme:"whiteAlpha",onClick:()=>te(!1)})]}),(0,q.jsx)(i.a,{p:2,borderBottom:"1px",borderColor:"whiteAlpha.400",bg:"whiteAlpha.200",children:(0,q.jsxs)(c.z,{justify:"space-between",children:[(0,q.jsx)(m.E,{fontSize:"xs",opacity:.85,children:"Za\u010d\xedt s pr\xe1zdn\xfdm rozlo\u017een\xedm"}),(0,q.jsx)(g.$,{size:"xs",variant:"outline",onClick:Nt,children:"Za\u010d\xedt s pr\xe1zdn\xfdm rozlo\u017een\xedm"})]})}),(0,q.jsxs)(b.T,{align:"stretch",p:3,spacing:2,flex:1,overflowY:"auto",children:[de.map((e,t)=>{const n=z.TD.find(t=>t.name===e),a=le.has(e),r=V===e,s=pe===e,o=ue===e;return(0,q.jsx)(i.a,{p:3,borderRadius:"lg",border:"2px",borderColor:o?Qe:r?Xe:"gray.200",bgGradient:s?"linear(to-r, gray.100, gray.200)":r?"linear(135deg, ".concat(Xe,"15, ").concat(Xe,"25)"):a?"linear(to-r, white, gray.50)":"linear(to-r, gray.100, gray.150)",cursor:s?"grabbing":"grab",opacity:s?.6:a?1:.5,transition:"all 0.3s cubic-bezier(0.4, 0, 0.2, 1)",transform:o?"scale(1.03) translateX(8px)":void 0,boxShadow:r?"0 4px 12px rgba(0,0,0,0.1)":"0 2px 4px rgba(0,0,0,0.05)",_hover:{borderColor:Xe,transform:o?"scale(1.03) translateX(8px)":"translateX(6px) translateY(-2px)",boxShadow:"0 6px 16px rgba(0,0,0,0.12)"},draggable:!0,onDragStart:t=>{Et(e,t),t.target.style.cursor="grabbing"},onDragEnd:e=>{e.target.style.cursor="grab",_t()},onDragOver:t=>Tt(t,e),onDragLeave:e=>At(e),onDrop:t=>Pt(t,e),onClick:()=>{U(e);const t=A('[data-element="'.concat(e,'"]'));if(t){const e=t.getBoundingClientRect();Y({top:e.top,left:e.left,width:e.width,height:e.height})}},children:(0,q.jsxs)(l.s,{align:"center",justify:"space-between",children:[(0,q.jsxs)(c.z,{flex:1,spacing:2,children:[(0,q.jsx)(d.I,{as:w.WhN,boxSize:4,color:"gray.400",cursor:"grab",_active:{cursor:"grabbing"}}),(0,q.jsx)(i.a,{p:2,bg:r?Xe:"".concat(Xe,"20"),borderRadius:"lg",transition:"all 0.2s",children:(0,q.jsx)(d.I,{as:(null===n||void 0===n?void 0:n.icon)||w.$ZR,boxSize:5,color:r?"white":Xe})}),(0,q.jsxs)(b.T,{align:"start",spacing:0,flex:1,children:[(0,q.jsx)(m.E,{fontWeight:"bold",fontSize:"sm",children:(null===n||void 0===n?void 0:n.label)||e}),(0,q.jsxs)(m.E,{fontSize:"xs",color:"gray.500",children:["Pozice ",t+1]})]})]}),(0,q.jsxs)(c.z,{spacing:1,children:[(0,q.jsx)(u.K,{"aria-label":"P\u0159esunout nahoru",icon:(0,q.jsx)(S.wAb,{}),size:"xs",variant:"ghost",onClick:t=>{t.stopPropagation(),kt(e)},isDisabled:0===t}),(0,q.jsx)(u.K,{"aria-label":"P\u0159esunout dol\u016f",icon:(0,q.jsx)(S.fK4,{}),size:"xs",variant:"ghost",onClick:t=>{t.stopPropagation(),Ct(e)},isDisabled:t===de.length-1}),(0,q.jsx)(u.K,{"aria-label":a?"Skr\xfdt":"Zobrazit",icon:(0,q.jsx)(S._NO,{}),size:"xs",variant:"ghost",colorScheme:a?"gray":"red",onClick:t=>{if(t.stopPropagation(),a)zt(e);else{const t=new Set(le);t.add(e),ce(t),G(!0),F&&window.dispatchEvent(new CustomEvent("myuibrix-change",{detail:{elementName:e,variant:K[e],visible:!0,previewMode:!0}})),setTimeout(()=>{const t=A('[data-element="'.concat(e,'"]'));t&&(t.style.display=""),ft(de)},0)}}})]})]})},e)}),0===de.length&&(0,q.jsxs)(i.a,{textAlign:"center",py:8,children:[(0,q.jsx)(d.I,{as:w.rrY,boxSize:12,color:"gray.300",mb:3}),(0,q.jsx)(m.E,{fontSize:"sm",color:"gray.500",fontWeight:"bold",children:"Zat\xedm \u017e\xe1dn\xe9 elementy"}),(0,q.jsx)(m.E,{fontSize:"xs",color:"gray.400",mb:3,children:"Za\u010dn\u011bte p\u0159id\xe1n\xedm prv\xe9ho elementu"}),(0,q.jsx)(g.$,{size:"sm",bg:Qe,color:"white",_hover:{opacity:.9},leftIcon:(0,q.jsx)(w.OiG,{}),onClick:()=>{te(!1),X(!0)},children:"P\u0159idat Element"})]})]}),(0,q.jsx)(i.a,{position:"absolute",bottom:0,right:0,width:"20px",height:"20px",cursor:"nwse-resize",bg:"gray.400",opacity:.6,_hover:{opacity:1},onMouseDown:e=>it("layersPanel",e),sx:{clipPath:"polygon(100% 0, 100% 100%, 0 100%)"}})]}),Q&&(0,q.jsxs)(y.Z,{children:[(0,q.jsx)(i.a,{position:"fixed",top:0,left:0,right:0,bottom:0,bg:"blackAlpha.700",backdropFilter:"blur(8px)",zIndex:10002,onClick:()=>{X(!1),ke(""),Ee("all")},sx:{"@keyframes fadeInBackdrop":{from:{opacity:0},to:{opacity:1}},animation:"fadeInBackdrop 0.2s ease-out"}}),(0,q.jsxs)(i.a,{className:"myuibrix-panel",position:"fixed",left:0===Be.elementPicker.x?"50%":"".concat(Be.elementPicker.x,"px"),top:0===Be.elementPicker.y?"50%":"".concat(Be.elementPicker.y,"px"),transform:0===Be.elementPicker.x&&0===Be.elementPicker.y?"translate(-50%, -50%)":void 0,width:"".concat(Be.elementPicker.width,"px"),height:"".concat(Be.elementPicker.height,"px"),maxWidth:"90vw",bg:"rgba(255, 255, 255, 0.98)",backdropFilter:"blur(20px) saturate(180%)",borderRadius:"3xl",boxShadow:"0 40px 120px rgba(0,0,0,0.4), 0 16px 50px rgba(0,0,0,0.3)",border:"2px solid",borderColor:"rgba(255,255,255,0.5)",zIndex:10003,overflow:"hidden",onMouseDown:e=>rt("elementPicker",e),cursor:"elementPicker"===Ge?"grabbing":"default",fontFamily:"var(--chakra-fonts-body)",sx:{"@keyframes modalZoomIn":{"0%":{opacity:0,transform:0===Be.elementPicker.x&&0===Be.elementPicker.y?"translate(-50%, -50%) scale(0.85)":"scale(0.85)"},"100%":{opacity:1,transform:0===Be.elementPicker.x&&0===Be.elementPicker.y?"translate(-50%, -50%) scale(1)":"scale(1)"}},animation:"modalZoomIn 0.3s cubic-bezier(0.34, 1.56, 0.64, 1)"},children:[(0,q.jsxs)(l.s,{className:"panel-header",bgGradient:"linear(135deg, ".concat(Qe,", ").concat(Qe,"dd)"),color:"white",p:5,align:"center",justify:"space-between",cursor:"move",borderTopRadius:"3xl",boxShadow:"0 6px 16px rgba(0,0,0,0.15)",borderBottom:"1px solid rgba(255,255,255,0.2)",children:[(0,q.jsxs)(c.z,{spacing:3,children:[(0,q.jsx)(i.a,{p:2,bg:"whiteAlpha.300",borderRadius:"lg",backdropFilter:"blur(8px)",children:(0,q.jsx)(d.I,{as:w.OiG,boxSize:6})}),(0,q.jsx)(f.D,{size:"md",fontWeight:"900",letterSpacing:"tight",children:"P\u0159idat Element"})]}),(0,q.jsx)(u.K,{"aria-label":"Zav\u0159\xedt",icon:(0,q.jsx)(S.yGN,{}),size:"sm",variant:"ghost",colorScheme:"whiteAlpha",onClick:()=>{X(!1),ke(""),Ee("all")}})]}),(0,q.jsx)(i.a,{p:5,borderBottom:"1px",borderColor:"gray.100",bg:"gray.50",children:(0,q.jsxs)(b.T,{spacing:4,children:[(0,q.jsx)(j.p,{placeholder:"\ud83d\udd0d Hledat element...",value:ze,onChange:e=>ke(e.target.value),size:"lg",bg:"white",borderRadius:"xl",border:"2px solid",borderColor:"gray.200",_hover:{borderColor:Qe},_focus:{borderColor:Qe,boxShadow:"0 0 0 3px ".concat(Qe,"33")},fontSize:"md",fontWeight:"500",transition:"all 0.2s"}),(0,q.jsx)(c.z,{spacing:2,w:"full",overflowX:"auto",pb:1,children:[{value:"all",label:"V\u0161echny",icon:w.$ZR},{value:"layout",label:"Rozvr\u017een\xed",icon:w.x7F},{value:"content",label:"Obsah",icon:w.Nhm},{value:"media",label:"M\xe9dia",icon:w.T0M},{value:"interactive",label:"Interaktivn\xed",icon:w.pBr}].map(e=>(0,q.jsx)(g.$,{size:"md",variant:Ce===e.value?"solid":"outline",bgGradient:Ce===e.value?"linear(135deg, ".concat(Qe,", ").concat(Qe,"dd)"):void 0,color:Ce===e.value?"white":"gray.700",borderColor:Ce===e.value?"transparent":"gray.300",borderRadius:"xl",fontWeight:"700",boxShadow:Ce===e.value?"0 4px 12px rgba(0,0,0,0.15)":"none",_hover:{bg:Ce===e.value?void 0:"gray.100",transform:"translateY(-2px)",boxShadow:Ce===e.value?"0 6px 16px rgba(0,0,0,0.2)":"0 2px 8px rgba(0,0,0,0.1)"},onClick:()=>Ee(e.value),leftIcon:(0,q.jsx)(d.I,{as:e.icon}),minW:"fit-content",transition:"all 0.2s cubic-bezier(0.4, 0, 0.2, 1)",children:e.label},e.value))})]})}),(0,q.jsxs)(b.T,{align:"stretch",p:4,spacing:4,maxH:"calc(80vh - 200px)",overflowY:"auto",children:[["layout","content","media","interactive"].map(e=>{if("all"!==Ce&&Ce!==e)return null;const t="homepage"===n?re:[],a=z.TD.filter(n=>n.category===e&&(0===t.length||t.includes(n.name))).filter(e=>{if(ze){const t=ze.toLowerCase();return e.label.toLowerCase().includes(t)||e.description.toLowerCase().includes(t)}return!0});if(0===a.length)return null;return(0,q.jsxs)(i.a,{children:[(0,q.jsx)(m.E,{fontSize:"sm",fontWeight:"bold",color:"gray.500",textTransform:"uppercase",mb:2,children:{layout:"Rozvr\u017een\xed",content:"Obsah",media:"M\xe9dia",interactive:"Interaktivn\xed"}[e]}),(0,q.jsx)(v.r,{columns:{base:1,md:2},spacing:3,children:a.map(e=>(0,q.jsx)(i.a,{p:4,borderRadius:"xl",border:"2px solid",borderColor:"gray.200",bg:"white",cursor:"pointer",transition:"all 0.3s cubic-bezier(0.4, 0, 0.2, 1)",_hover:{borderColor:Qe,transform:"translateY(-4px) scale(1.02)",boxShadow:"0 8px 24px rgba(0,0,0,0.12), 0 0 0 2px ".concat(Qe,"22"),bg:"".concat(Qe,"05")},_active:{transform:"translateY(-2px) scale(1)"},onClick:()=>St(e.name),children:(0,q.jsxs)(c.z,{spacing:3,children:[(0,q.jsx)(i.a,{p:3,bgGradient:"linear(135deg, ".concat(Qe,"15, ").concat(Qe,"25)"),borderRadius:"xl",transition:"all 0.2s",children:(0,q.jsx)(d.I,{as:e.icon,boxSize:6,color:Qe})}),(0,q.jsxs)(b.T,{align:"start",spacing:0,flex:1,children:[(0,q.jsx)(m.E,{fontWeight:"bold",fontSize:"sm",children:e.label}),(0,q.jsx)(m.E,{fontSize:"xs",color:"gray.500",children:e.description})]}),(0,q.jsx)(d.I,{as:w.OiG,color:Qe})]})},e.name))})]},e)}),z.TD.every(e=>le.has(e.name))&&(0,q.jsxs)(i.a,{textAlign:"center",py:8,children:[(0,q.jsx)(d.I,{as:w.Ky9,boxSize:8,color:Qe,mb:2}),(0,q.jsx)(m.E,{fontSize:"lg",fontWeight:"bold",mb:2,children:"V\u0161echny elementy p\u0159id\xe1ny!"}),(0,q.jsx)(m.E,{fontSize:"sm",color:"gray.500",children:"Pou\u017e\xedv\xe1te v\u0161echny dostupn\xe9 elementy"})]}),!z.TD.some(e=>{const t="all"===Ce||e.category===Ce,n=!ze||e.label.toLowerCase().includes(ze.toLowerCase())||e.description.toLowerCase().includes(ze.toLowerCase());return!le.has(e.name)&&t&&n})&&!z.TD.every(e=>le.has(e.name))&&(0,q.jsxs)(i.a,{textAlign:"center",py:8,children:[(0,q.jsx)(d.I,{as:w.TNq,boxSize:8,color:"gray.400",mb:2}),(0,q.jsx)(m.E,{fontSize:"md",fontWeight:"bold",mb:1,children:"\u017d\xe1dn\xe9 v\xfdsledky"}),(0,q.jsx)(m.E,{fontSize:"sm",color:"gray.500",children:"Zkuste zm\u011bnit vyhled\xe1vac\xed dotaz nebo filtr"})]})]}),(0,q.jsx)(i.a,{position:"absolute",bottom:0,right:0,width:"24px",height:"24px",cursor:"nwse-resize",bgGradient:"linear(135deg, transparent, rgba(0,0,0,0.15))",opacity:.4,_hover:{opacity:1,bgGradient:"linear(135deg, transparent, rgba(0,0,0,0.25))"},onMouseDown:e=>it("elementPicker",e),sx:{clipPath:"polygon(100% 0, 100% 100%, 0 100%)"},transition:"all 0.2s"})]})]})]}):null}}}]); //# sourceMappingURL=334.0d196877.chunk.js.map