"use strict";(()=>{var Qm=(t=>typeof require<"u"?require:typeof Proxy<"u"?new Proxy(t,{get:(e,n)=>(typeof require<"u"?require:e)[n]}):t)(function(t){if(typeof require<"u")return require.apply(this,arguments);throw Error('Dynamic require of "'+t+'" is not supported')});(function(){"use strict";try{if(typeof document<"u"){var t=document.createElement("style");t.appendChild(document.createTextNode('@import"https://fonts.googleapis.com/css2?family=Atkinson+Hyperlegible:ital,wght@0,400;0,500;0,600;0,700;1,400;1,500;1,600;1,700&display=swap";#leoai-wrapper{--bg: #ffffff;--window-shadow: 0 4px 20px 0 rgba(0, 123, 255, .25);--glass: rgba(248, 248, 248, .5);--3d-shadow: inset 0 -5px 8px rgba(0, 0, 0, .04);--3d-shadow-hover: inset 0 -5px 16px rgba(0, 0, 0, .08);--3d-shadow-top: inset 0 5px 8px rgba(0, 0, 0, .04);--drop-shadow: 0 2px 5px rgba(0, 0, 0, .04);--drop-shadow-hover: 0 5px 8px rgba(0, 0, 0, .06);--gradient: linear-gradient(45deg, #6366f1 0%, #0ea5e9 100%);--primary-300: #cce5ff;--primary-400: #66b2ff;--primary-500: #007bff;--primary-600: #0056b3;--primary-700: #004085;--gray-50: #fafafa;--gray-100: #f5f5f5;--gray-200: #e5e5e5;--gray-300: #d4d4d4;--gray-400: #a3a3a3;--gray-500: #737373;--gray-600: #525252;--gray-700: #404040;--gray-800: #262626;--gray-900: #171717;--gray-950: #0a0a0a;--user-message-text: #fff;--error: #ef4444}.leoai-container{position:fixed;right:0;bottom:0;display:flex;flex-direction:column;align-items:flex-end;z-index:999;transition:all .25s ease!important;box-sizing:border-box!important}.leoai-container ul,.leoai-container ol{padding-left:20px;padding-top:4px;padding-bottom:4px;list-style:disc!important}.leoai-container p,.leoai-container span,.leoai-container h1,.leoai-container h2,.leoai-container h3,.leoai-container h4,.leoai-container h5,.leoai-container h6,.leoai-container div{margin:0;font-family:Atkinson Hyperlegible,sans-serif!important}.leoai-container button,.leoai-container a{cursor:pointer;transition:all .15s;text-decoration:none}.leoai-container strong{font-weight:bolder!important}.leoai-container em{font-style:italic!important}#leoai-wrapper button,#leoai-wrapper input,#leoai-wrapper select,#leoai-wrapper textarea,#leoai-wrapper h1,#leoai-wrapper h2,#leoai-wrapper h3,#leoai-wrapper h4,#leoai-wrapper h5,#leoai-wrapper p,#leoai-wrapper span,#leoai-wrapper div{font-family:Atkinson Hyperlegible,sans-serif!important;box-sizing:border-box!important}#leoai-wrapper ::-webkit-scrollbar{width:8px}#leoai-wrapper ::-webkit-scrollbar-track{background:#fff;border-radius:10px}#leoai-wrapper ::-webkit-scrollbar-thumb{background-color:#d1d1d1;border-radius:10px;border:2px solid #f5f5f5}#leoai-wrapper ::-webkit-scrollbar-thumb:hover{background-color:#b3b3b3}@keyframes spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}@keyframes pulse{0%{opacity:1}50%{opacity:.5}to{opacity:1}}@media only screen and (min-width: 768px){.leoai-container{right:16px;bottom:16px}}.leoai-container .leoai-window{position:absolute;flex-direction:column;width:100dvw;height:100dvh;bottom:0;transform:translate(110%);overflow:clip;background-color:var(--bg);box-shadow:var(--window-shadow);visibility:hidden;outline:2px solid var(--gray-100)}.leoai-container .leoai-window.open{visibility:visible}@media only screen and (min-width: 768px){.leoai-container .leoai-window{border:1px solid var(--gray-100);border-radius:24px;bottom:54px;width:440px;height:700px;max-height:calc(100vh - 100px)}.leoai-container .leoai-window .leoai-window-border{border:1px solid var(--gray-200);border-radius:23px}}.leoai-container .leoai-window .leoai-window-border{height:100%}.leoai-container .leoai-window .leoai-loading-overlay{display:flex;justify-content:center;align-items:center;height:100%;position:absolute;top:0;bottom:0;left:0;right:0;z-index:10;background-color:var(--bg);color:var(--primary-500)}.leoai-container .leoai-window .leoai-loading-overlay .loading-spinner{animation:spin .7s linear infinite}.leoai-container .leoai-hot-toast{background-color:var(--bg);border:1px solid var(--gray-300);border-radius:12px;padding:12px 16px;box-shadow:var(--3d-shadow),var(--drop-shadow);color:var(--gray-900);gap:8px;width:70%}.leoai-container .open-leoai-button{align-items:center;justify-content:center;background:var(--gradient);border:none;padding:0;border-radius:16px;width:54px;height:54px;display:flex;cursor:pointer;z-index:99}.leoai-container .open-leoai-button svg{color:var(--user-message-text)!important}@media only screen and (max-width: 767px){.leoai-container .open-leoai-button{margin-right:8px;margin-bottom:8px}}.leoai-container .open-leoai-button.open{width:40px;height:40px;display:flex}@media only screen and (max-width: 767px){.leoai-container .open-leoai-button.open{display:none}}.leoai-container .open-leoai-button:hover{filter:brightness(1.1);transform:scale(1.05);transition:all .15s}.leoai-container .open-leoai-button:active{transform:scale(.9);transition-duration:.05s}.leoai-container .leoai-watermark{display:flex;align-items:center;justify-content:center;font-size:12px;color:var(--gray-800)}.leoai-container .leoai-watermark a{display:flex;align-items:center;gap:2px;margin-left:8px;text-decoration:none;color:#1d4ed8}.leoai-container .leoai-watermark a span{font-size:11px;font-weight:600;margin-left:2px}.leoai-container .leoai-watermark a:hover>span{text-decoration:underline}.leoai-container .leoai-footer-container{position:absolute;bottom:0;left:6px;right:6px;border:1px solid var(--gray-300);border-bottom:none;border-top-left-radius:20px;border-top-right-radius:20px;background-color:var(--glass);box-shadow:var(--3d-shadow-top);-webkit-backdrop-filter:blur(4px);backdrop-filter:blur(4px);padding:8px 8px 4px;z-index:3;display:flex;flex-direction:column;align-content:center;gap:4px}.leoai-container .leoai-footer-container:before{z-index:-1;content:"";position:absolute;bottom:-1px;left:-1px;right:-1px;height:100%;background:linear-gradient(0,var(--bg) 0%,transparent 100%)}.leoai-container .leoai-view-header{display:flex;justify-content:space-between;align-items:start;color:var(--gray-800)}.leoai-container .leoai-view-header:not(.home){gap:8px;background-color:var(--glass);box-shadow:var(--3d-shadow);-webkit-backdrop-filter:blur(8px);backdrop-filter:blur(8px);padding:8px;position:absolute;top:0;left:6px;right:6px;z-index:3;width:auto;border-bottom-left-radius:20px;border-bottom-right-radius:20px;border:1px solid var(--gray-300);border-top:none}.leoai-container .leoai-view-header:not(.home):before{z-index:-1;content:"";position:absolute;top:-1px;left:-1px;right:-1px;height:100%;background:linear-gradient(180deg,var(--bg) 0%,transparent 100%)}.leoai-container .leoai-view-header.home{padding:16px}.leoai-container .leoai-view-header.home .leoai-header-logo{height:36px;margin-left:8px;margin-top:8px}.leoai-container .leoai-view-header .leoai-header-left-side{display:flex;gap:6px;align-items:center}.leoai-container .leoai-view-header .leoai-header-button{display:flex;align-items:center;justify-content:center;background-color:var(--bg);border:1px solid transparent;color:var(--gray-500);border-radius:16px;width:48px;height:48px}.leoai-container .leoai-view-header .leoai-header-button:hover{background-color:var(--gray-50);color:var(--primary-500);border:1px solid var(--gray-200)}.leoai-container .leoai-view-header .leoai-header-button:hover.close{color:var(--error)}.leoai-container .leoai-article-card{display:flex;flex-direction:column;background-color:var(--bg);box-shadow:var(--3d-shadow),var(--drop-shadow);border-radius:14px;border:1px solid var(--gray-200);color:var(--gray-600);padding:16px;overflow:hidden}.leoai-container .leoai-article-card:hover{transform:translateY(-2px);box-shadow:var(--drop-shadow-hover),var(--3d-shadow-hover);border-color:var(--gray-300)}.leoai-container .leoai-article-card:hover .leoai-article-thumbnail{transform:scale(1.05)}.leoai-container .leoai-article-card .leoai-article-thumbnail-container{width:100%;overflow:hidden;clip-path:inset(0);border-radius:12px;display:flex;align-items:center;border:1px solid var(--gray-200)}.leoai-container .leoai-article-card .leoai-article-thumbnail-container .leoai-article-thumbnail{width:100%;height:auto;transition:transform .3s ease}.leoai-container .leoai-article-card .leoai-article-info{display:flex;flex-direction:column;gap:8px;margin-top:16px;align-items:start}.leoai-container .leoai-article-card .leoai-article-info .leoai-article-title{font-size:16px;font-weight:700;color:var(--gray-800);text-align:start}.leoai-container .leoai-article-card .leoai-article-info .leoai-article-description{font-size:14px;text-align:start}.leoai-container .leoai-message-group{display:flex;flex-direction:column;gap:6px}.leoai-container .leoai-message-group .leoai-message-container:first-child .leoai-message-bubble{border-bottom-left-radius:6px}.leoai-container .leoai-message-group .leoai-message-container:last-child .leoai-message-bubble{border-top-left-radius:6px}.leoai-container .leoai-message-group .leoai-message-container:not(:first-child):not(:last-child) .leoai-message-bubble{border-top-left-radius:6px;border-bottom-left-radius:6px}.leoai-container .leoai-message-group .leoai-message-container:only-child .leoai-message-bubble{border-radius:14px}.leoai-container .leoai-message-container{max-width:80%}.leoai-container .leoai-message-container .leoai-message-bubble .leoai-typing-dots{display:flex;gap:4px;padding:4px 0}.leoai-container .leoai-message-container .leoai-message-bubble .leoai-typing-dots span{width:8px;height:8px;border-radius:50%;background-color:var(--gray-400);animation:typing-bounce 1s infinite ease-in-out}.leoai-container .leoai-message-container .leoai-message-bubble .leoai-typing-dots span:nth-child(1){animation-delay:0s}.leoai-container .leoai-message-container .leoai-message-bubble .leoai-typing-dots span:nth-child(2){animation-delay:.2s}.leoai-container .leoai-message-container .leoai-message-bubble .leoai-typing-dots span:nth-child(3){animation-delay:.4s}@keyframes typing-bounce{0%,80%,to{transform:translateY(0)}40%{transform:translateY(-6px)}}.leoai-container .leoai-message-container .leoai-message-bubble{flex-direction:column;padding:12px 16px;color:var(--gray-900);border-radius:14px;font-size:17px}.leoai-container .leoai-message-container.ai{display:flex;flex-direction:row;align-items:end;gap:8px;max-width:95%}.leoai-container .leoai-message-container.ai .leoai-assistant-icon{width:32px;height:32px;filter:drop-shadow(var(--drop-shadow));margin-bottom:4px}.leoai-container .leoai-message-container.ai .leoai-message-bubble{color:var(--gray-800);background-color:var(--bg);border:1px solid var(--gray-200);box-shadow:var(--3d-shadow),var(--drop-shadow)}.leoai-container .leoai-message-container.ai .leoai-message-bubble p{margin:12px 2px}.leoai-container .leoai-message-container.ai.no-icon .leoai-message-bubble{margin-left:40px}.leoai-container .leoai-message-container.user{display:flex;justify-content:end;margin-left:auto;letter-spacing:.2px}.leoai-container .leoai-message-container.user .leoai-message-bubble{background:var(--gradient);color:var(--user-message-text);box-shadow:var(--3d-shadow),var(--drop-shadow)}.leoai-container .leoai-message-container .leoai-message-bubble{overflow-x:hidden}.leoai-container .leoai-message-container .leoai-message-bubble a{text-decoration:underline!important;color:var(--primary-500)!important}.leoai-container .leoai-message-container .leoai-message-bubble p:only-child{margin:0!important}.leoai-container .leoai-message-container .leoai-message-bubble p:first-child{margin-top:0!important}.leoai-container .leoai-message-container .leoai-message-bubble p:last-child{margin-bottom:0!important}.leoai-container .leoai-message-container .leoai-message-bubble h1:first-child,.leoai-container .leoai-message-container .leoai-message-bubble h2:first-child,.leoai-container .leoai-message-container .leoai-message-bubble h3:first-child,.leoai-container .leoai-message-container .leoai-message-bubble h4:first-child,.leoai-container .leoai-message-container .leoai-message-bubble h5:first-child{margin-top:0!important}.leoai-container .leoai-message-container .leoai-message-bubble h1{font-size:26px!important}.leoai-container .leoai-message-container .leoai-message-bubble h2{font-size:24px!important}.leoai-container .leoai-message-container .leoai-message-bubble h3{font-size:22px!important}.leoai-container .leoai-message-container .leoai-message-bubble h4{font-size:20px!important}.leoai-container .leoai-message-container .leoai-message-bubble h5{font-size:18px!important}.leoai-container .leoai-message-container .leoai-message-bubble img{max-width:100%;border-radius:6px;width:100%;border:1px solid var(--gray-300)}.leoai-container .leoai-message-container .leoai-message-bubble table{display:block;width:100%;overflow-x:auto;-webkit-overflow-scrolling:touch;background-color:var(--bg);max-width:100%;border-collapse:separate;border-spacing:0;margin-top:8px;border:1px solid var(--gray-300);box-shadow:var(--drop-shadow);border-style:hidden}.leoai-container .leoai-message-container .leoai-message-bubble table th,.leoai-container .leoai-message-container .leoai-message-bubble table td{border:1px solid var(--gray-300);padding:8px;text-align:left;min-width:100px}.leoai-container .leoai-message-container .leoai-message-bubble table th{background-color:var(--gray-100);font-weight:400}.leoai-container .leoai-message-container .leoai-message-bubble table thead tr th:first-child{border-top-left-radius:8px}.leoai-container .leoai-message-container .leoai-message-bubble table thead tr th:last-child{border-top-right-radius:8px}.leoai-container .leoai-message-container .leoai-message-bubble table tbody tr:last-child td:first-child{border-bottom-left-radius:8px}.leoai-container .leoai-message-container .leoai-message-bubble table tbody tr:last-child td:last-child{border-bottom-right-radius:8px}.leoai-container .leoai-message-container.user .leoai-message-bubble a{color:var(--user-message-text)!important}.leoai-container .leoai-quick-button{display:flex;justify-content:center;align-items:center;gap:6px;padding:10px 12px;border:1px solid var(--gray-200);border-radius:14px;background-color:var(--bg);box-shadow:var(--3d-shadow),var(--drop-shadow);color:var(--gray-700);font-size:15px}.leoai-container .leoai-quick-button:hover{transform:translateY(-2px);box-shadow:var(--drop-shadow-hover),var(--3d-shadow-hover);border-color:var(--gray-300)}.leoai-container .leoai-quick-button:focus{transform:translateY(0)!important}.leoai-container .leoai-quick-button.home{flex-grow:1}.leoai-container .leoai-quick-button.chat{width:auto}.leoai-container .product-cards{display:flex;gap:12px}.leoai-container .product-card-container{background:var(--bg);border-radius:16px;padding:20px;width:100%;max-width:260px;position:relative;transition:all .3s cubic-bezier(.4,0,.2,1);box-shadow:var(--3d-shadow),var(--drop-shadow),0 0 0 1px var(--gray-200)}.leoai-container .product-card-container:hover{box-shadow:var(--3d-shadow-hover),var(--drop-shadow-hover),0 0 0 1px var(--gray-300);transform:translateY(-1px)}.leoai-container .product-card-container .product-card-content{display:flex;flex-direction:column;gap:12px}.leoai-container .product-card-container .status-view{display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center;width:100%;gap:16px;min-height:100px}.leoai-container .product-card-container .status-view p{font-size:16px;font-weight:500;color:var(--gray-700);margin:0}.leoai-container .product-card-container .status-view .icon-container{width:48px;height:48px;display:flex;align-items:center;justify-content:center;border-radius:50%}.leoai-container .product-card-container .loading-view .icon-container{background:var(--primary-300)}.leoai-container .product-card-container .loading-view .spinner{width:28px;height:28px;border:3px solid var(--primary-400);border-top-color:var(--primary-600);border-radius:50%}.leoai-container .product-card-container .error-view .icon-container{background:#ef44441a}.leoai-container .product-card-container .error-view .error-icon{width:32px;height:32px;color:var(--error)}.leoai-container .product-card-container .success-view .product-image{width:100%;height:150px;border-radius:8px;overflow:hidden}.leoai-container .product-card-container .success-view .product-image img{width:100%;height:100%;-o-object-fit:cover;object-fit:cover;transition:transform .3s ease}.leoai-container .product-card-container .success-view .product-name{font-size:16px;font-weight:600;color:var(--gray-800);line-height:1;word-wrap:break-word}.leoai-container .product-card-container .success-view .product-name:hover{text-decoration:underline}.leoai-container .product-card-container .success-view .product-prices{display:flex;flex-direction:column;gap:4px}.leoai-container .product-card-container .success-view .product-prices .discount{color:var(--gray-400);text-decoration:line-through;font-size:14px;margin-bottom:-4px}.leoai-container .product-card-container .success-view .product-prices .price{color:var(--primary-500);font-size:22px;font-weight:600;letter-spacing:-.025rem}.leoai-container .product-card-container .success-view .product-colors{display:flex;gap:4px;align-items:center;margin-top:8px}.leoai-container .product-card-container .success-view .product-colors .color-dot{width:16px;height:16px;border-radius:50%;border:1px solid var(--gray-100);transition:transform .2s ease}.leoai-container .product-card-container .success-view .product-colors .color-dot:hover{transform:scale(1.1)}.contact-support-card-container{background:var(--bg);border-radius:16px;padding:20px;width:100%;width:260px;position:relative;transition:all .3s cubic-bezier(.4,0,.2,1);box-shadow:var(--3d-shadow),var(--drop-shadow),0 0 0 1px var(--gray-200)}.contact-support-card-container:hover{box-shadow:var(--3d-shadow-hover),var(--drop-shadow-hover),0 0 0 1px var(--gray-300);transform:translateY(-1px)}.contact-support-card-container .contact-support-card-content{display:flex;flex-direction:column;justify-content:center;align-items:center;min-height:60px;width:100%}.contact-support-card-container .status-view{display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center;width:100%;gap:16px}.contact-support-card-container .status-view p{font-size:16px;font-weight:500;color:var(--gray-700);margin:0}.contact-support-card-container .status-view .icon-container{width:48px;height:48px;display:flex;align-items:center;justify-content:center;border-radius:50%}.contact-support-card-container .loading-view .icon-container{background:var(--primary-300)}.contact-support-card-container .loading-view .spinner{width:28px;height:28px;border:3px solid var(--primary-400);border-top-color:var(--primary-600);border-radius:50%}.contact-support-card-container .success-view .icon-container{background:#22c55e1a}.contact-support-card-container .success-view .check-icon{width:32px;height:32px;color:#22c55e}.contact-support-card-container .error-view .icon-container{background:#ef44441a}.contact-support-card-container .error-view .error-icon{width:32px;height:32px;color:var(--error)}.leoai-container .leoai-popup-container{width:100vw;max-width:min(360px,100vw - 24px);display:none;flex-direction:column;position:relative;margin-bottom:12px}.leoai-container .leoai-popup-container.show{display:flex}.leoai-container .leoai-popup-container .leoai-popup-controls{display:none;gap:8px;position:absolute;left:0;right:0;color:#fff;z-index:10}.leoai-container .leoai-popup-container .leoai-popup-controls .leoai-popup-open,.leoai-container .leoai-popup-container .leoai-popup-controls .leoai-popup-close{display:flex;position:absolute;border:none;border-radius:30px;background-color:var(--gray-400);color:#fff}.leoai-container .leoai-popup-container .leoai-popup-controls .leoai-popup-open:hover,.leoai-container .leoai-popup-container .leoai-popup-controls .leoai-popup-close:hover{background-color:var(--gray-500);color:#fff}.leoai-container .leoai-popup-container .leoai-popup-controls .leoai-popup-open{top:0;right:50%;transform:translate(calc(50% + 20px)) translateY(-50%);padding:6px 12px;font-size:12px;font-weight:400;gap:4px}.leoai-container .leoai-popup-container .leoai-popup-controls .leoai-popup-close{top:0;right:4px;transform:translateY(-50%);border-radius:50%;padding:6px;cursor:pointer}.leoai-container .leoai-popup-container .leoai-popup-message-container{display:flex;align-items:end;gap:8px;justify-content:end}.leoai-container .leoai-popup-container .leoai-popup-message-icon{cursor:pointer;height:32px;width:32px;-o-object-fit:contain;object-fit:contain;box-shadow:var(--drop-shadow),var(--3d-shadow)}.leoai-container .leoai-popup-container .leoai-popup-message{width:100vw;max-width:calc(100vw - 75px);display:flex;flex-direction:column;height:-moz-fit-content;height:fit-content;padding:16px 20px;background-color:var(--bg);font-size:15px;color:var(--gray-800);border:1px solid var(--gray-200);border-radius:14px 14px 14px 6px;font-weight:400;cursor:pointer;position:relative;transition:all .2s;box-shadow:var(--3d-shadow),var(--drop-shadow);gap:2px}.leoai-container .leoai-popup-container .leoai-popup-message:hover{box-shadow:var(--drop-shadow-hover),var(--3d-shadow-hover);border:1px solid var(--gray-300)}.leoai-container .leoai-popup-container .leoai-popup-message .from{font-size:12px;margin:0;color:var(--gray-500)}.leoai-container .leoai-popup-container .leoai-popup-message p{font-size:16px;margin:0!important}.leoai-container .leoai-popup-container .leoai-popup-message .leoai-popup-close{position:absolute;top:6px;right:6px;padding:4px;cursor:pointer;background-color:transparent;border:none;color:#404040;display:none}.leoai-container .leoai-popup-container .leoai-popup-buttons-container{display:flex;flex-direction:column;gap:8px;align-items:flex-end;margin-top:20px;margin-bottom:8px}.leoai-container .leoai-popup-container .leoai-popup-buttons-container .leoai-quick-button.popup{width:auto;padding:8px 12px}@media (max-width: 768px){.leoai-container .leoai-popup-container .leoai-popup-message .leoai-popup-close{display:flex}}@media (min-width: 768px){.leoai-container .leoai-popup-container:hover .leoai-popup-controls{display:flex!important;opacity:1!important}}.leoai-container .leoai-home-view{padding-bottom:64px}.leoai-container .leoai-home-view .leoai-home-content{display:flex;flex-direction:column;align-items:start;justify-content:start;gap:40px;padding-inline:24px}.leoai-container .leoai-home-view .leoai-home-content .leoai-home-intro{margin-top:54px;padding-inline:8px}.leoai-container .leoai-home-view .leoai-home-content .leoai-home-intro p{font-weight:700!important;color:var(--gray-800)!important;font-size:36px!important;line-height:1.4!important;margin-bottom:0!important}.leoai-container .leoai-home-view .leoai-home-content .leoai-home-intro>*:first-child{color:var(--gray-600)!important}.leoai-container .leoai-home-view .leoai-home-content .leoai-home-buttons-container{display:flex;flex-direction:column;gap:16px;width:100%}.leoai-container .leoai-home-view .leoai-home-content .leoai-home-buttons-container .leoai-cta-button{display:flex;width:100%;justify-content:space-between;align-items:center;gap:16px;background:var(--gradient);border:none;border-radius:14px;font-size:18px;padding:16px 24px;box-shadow:var(--3d-shadow),var(--drop-shadow);color:var(--user-message-text)}.leoai-container .leoai-home-view .leoai-home-content .leoai-home-buttons-container .leoai-cta-button:hover{filter:brightness(1.1);transform:translateY(-2px);box-shadow:var(--drop-shadow-hover),var(--3d-shadow-hover)}.leoai-container .leoai-home-view .leoai-home-content .leoai-home-buttons-container .leoai-cta-button:focus{transform:translateY(0)}.leoai-container .leoai-home-view .leoai-home-content .leoai-home-buttons-container .leoai-home-secondary-button-container{display:flex;gap:8px;flex-wrap:wrap}.leoai-container .leoai-home-view .leoai-home-content .leoai-home-articles-container{display:flex;flex-direction:column;gap:24px;width:100%}.leoai-container .leoai-chat-view{padding-top:112px;padding-bottom:140px}.leoai-container .leoai-chat-view .leoai-view-header .leoai-chat-profile{display:flex;gap:8px;align-items:center}.leoai-container .leoai-chat-view .leoai-view-header .leoai-chat-profile .leoai-header-icon{width:36px;height:36px}.leoai-container .leoai-chat-view .leoai-view-header .leoai-chat-profile .leoai-profile-texts{display:flex;flex-direction:column}.leoai-container .leoai-chat-view .leoai-view-header .leoai-chat-profile .leoai-profile-texts .leoai-profile-name{font-size:16px;font-weight:700}.leoai-container .leoai-chat-view .leoai-view-header .leoai-chat-profile .leoai-profile-texts .leoai-role-description{font-size:12px;color:var(--gray-600)}.leoai-container .leoai-chat-view .leoai-messages-container{display:flex;flex-direction:column;gap:24px;width:100%;padding-inline:24px}.leoai-container .leoai-chat-buttons-container{display:flex;flex-direction:column;justify-content:end;align-items:end;gap:8px;padding-inline:36px;margin-top:64px}.leoai-container .leoai-chat-buttons-container .leoai-chat-button{display:flex;justify-content:center;align-items:center;gap:6px;padding:10px 12px;border:1px solid var(--gray-200);border-radius:14px;background-color:var(--bg);box-shadow:var(--3d-shadow),var(--drop-shadow);color:var(--gray-700);font-size:15px;flex-grow:1}.leoai-container .leoai-chat-buttons-container .leoai-chat-button:hover{transform:translateY(-2px);box-shadow:var(--drop-shadow-hover),var(--3d-shadow-hover);border-color:var(--gray-300)}.leoai-container .leoai-chat-form{background-color:var(--bg);border:1px solid var(--gray-300);border-radius:14px;display:flex;align-items:flex-start;width:auto;min-height:48px;gap:8px;box-shadow:var(--drop-shadow);position:relative}.leoai-container .leoai-chat-form:hover{border:1px solid var(--gray-400)}.leoai-container .leoai-chat-form:focus-within{border:1px solid var(--primary-500)}.leoai-container .leoai-chat-form .grow-wrap{display:grid;flex:1;align-items:stretch;max-height:260px;overflow:hidden}.leoai-container .leoai-chat-form .grow-wrap:after{content:attr(data-replicated-value) " ";white-space:pre-wrap;visibility:hidden;padding:12px 56px 12px 16px;font:inherit;line-height:22px;overflow-y:auto}.leoai-container .leoai-chat-form .grow-wrap:after,.leoai-container .leoai-chat-form .grow-wrap textarea{grid-area:1/1/2/2}.leoai-container .leoai-chat-form .leoai-chat-textarea{background-color:transparent;font-size:16px;color:var(--gray-950);border:none;height:auto;max-height:260px;min-height:48px;padding:12px 56px 12px 16px;display:block;width:100%;outline:none;resize:none;overflow-y:scroll;transition:all .15s;line-height:22px;scrollbar-width:thin;scrollbar-color:transparent transparent}.leoai-container .leoai-chat-form .leoai-chat-submit-button{background:var(--gradient);box-shadow:var(--3d-shadow);display:flex;justify-content:center;align-items:center;height:40px;width:40px;border:none;border-radius:10px;position:absolute;bottom:4px;right:4px;color:#fff;padding:0!important}.leoai-container .leoai-chat-form .leoai-chat-submit-button:hover{filter:brightness(1.1);transform:scale(1.05)}.leoai-container .leoai-chat-form .leoai-chat-submit-button:active{transform:scale(.9)}.leoai-container .leoai-article-view{padding-top:84px;padding-bottom:140px;padding-inline:24px}.leoai-container .leoai-article-view .leoai-article-header-title{font-size:18px;color:var(--gray-800)}.leoai-container .leoai-article-view .leoai-article-wrapper{color:var(--gray-800)}.leoai-container .leoai-article-view .leoai-article-wrapper .updated-at{display:flex;align-items:center;gap:4px;font-size:14px;color:var(--gray-600)}.leoai-container .leoai-article-view .leoai-article-wrapper .leoai-article-title{font-size:24px;font-weight:700;color:var(--gray-800);margin-top:16px}.leoai-container .leoai-article-view .leoai-article-wrapper .leoai-article-description{font-size:16px;color:var(--gray-600);margin-top:8px}.leoai-container .leoai-article-view .leoai-article-wrapper .leoai-article-thumbnail{width:100%;height:auto;border-radius:6px;-o-object-fit:cover;object-fit:cover;margin-top:16px}.leoai-container .leoai-article-view .leoai-article-wrapper .leoai-article{overflow-x:hidden}.leoai-container .leoai-article-view .leoai-article-wrapper .leoai-article a{text-decoration:underline!important;color:var(--primary-500)!important}.leoai-container .leoai-article-view .leoai-article-wrapper .leoai-article p{margin-top:10px;margin-right:2px;text-align:justify}.leoai-container .leoai-article-view .leoai-article-wrapper .leoai-article p:only-child{margin:0!important}.leoai-container .leoai-article-view .leoai-article-wrapper .leoai-article p:first-child{margin-top:0!important}.leoai-container .leoai-article-view .leoai-article-wrapper .leoai-article p:last-child{margin-bottom:0!important}.leoai-container .leoai-article-view .leoai-article-wrapper .leoai-article h1,.leoai-container .leoai-article-view .leoai-article-wrapper .leoai-article h2,.leoai-container .leoai-article-view .leoai-article-wrapper .leoai-article h3,.leoai-container .leoai-article-view .leoai-article-wrapper .leoai-article h4,.leoai-container .leoai-article-view .leoai-article-wrapper .leoai-article h5{margin-top:22px!important;margin-bottom:8px!important}.leoai-container .leoai-article-view .leoai-article-wrapper .leoai-article h1{font-size:26px!important}.leoai-container .leoai-article-view .leoai-article-wrapper .leoai-article h2{font-size:24px!important}.leoai-container .leoai-article-view .leoai-article-wrapper .leoai-article h3{font-size:22px!important}.leoai-container .leoai-article-view .leoai-article-wrapper .leoai-article h4{font-size:20px!important}.leoai-container .leoai-article-view .leoai-article-wrapper .leoai-article h5{font-size:18px!important}.leoai-container .leoai-article-view .leoai-article-wrapper .leoai-article img{max-width:100%;border-radius:6px;width:100%;border:1px solid var(--gray-300)}.leoai-container .leoai-article-view .leoai-article-wrapper .leoai-article blockquote{border-left:3px solid var(--primary-500);padding-left:14px;margin:16px 0;font-style:italic;border-radius:3px}.leoai-container .leoai-article-view .leoai-article-wrapper .leoai-article table{display:block;width:100%;overflow-x:auto;-webkit-overflow-scrolling:touch;background-color:var(--bg);max-width:100%;border-collapse:separate;border-spacing:0;margin-top:8px;border:1px solid var(--gray-300);box-shadow:var(--drop-shadow);border-style:hidden}.leoai-container .leoai-article-view .leoai-article-wrapper .leoai-article table th,.leoai-container .leoai-article-view .leoai-article-wrapper .leoai-article table td{border:1px solid var(--gray-300);padding:8px;text-align:left;min-width:100px}.leoai-container .leoai-article-view .leoai-article-wrapper .leoai-article table th{background-color:var(--gray-100);font-weight:400}.leoai-container .leoai-article-view .leoai-article-wrapper .leoai-article table thead tr th:first-child{border-top-left-radius:8px}.leoai-container .leoai-article-view .leoai-article-wrapper .leoai-article table thead tr th:last-child{border-top-right-radius:8px}.leoai-container .leoai-article-view .leoai-article-wrapper .leoai-article table tbody tr:last-child td:first-child{border-bottom-left-radius:8px}.leoai-container .leoai-article-view .leoai-article-wrapper .leoai-article table tbody tr:last-child td:last-child{border-bottom-right-radius:8px}.leoai-container .leoai-article-view .leoai-article-wrapper.user .leoai-message-bubble a{color:var(--user-message-text)!important}.leoai-container .leoai-article-view .leoai-article-footer-button{display:flex;width:100%;justify-content:space-between;align-items:center;gap:16px;background:var(--bg);border:none;border-radius:14px;font-size:18px;padding:16px 24px;box-shadow:var(--3d-shadow),var(--drop-shadow);color:var(--gray-700);border:1px solid var(--gray-200)}.leoai-container .leoai-article-view .leoai-article-footer-button:hover{transform:translateY(-2px);box-shadow:var(--drop-shadow-hover),var(--3d-shadow-hover);border:1px solid var(--gray-300)}.leoai-container .leoai-article-view .leoai-article-footer-button:focus{transform:translateY(0)}.leoai-container .leoai-view-container{width:100%;height:100%;overflow-y:auto;overflow-x:hidden}')),document.head.appendChild(t)}}catch(e){console.error("vite-plugin-css-injected-by-js",e)}})();(function(){let t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(let r of document.querySelectorAll('link[rel="modulepreload"]'))n(r);new MutationObserver(r=>{for(let i of r)if(i.type==="childList")for(let o of i.addedNodes)o.tagName==="LINK"&&o.rel==="modulepreload"&&n(o)}).observe(document,{childList:!0,subtree:!0});function e(r){let i={};return r.integrity&&(i.integrity=r.integrity),r.referrerPolicy&&(i.referrerPolicy=r.referrerPolicy),r.crossOrigin==="use-credentials"?i.credentials="include":r.crossOrigin==="anonymous"?i.credentials="omit":i.credentials="same-origin",i}function n(r){if(r.ep)return;r.ep=!0;let i=e(r);fetch(r.href,i)}})();var Jm=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function du(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var K1={exports:{}},hu={},X1={exports:{}},et={};var $a=Symbol.for("react.element"),KE=Symbol.for("react.portal"),XE=Symbol.for("react.fragment"),GE=Symbol.for("react.strict_mode"),QE=Symbol.for("react.profiler"),JE=Symbol.for("react.provider"),ZE=Symbol.for("react.context"),tC=Symbol.for("react.forward_ref"),eC=Symbol.for("react.suspense"),nC=Symbol.for("react.memo"),rC=Symbol.for("react.lazy"),Zm=Symbol.iterator;function iC(t){return t===null||typeof t!="object"?null:(t=Zm&&t[Zm]||t["@@iterator"],typeof t=="function"?t:null)}var G1={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},Q1=Object.assign,J1={};function ro(t,e,n){this.props=t,this.context=e,this.refs=J1,this.updater=n||G1}ro.prototype.isReactComponent={};ro.prototype.setState=function(t,e){if(typeof t!="object"&&typeof t!="function"&&t!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,t,e,"setState")};ro.prototype.forceUpdate=function(t){this.updater.enqueueForceUpdate(this,t,"forceUpdate")};function Z1(){}Z1.prototype=ro.prototype;function Cp(t,e,n){this.props=t,this.context=e,this.refs=J1,this.updater=n||G1}var Pp=Cp.prototype=new Z1;Pp.constructor=Cp;Q1(Pp,ro.prototype);Pp.isPureReactComponent=!0;var tg=Array.isArray,tb=Object.prototype.hasOwnProperty,Ap={current:null},eb={key:!0,ref:!0,__self:!0,__source:!0};function nb(t,e,n){var r,i={},o=null,a=null;if(e!=null)for(r in e.ref!==void 0&&(a=e.ref),e.key!==void 0&&(o=""+e.key),e)tb.call(e,r)&&!eb.hasOwnProperty(r)&&(i[r]=e[r]);var s=arguments.length-2;if(s===1)i.children=n;else if(1<s){for(var l=Array(s),u=0;u<s;u++)l[u]=arguments[u+2];i.children=l}if(t&&t.defaultProps)for(r in s=t.defaultProps,s)i[r]===void 0&&(i[r]=s[r]);return{$$typeof:$a,type:t,key:o,ref:a,props:i,_owner:Ap.current}}function oC(t,e){return{$$typeof:$a,type:t.type,key:e,ref:t.ref,props:t.props,_owner:t._owner}}function Mp(t){return typeof t=="object"&&t!==null&&t.$$typeof===$a}function aC(t){var e={"=":"=0",":":"=2"};return"$"+t.replace(/[=:]/g,function(n){return e[n]})}var eg=/\/+/g;function Ju(t,e){return typeof t=="object"&&t!==null&&t.key!=null?aC(""+t.key):e.toString(36)}function zs(t,e,n,r,i){var o=typeof t;(o==="undefined"||o==="boolean")&&(t=null);var a=!1;if(t===null)a=!0;else switch(o){case"string":case"number":a=!0;break;case"object":switch(t.$$typeof){case $a:case KE:a=!0}}if(a)return a=t,i=i(a),t=r===""?"."+Ju(a,0):r,tg(i)?(n="",t!=null&&(n=t.replace(eg,"$&/")+"/"),zs(i,e,n,"",function(u){return u})):i!=null&&(Mp(i)&&(i=oC(i,n+(!i.key||a&&a.key===i.key?"":(""+i.key).replace(eg,"$&/")+"/")+t)),e.push(i)),1;if(a=0,r=r===""?".":r+":",tg(t))for(var s=0;s<t.length;s++){o=t[s];var l=r+Ju(o,s);a+=zs(o,e,n,l,i)}else if(l=iC(t),typeof l=="function")for(t=l.call(t),s=0;!(o=t.next()).done;)o=o.value,l=r+Ju(o,s++),a+=zs(o,e,n,l,i);else if(o==="object")throw e=String(t),Error("Objects are not valid as a React child (found: "+(e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e)+"). If you meant to render a collection of children, use an array instead.");return a}function as(t,e,n){if(t==null)return t;var r=[],i=0;return zs(t,r,"","",function(o){return e.call(n,o,i++)}),r}function sC(t){if(t._status===-1){var e=t._result;e=e(),e.then(function(n){(t._status===0||t._status===-1)&&(t._status=1,t._result=n)},function(n){(t._status===0||t._status===-1)&&(t._status=2,t._result=n)}),t._status===-1&&(t._status=0,t._result=e)}if(t._status===1)return t._result.default;throw t._result}var ce={current:null},Bs={transition:null},lC={ReactCurrentDispatcher:ce,ReactCurrentBatchConfig:Bs,ReactCurrentOwner:Ap};function rb(){throw Error("act(...) is not supported in production builds of React.")}et.Children={map:as,forEach:function(t,e,n){as(t,function(){e.apply(this,arguments)},n)},count:function(t){var e=0;return as(t,function(){e++}),e},toArray:function(t){return as(t,function(e){return e})||[]},only:function(t){if(!Mp(t))throw Error("React.Children.only expected to receive a single React element child.");return t}};et.Component=ro;et.Fragment=XE;et.Profiler=QE;et.PureComponent=Cp;et.StrictMode=GE;et.Suspense=eC;et.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=lC;et.act=rb;et.cloneElement=function(t,e,n){if(t==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+t+".");var r=Q1({},t.props),i=t.key,o=t.ref,a=t._owner;if(e!=null){if(e.ref!==void 0&&(o=e.ref,a=Ap.current),e.key!==void 0&&(i=""+e.key),t.type&&t.type.defaultProps)var s=t.type.defaultProps;for(l in e)tb.call(e,l)&&!eb.hasOwnProperty(l)&&(r[l]=e[l]===void 0&&s!==void 0?s[l]:e[l])}var l=arguments.length-2;if(l===1)r.children=n;else if(1<l){s=Array(l);for(var u=0;u<l;u++)s[u]=arguments[u+2];r.children=s}return{$$typeof:$a,type:t.type,key:i,ref:o,props:r,_owner:a}};et.createContext=function(t){return t={$$typeof:ZE,_currentValue:t,_currentValue2:t,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},t.Provider={$$typeof:JE,_context:t},t.Consumer=t};et.createElement=nb;et.createFactory=function(t){var e=nb.bind(null,t);return e.type=t,e};et.createRef=function(){return{current:null}};et.forwardRef=function(t){return{$$typeof:tC,render:t}};et.isValidElement=Mp;et.lazy=function(t){return{$$typeof:rC,_payload:{_status:-1,_result:t},_init:sC}};et.memo=function(t,e){return{$$typeof:nC,type:t,compare:e===void 0?null:e}};et.startTransition=function(t){var e=Bs.transition;Bs.transition={};try{t()}finally{Bs.transition=e}};et.unstable_act=rb;et.useCallback=function(t,e){return ce.current.useCallback(t,e)};et.useContext=function(t){return ce.current.useContext(t)};et.useDebugValue=function(){};et.useDeferredValue=function(t){return ce.current.useDeferredValue(t)};et.useEffect=function(t,e){return ce.current.useEffect(t,e)};et.useId=function(){return ce.current.useId()};et.useImperativeHandle=function(t,e,n){return ce.current.useImperativeHandle(t,e,n)};et.useInsertionEffect=function(t,e){return ce.current.useInsertionEffect(t,e)};et.useLayoutEffect=function(t,e){return ce.current.useLayoutEffect(t,e)};et.useMemo=function(t,e){return ce.current.useMemo(t,e)};et.useReducer=function(t,e,n){return ce.current.useReducer(t,e,n)};et.useRef=function(t){return ce.current.useRef(t)};et.useState=function(t){return ce.current.useState(t)};et.useSyncExternalStore=function(t,e,n){return ce.current.useSyncExternalStore(t,e,n)};et.useTransition=function(){return ce.current.useTransition()};et.version="18.3.1";X1.exports=et;var S=X1.exports,Dp=du(S);var uC=S,cC=Symbol.for("react.element"),dC=Symbol.for("react.fragment"),hC=Object.prototype.hasOwnProperty,pC=uC.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,fC={key:!0,ref:!0,__self:!0,__source:!0};function ib(t,e,n){var r,i={},o=null,a=null;n!==void 0&&(o=""+n),e.key!==void 0&&(o=""+e.key),e.ref!==void 0&&(a=e.ref);for(r in e)hC.call(e,r)&&!fC.hasOwnProperty(r)&&(i[r]=e[r]);if(t&&t.defaultProps)for(r in e=t.defaultProps,e)i[r]===void 0&&(i[r]=e[r]);return{$$typeof:cC,type:t,key:o,ref:a,props:i,_owner:pC.current}}hu.Fragment=dC;hu.jsx=ib;hu.jsxs=ib;K1.exports=hu;var A=K1.exports,md={},ob={exports:{}},Re={},ab={exports:{}},sb={};(function(t){function e(I,z){var x=I.length;I.push(z);t:for(;0<x;){var X=x-1>>>1,Z=I[X];if(0<i(Z,z))I[X]=z,I[x]=Z,x=X;else break t}}function n(I){return I.length===0?null:I[0]}function r(I){if(I.length===0)return null;var z=I[0],x=I.pop();if(x!==z){I[0]=x;t:for(var X=0,Z=I.length,T=Z>>>1;X<T;){var bt=2*(X+1)-1,Mt=I[bt],at=bt+1,ae=I[at];if(0>i(Mt,x))at<Z&&0>i(ae,Mt)?(I[X]=ae,I[at]=x,X=at):(I[X]=Mt,I[bt]=x,X=bt);else if(at<Z&&0>i(ae,x))I[X]=ae,I[at]=x,X=at;else break t}}return z}function i(I,z){var x=I.sortIndex-z.sortIndex;return x!==0?x:I.id-z.id}if(typeof performance=="object"&&typeof performance.now=="function"){var o=performance;t.unstable_now=function(){return o.now()}}else{var a=Date,s=a.now();t.unstable_now=function(){return a.now()-s}}var l=[],u=[],c=1,d=null,h=3,p=!1,m=!1,v=!1,b=typeof setTimeout=="function"?setTimeout:null,f=typeof clearTimeout=="function"?clearTimeout:null,g=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function y(I){for(var z=n(u);z!==null;){if(z.callback===null)r(u);else if(z.startTime<=I)r(u),z.sortIndex=z.expirationTime,e(l,z);else break;z=n(u)}}function w(I){if(v=!1,y(I),!m)if(n(l)!==null)m=!0,K(C);else{var z=n(u);z!==null&&Q(w,z.startTime-I)}}function C(I,z){m=!1,v&&(v=!1,f(P),P=-1),p=!0;var x=h;try{for(y(z),d=n(l);d!==null&&(!(d.expirationTime>z)||I&&!L());){var X=d.callback;if(typeof X=="function"){d.callback=null,h=d.priorityLevel;var Z=X(d.expirationTime<=z);z=t.unstable_now(),typeof Z=="function"?d.callback=Z:d===n(l)&&r(l),y(z)}else r(l);d=n(l)}if(d!==null)var T=!0;else{var bt=n(u);bt!==null&&Q(w,bt.startTime-z),T=!1}return T}finally{d=null,h=x,p=!1}}var k=!1,M=null,P=-1,R=5,E=-1;function L(){return!(t.unstable_now()-E<R)}function N(){if(M!==null){var I=t.unstable_now();E=I;var z=!0;try{z=M(!0,I)}finally{z?B():(k=!1,M=null)}}else k=!1}var B;if(typeof g=="function")B=function(){g(N)};else if(typeof MessageChannel<"u"){var U=new MessageChannel,F=U.port2;U.port1.onmessage=N,B=function(){F.postMessage(null)}}else B=function(){b(N,0)};function K(I){M=I,k||(k=!0,B())}function Q(I,z){P=b(function(){I(t.unstable_now())},z)}t.unstable_IdlePriority=5,t.unstable_ImmediatePriority=1,t.unstable_LowPriority=4,t.unstable_NormalPriority=3,t.unstable_Profiling=null,t.unstable_UserBlockingPriority=2,t.unstable_cancelCallback=function(I){I.callback=null},t.unstable_continueExecution=function(){m||p||(m=!0,K(C))},t.unstable_forceFrameRate=function(I){0>I||125<I?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):R=0<I?Math.floor(1e3/I):5},t.unstable_getCurrentPriorityLevel=function(){return h},t.unstable_getFirstCallbackNode=function(){return n(l)},t.unstable_next=function(I){switch(h){case 1:case 2:case 3:var z=3;break;default:z=h}var x=h;h=z;try{return I()}finally{h=x}},t.unstable_pauseExecution=function(){},t.unstable_requestPaint=function(){},t.unstable_runWithPriority=function(I,z){switch(I){case 1:case 2:case 3:case 4:case 5:break;default:I=3}var x=h;h=I;try{return z()}finally{h=x}},t.unstable_scheduleCallback=function(I,z,x){var X=t.unstable_now();switch(typeof x=="object"&&x!==null?(x=x.delay,x=typeof x=="number"&&0<x?X+x:X):x=X,I){case 1:var Z=-1;break;case 2:Z=250;break;case 5:Z=1073741823;break;case 4:Z=1e4;break;default:Z=5e3}return Z=x+Z,I={id:c++,callback:z,priorityLevel:I,startTime:x,expirationTime:Z,sortIndex:-1},x>X?(I.sortIndex=x,e(u,I),n(l)===null&&I===n(u)&&(v?(f(P),P=-1):v=!0,Q(w,x-X))):(I.sortIndex=Z,e(l,I),m||p||(m=!0,K(C))),I},t.unstable_shouldYield=L,t.unstable_wrapCallback=function(I){var z=h;return function(){var x=h;h=z;try{return I.apply(this,arguments)}finally{h=x}}}})(sb);ab.exports=sb;var mC=ab.exports;var gC=S,Ae=mC;function j(t){for(var e="https://reactjs.org/docs/error-decoder.html?invariant="+t,n=1;n<arguments.length;n++)e+="&args[]="+encodeURIComponent(arguments[n]);return"Minified React error #"+t+"; visit "+e+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var lb=new Set,ta={};function ti(t,e){Bi(t,e),Bi(t+"Capture",e)}function Bi(t,e){for(ta[t]=e,t=0;t<e.length;t++)lb.add(e[t])}var Vn=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),gd=Object.prototype.hasOwnProperty,vC=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,ng={},rg={};function yC(t){return gd.call(rg,t)?!0:gd.call(ng,t)?!1:vC.test(t)?rg[t]=!0:(ng[t]=!0,!1)}function bC(t,e,n,r){if(n!==null&&n.type===0)return!1;switch(typeof e){case"function":case"symbol":return!0;case"boolean":return r?!1:n!==null?!n.acceptsBooleans:(t=t.toLowerCase().slice(0,5),t!=="data-"&&t!=="aria-");default:return!1}}function xC(t,e,n,r){if(e===null||typeof e>"u"||bC(t,e,n,r))return!0;if(r)return!1;if(n!==null)switch(n.type){case 3:return!e;case 4:return e===!1;case 5:return isNaN(e);case 6:return isNaN(e)||1>e}return!1}function de(t,e,n,r,i,o,a){this.acceptsBooleans=e===2||e===3||e===4,this.attributeName=r,this.attributeNamespace=i,this.mustUseProperty=n,this.propertyName=t,this.type=e,this.sanitizeURL=o,this.removeEmptyString=a}var Yt={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(t){Yt[t]=new de(t,0,!1,t,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(t){var e=t[0];Yt[e]=new de(e,1,!1,t[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(t){Yt[t]=new de(t,2,!1,t.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(t){Yt[t]=new de(t,2,!1,t,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(t){Yt[t]=new de(t,3,!1,t.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(t){Yt[t]=new de(t,3,!0,t,null,!1,!1)});["capture","download"].forEach(function(t){Yt[t]=new de(t,4,!1,t,null,!1,!1)});["cols","rows","size","span"].forEach(function(t){Yt[t]=new de(t,6,!1,t,null,!1,!1)});["rowSpan","start"].forEach(function(t){Yt[t]=new de(t,5,!1,t.toLowerCase(),null,!1,!1)});var Rp=/[\-:]([a-z])/g;function Ip(t){return t[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(t){var e=t.replace(Rp,Ip);Yt[e]=new de(e,1,!1,t,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(t){var e=t.replace(Rp,Ip);Yt[e]=new de(e,1,!1,t,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(t){var e=t.replace(Rp,Ip);Yt[e]=new de(e,1,!1,t,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(t){Yt[t]=new de(t,1,!1,t.toLowerCase(),null,!1,!1)});Yt.xlinkHref=new de("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(t){Yt[t]=new de(t,1,!1,t.toLowerCase(),null,!0,!0)});function Lp(t,e,n,r){var i=Yt.hasOwnProperty(e)?Yt[e]:null;(i!==null?i.type!==0:r||!(2<e.length)||e[0]!=="o"&&e[0]!=="O"||e[1]!=="n"&&e[1]!=="N")&&(xC(e,n,i,r)&&(n=null),r||i===null?yC(e)&&(n===null?t.removeAttribute(e):t.setAttribute(e,""+n)):i.mustUseProperty?t[i.propertyName]=n===null?i.type===3?!1:"":n:(e=i.attributeName,r=i.attributeNamespace,n===null?t.removeAttribute(e):(i=i.type,n=i===3||i===4&&n===!0?"":""+n,r?t.setAttributeNS(r,e,n):t.setAttribute(e,n))))}var Hn=gC.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,ss=Symbol.for("react.element"),hi=Symbol.for("react.portal"),pi=Symbol.for("react.fragment"),jp=Symbol.for("react.strict_mode"),vd=Symbol.for("react.profiler"),ub=Symbol.for("react.provider"),cb=Symbol.for("react.context"),Op=Symbol.for("react.forward_ref"),yd=Symbol.for("react.suspense"),bd=Symbol.for("react.suspense_list"),_p=Symbol.for("react.memo"),Gn=Symbol.for("react.lazy"),db=Symbol.for("react.offscreen"),ig=Symbol.iterator;function mo(t){return t===null||typeof t!="object"?null:(t=ig&&t[ig]||t["@@iterator"],typeof t=="function"?t:null)}var At=Object.assign,Zu;function Mo(t){if(Zu===void 0)try{throw Error()}catch(n){var e=n.stack.trim().match(/\n( *(at )?)/);Zu=e&&e[1]||""}return`
`+Zu+t}var tc=!1;function ec(t,e){if(!t||tc)return"";tc=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(e)if(e=function(){throw Error()},Object.defineProperty(e.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(e,[])}catch(u){var r=u}Reflect.construct(t,[],e)}else{try{e.call()}catch(u){r=u}t.call(e.prototype)}else{try{throw Error()}catch(u){r=u}t()}}catch(u){if(u&&r&&typeof u.stack=="string"){for(var i=u.stack.split(`
`),o=r.stack.split(`
`),a=i.length-1,s=o.length-1;1<=a&&0<=s&&i[a]!==o[s];)s--;for(;1<=a&&0<=s;a--,s--)if(i[a]!==o[s]){if(a!==1||s!==1)do if(a--,s--,0>s||i[a]!==o[s]){var l=`
`+i[a].replace(" at new "," at ");return t.displayName&&l.includes("<anonymous>")&&(l=l.replace("<anonymous>",t.displayName)),l}while(1<=a&&0<=s);break}}}finally{tc=!1,Error.prepareStackTrace=n}return(t=t?t.displayName||t.name:"")?Mo(t):""}function wC(t){switch(t.tag){case 5:return Mo(t.type);case 16:return Mo("Lazy");case 13:return Mo("Suspense");case 19:return Mo("SuspenseList");case 0:case 2:case 15:return t=ec(t.type,!1),t;case 11:return t=ec(t.type.render,!1),t;case 1:return t=ec(t.type,!0),t;default:return""}}function xd(t){if(t==null)return null;if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t;switch(t){case pi:return"Fragment";case hi:return"Portal";case vd:return"Profiler";case jp:return"StrictMode";case yd:return"Suspense";case bd:return"SuspenseList"}if(typeof t=="object")switch(t.$$typeof){case cb:return(t.displayName||"Context")+".Consumer";case ub:return(t._context.displayName||"Context")+".Provider";case Op:var e=t.render;return t=t.displayName,t||(t=e.displayName||e.name||"",t=t!==""?"ForwardRef("+t+")":"ForwardRef"),t;case _p:return e=t.displayName||null,e!==null?e:xd(t.type)||"Memo";case Gn:e=t._payload,t=t._init;try{return xd(t(e))}catch{}}return null}function kC(t){var e=t.type;switch(t.tag){case 24:return"Cache";case 9:return(e.displayName||"Context")+".Consumer";case 10:return(e._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return t=e.render,t=t.displayName||t.name||"",e.displayName||(t!==""?"ForwardRef("+t+")":"ForwardRef");case 7:return"Fragment";case 5:return e;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return xd(e);case 8:return e===jp?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e}return null}function hr(t){switch(typeof t){case"boolean":case"number":case"string":case"undefined":return t;case"object":return t;default:return""}}function hb(t){var e=t.type;return(t=t.nodeName)&&t.toLowerCase()==="input"&&(e==="checkbox"||e==="radio")}function SC(t){var e=hb(t)?"checked":"value",n=Object.getOwnPropertyDescriptor(t.constructor.prototype,e),r=""+t[e];if(!t.hasOwnProperty(e)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var i=n.get,o=n.set;return Object.defineProperty(t,e,{configurable:!0,get:function(){return i.call(this)},set:function(a){r=""+a,o.call(this,a)}}),Object.defineProperty(t,e,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(a){r=""+a},stopTracking:function(){t._valueTracker=null,delete t[e]}}}}function ls(t){t._valueTracker||(t._valueTracker=SC(t))}function pb(t){if(!t)return!1;var e=t._valueTracker;if(!e)return!0;var n=e.getValue(),r="";return t&&(r=hb(t)?t.checked?"true":"false":t.value),t=r,t!==n?(e.setValue(t),!0):!1}function ul(t){if(t=t||(typeof document<"u"?document:void 0),typeof t>"u")return null;try{return t.activeElement||t.body}catch{return t.body}}function wd(t,e){var n=e.checked;return At({},e,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??t._wrapperState.initialChecked})}function og(t,e){var n=e.defaultValue==null?"":e.defaultValue,r=e.checked!=null?e.checked:e.defaultChecked;n=hr(e.value!=null?e.value:n),t._wrapperState={initialChecked:r,initialValue:n,controlled:e.type==="checkbox"||e.type==="radio"?e.checked!=null:e.value!=null}}function fb(t,e){e=e.checked,e!=null&&Lp(t,"checked",e,!1)}function kd(t,e){fb(t,e);var n=hr(e.value),r=e.type;if(n!=null)r==="number"?(n===0&&t.value===""||t.value!=n)&&(t.value=""+n):t.value!==""+n&&(t.value=""+n);else if(r==="submit"||r==="reset"){t.removeAttribute("value");return}e.hasOwnProperty("value")?Sd(t,e.type,n):e.hasOwnProperty("defaultValue")&&Sd(t,e.type,hr(e.defaultValue)),e.checked==null&&e.defaultChecked!=null&&(t.defaultChecked=!!e.defaultChecked)}function ag(t,e,n){if(e.hasOwnProperty("value")||e.hasOwnProperty("defaultValue")){var r=e.type;if(!(r!=="submit"&&r!=="reset"||e.value!==void 0&&e.value!==null))return;e=""+t._wrapperState.initialValue,n||e===t.value||(t.value=e),t.defaultValue=e}n=t.name,n!==""&&(t.name=""),t.defaultChecked=!!t._wrapperState.initialChecked,n!==""&&(t.name=n)}function Sd(t,e,n){(e!=="number"||ul(t.ownerDocument)!==t)&&(n==null?t.defaultValue=""+t._wrapperState.initialValue:t.defaultValue!==""+n&&(t.defaultValue=""+n))}var Do=Array.isArray;function ji(t,e,n,r){if(t=t.options,e){e={};for(var i=0;i<n.length;i++)e["$"+n[i]]=!0;for(n=0;n<t.length;n++)i=e.hasOwnProperty("$"+t[n].value),t[n].selected!==i&&(t[n].selected=i),i&&r&&(t[n].defaultSelected=!0)}else{for(n=""+hr(n),e=null,i=0;i<t.length;i++){if(t[i].value===n){t[i].selected=!0,r&&(t[i].defaultSelected=!0);return}e!==null||t[i].disabled||(e=t[i])}e!==null&&(e.selected=!0)}}function Td(t,e){if(e.dangerouslySetInnerHTML!=null)throw Error(j(91));return At({},e,{value:void 0,defaultValue:void 0,children:""+t._wrapperState.initialValue})}function sg(t,e){var n=e.value;if(n==null){if(n=e.children,e=e.defaultValue,n!=null){if(e!=null)throw Error(j(92));if(Do(n)){if(1<n.length)throw Error(j(93));n=n[0]}e=n}e==null&&(e=""),n=e}t._wrapperState={initialValue:hr(n)}}function mb(t,e){var n=hr(e.value),r=hr(e.defaultValue);n!=null&&(n=""+n,n!==t.value&&(t.value=n),e.defaultValue==null&&t.defaultValue!==n&&(t.defaultValue=n)),r!=null&&(t.defaultValue=""+r)}function lg(t){var e=t.textContent;e===t._wrapperState.initialValue&&e!==""&&e!==null&&(t.value=e)}function gb(t){switch(t){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function Ed(t,e){return t==null||t==="http://www.w3.org/1999/xhtml"?gb(e):t==="http://www.w3.org/2000/svg"&&e==="foreignObject"?"http://www.w3.org/1999/xhtml":t}var us,vb=function(t){return typeof MSApp<"u"&&MSApp.execUnsafeLocalFunction?function(e,n,r,i){MSApp.execUnsafeLocalFunction(function(){return t(e,n,r,i)})}:t}(function(t,e){if(t.namespaceURI!=="http://www.w3.org/2000/svg"||"innerHTML"in t)t.innerHTML=e;else{for(us=us||document.createElement("div"),us.innerHTML="<svg>"+e.valueOf().toString()+"</svg>",e=us.firstChild;t.firstChild;)t.removeChild(t.firstChild);for(;e.firstChild;)t.appendChild(e.firstChild)}});function ea(t,e){if(e){var n=t.firstChild;if(n&&n===t.lastChild&&n.nodeType===3){n.nodeValue=e;return}}t.textContent=e}var No={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},TC=["Webkit","ms","Moz","O"];Object.keys(No).forEach(function(t){TC.forEach(function(e){e=e+t.charAt(0).toUpperCase()+t.substring(1),No[e]=No[t]})});function yb(t,e,n){return e==null||typeof e=="boolean"||e===""?"":n||typeof e!="number"||e===0||No.hasOwnProperty(t)&&No[t]?(""+e).trim():e+"px"}function bb(t,e){t=t.style;for(var n in e)if(e.hasOwnProperty(n)){var r=n.indexOf("--")===0,i=yb(n,e[n],r);n==="float"&&(n="cssFloat"),r?t.setProperty(n,i):t[n]=i}}var EC=At({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function Cd(t,e){if(e){if(EC[t]&&(e.children!=null||e.dangerouslySetInnerHTML!=null))throw Error(j(137,t));if(e.dangerouslySetInnerHTML!=null){if(e.children!=null)throw Error(j(60));if(typeof e.dangerouslySetInnerHTML!="object"||!("__html"in e.dangerouslySetInnerHTML))throw Error(j(61))}if(e.style!=null&&typeof e.style!="object")throw Error(j(62))}}function Pd(t,e){if(t.indexOf("-")===-1)return typeof e.is=="string";switch(t){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var Ad=null;function Np(t){return t=t.target||t.srcElement||window,t.correspondingUseElement&&(t=t.correspondingUseElement),t.nodeType===3?t.parentNode:t}var Md=null,Oi=null,_i=null;function ug(t){if(t=qa(t)){if(typeof Md!="function")throw Error(j(280));var e=t.stateNode;e&&(e=vu(e),Md(t.stateNode,t.type,e))}}function xb(t){Oi?_i?_i.push(t):_i=[t]:Oi=t}function wb(){if(Oi){var t=Oi,e=_i;if(_i=Oi=null,ug(t),e)for(t=0;t<e.length;t++)ug(e[t])}}function kb(t,e){return t(e)}function Sb(){}var nc=!1;function Tb(t,e,n){if(nc)return t(e,n);nc=!0;try{return kb(t,e,n)}finally{nc=!1,(Oi!==null||_i!==null)&&(Sb(),wb())}}function na(t,e){var n=t.stateNode;if(n===null)return null;var r=vu(n);if(r===null)return null;n=r[e];t:switch(e){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(r=!r.disabled)||(t=t.type,r=!(t==="button"||t==="input"||t==="select"||t==="textarea")),t=!r;break t;default:t=!1}if(t)return null;if(n&&typeof n!="function")throw Error(j(231,e,typeof n));return n}var Dd=!1;if(Vn)try{li={},Object.defineProperty(li,"passive",{get:function(){Dd=!0}}),window.addEventListener("test",li,li),window.removeEventListener("test",li,li)}catch{Dd=!1}var li;function CC(t,e,n,r,i,o,a,s,l){var u=Array.prototype.slice.call(arguments,3);try{e.apply(n,u)}catch(c){this.onError(c)}}var Fo=!1,cl=null,dl=!1,Rd=null,PC={onError:function(t){Fo=!0,cl=t}};function AC(t,e,n,r,i,o,a,s,l){Fo=!1,cl=null,CC.apply(PC,arguments)}function MC(t,e,n,r,i,o,a,s,l){if(AC.apply(this,arguments),Fo){if(Fo){var u=cl;Fo=!1,cl=null}else throw Error(j(198));dl||(dl=!0,Rd=u)}}function ei(t){var e=t,n=t;if(t.alternate)for(;e.return;)e=e.return;else{t=e;do e=t,e.flags&4098&&(n=e.return),t=e.return;while(t)}return e.tag===3?n:null}function Eb(t){if(t.tag===13){var e=t.memoizedState;if(e===null&&(t=t.alternate,t!==null&&(e=t.memoizedState)),e!==null)return e.dehydrated}return null}function cg(t){if(ei(t)!==t)throw Error(j(188))}function DC(t){var e=t.alternate;if(!e){if(e=ei(t),e===null)throw Error(j(188));return e!==t?null:t}for(var n=t,r=e;;){var i=n.return;if(i===null)break;var o=i.alternate;if(o===null){if(r=i.return,r!==null){n=r;continue}break}if(i.child===o.child){for(o=i.child;o;){if(o===n)return cg(i),t;if(o===r)return cg(i),e;o=o.sibling}throw Error(j(188))}if(n.return!==r.return)n=i,r=o;else{for(var a=!1,s=i.child;s;){if(s===n){a=!0,n=i,r=o;break}if(s===r){a=!0,r=i,n=o;break}s=s.sibling}if(!a){for(s=o.child;s;){if(s===n){a=!0,n=o,r=i;break}if(s===r){a=!0,r=o,n=i;break}s=s.sibling}if(!a)throw Error(j(189))}}if(n.alternate!==r)throw Error(j(190))}if(n.tag!==3)throw Error(j(188));return n.stateNode.current===n?t:e}function Cb(t){return t=DC(t),t!==null?Pb(t):null}function Pb(t){if(t.tag===5||t.tag===6)return t;for(t=t.child;t!==null;){var e=Pb(t);if(e!==null)return e;t=t.sibling}return null}var Ab=Ae.unstable_scheduleCallback,dg=Ae.unstable_cancelCallback,RC=Ae.unstable_shouldYield,IC=Ae.unstable_requestPaint,Lt=Ae.unstable_now,LC=Ae.unstable_getCurrentPriorityLevel,Fp=Ae.unstable_ImmediatePriority,Mb=Ae.unstable_UserBlockingPriority,hl=Ae.unstable_NormalPriority,jC=Ae.unstable_LowPriority,Db=Ae.unstable_IdlePriority,pu=null,dn=null;function OC(t){if(dn&&typeof dn.onCommitFiberRoot=="function")try{dn.onCommitFiberRoot(pu,t,void 0,(t.current.flags&128)===128)}catch{}}var Ze=Math.clz32?Math.clz32:FC,_C=Math.log,NC=Math.LN2;function FC(t){return t>>>=0,t===0?32:31-(_C(t)/NC|0)|0}var cs=64,ds=4194304;function Ro(t){switch(t&-t){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return t&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return t}}function pl(t,e){var n=t.pendingLanes;if(n===0)return 0;var r=0,i=t.suspendedLanes,o=t.pingedLanes,a=n&268435455;if(a!==0){var s=a&~i;s!==0?r=Ro(s):(o&=a,o!==0&&(r=Ro(o)))}else a=n&~i,a!==0?r=Ro(a):o!==0&&(r=Ro(o));if(r===0)return 0;if(e!==0&&e!==r&&!(e&i)&&(i=r&-r,o=e&-e,i>=o||i===16&&(o&4194240)!==0))return e;if(r&4&&(r|=n&16),e=t.entangledLanes,e!==0)for(t=t.entanglements,e&=r;0<e;)n=31-Ze(e),i=1<<n,r|=t[n],e&=~i;return r}function VC(t,e){switch(t){case 1:case 2:case 4:return e+250;case 8:case 16:case 32:case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return e+5e3;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return-1;case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function zC(t,e){for(var n=t.suspendedLanes,r=t.pingedLanes,i=t.expirationTimes,o=t.pendingLanes;0<o;){var a=31-Ze(o),s=1<<a,l=i[a];l===-1?(!(s&n)||s&r)&&(i[a]=VC(s,e)):l<=e&&(t.expiredLanes|=s),o&=~s}}function Id(t){return t=t.pendingLanes&-1073741825,t!==0?t:t&1073741824?1073741824:0}function Rb(){var t=cs;return cs<<=1,!(cs&4194240)&&(cs=64),t}function rc(t){for(var e=[],n=0;31>n;n++)e.push(t);return e}function Ha(t,e,n){t.pendingLanes|=e,e!==536870912&&(t.suspendedLanes=0,t.pingedLanes=0),t=t.eventTimes,e=31-Ze(e),t[e]=n}function BC(t,e){var n=t.pendingLanes&~e;t.pendingLanes=e,t.suspendedLanes=0,t.pingedLanes=0,t.expiredLanes&=e,t.mutableReadLanes&=e,t.entangledLanes&=e,e=t.entanglements;var r=t.eventTimes;for(t=t.expirationTimes;0<n;){var i=31-Ze(n),o=1<<i;e[i]=0,r[i]=-1,t[i]=-1,n&=~o}}function Vp(t,e){var n=t.entangledLanes|=e;for(t=t.entanglements;n;){var r=31-Ze(n),i=1<<r;i&e|t[r]&e&&(t[r]|=e),n&=~i}}var ut=0;function Ib(t){return t&=-t,1<t?4<t?t&268435455?16:536870912:4:1}var Lb,zp,jb,Ob,_b,Ld=!1,hs=[],ir=null,or=null,ar=null,ra=new Map,ia=new Map,Jn=[],UC="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset submit".split(" ");function hg(t,e){switch(t){case"focusin":case"focusout":ir=null;break;case"dragenter":case"dragleave":or=null;break;case"mouseover":case"mouseout":ar=null;break;case"pointerover":case"pointerout":ra.delete(e.pointerId);break;case"gotpointercapture":case"lostpointercapture":ia.delete(e.pointerId)}}function go(t,e,n,r,i,o){return t===null||t.nativeEvent!==o?(t={blockedOn:e,domEventName:n,eventSystemFlags:r,nativeEvent:o,targetContainers:[i]},e!==null&&(e=qa(e),e!==null&&zp(e)),t):(t.eventSystemFlags|=r,e=t.targetContainers,i!==null&&e.indexOf(i)===-1&&e.push(i),t)}function $C(t,e,n,r,i){switch(e){case"focusin":return ir=go(ir,t,e,n,r,i),!0;case"dragenter":return or=go(or,t,e,n,r,i),!0;case"mouseover":return ar=go(ar,t,e,n,r,i),!0;case"pointerover":var o=i.pointerId;return ra.set(o,go(ra.get(o)||null,t,e,n,r,i)),!0;case"gotpointercapture":return o=i.pointerId,ia.set(o,go(ia.get(o)||null,t,e,n,r,i)),!0}return!1}function Nb(t){var e=Nr(t.target);if(e!==null){var n=ei(e);if(n!==null){if(e=n.tag,e===13){if(e=Eb(n),e!==null){t.blockedOn=e,_b(t.priority,function(){jb(n)});return}}else if(e===3&&n.stateNode.current.memoizedState.isDehydrated){t.blockedOn=n.tag===3?n.stateNode.containerInfo:null;return}}}t.blockedOn=null}function Us(t){if(t.blockedOn!==null)return!1;for(var e=t.targetContainers;0<e.length;){var n=jd(t.domEventName,t.eventSystemFlags,e[0],t.nativeEvent);if(n===null){n=t.nativeEvent;var r=new n.constructor(n.type,n);Ad=r,n.target.dispatchEvent(r),Ad=null}else return e=qa(n),e!==null&&zp(e),t.blockedOn=n,!1;e.shift()}return!0}function pg(t,e,n){Us(t)&&n.delete(e)}function HC(){Ld=!1,ir!==null&&Us(ir)&&(ir=null),or!==null&&Us(or)&&(or=null),ar!==null&&Us(ar)&&(ar=null),ra.forEach(pg),ia.forEach(pg)}function vo(t,e){t.blockedOn===e&&(t.blockedOn=null,Ld||(Ld=!0,Ae.unstable_scheduleCallback(Ae.unstable_NormalPriority,HC)))}function oa(t){function e(i){return vo(i,t)}if(0<hs.length){vo(hs[0],t);for(var n=1;n<hs.length;n++){var r=hs[n];r.blockedOn===t&&(r.blockedOn=null)}}for(ir!==null&&vo(ir,t),or!==null&&vo(or,t),ar!==null&&vo(ar,t),ra.forEach(e),ia.forEach(e),n=0;n<Jn.length;n++)r=Jn[n],r.blockedOn===t&&(r.blockedOn=null);for(;0<Jn.length&&(n=Jn[0],n.blockedOn===null);)Nb(n),n.blockedOn===null&&Jn.shift()}var Ni=Hn.ReactCurrentBatchConfig,fl=!0;function WC(t,e,n,r){var i=ut,o=Ni.transition;Ni.transition=null;try{ut=1,Bp(t,e,n,r)}finally{ut=i,Ni.transition=o}}function qC(t,e,n,r){var i=ut,o=Ni.transition;Ni.transition=null;try{ut=4,Bp(t,e,n,r)}finally{ut=i,Ni.transition=o}}function Bp(t,e,n,r){if(fl){var i=jd(t,e,n,r);if(i===null)cc(t,e,r,ml,n),hg(t,r);else if($C(i,t,e,n,r))r.stopPropagation();else if(hg(t,r),e&4&&-1<UC.indexOf(t)){for(;i!==null;){var o=qa(i);if(o!==null&&Lb(o),o=jd(t,e,n,r),o===null&&cc(t,e,r,ml,n),o===i)break;i=o}i!==null&&r.stopPropagation()}else cc(t,e,r,null,n)}}var ml=null;function jd(t,e,n,r){if(ml=null,t=Np(r),t=Nr(t),t!==null)if(e=ei(t),e===null)t=null;else if(n=e.tag,n===13){if(t=Eb(e),t!==null)return t;t=null}else if(n===3){if(e.stateNode.current.memoizedState.isDehydrated)return e.tag===3?e.stateNode.containerInfo:null;t=null}else e!==t&&(t=null);return ml=t,null}function Fb(t){switch(t){case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 1;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"toggle":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 4;case"message":switch(LC()){case Fp:return 1;case Mb:return 4;case hl:case jC:return 16;case Db:return 536870912;default:return 16}default:return 16}}var er=null,Up=null,$s=null;function Vb(){if($s)return $s;var t,e=Up,n=e.length,r,i="value"in er?er.value:er.textContent,o=i.length;for(t=0;t<n&&e[t]===i[t];t++);var a=n-t;for(r=1;r<=a&&e[n-r]===i[o-r];r++);return $s=i.slice(t,1<r?1-r:void 0)}function Hs(t){var e=t.keyCode;return"charCode"in t?(t=t.charCode,t===0&&e===13&&(t=13)):t=e,t===10&&(t=13),32<=t||t===13?t:0}function ps(){return!0}function fg(){return!1}function Ie(t){function e(n,r,i,o,a){this._reactName=n,this._targetInst=i,this.type=r,this.nativeEvent=o,this.target=a,this.currentTarget=null;for(var s in t)t.hasOwnProperty(s)&&(n=t[s],this[s]=n?n(o):o[s]);return this.isDefaultPrevented=(o.defaultPrevented!=null?o.defaultPrevented:o.returnValue===!1)?ps:fg,this.isPropagationStopped=fg,this}return At(e.prototype,{preventDefault:function(){this.defaultPrevented=!0;var n=this.nativeEvent;n&&(n.preventDefault?n.preventDefault():typeof n.returnValue!="unknown"&&(n.returnValue=!1),this.isDefaultPrevented=ps)},stopPropagation:function(){var n=this.nativeEvent;n&&(n.stopPropagation?n.stopPropagation():typeof n.cancelBubble!="unknown"&&(n.cancelBubble=!0),this.isPropagationStopped=ps)},persist:function(){},isPersistent:ps}),e}var io={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(t){return t.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},$p=Ie(io),Wa=At({},io,{view:0,detail:0}),YC=Ie(Wa),ic,oc,yo,fu=At({},Wa,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Hp,button:0,buttons:0,relatedTarget:function(t){return t.relatedTarget===void 0?t.fromElement===t.srcElement?t.toElement:t.fromElement:t.relatedTarget},movementX:function(t){return"movementX"in t?t.movementX:(t!==yo&&(yo&&t.type==="mousemove"?(ic=t.screenX-yo.screenX,oc=t.screenY-yo.screenY):oc=ic=0,yo=t),ic)},movementY:function(t){return"movementY"in t?t.movementY:oc}}),mg=Ie(fu),KC=At({},fu,{dataTransfer:0}),XC=Ie(KC),GC=At({},Wa,{relatedTarget:0}),ac=Ie(GC),QC=At({},io,{animationName:0,elapsedTime:0,pseudoElement:0}),JC=Ie(QC),ZC=At({},io,{clipboardData:function(t){return"clipboardData"in t?t.clipboardData:window.clipboardData}}),tP=Ie(ZC),eP=At({},io,{data:0}),gg=Ie(eP),nP={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},rP={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},iP={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function oP(t){var e=this.nativeEvent;return e.getModifierState?e.getModifierState(t):(t=iP[t])?!!e[t]:!1}function Hp(){return oP}var aP=At({},Wa,{key:function(t){if(t.key){var e=nP[t.key]||t.key;if(e!=="Unidentified")return e}return t.type==="keypress"?(t=Hs(t),t===13?"Enter":String.fromCharCode(t)):t.type==="keydown"||t.type==="keyup"?rP[t.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Hp,charCode:function(t){return t.type==="keypress"?Hs(t):0},keyCode:function(t){return t.type==="keydown"||t.type==="keyup"?t.keyCode:0},which:function(t){return t.type==="keypress"?Hs(t):t.type==="keydown"||t.type==="keyup"?t.keyCode:0}}),sP=Ie(aP),lP=At({},fu,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),vg=Ie(lP),uP=At({},Wa,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Hp}),cP=Ie(uP),dP=At({},io,{propertyName:0,elapsedTime:0,pseudoElement:0}),hP=Ie(dP),pP=At({},fu,{deltaX:function(t){return"deltaX"in t?t.deltaX:"wheelDeltaX"in t?-t.wheelDeltaX:0},deltaY:function(t){return"deltaY"in t?t.deltaY:"wheelDeltaY"in t?-t.wheelDeltaY:"wheelDelta"in t?-t.wheelDelta:0},deltaZ:0,deltaMode:0}),fP=Ie(pP),mP=[9,13,27,32],Wp=Vn&&"CompositionEvent"in window,Vo=null;Vn&&"documentMode"in document&&(Vo=document.documentMode);var gP=Vn&&"TextEvent"in window&&!Vo,zb=Vn&&(!Wp||Vo&&8<Vo&&11>=Vo),yg=" ",bg=!1;function Bb(t,e){switch(t){case"keyup":return mP.indexOf(e.keyCode)!==-1;case"keydown":return e.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Ub(t){return t=t.detail,typeof t=="object"&&"data"in t?t.data:null}var fi=!1;function vP(t,e){switch(t){case"compositionend":return Ub(e);case"keypress":return e.which!==32?null:(bg=!0,yg);case"textInput":return t=e.data,t===yg&&bg?null:t;default:return null}}function yP(t,e){if(fi)return t==="compositionend"||!Wp&&Bb(t,e)?(t=Vb(),$s=Up=er=null,fi=!1,t):null;switch(t){case"paste":return null;case"keypress":if(!(e.ctrlKey||e.altKey||e.metaKey)||e.ctrlKey&&e.altKey){if(e.char&&1<e.char.length)return e.char;if(e.which)return String.fromCharCode(e.which)}return null;case"compositionend":return zb&&e.locale!=="ko"?null:e.data;default:return null}}var bP={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function xg(t){var e=t&&t.nodeName&&t.nodeName.toLowerCase();return e==="input"?!!bP[t.type]:e==="textarea"}function $b(t,e,n,r){xb(r),e=gl(e,"onChange"),0<e.length&&(n=new $p("onChange","change",null,n,r),t.push({event:n,listeners:e}))}var zo=null,aa=null;function xP(t){tx(t,0)}function mu(t){var e=vi(t);if(pb(e))return t}function wP(t,e){if(t==="change")return e}var Hb=!1;Vn&&(Vn?(ms="oninput"in document,ms||(sc=document.createElement("div"),sc.setAttribute("oninput","return;"),ms=typeof sc.oninput=="function"),fs=ms):fs=!1,Hb=fs&&(!document.documentMode||9<document.documentMode));var fs,ms,sc;function wg(){zo&&(zo.detachEvent("onpropertychange",Wb),aa=zo=null)}function Wb(t){if(t.propertyName==="value"&&mu(aa)){var e=[];$b(e,aa,t,Np(t)),Tb(xP,e)}}function kP(t,e,n){t==="focusin"?(wg(),zo=e,aa=n,zo.attachEvent("onpropertychange",Wb)):t==="focusout"&&wg()}function SP(t){if(t==="selectionchange"||t==="keyup"||t==="keydown")return mu(aa)}function TP(t,e){if(t==="click")return mu(e)}function EP(t,e){if(t==="input"||t==="change")return mu(e)}function CP(t,e){return t===e&&(t!==0||1/t===1/e)||t!==t&&e!==e}var nn=typeof Object.is=="function"?Object.is:CP;function sa(t,e){if(nn(t,e))return!0;if(typeof t!="object"||t===null||typeof e!="object"||e===null)return!1;var n=Object.keys(t),r=Object.keys(e);if(n.length!==r.length)return!1;for(r=0;r<n.length;r++){var i=n[r];if(!gd.call(e,i)||!nn(t[i],e[i]))return!1}return!0}function kg(t){for(;t&&t.firstChild;)t=t.firstChild;return t}function Sg(t,e){var n=kg(t);t=0;for(var r;n;){if(n.nodeType===3){if(r=t+n.textContent.length,t<=e&&r>=e)return{node:n,offset:e-t};t=r}t:{for(;n;){if(n.nextSibling){n=n.nextSibling;break t}n=n.parentNode}n=void 0}n=kg(n)}}function qb(t,e){return t&&e?t===e?!0:t&&t.nodeType===3?!1:e&&e.nodeType===3?qb(t,e.parentNode):"contains"in t?t.contains(e):t.compareDocumentPosition?!!(t.compareDocumentPosition(e)&16):!1:!1}function Yb(){for(var t=window,e=ul();e instanceof t.HTMLIFrameElement;){try{var n=typeof e.contentWindow.location.href=="string"}catch{n=!1}if(n)t=e.contentWindow;else break;e=ul(t.document)}return e}function qp(t){var e=t&&t.nodeName&&t.nodeName.toLowerCase();return e&&(e==="input"&&(t.type==="text"||t.type==="search"||t.type==="tel"||t.type==="url"||t.type==="password")||e==="textarea"||t.contentEditable==="true")}function PP(t){var e=Yb(),n=t.focusedElem,r=t.selectionRange;if(e!==n&&n&&n.ownerDocument&&qb(n.ownerDocument.documentElement,n)){if(r!==null&&qp(n)){if(e=r.start,t=r.end,t===void 0&&(t=e),"selectionStart"in n)n.selectionStart=e,n.selectionEnd=Math.min(t,n.value.length);else if(t=(e=n.ownerDocument||document)&&e.defaultView||window,t.getSelection){t=t.getSelection();var i=n.textContent.length,o=Math.min(r.start,i);r=r.end===void 0?o:Math.min(r.end,i),!t.extend&&o>r&&(i=r,r=o,o=i),i=Sg(n,o);var a=Sg(n,r);i&&a&&(t.rangeCount!==1||t.anchorNode!==i.node||t.anchorOffset!==i.offset||t.focusNode!==a.node||t.focusOffset!==a.offset)&&(e=e.createRange(),e.setStart(i.node,i.offset),t.removeAllRanges(),o>r?(t.addRange(e),t.extend(a.node,a.offset)):(e.setEnd(a.node,a.offset),t.addRange(e)))}}for(e=[],t=n;t=t.parentNode;)t.nodeType===1&&e.push({element:t,left:t.scrollLeft,top:t.scrollTop});for(typeof n.focus=="function"&&n.focus(),n=0;n<e.length;n++)t=e[n],t.element.scrollLeft=t.left,t.element.scrollTop=t.top}}var AP=Vn&&"documentMode"in document&&11>=document.documentMode,mi=null,Od=null,Bo=null,_d=!1;function Tg(t,e,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;_d||mi==null||mi!==ul(r)||(r=mi,"selectionStart"in r&&qp(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),Bo&&sa(Bo,r)||(Bo=r,r=gl(Od,"onSelect"),0<r.length&&(e=new $p("onSelect","select",null,e,n),t.push({event:e,listeners:r}),e.target=mi)))}function gs(t,e){var n={};return n[t.toLowerCase()]=e.toLowerCase(),n["Webkit"+t]="webkit"+e,n["Moz"+t]="moz"+e,n}var gi={animationend:gs("Animation","AnimationEnd"),animationiteration:gs("Animation","AnimationIteration"),animationstart:gs("Animation","AnimationStart"),transitionend:gs("Transition","TransitionEnd")},lc={},Kb={};Vn&&(Kb=document.createElement("div").style,"AnimationEvent"in window||(delete gi.animationend.animation,delete gi.animationiteration.animation,delete gi.animationstart.animation),"TransitionEvent"in window||delete gi.transitionend.transition);function gu(t){if(lc[t])return lc[t];if(!gi[t])return t;var e=gi[t],n;for(n in e)if(e.hasOwnProperty(n)&&n in Kb)return lc[t]=e[n];return t}var Xb=gu("animationend"),Gb=gu("animationiteration"),Qb=gu("animationstart"),Jb=gu("transitionend"),Zb=new Map,Eg="abort auxClick cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");function wr(t,e){Zb.set(t,e),ti(e,[t])}for(vs=0;vs<Eg.length;vs++)ys=Eg[vs],Cg=ys.toLowerCase(),Pg=ys[0].toUpperCase()+ys.slice(1),wr(Cg,"on"+Pg);var ys,Cg,Pg,vs;wr(Xb,"onAnimationEnd");wr(Gb,"onAnimationIteration");wr(Qb,"onAnimationStart");wr("dblclick","onDoubleClick");wr("focusin","onFocus");wr("focusout","onBlur");wr(Jb,"onTransitionEnd");Bi("onMouseEnter",["mouseout","mouseover"]);Bi("onMouseLeave",["mouseout","mouseover"]);Bi("onPointerEnter",["pointerout","pointerover"]);Bi("onPointerLeave",["pointerout","pointerover"]);ti("onChange","change click focusin focusout input keydown keyup selectionchange".split(" "));ti("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" "));ti("onBeforeInput",["compositionend","keypress","textInput","paste"]);ti("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" "));ti("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" "));ti("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Io="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),MP=new Set("cancel close invalid load scroll toggle".split(" ").concat(Io));function Ag(t,e,n){var r=t.type||"unknown-event";t.currentTarget=n,MC(r,e,void 0,t),t.currentTarget=null}function tx(t,e){e=(e&4)!==0;for(var n=0;n<t.length;n++){var r=t[n],i=r.event;r=r.listeners;t:{var o=void 0;if(e)for(var a=r.length-1;0<=a;a--){var s=r[a],l=s.instance,u=s.currentTarget;if(s=s.listener,l!==o&&i.isPropagationStopped())break t;Ag(i,s,u),o=l}else for(a=0;a<r.length;a++){if(s=r[a],l=s.instance,u=s.currentTarget,s=s.listener,l!==o&&i.isPropagationStopped())break t;Ag(i,s,u),o=l}}}if(dl)throw t=Rd,dl=!1,Rd=null,t}function vt(t,e){var n=e[Bd];n===void 0&&(n=e[Bd]=new Set);var r=t+"__bubble";n.has(r)||(ex(e,t,2,!1),n.add(r))}function uc(t,e,n){var r=0;e&&(r|=4),ex(n,t,r,e)}var bs="_reactListening"+Math.random().toString(36).slice(2);function la(t){if(!t[bs]){t[bs]=!0,lb.forEach(function(n){n!=="selectionchange"&&(MP.has(n)||uc(n,!1,t),uc(n,!0,t))});var e=t.nodeType===9?t:t.ownerDocument;e===null||e[bs]||(e[bs]=!0,uc("selectionchange",!1,e))}}function ex(t,e,n,r){switch(Fb(e)){case 1:var i=WC;break;case 4:i=qC;break;default:i=Bp}n=i.bind(null,e,n,t),i=void 0,!Dd||e!=="touchstart"&&e!=="touchmove"&&e!=="wheel"||(i=!0),r?i!==void 0?t.addEventListener(e,n,{capture:!0,passive:i}):t.addEventListener(e,n,!0):i!==void 0?t.addEventListener(e,n,{passive:i}):t.addEventListener(e,n,!1)}function cc(t,e,n,r,i){var o=r;if(!(e&1)&&!(e&2)&&r!==null)t:for(;;){if(r===null)return;var a=r.tag;if(a===3||a===4){var s=r.stateNode.containerInfo;if(s===i||s.nodeType===8&&s.parentNode===i)break;if(a===4)for(a=r.return;a!==null;){var l=a.tag;if((l===3||l===4)&&(l=a.stateNode.containerInfo,l===i||l.nodeType===8&&l.parentNode===i))return;a=a.return}for(;s!==null;){if(a=Nr(s),a===null)return;if(l=a.tag,l===5||l===6){r=o=a;continue t}s=s.parentNode}}r=r.return}Tb(function(){var u=o,c=Np(n),d=[];t:{var h=Zb.get(t);if(h!==void 0){var p=$p,m=t;switch(t){case"keypress":if(Hs(n)===0)break t;case"keydown":case"keyup":p=sP;break;case"focusin":m="focus",p=ac;break;case"focusout":m="blur",p=ac;break;case"beforeblur":case"afterblur":p=ac;break;case"click":if(n.button===2)break t;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":p=mg;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":p=XC;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":p=cP;break;case Xb:case Gb:case Qb:p=JC;break;case Jb:p=hP;break;case"scroll":p=YC;break;case"wheel":p=fP;break;case"copy":case"cut":case"paste":p=tP;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":p=vg}var v=(e&4)!==0,b=!v&&t==="scroll",f=v?h!==null?h+"Capture":null:h;v=[];for(var g=u,y;g!==null;){y=g;var w=y.stateNode;if(y.tag===5&&w!==null&&(y=w,f!==null&&(w=na(g,f),w!=null&&v.push(ua(g,w,y)))),b)break;g=g.return}0<v.length&&(h=new p(h,m,null,n,c),d.push({event:h,listeners:v}))}}if(!(e&7)){t:{if(h=t==="mouseover"||t==="pointerover",p=t==="mouseout"||t==="pointerout",h&&n!==Ad&&(m=n.relatedTarget||n.fromElement)&&(Nr(m)||m[zn]))break t;if((p||h)&&(h=c.window===c?c:(h=c.ownerDocument)?h.defaultView||h.parentWindow:window,p?(m=n.relatedTarget||n.toElement,p=u,m=m?Nr(m):null,m!==null&&(b=ei(m),m!==b||m.tag!==5&&m.tag!==6)&&(m=null)):(p=null,m=u),p!==m)){if(v=mg,w="onMouseLeave",f="onMouseEnter",g="mouse",(t==="pointerout"||t==="pointerover")&&(v=vg,w="onPointerLeave",f="onPointerEnter",g="pointer"),b=p==null?h:vi(p),y=m==null?h:vi(m),h=new v(w,g+"leave",p,n,c),h.target=b,h.relatedTarget=y,w=null,Nr(c)===u&&(v=new v(f,g+"enter",m,n,c),v.target=y,v.relatedTarget=b,w=v),b=w,p&&m)e:{for(v=p,f=m,g=0,y=v;y;y=ui(y))g++;for(y=0,w=f;w;w=ui(w))y++;for(;0<g-y;)v=ui(v),g--;for(;0<y-g;)f=ui(f),y--;for(;g--;){if(v===f||f!==null&&v===f.alternate)break e;v=ui(v),f=ui(f)}v=null}else v=null;p!==null&&Mg(d,h,p,v,!1),m!==null&&b!==null&&Mg(d,b,m,v,!0)}}t:{if(h=u?vi(u):window,p=h.nodeName&&h.nodeName.toLowerCase(),p==="select"||p==="input"&&h.type==="file")var C=wP;else if(xg(h))if(Hb)C=EP;else{C=SP;var k=kP}else(p=h.nodeName)&&p.toLowerCase()==="input"&&(h.type==="checkbox"||h.type==="radio")&&(C=TP);if(C&&(C=C(t,u))){$b(d,C,n,c);break t}k&&k(t,h,u),t==="focusout"&&(k=h._wrapperState)&&k.controlled&&h.type==="number"&&Sd(h,"number",h.value)}switch(k=u?vi(u):window,t){case"focusin":(xg(k)||k.contentEditable==="true")&&(mi=k,Od=u,Bo=null);break;case"focusout":Bo=Od=mi=null;break;case"mousedown":_d=!0;break;case"contextmenu":case"mouseup":case"dragend":_d=!1,Tg(d,n,c);break;case"selectionchange":if(AP)break;case"keydown":case"keyup":Tg(d,n,c)}var M;if(Wp)t:{switch(t){case"compositionstart":var P="onCompositionStart";break t;case"compositionend":P="onCompositionEnd";break t;case"compositionupdate":P="onCompositionUpdate";break t}P=void 0}else fi?Bb(t,n)&&(P="onCompositionEnd"):t==="keydown"&&n.keyCode===229&&(P="onCompositionStart");P&&(zb&&n.locale!=="ko"&&(fi||P!=="onCompositionStart"?P==="onCompositionEnd"&&fi&&(M=Vb()):(er=c,Up="value"in er?er.value:er.textContent,fi=!0)),k=gl(u,P),0<k.length&&(P=new gg(P,t,null,n,c),d.push({event:P,listeners:k}),M?P.data=M:(M=Ub(n),M!==null&&(P.data=M)))),(M=gP?vP(t,n):yP(t,n))&&(u=gl(u,"onBeforeInput"),0<u.length&&(c=new gg("onBeforeInput","beforeinput",null,n,c),d.push({event:c,listeners:u}),c.data=M))}tx(d,e)})}function ua(t,e,n){return{instance:t,listener:e,currentTarget:n}}function gl(t,e){for(var n=e+"Capture",r=[];t!==null;){var i=t,o=i.stateNode;i.tag===5&&o!==null&&(i=o,o=na(t,n),o!=null&&r.unshift(ua(t,o,i)),o=na(t,e),o!=null&&r.push(ua(t,o,i))),t=t.return}return r}function ui(t){if(t===null)return null;do t=t.return;while(t&&t.tag!==5);return t||null}function Mg(t,e,n,r,i){for(var o=e._reactName,a=[];n!==null&&n!==r;){var s=n,l=s.alternate,u=s.stateNode;if(l!==null&&l===r)break;s.tag===5&&u!==null&&(s=u,i?(l=na(n,o),l!=null&&a.unshift(ua(n,l,s))):i||(l=na(n,o),l!=null&&a.push(ua(n,l,s)))),n=n.return}a.length!==0&&t.push({event:e,listeners:a})}var DP=/\r\n?/g,RP=/\u0000|\uFFFD/g;function Dg(t){return(typeof t=="string"?t:""+t).replace(DP,`
`).replace(RP,"")}function xs(t,e,n){if(e=Dg(e),Dg(t)!==e&&n)throw Error(j(425))}function vl(){}var Nd=null,Fd=null;function Vd(t,e){return t==="textarea"||t==="noscript"||typeof e.children=="string"||typeof e.children=="number"||typeof e.dangerouslySetInnerHTML=="object"&&e.dangerouslySetInnerHTML!==null&&e.dangerouslySetInnerHTML.__html!=null}var zd=typeof setTimeout=="function"?setTimeout:void 0,IP=typeof clearTimeout=="function"?clearTimeout:void 0,Rg=typeof Promise=="function"?Promise:void 0,LP=typeof queueMicrotask=="function"?queueMicrotask:typeof Rg<"u"?function(t){return Rg.resolve(null).then(t).catch(jP)}:zd;function jP(t){setTimeout(function(){throw t})}function dc(t,e){var n=e,r=0;do{var i=n.nextSibling;if(t.removeChild(n),i&&i.nodeType===8)if(n=i.data,n==="/$"){if(r===0){t.removeChild(i),oa(e);return}r--}else n!=="$"&&n!=="$?"&&n!=="$!"||r++;n=i}while(n);oa(e)}function sr(t){for(;t!=null;t=t.nextSibling){var e=t.nodeType;if(e===1||e===3)break;if(e===8){if(e=t.data,e==="$"||e==="$!"||e==="$?")break;if(e==="/$")return null}}return t}function Ig(t){t=t.previousSibling;for(var e=0;t;){if(t.nodeType===8){var n=t.data;if(n==="$"||n==="$!"||n==="$?"){if(e===0)return t;e--}else n==="/$"&&e++}t=t.previousSibling}return null}var oo=Math.random().toString(36).slice(2),un="__reactFiber$"+oo,ca="__reactProps$"+oo,zn="__reactContainer$"+oo,Bd="__reactEvents$"+oo,OP="__reactListeners$"+oo,_P="__reactHandles$"+oo;function Nr(t){var e=t[un];if(e)return e;for(var n=t.parentNode;n;){if(e=n[zn]||n[un]){if(n=e.alternate,e.child!==null||n!==null&&n.child!==null)for(t=Ig(t);t!==null;){if(n=t[un])return n;t=Ig(t)}return e}t=n,n=t.parentNode}return null}function qa(t){return t=t[un]||t[zn],!t||t.tag!==5&&t.tag!==6&&t.tag!==13&&t.tag!==3?null:t}function vi(t){if(t.tag===5||t.tag===6)return t.stateNode;throw Error(j(33))}function vu(t){return t[ca]||null}var Ud=[],yi=-1;function kr(t){return{current:t}}function yt(t){0>yi||(t.current=Ud[yi],Ud[yi]=null,yi--)}function mt(t,e){yi++,Ud[yi]=t.current,t.current=e}var pr={},oe=kr(pr),ve=kr(!1),Yr=pr;function Ui(t,e){var n=t.type.contextTypes;if(!n)return pr;var r=t.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===e)return r.__reactInternalMemoizedMaskedChildContext;var i={},o;for(o in n)i[o]=e[o];return r&&(t=t.stateNode,t.__reactInternalMemoizedUnmaskedChildContext=e,t.__reactInternalMemoizedMaskedChildContext=i),i}function ye(t){return t=t.childContextTypes,t!=null}function yl(){yt(ve),yt(oe)}function Lg(t,e,n){if(oe.current!==pr)throw Error(j(168));mt(oe,e),mt(ve,n)}function nx(t,e,n){var r=t.stateNode;if(e=e.childContextTypes,typeof r.getChildContext!="function")return n;r=r.getChildContext();for(var i in r)if(!(i in e))throw Error(j(108,kC(t)||"Unknown",i));return At({},n,r)}function bl(t){return t=(t=t.stateNode)&&t.__reactInternalMemoizedMergedChildContext||pr,Yr=oe.current,mt(oe,t),mt(ve,ve.current),!0}function jg(t,e,n){var r=t.stateNode;if(!r)throw Error(j(169));n?(t=nx(t,e,Yr),r.__reactInternalMemoizedMergedChildContext=t,yt(ve),yt(oe),mt(oe,t)):yt(ve),mt(ve,n)}var Tn=null,yu=!1,hc=!1;function rx(t){Tn===null?Tn=[t]:Tn.push(t)}function NP(t){yu=!0,rx(t)}function Sr(){if(!hc&&Tn!==null){hc=!0;var t=0,e=ut;try{var n=Tn;for(ut=1;t<n.length;t++){var r=n[t];do r=r(!0);while(r!==null)}Tn=null,yu=!1}catch(i){throw Tn!==null&&(Tn=Tn.slice(t+1)),Ab(Fp,Sr),i}finally{ut=e,hc=!1}}return null}var bi=[],xi=0,xl=null,wl=0,Ve=[],ze=0,Kr=null,Cn=1,Pn="";function Dr(t,e){bi[xi++]=wl,bi[xi++]=xl,xl=t,wl=e}function ix(t,e,n){Ve[ze++]=Cn,Ve[ze++]=Pn,Ve[ze++]=Kr,Kr=t;var r=Cn;t=Pn;var i=32-Ze(r)-1;r&=~(1<<i),n+=1;var o=32-Ze(e)+i;if(30<o){var a=i-i%5;o=(r&(1<<a)-1).toString(32),r>>=a,i-=a,Cn=1<<32-Ze(e)+i|n<<i|r,Pn=o+t}else Cn=1<<o|n<<i|r,Pn=t}function Yp(t){t.return!==null&&(Dr(t,1),ix(t,1,0))}function Kp(t){for(;t===xl;)xl=bi[--xi],bi[xi]=null,wl=bi[--xi],bi[xi]=null;for(;t===Kr;)Kr=Ve[--ze],Ve[ze]=null,Pn=Ve[--ze],Ve[ze]=null,Cn=Ve[--ze],Ve[ze]=null}var Pe=null,Ee=null,wt=!1,Je=null;function ox(t,e){var n=Ue(5,null,null,0);n.elementType="DELETED",n.stateNode=e,n.return=t,e=t.deletions,e===null?(t.deletions=[n],t.flags|=16):e.push(n)}function Og(t,e){switch(t.tag){case 5:var n=t.type;return e=e.nodeType!==1||n.toLowerCase()!==e.nodeName.toLowerCase()?null:e,e!==null?(t.stateNode=e,Pe=t,Ee=sr(e.firstChild),!0):!1;case 6:return e=t.pendingProps===""||e.nodeType!==3?null:e,e!==null?(t.stateNode=e,Pe=t,Ee=null,!0):!1;case 13:return e=e.nodeType!==8?null:e,e!==null?(n=Kr!==null?{id:Cn,overflow:Pn}:null,t.memoizedState={dehydrated:e,treeContext:n,retryLane:1073741824},n=Ue(18,null,null,0),n.stateNode=e,n.return=t,t.child=n,Pe=t,Ee=null,!0):!1;default:return!1}}function $d(t){return(t.mode&1)!==0&&(t.flags&128)===0}function Hd(t){if(wt){var e=Ee;if(e){var n=e;if(!Og(t,e)){if($d(t))throw Error(j(418));e=sr(n.nextSibling);var r=Pe;e&&Og(t,e)?ox(r,n):(t.flags=t.flags&-4097|2,wt=!1,Pe=t)}}else{if($d(t))throw Error(j(418));t.flags=t.flags&-4097|2,wt=!1,Pe=t}}}function _g(t){for(t=t.return;t!==null&&t.tag!==5&&t.tag!==3&&t.tag!==13;)t=t.return;Pe=t}function ws(t){if(t!==Pe)return!1;if(!wt)return _g(t),wt=!0,!1;var e;if((e=t.tag!==3)&&!(e=t.tag!==5)&&(e=t.type,e=e!=="head"&&e!=="body"&&!Vd(t.type,t.memoizedProps)),e&&(e=Ee)){if($d(t))throw ax(),Error(j(418));for(;e;)ox(t,e),e=sr(e.nextSibling)}if(_g(t),t.tag===13){if(t=t.memoizedState,t=t!==null?t.dehydrated:null,!t)throw Error(j(317));t:{for(t=t.nextSibling,e=0;t;){if(t.nodeType===8){var n=t.data;if(n==="/$"){if(e===0){Ee=sr(t.nextSibling);break t}e--}else n!=="$"&&n!=="$!"&&n!=="$?"||e++}t=t.nextSibling}Ee=null}}else Ee=Pe?sr(t.stateNode.nextSibling):null;return!0}function ax(){for(var t=Ee;t;)t=sr(t.nextSibling)}function $i(){Ee=Pe=null,wt=!1}function Xp(t){Je===null?Je=[t]:Je.push(t)}var FP=Hn.ReactCurrentBatchConfig;function bo(t,e,n){if(t=n.ref,t!==null&&typeof t!="function"&&typeof t!="object"){if(n._owner){if(n=n._owner,n){if(n.tag!==1)throw Error(j(309));var r=n.stateNode}if(!r)throw Error(j(147,t));var i=r,o=""+t;return e!==null&&e.ref!==null&&typeof e.ref=="function"&&e.ref._stringRef===o?e.ref:(e=function(a){var s=i.refs;a===null?delete s[o]:s[o]=a},e._stringRef=o,e)}if(typeof t!="string")throw Error(j(284));if(!n._owner)throw Error(j(290,t))}return t}function ks(t,e){throw t=Object.prototype.toString.call(e),Error(j(31,t==="[object Object]"?"object with keys {"+Object.keys(e).join(", ")+"}":t))}function Ng(t){var e=t._init;return e(t._payload)}function sx(t){function e(f,g){if(t){var y=f.deletions;y===null?(f.deletions=[g],f.flags|=16):y.push(g)}}function n(f,g){if(!t)return null;for(;g!==null;)e(f,g),g=g.sibling;return null}function r(f,g){for(f=new Map;g!==null;)g.key!==null?f.set(g.key,g):f.set(g.index,g),g=g.sibling;return f}function i(f,g){return f=dr(f,g),f.index=0,f.sibling=null,f}function o(f,g,y){return f.index=y,t?(y=f.alternate,y!==null?(y=y.index,y<g?(f.flags|=2,g):y):(f.flags|=2,g)):(f.flags|=1048576,g)}function a(f){return t&&f.alternate===null&&(f.flags|=2),f}function s(f,g,y,w){return g===null||g.tag!==6?(g=bc(y,f.mode,w),g.return=f,g):(g=i(g,y),g.return=f,g)}function l(f,g,y,w){var C=y.type;return C===pi?c(f,g,y.props.children,w,y.key):g!==null&&(g.elementType===C||typeof C=="object"&&C!==null&&C.$$typeof===Gn&&Ng(C)===g.type)?(w=i(g,y.props),w.ref=bo(f,g,y),w.return=f,w):(w=Qs(y.type,y.key,y.props,null,f.mode,w),w.ref=bo(f,g,y),w.return=f,w)}function u(f,g,y,w){return g===null||g.tag!==4||g.stateNode.containerInfo!==y.containerInfo||g.stateNode.implementation!==y.implementation?(g=xc(y,f.mode,w),g.return=f,g):(g=i(g,y.children||[]),g.return=f,g)}function c(f,g,y,w,C){return g===null||g.tag!==7?(g=$r(y,f.mode,w,C),g.return=f,g):(g=i(g,y),g.return=f,g)}function d(f,g,y){if(typeof g=="string"&&g!==""||typeof g=="number")return g=bc(""+g,f.mode,y),g.return=f,g;if(typeof g=="object"&&g!==null){switch(g.$$typeof){case ss:return y=Qs(g.type,g.key,g.props,null,f.mode,y),y.ref=bo(f,null,g),y.return=f,y;case hi:return g=xc(g,f.mode,y),g.return=f,g;case Gn:var w=g._init;return d(f,w(g._payload),y)}if(Do(g)||mo(g))return g=$r(g,f.mode,y,null),g.return=f,g;ks(f,g)}return null}function h(f,g,y,w){var C=g!==null?g.key:null;if(typeof y=="string"&&y!==""||typeof y=="number")return C!==null?null:s(f,g,""+y,w);if(typeof y=="object"&&y!==null){switch(y.$$typeof){case ss:return y.key===C?l(f,g,y,w):null;case hi:return y.key===C?u(f,g,y,w):null;case Gn:return C=y._init,h(f,g,C(y._payload),w)}if(Do(y)||mo(y))return C!==null?null:c(f,g,y,w,null);ks(f,y)}return null}function p(f,g,y,w,C){if(typeof w=="string"&&w!==""||typeof w=="number")return f=f.get(y)||null,s(g,f,""+w,C);if(typeof w=="object"&&w!==null){switch(w.$$typeof){case ss:return f=f.get(w.key===null?y:w.key)||null,l(g,f,w,C);case hi:return f=f.get(w.key===null?y:w.key)||null,u(g,f,w,C);case Gn:var k=w._init;return p(f,g,y,k(w._payload),C)}if(Do(w)||mo(w))return f=f.get(y)||null,c(g,f,w,C,null);ks(g,w)}return null}function m(f,g,y,w){for(var C=null,k=null,M=g,P=g=0,R=null;M!==null&&P<y.length;P++){M.index>P?(R=M,M=null):R=M.sibling;var E=h(f,M,y[P],w);if(E===null){M===null&&(M=R);break}t&&M&&E.alternate===null&&e(f,M),g=o(E,g,P),k===null?C=E:k.sibling=E,k=E,M=R}if(P===y.length)return n(f,M),wt&&Dr(f,P),C;if(M===null){for(;P<y.length;P++)M=d(f,y[P],w),M!==null&&(g=o(M,g,P),k===null?C=M:k.sibling=M,k=M);return wt&&Dr(f,P),C}for(M=r(f,M);P<y.length;P++)R=p(M,f,P,y[P],w),R!==null&&(t&&R.alternate!==null&&M.delete(R.key===null?P:R.key),g=o(R,g,P),k===null?C=R:k.sibling=R,k=R);return t&&M.forEach(function(L){return e(f,L)}),wt&&Dr(f,P),C}function v(f,g,y,w){var C=mo(y);if(typeof C!="function")throw Error(j(150));if(y=C.call(y),y==null)throw Error(j(151));for(var k=C=null,M=g,P=g=0,R=null,E=y.next();M!==null&&!E.done;P++,E=y.next()){M.index>P?(R=M,M=null):R=M.sibling;var L=h(f,M,E.value,w);if(L===null){M===null&&(M=R);break}t&&M&&L.alternate===null&&e(f,M),g=o(L,g,P),k===null?C=L:k.sibling=L,k=L,M=R}if(E.done)return n(f,M),wt&&Dr(f,P),C;if(M===null){for(;!E.done;P++,E=y.next())E=d(f,E.value,w),E!==null&&(g=o(E,g,P),k===null?C=E:k.sibling=E,k=E);return wt&&Dr(f,P),C}for(M=r(f,M);!E.done;P++,E=y.next())E=p(M,f,P,E.value,w),E!==null&&(t&&E.alternate!==null&&M.delete(E.key===null?P:E.key),g=o(E,g,P),k===null?C=E:k.sibling=E,k=E);return t&&M.forEach(function(N){return e(f,N)}),wt&&Dr(f,P),C}function b(f,g,y,w){if(typeof y=="object"&&y!==null&&y.type===pi&&y.key===null&&(y=y.props.children),typeof y=="object"&&y!==null){switch(y.$$typeof){case ss:t:{for(var C=y.key,k=g;k!==null;){if(k.key===C){if(C=y.type,C===pi){if(k.tag===7){n(f,k.sibling),g=i(k,y.props.children),g.return=f,f=g;break t}}else if(k.elementType===C||typeof C=="object"&&C!==null&&C.$$typeof===Gn&&Ng(C)===k.type){n(f,k.sibling),g=i(k,y.props),g.ref=bo(f,k,y),g.return=f,f=g;break t}n(f,k);break}else e(f,k);k=k.sibling}y.type===pi?(g=$r(y.props.children,f.mode,w,y.key),g.return=f,f=g):(w=Qs(y.type,y.key,y.props,null,f.mode,w),w.ref=bo(f,g,y),w.return=f,f=w)}return a(f);case hi:t:{for(k=y.key;g!==null;){if(g.key===k)if(g.tag===4&&g.stateNode.containerInfo===y.containerInfo&&g.stateNode.implementation===y.implementation){n(f,g.sibling),g=i(g,y.children||[]),g.return=f,f=g;break t}else{n(f,g);break}else e(f,g);g=g.sibling}g=xc(y,f.mode,w),g.return=f,f=g}return a(f);case Gn:return k=y._init,b(f,g,k(y._payload),w)}if(Do(y))return m(f,g,y,w);if(mo(y))return v(f,g,y,w);ks(f,y)}return typeof y=="string"&&y!==""||typeof y=="number"?(y=""+y,g!==null&&g.tag===6?(n(f,g.sibling),g=i(g,y),g.return=f,f=g):(n(f,g),g=bc(y,f.mode,w),g.return=f,f=g),a(f)):n(f,g)}return b}var Hi=sx(!0),lx=sx(!1),kl=kr(null),Sl=null,wi=null,Gp=null;function Qp(){Gp=wi=Sl=null}function Jp(t){var e=kl.current;yt(kl),t._currentValue=e}function Wd(t,e,n){for(;t!==null;){var r=t.alternate;if((t.childLanes&e)!==e?(t.childLanes|=e,r!==null&&(r.childLanes|=e)):r!==null&&(r.childLanes&e)!==e&&(r.childLanes|=e),t===n)break;t=t.return}}function Fi(t,e){Sl=t,Gp=wi=null,t=t.dependencies,t!==null&&t.firstContext!==null&&(t.lanes&e&&(ge=!0),t.firstContext=null)}function We(t){var e=t._currentValue;if(Gp!==t)if(t={context:t,memoizedValue:e,next:null},wi===null){if(Sl===null)throw Error(j(308));wi=t,Sl.dependencies={lanes:0,firstContext:t}}else wi=wi.next=t;return e}var Fr=null;function Zp(t){Fr===null?Fr=[t]:Fr.push(t)}function ux(t,e,n,r){var i=e.interleaved;return i===null?(n.next=n,Zp(e)):(n.next=i.next,i.next=n),e.interleaved=n,Bn(t,r)}function Bn(t,e){t.lanes|=e;var n=t.alternate;for(n!==null&&(n.lanes|=e),n=t,t=t.return;t!==null;)t.childLanes|=e,n=t.alternate,n!==null&&(n.childLanes|=e),n=t,t=t.return;return n.tag===3?n.stateNode:null}var Qn=!1;function tf(t){t.updateQueue={baseState:t.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function cx(t,e){t=t.updateQueue,e.updateQueue===t&&(e.updateQueue={baseState:t.baseState,firstBaseUpdate:t.firstBaseUpdate,lastBaseUpdate:t.lastBaseUpdate,shared:t.shared,effects:t.effects})}function Dn(t,e){return{eventTime:t,lane:e,tag:0,payload:null,callback:null,next:null}}function lr(t,e,n){var r=t.updateQueue;if(r===null)return null;if(r=r.shared,ot&2){var i=r.pending;return i===null?e.next=e:(e.next=i.next,i.next=e),r.pending=e,Bn(t,n)}return i=r.interleaved,i===null?(e.next=e,Zp(r)):(e.next=i.next,i.next=e),r.interleaved=e,Bn(t,n)}function Ws(t,e,n){if(e=e.updateQueue,e!==null&&(e=e.shared,(n&4194240)!==0)){var r=e.lanes;r&=t.pendingLanes,n|=r,e.lanes=n,Vp(t,n)}}function Fg(t,e){var n=t.updateQueue,r=t.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var i=null,o=null;if(n=n.firstBaseUpdate,n!==null){do{var a={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};o===null?i=o=a:o=o.next=a,n=n.next}while(n!==null);o===null?i=o=e:o=o.next=e}else i=o=e;n={baseState:r.baseState,firstBaseUpdate:i,lastBaseUpdate:o,shared:r.shared,effects:r.effects},t.updateQueue=n;return}t=n.lastBaseUpdate,t===null?n.firstBaseUpdate=e:t.next=e,n.lastBaseUpdate=e}function Tl(t,e,n,r){var i=t.updateQueue;Qn=!1;var o=i.firstBaseUpdate,a=i.lastBaseUpdate,s=i.shared.pending;if(s!==null){i.shared.pending=null;var l=s,u=l.next;l.next=null,a===null?o=u:a.next=u,a=l;var c=t.alternate;c!==null&&(c=c.updateQueue,s=c.lastBaseUpdate,s!==a&&(s===null?c.firstBaseUpdate=u:s.next=u,c.lastBaseUpdate=l))}if(o!==null){var d=i.baseState;a=0,c=u=l=null,s=o;do{var h=s.lane,p=s.eventTime;if((r&h)===h){c!==null&&(c=c.next={eventTime:p,lane:0,tag:s.tag,payload:s.payload,callback:s.callback,next:null});t:{var m=t,v=s;switch(h=e,p=n,v.tag){case 1:if(m=v.payload,typeof m=="function"){d=m.call(p,d,h);break t}d=m;break t;case 3:m.flags=m.flags&-65537|128;case 0:if(m=v.payload,h=typeof m=="function"?m.call(p,d,h):m,h==null)break t;d=At({},d,h);break t;case 2:Qn=!0}}s.callback!==null&&s.lane!==0&&(t.flags|=64,h=i.effects,h===null?i.effects=[s]:h.push(s))}else p={eventTime:p,lane:h,tag:s.tag,payload:s.payload,callback:s.callback,next:null},c===null?(u=c=p,l=d):c=c.next=p,a|=h;if(s=s.next,s===null){if(s=i.shared.pending,s===null)break;h=s,s=h.next,h.next=null,i.lastBaseUpdate=h,i.shared.pending=null}}while(!0);if(c===null&&(l=d),i.baseState=l,i.firstBaseUpdate=u,i.lastBaseUpdate=c,e=i.shared.interleaved,e!==null){i=e;do a|=i.lane,i=i.next;while(i!==e)}else o===null&&(i.shared.lanes=0);Gr|=a,t.lanes=a,t.memoizedState=d}}function Vg(t,e,n){if(t=e.effects,e.effects=null,t!==null)for(e=0;e<t.length;e++){var r=t[e],i=r.callback;if(i!==null){if(r.callback=null,r=n,typeof i!="function")throw Error(j(191,i));i.call(r)}}}var Ya={},hn=kr(Ya),da=kr(Ya),ha=kr(Ya);function Vr(t){if(t===Ya)throw Error(j(174));return t}function ef(t,e){switch(mt(ha,e),mt(da,t),mt(hn,Ya),t=e.nodeType,t){case 9:case 11:e=(e=e.documentElement)?e.namespaceURI:Ed(null,"");break;default:t=t===8?e.parentNode:e,e=t.namespaceURI||null,t=t.tagName,e=Ed(e,t)}yt(hn),mt(hn,e)}function Wi(){yt(hn),yt(da),yt(ha)}function dx(t){Vr(ha.current);var e=Vr(hn.current),n=Ed(e,t.type);e!==n&&(mt(da,t),mt(hn,n))}function nf(t){da.current===t&&(yt(hn),yt(da))}var Tt=kr(0);function El(t){for(var e=t;e!==null;){if(e.tag===13){var n=e.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||n.data==="$?"||n.data==="$!"))return e}else if(e.tag===19&&e.memoizedProps.revealOrder!==void 0){if(e.flags&128)return e}else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break;for(;e.sibling===null;){if(e.return===null||e.return===t)return null;e=e.return}e.sibling.return=e.return,e=e.sibling}return null}var pc=[];function rf(){for(var t=0;t<pc.length;t++)pc[t]._workInProgressVersionPrimary=null;pc.length=0}var qs=Hn.ReactCurrentDispatcher,fc=Hn.ReactCurrentBatchConfig,Xr=0,Pt=null,_t=null,zt=null,Cl=!1,Uo=!1,pa=0,VP=0;function Xt(){throw Error(j(321))}function of(t,e){if(e===null)return!1;for(var n=0;n<e.length&&n<t.length;n++)if(!nn(t[n],e[n]))return!1;return!0}function af(t,e,n,r,i,o){if(Xr=o,Pt=e,e.memoizedState=null,e.updateQueue=null,e.lanes=0,qs.current=t===null||t.memoizedState===null?$P:HP,t=n(r,i),Uo){o=0;do{if(Uo=!1,pa=0,25<=o)throw Error(j(301));o+=1,zt=_t=null,e.updateQueue=null,qs.current=WP,t=n(r,i)}while(Uo)}if(qs.current=Pl,e=_t!==null&&_t.next!==null,Xr=0,zt=_t=Pt=null,Cl=!1,e)throw Error(j(300));return t}function sf(){var t=pa!==0;return pa=0,t}function sn(){var t={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return zt===null?Pt.memoizedState=zt=t:zt=zt.next=t,zt}function qe(){if(_t===null){var t=Pt.alternate;t=t!==null?t.memoizedState:null}else t=_t.next;var e=zt===null?Pt.memoizedState:zt.next;if(e!==null)zt=e,_t=t;else{if(t===null)throw Error(j(310));_t=t,t={memoizedState:_t.memoizedState,baseState:_t.baseState,baseQueue:_t.baseQueue,queue:_t.queue,next:null},zt===null?Pt.memoizedState=zt=t:zt=zt.next=t}return zt}function fa(t,e){return typeof e=="function"?e(t):e}function mc(t){var e=qe(),n=e.queue;if(n===null)throw Error(j(311));n.lastRenderedReducer=t;var r=_t,i=r.baseQueue,o=n.pending;if(o!==null){if(i!==null){var a=i.next;i.next=o.next,o.next=a}r.baseQueue=i=o,n.pending=null}if(i!==null){o=i.next,r=r.baseState;var s=a=null,l=null,u=o;do{var c=u.lane;if((Xr&c)===c)l!==null&&(l=l.next={lane:0,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null}),r=u.hasEagerState?u.eagerState:t(r,u.action);else{var d={lane:c,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null};l===null?(s=l=d,a=r):l=l.next=d,Pt.lanes|=c,Gr|=c}u=u.next}while(u!==null&&u!==o);l===null?a=r:l.next=s,nn(r,e.memoizedState)||(ge=!0),e.memoizedState=r,e.baseState=a,e.baseQueue=l,n.lastRenderedState=r}if(t=n.interleaved,t!==null){i=t;do o=i.lane,Pt.lanes|=o,Gr|=o,i=i.next;while(i!==t)}else i===null&&(n.lanes=0);return[e.memoizedState,n.dispatch]}function gc(t){var e=qe(),n=e.queue;if(n===null)throw Error(j(311));n.lastRenderedReducer=t;var r=n.dispatch,i=n.pending,o=e.memoizedState;if(i!==null){n.pending=null;var a=i=i.next;do o=t(o,a.action),a=a.next;while(a!==i);nn(o,e.memoizedState)||(ge=!0),e.memoizedState=o,e.baseQueue===null&&(e.baseState=o),n.lastRenderedState=o}return[o,r]}function hx(){}function px(t,e){var n=Pt,r=qe(),i=e(),o=!nn(r.memoizedState,i);if(o&&(r.memoizedState=i,ge=!0),r=r.queue,lf(gx.bind(null,n,r,t),[t]),r.getSnapshot!==e||o||zt!==null&&zt.memoizedState.tag&1){if(n.flags|=2048,ma(9,mx.bind(null,n,r,i,e),void 0,null),Bt===null)throw Error(j(349));Xr&30||fx(n,e,i)}return i}function fx(t,e,n){t.flags|=16384,t={getSnapshot:e,value:n},e=Pt.updateQueue,e===null?(e={lastEffect:null,stores:null},Pt.updateQueue=e,e.stores=[t]):(n=e.stores,n===null?e.stores=[t]:n.push(t))}function mx(t,e,n,r){e.value=n,e.getSnapshot=r,vx(e)&&yx(t)}function gx(t,e,n){return n(function(){vx(e)&&yx(t)})}function vx(t){var e=t.getSnapshot;t=t.value;try{var n=e();return!nn(t,n)}catch{return!0}}function yx(t){var e=Bn(t,1);e!==null&&tn(e,t,1,-1)}function zg(t){var e=sn();return typeof t=="function"&&(t=t()),e.memoizedState=e.baseState=t,t={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:fa,lastRenderedState:t},e.queue=t,t=t.dispatch=UP.bind(null,Pt,t),[e.memoizedState,t]}function ma(t,e,n,r){return t={tag:t,create:e,destroy:n,deps:r,next:null},e=Pt.updateQueue,e===null?(e={lastEffect:null,stores:null},Pt.updateQueue=e,e.lastEffect=t.next=t):(n=e.lastEffect,n===null?e.lastEffect=t.next=t:(r=n.next,n.next=t,t.next=r,e.lastEffect=t)),t}function bx(){return qe().memoizedState}function Ys(t,e,n,r){var i=sn();Pt.flags|=t,i.memoizedState=ma(1|e,n,void 0,r===void 0?null:r)}function bu(t,e,n,r){var i=qe();r=r===void 0?null:r;var o=void 0;if(_t!==null){var a=_t.memoizedState;if(o=a.destroy,r!==null&&of(r,a.deps)){i.memoizedState=ma(e,n,o,r);return}}Pt.flags|=t,i.memoizedState=ma(1|e,n,o,r)}function Bg(t,e){return Ys(8390656,8,t,e)}function lf(t,e){return bu(2048,8,t,e)}function xx(t,e){return bu(4,2,t,e)}function wx(t,e){return bu(4,4,t,e)}function kx(t,e){if(typeof e=="function")return t=t(),e(t),function(){e(null)};if(e!=null)return t=t(),e.current=t,function(){e.current=null}}function Sx(t,e,n){return n=n!=null?n.concat([t]):null,bu(4,4,kx.bind(null,e,t),n)}function uf(){}function Tx(t,e){var n=qe();e=e===void 0?null:e;var r=n.memoizedState;return r!==null&&e!==null&&of(e,r[1])?r[0]:(n.memoizedState=[t,e],t)}function Ex(t,e){var n=qe();e=e===void 0?null:e;var r=n.memoizedState;return r!==null&&e!==null&&of(e,r[1])?r[0]:(t=t(),n.memoizedState=[t,e],t)}function Cx(t,e,n){return Xr&21?(nn(n,e)||(n=Rb(),Pt.lanes|=n,Gr|=n,t.baseState=!0),e):(t.baseState&&(t.baseState=!1,ge=!0),t.memoizedState=n)}function zP(t,e){var n=ut;ut=n!==0&&4>n?n:4,t(!0);var r=fc.transition;fc.transition={};try{t(!1),e()}finally{ut=n,fc.transition=r}}function Px(){return qe().memoizedState}function BP(t,e,n){var r=cr(t);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},Ax(t))Mx(e,n);else if(n=ux(t,e,n,r),n!==null){var i=ue();tn(n,t,r,i),Dx(n,e,r)}}function UP(t,e,n){var r=cr(t),i={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(Ax(t))Mx(e,i);else{var o=t.alternate;if(t.lanes===0&&(o===null||o.lanes===0)&&(o=e.lastRenderedReducer,o!==null))try{var a=e.lastRenderedState,s=o(a,n);if(i.hasEagerState=!0,i.eagerState=s,nn(s,a)){var l=e.interleaved;l===null?(i.next=i,Zp(e)):(i.next=l.next,l.next=i),e.interleaved=i;return}}catch{}finally{}n=ux(t,e,i,r),n!==null&&(i=ue(),tn(n,t,r,i),Dx(n,e,r))}}function Ax(t){var e=t.alternate;return t===Pt||e!==null&&e===Pt}function Mx(t,e){Uo=Cl=!0;var n=t.pending;n===null?e.next=e:(e.next=n.next,n.next=e),t.pending=e}function Dx(t,e,n){if(n&4194240){var r=e.lanes;r&=t.pendingLanes,n|=r,e.lanes=n,Vp(t,n)}}var Pl={readContext:We,useCallback:Xt,useContext:Xt,useEffect:Xt,useImperativeHandle:Xt,useInsertionEffect:Xt,useLayoutEffect:Xt,useMemo:Xt,useReducer:Xt,useRef:Xt,useState:Xt,useDebugValue:Xt,useDeferredValue:Xt,useTransition:Xt,useMutableSource:Xt,useSyncExternalStore:Xt,useId:Xt,unstable_isNewReconciler:!1},$P={readContext:We,useCallback:function(t,e){return sn().memoizedState=[t,e===void 0?null:e],t},useContext:We,useEffect:Bg,useImperativeHandle:function(t,e,n){return n=n!=null?n.concat([t]):null,Ys(4194308,4,kx.bind(null,e,t),n)},useLayoutEffect:function(t,e){return Ys(4194308,4,t,e)},useInsertionEffect:function(t,e){return Ys(4,2,t,e)},useMemo:function(t,e){var n=sn();return e=e===void 0?null:e,t=t(),n.memoizedState=[t,e],t},useReducer:function(t,e,n){var r=sn();return e=n!==void 0?n(e):e,r.memoizedState=r.baseState=e,t={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:t,lastRenderedState:e},r.queue=t,t=t.dispatch=BP.bind(null,Pt,t),[r.memoizedState,t]},useRef:function(t){var e=sn();return t={current:t},e.memoizedState=t},useState:zg,useDebugValue:uf,useDeferredValue:function(t){return sn().memoizedState=t},useTransition:function(){var t=zg(!1),e=t[0];return t=zP.bind(null,t[1]),sn().memoizedState=t,[e,t]},useMutableSource:function(){},useSyncExternalStore:function(t,e,n){var r=Pt,i=sn();if(wt){if(n===void 0)throw Error(j(407));n=n()}else{if(n=e(),Bt===null)throw Error(j(349));Xr&30||fx(r,e,n)}i.memoizedState=n;var o={value:n,getSnapshot:e};return i.queue=o,Bg(gx.bind(null,r,o,t),[t]),r.flags|=2048,ma(9,mx.bind(null,r,o,n,e),void 0,null),n},useId:function(){var t=sn(),e=Bt.identifierPrefix;if(wt){var n=Pn,r=Cn;n=(r&~(1<<32-Ze(r)-1)).toString(32)+n,e=":"+e+"R"+n,n=pa++,0<n&&(e+="H"+n.toString(32)),e+=":"}else n=VP++,e=":"+e+"r"+n.toString(32)+":";return t.memoizedState=e},unstable_isNewReconciler:!1},HP={readContext:We,useCallback:Tx,useContext:We,useEffect:lf,useImperativeHandle:Sx,useInsertionEffect:xx,useLayoutEffect:wx,useMemo:Ex,useReducer:mc,useRef:bx,useState:function(){return mc(fa)},useDebugValue:uf,useDeferredValue:function(t){var e=qe();return Cx(e,_t.memoizedState,t)},useTransition:function(){var t=mc(fa)[0],e=qe().memoizedState;return[t,e]},useMutableSource:hx,useSyncExternalStore:px,useId:Px,unstable_isNewReconciler:!1},WP={readContext:We,useCallback:Tx,useContext:We,useEffect:lf,useImperativeHandle:Sx,useInsertionEffect:xx,useLayoutEffect:wx,useMemo:Ex,useReducer:gc,useRef:bx,useState:function(){return gc(fa)},useDebugValue:uf,useDeferredValue:function(t){var e=qe();return _t===null?e.memoizedState=t:Cx(e,_t.memoizedState,t)},useTransition:function(){var t=gc(fa)[0],e=qe().memoizedState;return[t,e]},useMutableSource:hx,useSyncExternalStore:px,useId:Px,unstable_isNewReconciler:!1};function Ge(t,e){if(t&&t.defaultProps){e=At({},e),t=t.defaultProps;for(var n in t)e[n]===void 0&&(e[n]=t[n]);return e}return e}function qd(t,e,n,r){e=t.memoizedState,n=n(r,e),n=n==null?e:At({},e,n),t.memoizedState=n,t.lanes===0&&(t.updateQueue.baseState=n)}var xu={isMounted:function(t){return(t=t._reactInternals)?ei(t)===t:!1},enqueueSetState:function(t,e,n){t=t._reactInternals;var r=ue(),i=cr(t),o=Dn(r,i);o.payload=e,n!=null&&(o.callback=n),e=lr(t,o,i),e!==null&&(tn(e,t,i,r),Ws(e,t,i))},enqueueReplaceState:function(t,e,n){t=t._reactInternals;var r=ue(),i=cr(t),o=Dn(r,i);o.tag=1,o.payload=e,n!=null&&(o.callback=n),e=lr(t,o,i),e!==null&&(tn(e,t,i,r),Ws(e,t,i))},enqueueForceUpdate:function(t,e){t=t._reactInternals;var n=ue(),r=cr(t),i=Dn(n,r);i.tag=2,e!=null&&(i.callback=e),e=lr(t,i,r),e!==null&&(tn(e,t,r,n),Ws(e,t,r))}};function Ug(t,e,n,r,i,o,a){return t=t.stateNode,typeof t.shouldComponentUpdate=="function"?t.shouldComponentUpdate(r,o,a):e.prototype&&e.prototype.isPureReactComponent?!sa(n,r)||!sa(i,o):!0}function Rx(t,e,n){var r=!1,i=pr,o=e.contextType;return typeof o=="object"&&o!==null?o=We(o):(i=ye(e)?Yr:oe.current,r=e.contextTypes,o=(r=r!=null)?Ui(t,i):pr),e=new e(n,o),t.memoizedState=e.state!==null&&e.state!==void 0?e.state:null,e.updater=xu,t.stateNode=e,e._reactInternals=t,r&&(t=t.stateNode,t.__reactInternalMemoizedUnmaskedChildContext=i,t.__reactInternalMemoizedMaskedChildContext=o),e}function $g(t,e,n,r){t=e.state,typeof e.componentWillReceiveProps=="function"&&e.componentWillReceiveProps(n,r),typeof e.UNSAFE_componentWillReceiveProps=="function"&&e.UNSAFE_componentWillReceiveProps(n,r),e.state!==t&&xu.enqueueReplaceState(e,e.state,null)}function Yd(t,e,n,r){var i=t.stateNode;i.props=n,i.state=t.memoizedState,i.refs={},tf(t);var o=e.contextType;typeof o=="object"&&o!==null?i.context=We(o):(o=ye(e)?Yr:oe.current,i.context=Ui(t,o)),i.state=t.memoizedState,o=e.getDerivedStateFromProps,typeof o=="function"&&(qd(t,e,o,n),i.state=t.memoizedState),typeof e.getDerivedStateFromProps=="function"||typeof i.getSnapshotBeforeUpdate=="function"||typeof i.UNSAFE_componentWillMount!="function"&&typeof i.componentWillMount!="function"||(e=i.state,typeof i.componentWillMount=="function"&&i.componentWillMount(),typeof i.UNSAFE_componentWillMount=="function"&&i.UNSAFE_componentWillMount(),e!==i.state&&xu.enqueueReplaceState(i,i.state,null),Tl(t,n,i,r),i.state=t.memoizedState),typeof i.componentDidMount=="function"&&(t.flags|=4194308)}function qi(t,e){try{var n="",r=e;do n+=wC(r),r=r.return;while(r);var i=n}catch(o){i=`
Error generating stack: `+o.message+`
`+o.stack}return{value:t,source:e,stack:i,digest:null}}function vc(t,e,n){return{value:t,source:null,stack:n??null,digest:e??null}}function Kd(t,e){try{console.error(e.value)}catch(n){setTimeout(function(){throw n})}}var qP=typeof WeakMap=="function"?WeakMap:Map;function Ix(t,e,n){n=Dn(-1,n),n.tag=3,n.payload={element:null};var r=e.value;return n.callback=function(){Ml||(Ml=!0,rh=r),Kd(t,e)},n}function Lx(t,e,n){n=Dn(-1,n),n.tag=3;var r=t.type.getDerivedStateFromError;if(typeof r=="function"){var i=e.value;n.payload=function(){return r(i)},n.callback=function(){Kd(t,e)}}var o=t.stateNode;return o!==null&&typeof o.componentDidCatch=="function"&&(n.callback=function(){Kd(t,e),typeof r!="function"&&(ur===null?ur=new Set([this]):ur.add(this));var a=e.stack;this.componentDidCatch(e.value,{componentStack:a!==null?a:""})}),n}function Hg(t,e,n){var r=t.pingCache;if(r===null){r=t.pingCache=new qP;var i=new Set;r.set(e,i)}else i=r.get(e),i===void 0&&(i=new Set,r.set(e,i));i.has(n)||(i.add(n),t=a2.bind(null,t,e,n),e.then(t,t))}function Wg(t){do{var e;if((e=t.tag===13)&&(e=t.memoizedState,e=e!==null?e.dehydrated!==null:!0),e)return t;t=t.return}while(t!==null);return null}function qg(t,e,n,r,i){return t.mode&1?(t.flags|=65536,t.lanes=i,t):(t===e?t.flags|=65536:(t.flags|=128,n.flags|=131072,n.flags&=-52805,n.tag===1&&(n.alternate===null?n.tag=17:(e=Dn(-1,1),e.tag=2,lr(n,e,1))),n.lanes|=1),t)}var YP=Hn.ReactCurrentOwner,ge=!1;function se(t,e,n,r){e.child=t===null?lx(e,null,n,r):Hi(e,t.child,n,r)}function Yg(t,e,n,r,i){n=n.render;var o=e.ref;return Fi(e,i),r=af(t,e,n,r,o,i),n=sf(),t!==null&&!ge?(e.updateQueue=t.updateQueue,e.flags&=-2053,t.lanes&=~i,Un(t,e,i)):(wt&&n&&Yp(e),e.flags|=1,se(t,e,r,i),e.child)}function Kg(t,e,n,r,i){if(t===null){var o=n.type;return typeof o=="function"&&!vf(o)&&o.defaultProps===void 0&&n.compare===null&&n.defaultProps===void 0?(e.tag=15,e.type=o,jx(t,e,o,r,i)):(t=Qs(n.type,null,r,e,e.mode,i),t.ref=e.ref,t.return=e,e.child=t)}if(o=t.child,!(t.lanes&i)){var a=o.memoizedProps;if(n=n.compare,n=n!==null?n:sa,n(a,r)&&t.ref===e.ref)return Un(t,e,i)}return e.flags|=1,t=dr(o,r),t.ref=e.ref,t.return=e,e.child=t}function jx(t,e,n,r,i){if(t!==null){var o=t.memoizedProps;if(sa(o,r)&&t.ref===e.ref)if(ge=!1,e.pendingProps=r=o,(t.lanes&i)!==0)t.flags&131072&&(ge=!0);else return e.lanes=t.lanes,Un(t,e,i)}return Xd(t,e,n,r,i)}function Ox(t,e,n){var r=e.pendingProps,i=r.children,o=t!==null?t.memoizedState:null;if(r.mode==="hidden")if(!(e.mode&1))e.memoizedState={baseLanes:0,cachePool:null,transitions:null},mt(Si,Te),Te|=n;else{if(!(n&1073741824))return t=o!==null?o.baseLanes|n:n,e.lanes=e.childLanes=1073741824,e.memoizedState={baseLanes:t,cachePool:null,transitions:null},e.updateQueue=null,mt(Si,Te),Te|=t,null;e.memoizedState={baseLanes:0,cachePool:null,transitions:null},r=o!==null?o.baseLanes:n,mt(Si,Te),Te|=r}else o!==null?(r=o.baseLanes|n,e.memoizedState=null):r=n,mt(Si,Te),Te|=r;return se(t,e,i,n),e.child}function _x(t,e){var n=e.ref;(t===null&&n!==null||t!==null&&t.ref!==n)&&(e.flags|=512,e.flags|=2097152)}function Xd(t,e,n,r,i){var o=ye(n)?Yr:oe.current;return o=Ui(e,o),Fi(e,i),n=af(t,e,n,r,o,i),r=sf(),t!==null&&!ge?(e.updateQueue=t.updateQueue,e.flags&=-2053,t.lanes&=~i,Un(t,e,i)):(wt&&r&&Yp(e),e.flags|=1,se(t,e,n,i),e.child)}function Xg(t,e,n,r,i){if(ye(n)){var o=!0;bl(e)}else o=!1;if(Fi(e,i),e.stateNode===null)Ks(t,e),Rx(e,n,r),Yd(e,n,r,i),r=!0;else if(t===null){var a=e.stateNode,s=e.memoizedProps;a.props=s;var l=a.context,u=n.contextType;typeof u=="object"&&u!==null?u=We(u):(u=ye(n)?Yr:oe.current,u=Ui(e,u));var c=n.getDerivedStateFromProps,d=typeof c=="function"||typeof a.getSnapshotBeforeUpdate=="function";d||typeof a.UNSAFE_componentWillReceiveProps!="function"&&typeof a.componentWillReceiveProps!="function"||(s!==r||l!==u)&&$g(e,a,r,u),Qn=!1;var h=e.memoizedState;a.state=h,Tl(e,r,a,i),l=e.memoizedState,s!==r||h!==l||ve.current||Qn?(typeof c=="function"&&(qd(e,n,c,r),l=e.memoizedState),(s=Qn||Ug(e,n,s,r,h,l,u))?(d||typeof a.UNSAFE_componentWillMount!="function"&&typeof a.componentWillMount!="function"||(typeof a.componentWillMount=="function"&&a.componentWillMount(),typeof a.UNSAFE_componentWillMount=="function"&&a.UNSAFE_componentWillMount()),typeof a.componentDidMount=="function"&&(e.flags|=4194308)):(typeof a.componentDidMount=="function"&&(e.flags|=4194308),e.memoizedProps=r,e.memoizedState=l),a.props=r,a.state=l,a.context=u,r=s):(typeof a.componentDidMount=="function"&&(e.flags|=4194308),r=!1)}else{a=e.stateNode,cx(t,e),s=e.memoizedProps,u=e.type===e.elementType?s:Ge(e.type,s),a.props=u,d=e.pendingProps,h=a.context,l=n.contextType,typeof l=="object"&&l!==null?l=We(l):(l=ye(n)?Yr:oe.current,l=Ui(e,l));var p=n.getDerivedStateFromProps;(c=typeof p=="function"||typeof a.getSnapshotBeforeUpdate=="function")||typeof a.UNSAFE_componentWillReceiveProps!="function"&&typeof a.componentWillReceiveProps!="function"||(s!==d||h!==l)&&$g(e,a,r,l),Qn=!1,h=e.memoizedState,a.state=h,Tl(e,r,a,i);var m=e.memoizedState;s!==d||h!==m||ve.current||Qn?(typeof p=="function"&&(qd(e,n,p,r),m=e.memoizedState),(u=Qn||Ug(e,n,u,r,h,m,l)||!1)?(c||typeof a.UNSAFE_componentWillUpdate!="function"&&typeof a.componentWillUpdate!="function"||(typeof a.componentWillUpdate=="function"&&a.componentWillUpdate(r,m,l),typeof a.UNSAFE_componentWillUpdate=="function"&&a.UNSAFE_componentWillUpdate(r,m,l)),typeof a.componentDidUpdate=="function"&&(e.flags|=4),typeof a.getSnapshotBeforeUpdate=="function"&&(e.flags|=1024)):(typeof a.componentDidUpdate!="function"||s===t.memoizedProps&&h===t.memoizedState||(e.flags|=4),typeof a.getSnapshotBeforeUpdate!="function"||s===t.memoizedProps&&h===t.memoizedState||(e.flags|=1024),e.memoizedProps=r,e.memoizedState=m),a.props=r,a.state=m,a.context=l,r=u):(typeof a.componentDidUpdate!="function"||s===t.memoizedProps&&h===t.memoizedState||(e.flags|=4),typeof a.getSnapshotBeforeUpdate!="function"||s===t.memoizedProps&&h===t.memoizedState||(e.flags|=1024),r=!1)}return Gd(t,e,n,r,o,i)}function Gd(t,e,n,r,i,o){_x(t,e);var a=(e.flags&128)!==0;if(!r&&!a)return i&&jg(e,n,!1),Un(t,e,o);r=e.stateNode,YP.current=e;var s=a&&typeof n.getDerivedStateFromError!="function"?null:r.render();return e.flags|=1,t!==null&&a?(e.child=Hi(e,t.child,null,o),e.child=Hi(e,null,s,o)):se(t,e,s,o),e.memoizedState=r.state,i&&jg(e,n,!0),e.child}function Nx(t){var e=t.stateNode;e.pendingContext?Lg(t,e.pendingContext,e.pendingContext!==e.context):e.context&&Lg(t,e.context,!1),ef(t,e.containerInfo)}function Gg(t,e,n,r,i){return $i(),Xp(i),e.flags|=256,se(t,e,n,r),e.child}var Qd={dehydrated:null,treeContext:null,retryLane:0};function Jd(t){return{baseLanes:t,cachePool:null,transitions:null}}function Fx(t,e,n){var r=e.pendingProps,i=Tt.current,o=!1,a=(e.flags&128)!==0,s;if((s=a)||(s=t!==null&&t.memoizedState===null?!1:(i&2)!==0),s?(o=!0,e.flags&=-129):(t===null||t.memoizedState!==null)&&(i|=1),mt(Tt,i&1),t===null)return Hd(e),t=e.memoizedState,t!==null&&(t=t.dehydrated,t!==null)?(e.mode&1?t.data==="$!"?e.lanes=8:e.lanes=1073741824:e.lanes=1,null):(a=r.children,t=r.fallback,o?(r=e.mode,o=e.child,a={mode:"hidden",children:a},!(r&1)&&o!==null?(o.childLanes=0,o.pendingProps=a):o=Su(a,r,0,null),t=$r(t,r,n,null),o.return=e,t.return=e,o.sibling=t,e.child=o,e.child.memoizedState=Jd(n),e.memoizedState=Qd,t):cf(e,a));if(i=t.memoizedState,i!==null&&(s=i.dehydrated,s!==null))return KP(t,e,a,r,s,i,n);if(o){o=r.fallback,a=e.mode,i=t.child,s=i.sibling;var l={mode:"hidden",children:r.children};return!(a&1)&&e.child!==i?(r=e.child,r.childLanes=0,r.pendingProps=l,e.deletions=null):(r=dr(i,l),r.subtreeFlags=i.subtreeFlags&14680064),s!==null?o=dr(s,o):(o=$r(o,a,n,null),o.flags|=2),o.return=e,r.return=e,r.sibling=o,e.child=r,r=o,o=e.child,a=t.child.memoizedState,a=a===null?Jd(n):{baseLanes:a.baseLanes|n,cachePool:null,transitions:a.transitions},o.memoizedState=a,o.childLanes=t.childLanes&~n,e.memoizedState=Qd,r}return o=t.child,t=o.sibling,r=dr(o,{mode:"visible",children:r.children}),!(e.mode&1)&&(r.lanes=n),r.return=e,r.sibling=null,t!==null&&(n=e.deletions,n===null?(e.deletions=[t],e.flags|=16):n.push(t)),e.child=r,e.memoizedState=null,r}function cf(t,e){return e=Su({mode:"visible",children:e},t.mode,0,null),e.return=t,t.child=e}function Ss(t,e,n,r){return r!==null&&Xp(r),Hi(e,t.child,null,n),t=cf(e,e.pendingProps.children),t.flags|=2,e.memoizedState=null,t}function KP(t,e,n,r,i,o,a){if(n)return e.flags&256?(e.flags&=-257,r=vc(Error(j(422))),Ss(t,e,a,r)):e.memoizedState!==null?(e.child=t.child,e.flags|=128,null):(o=r.fallback,i=e.mode,r=Su({mode:"visible",children:r.children},i,0,null),o=$r(o,i,a,null),o.flags|=2,r.return=e,o.return=e,r.sibling=o,e.child=r,e.mode&1&&Hi(e,t.child,null,a),e.child.memoizedState=Jd(a),e.memoizedState=Qd,o);if(!(e.mode&1))return Ss(t,e,a,null);if(i.data==="$!"){if(r=i.nextSibling&&i.nextSibling.dataset,r)var s=r.dgst;return r=s,o=Error(j(419)),r=vc(o,r,void 0),Ss(t,e,a,r)}if(s=(a&t.childLanes)!==0,ge||s){if(r=Bt,r!==null){switch(a&-a){case 4:i=2;break;case 16:i=8;break;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:i=32;break;case 536870912:i=268435456;break;default:i=0}i=i&(r.suspendedLanes|a)?0:i,i!==0&&i!==o.retryLane&&(o.retryLane=i,Bn(t,i),tn(r,t,i,-1))}return gf(),r=vc(Error(j(421))),Ss(t,e,a,r)}return i.data==="$?"?(e.flags|=128,e.child=t.child,e=s2.bind(null,t),i._reactRetry=e,null):(t=o.treeContext,Ee=sr(i.nextSibling),Pe=e,wt=!0,Je=null,t!==null&&(Ve[ze++]=Cn,Ve[ze++]=Pn,Ve[ze++]=Kr,Cn=t.id,Pn=t.overflow,Kr=e),e=cf(e,r.children),e.flags|=4096,e)}function Qg(t,e,n){t.lanes|=e;var r=t.alternate;r!==null&&(r.lanes|=e),Wd(t.return,e,n)}function yc(t,e,n,r,i){var o=t.memoizedState;o===null?t.memoizedState={isBackwards:e,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:i}:(o.isBackwards=e,o.rendering=null,o.renderingStartTime=0,o.last=r,o.tail=n,o.tailMode=i)}function Vx(t,e,n){var r=e.pendingProps,i=r.revealOrder,o=r.tail;if(se(t,e,r.children,n),r=Tt.current,r&2)r=r&1|2,e.flags|=128;else{if(t!==null&&t.flags&128)t:for(t=e.child;t!==null;){if(t.tag===13)t.memoizedState!==null&&Qg(t,n,e);else if(t.tag===19)Qg(t,n,e);else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break t;for(;t.sibling===null;){if(t.return===null||t.return===e)break t;t=t.return}t.sibling.return=t.return,t=t.sibling}r&=1}if(mt(Tt,r),!(e.mode&1))e.memoizedState=null;else switch(i){case"forwards":for(n=e.child,i=null;n!==null;)t=n.alternate,t!==null&&El(t)===null&&(i=n),n=n.sibling;n=i,n===null?(i=e.child,e.child=null):(i=n.sibling,n.sibling=null),yc(e,!1,i,n,o);break;case"backwards":for(n=null,i=e.child,e.child=null;i!==null;){if(t=i.alternate,t!==null&&El(t)===null){e.child=i;break}t=i.sibling,i.sibling=n,n=i,i=t}yc(e,!0,n,null,o);break;case"together":yc(e,!1,null,null,void 0);break;default:e.memoizedState=null}return e.child}function Ks(t,e){!(e.mode&1)&&t!==null&&(t.alternate=null,e.alternate=null,e.flags|=2)}function Un(t,e,n){if(t!==null&&(e.dependencies=t.dependencies),Gr|=e.lanes,!(n&e.childLanes))return null;if(t!==null&&e.child!==t.child)throw Error(j(153));if(e.child!==null){for(t=e.child,n=dr(t,t.pendingProps),e.child=n,n.return=e;t.sibling!==null;)t=t.sibling,n=n.sibling=dr(t,t.pendingProps),n.return=e;n.sibling=null}return e.child}function XP(t,e,n){switch(e.tag){case 3:Nx(e),$i();break;case 5:dx(e);break;case 1:ye(e.type)&&bl(e);break;case 4:ef(e,e.stateNode.containerInfo);break;case 10:var r=e.type._context,i=e.memoizedProps.value;mt(kl,r._currentValue),r._currentValue=i;break;case 13:if(r=e.memoizedState,r!==null)return r.dehydrated!==null?(mt(Tt,Tt.current&1),e.flags|=128,null):n&e.child.childLanes?Fx(t,e,n):(mt(Tt,Tt.current&1),t=Un(t,e,n),t!==null?t.sibling:null);mt(Tt,Tt.current&1);break;case 19:if(r=(n&e.childLanes)!==0,t.flags&128){if(r)return Vx(t,e,n);e.flags|=128}if(i=e.memoizedState,i!==null&&(i.rendering=null,i.tail=null,i.lastEffect=null),mt(Tt,Tt.current),r)break;return null;case 22:case 23:return e.lanes=0,Ox(t,e,n)}return Un(t,e,n)}var zx,Zd,Bx,Ux;zx=function(t,e){for(var n=e.child;n!==null;){if(n.tag===5||n.tag===6)t.appendChild(n.stateNode);else if(n.tag!==4&&n.child!==null){n.child.return=n,n=n.child;continue}if(n===e)break;for(;n.sibling===null;){if(n.return===null||n.return===e)return;n=n.return}n.sibling.return=n.return,n=n.sibling}};Zd=function(){};Bx=function(t,e,n,r){var i=t.memoizedProps;if(i!==r){t=e.stateNode,Vr(hn.current);var o=null;switch(n){case"input":i=wd(t,i),r=wd(t,r),o=[];break;case"select":i=At({},i,{value:void 0}),r=At({},r,{value:void 0}),o=[];break;case"textarea":i=Td(t,i),r=Td(t,r),o=[];break;default:typeof i.onClick!="function"&&typeof r.onClick=="function"&&(t.onclick=vl)}Cd(n,r);var a;n=null;for(u in i)if(!r.hasOwnProperty(u)&&i.hasOwnProperty(u)&&i[u]!=null)if(u==="style"){var s=i[u];for(a in s)s.hasOwnProperty(a)&&(n||(n={}),n[a]="")}else u!=="dangerouslySetInnerHTML"&&u!=="children"&&u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&u!=="autoFocus"&&(ta.hasOwnProperty(u)?o||(o=[]):(o=o||[]).push(u,null));for(u in r){var l=r[u];if(s=i?.[u],r.hasOwnProperty(u)&&l!==s&&(l!=null||s!=null))if(u==="style")if(s){for(a in s)!s.hasOwnProperty(a)||l&&l.hasOwnProperty(a)||(n||(n={}),n[a]="");for(a in l)l.hasOwnProperty(a)&&s[a]!==l[a]&&(n||(n={}),n[a]=l[a])}else n||(o||(o=[]),o.push(u,n)),n=l;else u==="dangerouslySetInnerHTML"?(l=l?l.__html:void 0,s=s?s.__html:void 0,l!=null&&s!==l&&(o=o||[]).push(u,l)):u==="children"?typeof l!="string"&&typeof l!="number"||(o=o||[]).push(u,""+l):u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&(ta.hasOwnProperty(u)?(l!=null&&u==="onScroll"&&vt("scroll",t),o||s===l||(o=[])):(o=o||[]).push(u,l))}n&&(o=o||[]).push("style",n);var u=o;(e.updateQueue=u)&&(e.flags|=4)}};Ux=function(t,e,n,r){n!==r&&(e.flags|=4)};function xo(t,e){if(!wt)switch(t.tailMode){case"hidden":e=t.tail;for(var n=null;e!==null;)e.alternate!==null&&(n=e),e=e.sibling;n===null?t.tail=null:n.sibling=null;break;case"collapsed":n=t.tail;for(var r=null;n!==null;)n.alternate!==null&&(r=n),n=n.sibling;r===null?e||t.tail===null?t.tail=null:t.tail.sibling=null:r.sibling=null}}function Gt(t){var e=t.alternate!==null&&t.alternate.child===t.child,n=0,r=0;if(e)for(var i=t.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags&14680064,r|=i.flags&14680064,i.return=t,i=i.sibling;else for(i=t.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags,r|=i.flags,i.return=t,i=i.sibling;return t.subtreeFlags|=r,t.childLanes=n,e}function GP(t,e,n){var r=e.pendingProps;switch(Kp(e),e.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Gt(e),null;case 1:return ye(e.type)&&yl(),Gt(e),null;case 3:return r=e.stateNode,Wi(),yt(ve),yt(oe),rf(),r.pendingContext&&(r.context=r.pendingContext,r.pendingContext=null),(t===null||t.child===null)&&(ws(e)?e.flags|=4:t===null||t.memoizedState.isDehydrated&&!(e.flags&256)||(e.flags|=1024,Je!==null&&(ah(Je),Je=null))),Zd(t,e),Gt(e),null;case 5:nf(e);var i=Vr(ha.current);if(n=e.type,t!==null&&e.stateNode!=null)Bx(t,e,n,r,i),t.ref!==e.ref&&(e.flags|=512,e.flags|=2097152);else{if(!r){if(e.stateNode===null)throw Error(j(166));return Gt(e),null}if(t=Vr(hn.current),ws(e)){r=e.stateNode,n=e.type;var o=e.memoizedProps;switch(r[un]=e,r[ca]=o,t=(e.mode&1)!==0,n){case"dialog":vt("cancel",r),vt("close",r);break;case"iframe":case"object":case"embed":vt("load",r);break;case"video":case"audio":for(i=0;i<Io.length;i++)vt(Io[i],r);break;case"source":vt("error",r);break;case"img":case"image":case"link":vt("error",r),vt("load",r);break;case"details":vt("toggle",r);break;case"input":og(r,o),vt("invalid",r);break;case"select":r._wrapperState={wasMultiple:!!o.multiple},vt("invalid",r);break;case"textarea":sg(r,o),vt("invalid",r)}Cd(n,o),i=null;for(var a in o)if(o.hasOwnProperty(a)){var s=o[a];a==="children"?typeof s=="string"?r.textContent!==s&&(o.suppressHydrationWarning!==!0&&xs(r.textContent,s,t),i=["children",s]):typeof s=="number"&&r.textContent!==""+s&&(o.suppressHydrationWarning!==!0&&xs(r.textContent,s,t),i=["children",""+s]):ta.hasOwnProperty(a)&&s!=null&&a==="onScroll"&&vt("scroll",r)}switch(n){case"input":ls(r),ag(r,o,!0);break;case"textarea":ls(r),lg(r);break;case"select":case"option":break;default:typeof o.onClick=="function"&&(r.onclick=vl)}r=i,e.updateQueue=r,r!==null&&(e.flags|=4)}else{a=i.nodeType===9?i:i.ownerDocument,t==="http://www.w3.org/1999/xhtml"&&(t=gb(n)),t==="http://www.w3.org/1999/xhtml"?n==="script"?(t=a.createElement("div"),t.innerHTML="<script><\/script>",t=t.removeChild(t.firstChild)):typeof r.is=="string"?t=a.createElement(n,{is:r.is}):(t=a.createElement(n),n==="select"&&(a=t,r.multiple?a.multiple=!0:r.size&&(a.size=r.size))):t=a.createElementNS(t,n),t[un]=e,t[ca]=r,zx(t,e,!1,!1),e.stateNode=t;t:{switch(a=Pd(n,r),n){case"dialog":vt("cancel",t),vt("close",t),i=r;break;case"iframe":case"object":case"embed":vt("load",t),i=r;break;case"video":case"audio":for(i=0;i<Io.length;i++)vt(Io[i],t);i=r;break;case"source":vt("error",t),i=r;break;case"img":case"image":case"link":vt("error",t),vt("load",t),i=r;break;case"details":vt("toggle",t),i=r;break;case"input":og(t,r),i=wd(t,r),vt("invalid",t);break;case"option":i=r;break;case"select":t._wrapperState={wasMultiple:!!r.multiple},i=At({},r,{value:void 0}),vt("invalid",t);break;case"textarea":sg(t,r),i=Td(t,r),vt("invalid",t);break;default:i=r}Cd(n,i),s=i;for(o in s)if(s.hasOwnProperty(o)){var l=s[o];o==="style"?bb(t,l):o==="dangerouslySetInnerHTML"?(l=l?l.__html:void 0,l!=null&&vb(t,l)):o==="children"?typeof l=="string"?(n!=="textarea"||l!=="")&&ea(t,l):typeof l=="number"&&ea(t,""+l):o!=="suppressContentEditableWarning"&&o!=="suppressHydrationWarning"&&o!=="autoFocus"&&(ta.hasOwnProperty(o)?l!=null&&o==="onScroll"&&vt("scroll",t):l!=null&&Lp(t,o,l,a))}switch(n){case"input":ls(t),ag(t,r,!1);break;case"textarea":ls(t),lg(t);break;case"option":r.value!=null&&t.setAttribute("value",""+hr(r.value));break;case"select":t.multiple=!!r.multiple,o=r.value,o!=null?ji(t,!!r.multiple,o,!1):r.defaultValue!=null&&ji(t,!!r.multiple,r.defaultValue,!0);break;default:typeof i.onClick=="function"&&(t.onclick=vl)}switch(n){case"button":case"input":case"select":case"textarea":r=!!r.autoFocus;break t;case"img":r=!0;break t;default:r=!1}}r&&(e.flags|=4)}e.ref!==null&&(e.flags|=512,e.flags|=2097152)}return Gt(e),null;case 6:if(t&&e.stateNode!=null)Ux(t,e,t.memoizedProps,r);else{if(typeof r!="string"&&e.stateNode===null)throw Error(j(166));if(n=Vr(ha.current),Vr(hn.current),ws(e)){if(r=e.stateNode,n=e.memoizedProps,r[un]=e,(o=r.nodeValue!==n)&&(t=Pe,t!==null))switch(t.tag){case 3:xs(r.nodeValue,n,(t.mode&1)!==0);break;case 5:t.memoizedProps.suppressHydrationWarning!==!0&&xs(r.nodeValue,n,(t.mode&1)!==0)}o&&(e.flags|=4)}else r=(n.nodeType===9?n:n.ownerDocument).createTextNode(r),r[un]=e,e.stateNode=r}return Gt(e),null;case 13:if(yt(Tt),r=e.memoizedState,t===null||t.memoizedState!==null&&t.memoizedState.dehydrated!==null){if(wt&&Ee!==null&&e.mode&1&&!(e.flags&128))ax(),$i(),e.flags|=98560,o=!1;else if(o=ws(e),r!==null&&r.dehydrated!==null){if(t===null){if(!o)throw Error(j(318));if(o=e.memoizedState,o=o!==null?o.dehydrated:null,!o)throw Error(j(317));o[un]=e}else $i(),!(e.flags&128)&&(e.memoizedState=null),e.flags|=4;Gt(e),o=!1}else Je!==null&&(ah(Je),Je=null),o=!0;if(!o)return e.flags&65536?e:null}return e.flags&128?(e.lanes=n,e):(r=r!==null,r!==(t!==null&&t.memoizedState!==null)&&r&&(e.child.flags|=8192,e.mode&1&&(t===null||Tt.current&1?Ft===0&&(Ft=3):gf())),e.updateQueue!==null&&(e.flags|=4),Gt(e),null);case 4:return Wi(),Zd(t,e),t===null&&la(e.stateNode.containerInfo),Gt(e),null;case 10:return Jp(e.type._context),Gt(e),null;case 17:return ye(e.type)&&yl(),Gt(e),null;case 19:if(yt(Tt),o=e.memoizedState,o===null)return Gt(e),null;if(r=(e.flags&128)!==0,a=o.rendering,a===null)if(r)xo(o,!1);else{if(Ft!==0||t!==null&&t.flags&128)for(t=e.child;t!==null;){if(a=El(t),a!==null){for(e.flags|=128,xo(o,!1),r=a.updateQueue,r!==null&&(e.updateQueue=r,e.flags|=4),e.subtreeFlags=0,r=n,n=e.child;n!==null;)o=n,t=r,o.flags&=14680066,a=o.alternate,a===null?(o.childLanes=0,o.lanes=t,o.child=null,o.subtreeFlags=0,o.memoizedProps=null,o.memoizedState=null,o.updateQueue=null,o.dependencies=null,o.stateNode=null):(o.childLanes=a.childLanes,o.lanes=a.lanes,o.child=a.child,o.subtreeFlags=0,o.deletions=null,o.memoizedProps=a.memoizedProps,o.memoizedState=a.memoizedState,o.updateQueue=a.updateQueue,o.type=a.type,t=a.dependencies,o.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext}),n=n.sibling;return mt(Tt,Tt.current&1|2),e.child}t=t.sibling}o.tail!==null&&Lt()>Yi&&(e.flags|=128,r=!0,xo(o,!1),e.lanes=4194304)}else{if(!r)if(t=El(a),t!==null){if(e.flags|=128,r=!0,n=t.updateQueue,n!==null&&(e.updateQueue=n,e.flags|=4),xo(o,!0),o.tail===null&&o.tailMode==="hidden"&&!a.alternate&&!wt)return Gt(e),null}else 2*Lt()-o.renderingStartTime>Yi&&n!==1073741824&&(e.flags|=128,r=!0,xo(o,!1),e.lanes=4194304);o.isBackwards?(a.sibling=e.child,e.child=a):(n=o.last,n!==null?n.sibling=a:e.child=a,o.last=a)}return o.tail!==null?(e=o.tail,o.rendering=e,o.tail=e.sibling,o.renderingStartTime=Lt(),e.sibling=null,n=Tt.current,mt(Tt,r?n&1|2:n&1),e):(Gt(e),null);case 22:case 23:return mf(),r=e.memoizedState!==null,t!==null&&t.memoizedState!==null!==r&&(e.flags|=8192),r&&e.mode&1?Te&1073741824&&(Gt(e),e.subtreeFlags&6&&(e.flags|=8192)):Gt(e),null;case 24:return null;case 25:return null}throw Error(j(156,e.tag))}function QP(t,e){switch(Kp(e),e.tag){case 1:return ye(e.type)&&yl(),t=e.flags,t&65536?(e.flags=t&-65537|128,e):null;case 3:return Wi(),yt(ve),yt(oe),rf(),t=e.flags,t&65536&&!(t&128)?(e.flags=t&-65537|128,e):null;case 5:return nf(e),null;case 13:if(yt(Tt),t=e.memoizedState,t!==null&&t.dehydrated!==null){if(e.alternate===null)throw Error(j(340));$i()}return t=e.flags,t&65536?(e.flags=t&-65537|128,e):null;case 19:return yt(Tt),null;case 4:return Wi(),null;case 10:return Jp(e.type._context),null;case 22:case 23:return mf(),null;case 24:return null;default:return null}}var Ts=!1,Zt=!1,JP=typeof WeakSet=="function"?WeakSet:Set,V=null;function ki(t,e){var n=t.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){Dt(t,e,r)}else n.current=null}function $x(t,e,n){try{n()}catch(r){Dt(t,e,r)}}var Jg=!1;function ZP(t,e){if(Nd=fl,t=Yb(),qp(t)){if("selectionStart"in t)var n={start:t.selectionStart,end:t.selectionEnd};else t:{n=(n=t.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var i=r.anchorOffset,o=r.focusNode;r=r.focusOffset;try{n.nodeType,o.nodeType}catch{n=null;break t}var a=0,s=-1,l=-1,u=0,c=0,d=t,h=null;e:for(;;){for(var p;d!==n||i!==0&&d.nodeType!==3||(s=a+i),d!==o||r!==0&&d.nodeType!==3||(l=a+r),d.nodeType===3&&(a+=d.nodeValue.length),(p=d.firstChild)!==null;)h=d,d=p;for(;;){if(d===t)break e;if(h===n&&++u===i&&(s=a),h===o&&++c===r&&(l=a),(p=d.nextSibling)!==null)break;d=h,h=d.parentNode}d=p}n=s===-1||l===-1?null:{start:s,end:l}}else n=null}n=n||{start:0,end:0}}else n=null;for(Fd={focusedElem:t,selectionRange:n},fl=!1,V=e;V!==null;)if(e=V,t=e.child,(e.subtreeFlags&1028)!==0&&t!==null)t.return=e,V=t;else for(;V!==null;){e=V;try{var m=e.alternate;if(e.flags&1024)switch(e.tag){case 0:case 11:case 15:break;case 1:if(m!==null){var v=m.memoizedProps,b=m.memoizedState,f=e.stateNode,g=f.getSnapshotBeforeUpdate(e.elementType===e.type?v:Ge(e.type,v),b);f.__reactInternalSnapshotBeforeUpdate=g}break;case 3:var y=e.stateNode.containerInfo;y.nodeType===1?y.textContent="":y.nodeType===9&&y.documentElement&&y.removeChild(y.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(j(163))}}catch(w){Dt(e,e.return,w)}if(t=e.sibling,t!==null){t.return=e.return,V=t;break}V=e.return}return m=Jg,Jg=!1,m}function $o(t,e,n){var r=e.updateQueue;if(r=r!==null?r.lastEffect:null,r!==null){var i=r=r.next;do{if((i.tag&t)===t){var o=i.destroy;i.destroy=void 0,o!==void 0&&$x(e,n,o)}i=i.next}while(i!==r)}}function wu(t,e){if(e=e.updateQueue,e=e!==null?e.lastEffect:null,e!==null){var n=e=e.next;do{if((n.tag&t)===t){var r=n.create;n.destroy=r()}n=n.next}while(n!==e)}}function th(t){var e=t.ref;if(e!==null){var n=t.stateNode;switch(t.tag){case 5:t=n;break;default:t=n}typeof e=="function"?e(t):e.current=t}}function Hx(t){var e=t.alternate;e!==null&&(t.alternate=null,Hx(e)),t.child=null,t.deletions=null,t.sibling=null,t.tag===5&&(e=t.stateNode,e!==null&&(delete e[un],delete e[ca],delete e[Bd],delete e[OP],delete e[_P])),t.stateNode=null,t.return=null,t.dependencies=null,t.memoizedProps=null,t.memoizedState=null,t.pendingProps=null,t.stateNode=null,t.updateQueue=null}function Wx(t){return t.tag===5||t.tag===3||t.tag===4}function Zg(t){t:for(;;){for(;t.sibling===null;){if(t.return===null||Wx(t.return))return null;t=t.return}for(t.sibling.return=t.return,t=t.sibling;t.tag!==5&&t.tag!==6&&t.tag!==18;){if(t.flags&2||t.child===null||t.tag===4)continue t;t.child.return=t,t=t.child}if(!(t.flags&2))return t.stateNode}}function eh(t,e,n){var r=t.tag;if(r===5||r===6)t=t.stateNode,e?n.nodeType===8?n.parentNode.insertBefore(t,e):n.insertBefore(t,e):(n.nodeType===8?(e=n.parentNode,e.insertBefore(t,n)):(e=n,e.appendChild(t)),n=n._reactRootContainer,n!=null||e.onclick!==null||(e.onclick=vl));else if(r!==4&&(t=t.child,t!==null))for(eh(t,e,n),t=t.sibling;t!==null;)eh(t,e,n),t=t.sibling}function nh(t,e,n){var r=t.tag;if(r===5||r===6)t=t.stateNode,e?n.insertBefore(t,e):n.appendChild(t);else if(r!==4&&(t=t.child,t!==null))for(nh(t,e,n),t=t.sibling;t!==null;)nh(t,e,n),t=t.sibling}var $t=null,Qe=!1;function qn(t,e,n){for(n=n.child;n!==null;)qx(t,e,n),n=n.sibling}function qx(t,e,n){if(dn&&typeof dn.onCommitFiberUnmount=="function")try{dn.onCommitFiberUnmount(pu,n)}catch{}switch(n.tag){case 5:Zt||ki(n,e);case 6:var r=$t,i=Qe;$t=null,qn(t,e,n),$t=r,Qe=i,$t!==null&&(Qe?(t=$t,n=n.stateNode,t.nodeType===8?t.parentNode.removeChild(n):t.removeChild(n)):$t.removeChild(n.stateNode));break;case 18:$t!==null&&(Qe?(t=$t,n=n.stateNode,t.nodeType===8?dc(t.parentNode,n):t.nodeType===1&&dc(t,n),oa(t)):dc($t,n.stateNode));break;case 4:r=$t,i=Qe,$t=n.stateNode.containerInfo,Qe=!0,qn(t,e,n),$t=r,Qe=i;break;case 0:case 11:case 14:case 15:if(!Zt&&(r=n.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){i=r=r.next;do{var o=i,a=o.destroy;o=o.tag,a!==void 0&&(o&2||o&4)&&$x(n,e,a),i=i.next}while(i!==r)}qn(t,e,n);break;case 1:if(!Zt&&(ki(n,e),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(s){Dt(n,e,s)}qn(t,e,n);break;case 21:qn(t,e,n);break;case 22:n.mode&1?(Zt=(r=Zt)||n.memoizedState!==null,qn(t,e,n),Zt=r):qn(t,e,n);break;default:qn(t,e,n)}}function tv(t){var e=t.updateQueue;if(e!==null){t.updateQueue=null;var n=t.stateNode;n===null&&(n=t.stateNode=new JP),e.forEach(function(r){var i=l2.bind(null,t,r);n.has(r)||(n.add(r),r.then(i,i))})}}function Xe(t,e){var n=e.deletions;if(n!==null)for(var r=0;r<n.length;r++){var i=n[r];try{var o=t,a=e,s=a;t:for(;s!==null;){switch(s.tag){case 5:$t=s.stateNode,Qe=!1;break t;case 3:$t=s.stateNode.containerInfo,Qe=!0;break t;case 4:$t=s.stateNode.containerInfo,Qe=!0;break t}s=s.return}if($t===null)throw Error(j(160));qx(o,a,i),$t=null,Qe=!1;var l=i.alternate;l!==null&&(l.return=null),i.return=null}catch(u){Dt(i,e,u)}}if(e.subtreeFlags&12854)for(e=e.child;e!==null;)Yx(e,t),e=e.sibling}function Yx(t,e){var n=t.alternate,r=t.flags;switch(t.tag){case 0:case 11:case 14:case 15:if(Xe(e,t),an(t),r&4){try{$o(3,t,t.return),wu(3,t)}catch(v){Dt(t,t.return,v)}try{$o(5,t,t.return)}catch(v){Dt(t,t.return,v)}}break;case 1:Xe(e,t),an(t),r&512&&n!==null&&ki(n,n.return);break;case 5:if(Xe(e,t),an(t),r&512&&n!==null&&ki(n,n.return),t.flags&32){var i=t.stateNode;try{ea(i,"")}catch(v){Dt(t,t.return,v)}}if(r&4&&(i=t.stateNode,i!=null)){var o=t.memoizedProps,a=n!==null?n.memoizedProps:o,s=t.type,l=t.updateQueue;if(t.updateQueue=null,l!==null)try{s==="input"&&o.type==="radio"&&o.name!=null&&fb(i,o),Pd(s,a);var u=Pd(s,o);for(a=0;a<l.length;a+=2){var c=l[a],d=l[a+1];c==="style"?bb(i,d):c==="dangerouslySetInnerHTML"?vb(i,d):c==="children"?ea(i,d):Lp(i,c,d,u)}switch(s){case"input":kd(i,o);break;case"textarea":mb(i,o);break;case"select":var h=i._wrapperState.wasMultiple;i._wrapperState.wasMultiple=!!o.multiple;var p=o.value;p!=null?ji(i,!!o.multiple,p,!1):h!==!!o.multiple&&(o.defaultValue!=null?ji(i,!!o.multiple,o.defaultValue,!0):ji(i,!!o.multiple,o.multiple?[]:"",!1))}i[ca]=o}catch(v){Dt(t,t.return,v)}}break;case 6:if(Xe(e,t),an(t),r&4){if(t.stateNode===null)throw Error(j(162));i=t.stateNode,o=t.memoizedProps;try{i.nodeValue=o}catch(v){Dt(t,t.return,v)}}break;case 3:if(Xe(e,t),an(t),r&4&&n!==null&&n.memoizedState.isDehydrated)try{oa(e.containerInfo)}catch(v){Dt(t,t.return,v)}break;case 4:Xe(e,t),an(t);break;case 13:Xe(e,t),an(t),i=t.child,i.flags&8192&&(o=i.memoizedState!==null,i.stateNode.isHidden=o,!o||i.alternate!==null&&i.alternate.memoizedState!==null||(pf=Lt())),r&4&&tv(t);break;case 22:if(c=n!==null&&n.memoizedState!==null,t.mode&1?(Zt=(u=Zt)||c,Xe(e,t),Zt=u):Xe(e,t),an(t),r&8192){if(u=t.memoizedState!==null,(t.stateNode.isHidden=u)&&!c&&t.mode&1)for(V=t,c=t.child;c!==null;){for(d=V=c;V!==null;){switch(h=V,p=h.child,h.tag){case 0:case 11:case 14:case 15:$o(4,h,h.return);break;case 1:ki(h,h.return);var m=h.stateNode;if(typeof m.componentWillUnmount=="function"){r=h,n=h.return;try{e=r,m.props=e.memoizedProps,m.state=e.memoizedState,m.componentWillUnmount()}catch(v){Dt(r,n,v)}}break;case 5:ki(h,h.return);break;case 22:if(h.memoizedState!==null){nv(d);continue}}p!==null?(p.return=h,V=p):nv(d)}c=c.sibling}t:for(c=null,d=t;;){if(d.tag===5){if(c===null){c=d;try{i=d.stateNode,u?(o=i.style,typeof o.setProperty=="function"?o.setProperty("display","none","important"):o.display="none"):(s=d.stateNode,l=d.memoizedProps.style,a=l!=null&&l.hasOwnProperty("display")?l.display:null,s.style.display=yb("display",a))}catch(v){Dt(t,t.return,v)}}}else if(d.tag===6){if(c===null)try{d.stateNode.nodeValue=u?"":d.memoizedProps}catch(v){Dt(t,t.return,v)}}else if((d.tag!==22&&d.tag!==23||d.memoizedState===null||d===t)&&d.child!==null){d.child.return=d,d=d.child;continue}if(d===t)break t;for(;d.sibling===null;){if(d.return===null||d.return===t)break t;c===d&&(c=null),d=d.return}c===d&&(c=null),d.sibling.return=d.return,d=d.sibling}}break;case 19:Xe(e,t),an(t),r&4&&tv(t);break;case 21:break;default:Xe(e,t),an(t)}}function an(t){var e=t.flags;if(e&2){try{t:{for(var n=t.return;n!==null;){if(Wx(n)){var r=n;break t}n=n.return}throw Error(j(160))}switch(r.tag){case 5:var i=r.stateNode;r.flags&32&&(ea(i,""),r.flags&=-33);var o=Zg(t);nh(t,o,i);break;case 3:case 4:var a=r.stateNode.containerInfo,s=Zg(t);eh(t,s,a);break;default:throw Error(j(161))}}catch(l){Dt(t,t.return,l)}t.flags&=-3}e&4096&&(t.flags&=-4097)}function t2(t,e,n){V=t,Kx(t)}function Kx(t,e,n){for(var r=(t.mode&1)!==0;V!==null;){var i=V,o=i.child;if(i.tag===22&&r){var a=i.memoizedState!==null||Ts;if(!a){var s=i.alternate,l=s!==null&&s.memoizedState!==null||Zt;s=Ts;var u=Zt;if(Ts=a,(Zt=l)&&!u)for(V=i;V!==null;)a=V,l=a.child,a.tag===22&&a.memoizedState!==null?rv(i):l!==null?(l.return=a,V=l):rv(i);for(;o!==null;)V=o,Kx(o),o=o.sibling;V=i,Ts=s,Zt=u}ev(t)}else i.subtreeFlags&8772&&o!==null?(o.return=i,V=o):ev(t)}}function ev(t){for(;V!==null;){var e=V;if(e.flags&8772){var n=e.alternate;try{if(e.flags&8772)switch(e.tag){case 0:case 11:case 15:Zt||wu(5,e);break;case 1:var r=e.stateNode;if(e.flags&4&&!Zt)if(n===null)r.componentDidMount();else{var i=e.elementType===e.type?n.memoizedProps:Ge(e.type,n.memoizedProps);r.componentDidUpdate(i,n.memoizedState,r.__reactInternalSnapshotBeforeUpdate)}var o=e.updateQueue;o!==null&&Vg(e,o,r);break;case 3:var a=e.updateQueue;if(a!==null){if(n=null,e.child!==null)switch(e.child.tag){case 5:n=e.child.stateNode;break;case 1:n=e.child.stateNode}Vg(e,a,n)}break;case 5:var s=e.stateNode;if(n===null&&e.flags&4){n=s;var l=e.memoizedProps;switch(e.type){case"button":case"input":case"select":case"textarea":l.autoFocus&&n.focus();break;case"img":l.src&&(n.src=l.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(e.memoizedState===null){var u=e.alternate;if(u!==null){var c=u.memoizedState;if(c!==null){var d=c.dehydrated;d!==null&&oa(d)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(j(163))}Zt||e.flags&512&&th(e)}catch(h){Dt(e,e.return,h)}}if(e===t){V=null;break}if(n=e.sibling,n!==null){n.return=e.return,V=n;break}V=e.return}}function nv(t){for(;V!==null;){var e=V;if(e===t){V=null;break}var n=e.sibling;if(n!==null){n.return=e.return,V=n;break}V=e.return}}function rv(t){for(;V!==null;){var e=V;try{switch(e.tag){case 0:case 11:case 15:var n=e.return;try{wu(4,e)}catch(l){Dt(e,n,l)}break;case 1:var r=e.stateNode;if(typeof r.componentDidMount=="function"){var i=e.return;try{r.componentDidMount()}catch(l){Dt(e,i,l)}}var o=e.return;try{th(e)}catch(l){Dt(e,o,l)}break;case 5:var a=e.return;try{th(e)}catch(l){Dt(e,a,l)}}}catch(l){Dt(e,e.return,l)}if(e===t){V=null;break}var s=e.sibling;if(s!==null){s.return=e.return,V=s;break}V=e.return}}var e2=Math.ceil,Al=Hn.ReactCurrentDispatcher,df=Hn.ReactCurrentOwner,$e=Hn.ReactCurrentBatchConfig,ot=0,Bt=null,Ot=null,qt=0,Te=0,Si=kr(0),Ft=0,ga=null,Gr=0,ku=0,hf=0,Ho=null,fe=null,pf=0,Yi=1/0,Sn=null,Ml=!1,rh=null,ur=null,Es=!1,nr=null,Dl=0,Wo=0,ih=null,Xs=-1,Gs=0;function ue(){return ot&6?Lt():Xs!==-1?Xs:Xs=Lt()}function cr(t){return t.mode&1?ot&2&&qt!==0?qt&-qt:FP.transition!==null?(Gs===0&&(Gs=Rb()),Gs):(t=ut,t!==0||(t=window.event,t=t===void 0?16:Fb(t.type)),t):1}function tn(t,e,n,r){if(50<Wo)throw Wo=0,ih=null,Error(j(185));Ha(t,n,r),(!(ot&2)||t!==Bt)&&(t===Bt&&(!(ot&2)&&(ku|=n),Ft===4&&Zn(t,qt)),be(t,r),n===1&&ot===0&&!(e.mode&1)&&(Yi=Lt()+500,yu&&Sr()))}function be(t,e){var n=t.callbackNode;zC(t,e);var r=pl(t,t===Bt?qt:0);if(r===0)n!==null&&dg(n),t.callbackNode=null,t.callbackPriority=0;else if(e=r&-r,t.callbackPriority!==e){if(n!=null&&dg(n),e===1)t.tag===0?NP(iv.bind(null,t)):rx(iv.bind(null,t)),LP(function(){!(ot&6)&&Sr()}),n=null;else{switch(Ib(r)){case 1:n=Fp;break;case 4:n=Mb;break;case 16:n=hl;break;case 536870912:n=Db;break;default:n=hl}n=nw(n,Xx.bind(null,t))}t.callbackPriority=e,t.callbackNode=n}}function Xx(t,e){if(Xs=-1,Gs=0,ot&6)throw Error(j(327));var n=t.callbackNode;if(Vi()&&t.callbackNode!==n)return null;var r=pl(t,t===Bt?qt:0);if(r===0)return null;if(r&30||r&t.expiredLanes||e)e=Rl(t,r);else{e=r;var i=ot;ot|=2;var o=Qx();(Bt!==t||qt!==e)&&(Sn=null,Yi=Lt()+500,Ur(t,e));do try{i2();break}catch(s){Gx(t,s)}while(!0);Qp(),Al.current=o,ot=i,Ot!==null?e=0:(Bt=null,qt=0,e=Ft)}if(e!==0){if(e===2&&(i=Id(t),i!==0&&(r=i,e=oh(t,i))),e===1)throw n=ga,Ur(t,0),Zn(t,r),be(t,Lt()),n;if(e===6)Zn(t,r);else{if(i=t.current.alternate,!(r&30)&&!n2(i)&&(e=Rl(t,r),e===2&&(o=Id(t),o!==0&&(r=o,e=oh(t,o))),e===1))throw n=ga,Ur(t,0),Zn(t,r),be(t,Lt()),n;switch(t.finishedWork=i,t.finishedLanes=r,e){case 0:case 1:throw Error(j(345));case 2:Rr(t,fe,Sn);break;case 3:if(Zn(t,r),(r&130023424)===r&&(e=pf+500-Lt(),10<e)){if(pl(t,0)!==0)break;if(i=t.suspendedLanes,(i&r)!==r){ue(),t.pingedLanes|=t.suspendedLanes&i;break}t.timeoutHandle=zd(Rr.bind(null,t,fe,Sn),e);break}Rr(t,fe,Sn);break;case 4:if(Zn(t,r),(r&4194240)===r)break;for(e=t.eventTimes,i=-1;0<r;){var a=31-Ze(r);o=1<<a,a=e[a],a>i&&(i=a),r&=~o}if(r=i,r=Lt()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*e2(r/1960))-r,10<r){t.timeoutHandle=zd(Rr.bind(null,t,fe,Sn),r);break}Rr(t,fe,Sn);break;case 5:Rr(t,fe,Sn);break;default:throw Error(j(329))}}}return be(t,Lt()),t.callbackNode===n?Xx.bind(null,t):null}function oh(t,e){var n=Ho;return t.current.memoizedState.isDehydrated&&(Ur(t,e).flags|=256),t=Rl(t,e),t!==2&&(e=fe,fe=n,e!==null&&ah(e)),t}function ah(t){fe===null?fe=t:fe.push.apply(fe,t)}function n2(t){for(var e=t;;){if(e.flags&16384){var n=e.updateQueue;if(n!==null&&(n=n.stores,n!==null))for(var r=0;r<n.length;r++){var i=n[r],o=i.getSnapshot;i=i.value;try{if(!nn(o(),i))return!1}catch{return!1}}}if(n=e.child,e.subtreeFlags&16384&&n!==null)n.return=e,e=n;else{if(e===t)break;for(;e.sibling===null;){if(e.return===null||e.return===t)return!0;e=e.return}e.sibling.return=e.return,e=e.sibling}}return!0}function Zn(t,e){for(e&=~hf,e&=~ku,t.suspendedLanes|=e,t.pingedLanes&=~e,t=t.expirationTimes;0<e;){var n=31-Ze(e),r=1<<n;t[n]=-1,e&=~r}}function iv(t){if(ot&6)throw Error(j(327));Vi();var e=pl(t,0);if(!(e&1))return be(t,Lt()),null;var n=Rl(t,e);if(t.tag!==0&&n===2){var r=Id(t);r!==0&&(e=r,n=oh(t,r))}if(n===1)throw n=ga,Ur(t,0),Zn(t,e),be(t,Lt()),n;if(n===6)throw Error(j(345));return t.finishedWork=t.current.alternate,t.finishedLanes=e,Rr(t,fe,Sn),be(t,Lt()),null}function ff(t,e){var n=ot;ot|=1;try{return t(e)}finally{ot=n,ot===0&&(Yi=Lt()+500,yu&&Sr())}}function Qr(t){nr!==null&&nr.tag===0&&!(ot&6)&&Vi();var e=ot;ot|=1;var n=$e.transition,r=ut;try{if($e.transition=null,ut=1,t)return t()}finally{ut=r,$e.transition=n,ot=e,!(ot&6)&&Sr()}}function mf(){Te=Si.current,yt(Si)}function Ur(t,e){t.finishedWork=null,t.finishedLanes=0;var n=t.timeoutHandle;if(n!==-1&&(t.timeoutHandle=-1,IP(n)),Ot!==null)for(n=Ot.return;n!==null;){var r=n;switch(Kp(r),r.tag){case 1:r=r.type.childContextTypes,r!=null&&yl();break;case 3:Wi(),yt(ve),yt(oe),rf();break;case 5:nf(r);break;case 4:Wi();break;case 13:yt(Tt);break;case 19:yt(Tt);break;case 10:Jp(r.type._context);break;case 22:case 23:mf()}n=n.return}if(Bt=t,Ot=t=dr(t.current,null),qt=Te=e,Ft=0,ga=null,hf=ku=Gr=0,fe=Ho=null,Fr!==null){for(e=0;e<Fr.length;e++)if(n=Fr[e],r=n.interleaved,r!==null){n.interleaved=null;var i=r.next,o=n.pending;if(o!==null){var a=o.next;o.next=i,r.next=a}n.pending=r}Fr=null}return t}function Gx(t,e){do{var n=Ot;try{if(Qp(),qs.current=Pl,Cl){for(var r=Pt.memoizedState;r!==null;){var i=r.queue;i!==null&&(i.pending=null),r=r.next}Cl=!1}if(Xr=0,zt=_t=Pt=null,Uo=!1,pa=0,df.current=null,n===null||n.return===null){Ft=1,ga=e,Ot=null;break}t:{var o=t,a=n.return,s=n,l=e;if(e=qt,s.flags|=32768,l!==null&&typeof l=="object"&&typeof l.then=="function"){var u=l,c=s,d=c.tag;if(!(c.mode&1)&&(d===0||d===11||d===15)){var h=c.alternate;h?(c.updateQueue=h.updateQueue,c.memoizedState=h.memoizedState,c.lanes=h.lanes):(c.updateQueue=null,c.memoizedState=null)}var p=Wg(a);if(p!==null){p.flags&=-257,qg(p,a,s,o,e),p.mode&1&&Hg(o,u,e),e=p,l=u;var m=e.updateQueue;if(m===null){var v=new Set;v.add(l),e.updateQueue=v}else m.add(l);break t}else{if(!(e&1)){Hg(o,u,e),gf();break t}l=Error(j(426))}}else if(wt&&s.mode&1){var b=Wg(a);if(b!==null){!(b.flags&65536)&&(b.flags|=256),qg(b,a,s,o,e),Xp(qi(l,s));break t}}o=l=qi(l,s),Ft!==4&&(Ft=2),Ho===null?Ho=[o]:Ho.push(o),o=a;do{switch(o.tag){case 3:o.flags|=65536,e&=-e,o.lanes|=e;var f=Ix(o,l,e);Fg(o,f);break t;case 1:s=l;var g=o.type,y=o.stateNode;if(!(o.flags&128)&&(typeof g.getDerivedStateFromError=="function"||y!==null&&typeof y.componentDidCatch=="function"&&(ur===null||!ur.has(y)))){o.flags|=65536,e&=-e,o.lanes|=e;var w=Lx(o,s,e);Fg(o,w);break t}}o=o.return}while(o!==null)}Zx(n)}catch(C){e=C,Ot===n&&n!==null&&(Ot=n=n.return);continue}break}while(!0)}function Qx(){var t=Al.current;return Al.current=Pl,t===null?Pl:t}function gf(){(Ft===0||Ft===3||Ft===2)&&(Ft=4),Bt===null||!(Gr&268435455)&&!(ku&268435455)||Zn(Bt,qt)}function Rl(t,e){var n=ot;ot|=2;var r=Qx();(Bt!==t||qt!==e)&&(Sn=null,Ur(t,e));do try{r2();break}catch(i){Gx(t,i)}while(!0);if(Qp(),ot=n,Al.current=r,Ot!==null)throw Error(j(261));return Bt=null,qt=0,Ft}function r2(){for(;Ot!==null;)Jx(Ot)}function i2(){for(;Ot!==null&&!RC();)Jx(Ot)}function Jx(t){var e=ew(t.alternate,t,Te);t.memoizedProps=t.pendingProps,e===null?Zx(t):Ot=e,df.current=null}function Zx(t){var e=t;do{var n=e.alternate;if(t=e.return,e.flags&32768){if(n=QP(n,e),n!==null){n.flags&=32767,Ot=n;return}if(t!==null)t.flags|=32768,t.subtreeFlags=0,t.deletions=null;else{Ft=6,Ot=null;return}}else if(n=GP(n,e,Te),n!==null){Ot=n;return}if(e=e.sibling,e!==null){Ot=e;return}Ot=e=t}while(e!==null);Ft===0&&(Ft=5)}function Rr(t,e,n){var r=ut,i=$e.transition;try{$e.transition=null,ut=1,o2(t,e,n,r)}finally{$e.transition=i,ut=r}return null}function o2(t,e,n,r){do Vi();while(nr!==null);if(ot&6)throw Error(j(327));n=t.finishedWork;var i=t.finishedLanes;if(n===null)return null;if(t.finishedWork=null,t.finishedLanes=0,n===t.current)throw Error(j(177));t.callbackNode=null,t.callbackPriority=0;var o=n.lanes|n.childLanes;if(BC(t,o),t===Bt&&(Ot=Bt=null,qt=0),!(n.subtreeFlags&2064)&&!(n.flags&2064)||Es||(Es=!0,nw(hl,function(){return Vi(),null})),o=(n.flags&15990)!==0,n.subtreeFlags&15990||o){o=$e.transition,$e.transition=null;var a=ut;ut=1;var s=ot;ot|=4,df.current=null,ZP(t,n),Yx(n,t),PP(Fd),fl=!!Nd,Fd=Nd=null,t.current=n,t2(n),IC(),ot=s,ut=a,$e.transition=o}else t.current=n;if(Es&&(Es=!1,nr=t,Dl=i),o=t.pendingLanes,o===0&&(ur=null),OC(n.stateNode),be(t,Lt()),e!==null)for(r=t.onRecoverableError,n=0;n<e.length;n++)i=e[n],r(i.value,{componentStack:i.stack,digest:i.digest});if(Ml)throw Ml=!1,t=rh,rh=null,t;return Dl&1&&t.tag!==0&&Vi(),o=t.pendingLanes,o&1?t===ih?Wo++:(Wo=0,ih=t):Wo=0,Sr(),null}function Vi(){if(nr!==null){var t=Ib(Dl),e=$e.transition,n=ut;try{if($e.transition=null,ut=16>t?16:t,nr===null)var r=!1;else{if(t=nr,nr=null,Dl=0,ot&6)throw Error(j(331));var i=ot;for(ot|=4,V=t.current;V!==null;){var o=V,a=o.child;if(V.flags&16){var s=o.deletions;if(s!==null){for(var l=0;l<s.length;l++){var u=s[l];for(V=u;V!==null;){var c=V;switch(c.tag){case 0:case 11:case 15:$o(8,c,o)}var d=c.child;if(d!==null)d.return=c,V=d;else for(;V!==null;){c=V;var h=c.sibling,p=c.return;if(Hx(c),c===u){V=null;break}if(h!==null){h.return=p,V=h;break}V=p}}}var m=o.alternate;if(m!==null){var v=m.child;if(v!==null){m.child=null;do{var b=v.sibling;v.sibling=null,v=b}while(v!==null)}}V=o}}if(o.subtreeFlags&2064&&a!==null)a.return=o,V=a;else t:for(;V!==null;){if(o=V,o.flags&2048)switch(o.tag){case 0:case 11:case 15:$o(9,o,o.return)}var f=o.sibling;if(f!==null){f.return=o.return,V=f;break t}V=o.return}}var g=t.current;for(V=g;V!==null;){a=V;var y=a.child;if(a.subtreeFlags&2064&&y!==null)y.return=a,V=y;else t:for(a=g;V!==null;){if(s=V,s.flags&2048)try{switch(s.tag){case 0:case 11:case 15:wu(9,s)}}catch(C){Dt(s,s.return,C)}if(s===a){V=null;break t}var w=s.sibling;if(w!==null){w.return=s.return,V=w;break t}V=s.return}}if(ot=i,Sr(),dn&&typeof dn.onPostCommitFiberRoot=="function")try{dn.onPostCommitFiberRoot(pu,t)}catch{}r=!0}return r}finally{ut=n,$e.transition=e}}return!1}function ov(t,e,n){e=qi(n,e),e=Ix(t,e,1),t=lr(t,e,1),e=ue(),t!==null&&(Ha(t,1,e),be(t,e))}function Dt(t,e,n){if(t.tag===3)ov(t,t,n);else for(;e!==null;){if(e.tag===3){ov(e,t,n);break}else if(e.tag===1){var r=e.stateNode;if(typeof e.type.getDerivedStateFromError=="function"||typeof r.componentDidCatch=="function"&&(ur===null||!ur.has(r))){t=qi(n,t),t=Lx(e,t,1),e=lr(e,t,1),t=ue(),e!==null&&(Ha(e,1,t),be(e,t));break}}e=e.return}}function a2(t,e,n){var r=t.pingCache;r!==null&&r.delete(e),e=ue(),t.pingedLanes|=t.suspendedLanes&n,Bt===t&&(qt&n)===n&&(Ft===4||Ft===3&&(qt&130023424)===qt&&500>Lt()-pf?Ur(t,0):hf|=n),be(t,e)}function tw(t,e){e===0&&(t.mode&1?(e=ds,ds<<=1,!(ds&130023424)&&(ds=4194304)):e=1);var n=ue();t=Bn(t,e),t!==null&&(Ha(t,e,n),be(t,n))}function s2(t){var e=t.memoizedState,n=0;e!==null&&(n=e.retryLane),tw(t,n)}function l2(t,e){var n=0;switch(t.tag){case 13:var r=t.stateNode,i=t.memoizedState;i!==null&&(n=i.retryLane);break;case 19:r=t.stateNode;break;default:throw Error(j(314))}r!==null&&r.delete(e),tw(t,n)}var ew;ew=function(t,e,n){if(t!==null)if(t.memoizedProps!==e.pendingProps||ve.current)ge=!0;else{if(!(t.lanes&n)&&!(e.flags&128))return ge=!1,XP(t,e,n);ge=!!(t.flags&131072)}else ge=!1,wt&&e.flags&1048576&&ix(e,wl,e.index);switch(e.lanes=0,e.tag){case 2:var r=e.type;Ks(t,e),t=e.pendingProps;var i=Ui(e,oe.current);Fi(e,n),i=af(null,e,r,t,i,n);var o=sf();return e.flags|=1,typeof i=="object"&&i!==null&&typeof i.render=="function"&&i.$$typeof===void 0?(e.tag=1,e.memoizedState=null,e.updateQueue=null,ye(r)?(o=!0,bl(e)):o=!1,e.memoizedState=i.state!==null&&i.state!==void 0?i.state:null,tf(e),i.updater=xu,e.stateNode=i,i._reactInternals=e,Yd(e,r,t,n),e=Gd(null,e,r,!0,o,n)):(e.tag=0,wt&&o&&Yp(e),se(null,e,i,n),e=e.child),e;case 16:r=e.elementType;t:{switch(Ks(t,e),t=e.pendingProps,i=r._init,r=i(r._payload),e.type=r,i=e.tag=c2(r),t=Ge(r,t),i){case 0:e=Xd(null,e,r,t,n);break t;case 1:e=Xg(null,e,r,t,n);break t;case 11:e=Yg(null,e,r,t,n);break t;case 14:e=Kg(null,e,r,Ge(r.type,t),n);break t}throw Error(j(306,r,""))}return e;case 0:return r=e.type,i=e.pendingProps,i=e.elementType===r?i:Ge(r,i),Xd(t,e,r,i,n);case 1:return r=e.type,i=e.pendingProps,i=e.elementType===r?i:Ge(r,i),Xg(t,e,r,i,n);case 3:t:{if(Nx(e),t===null)throw Error(j(387));r=e.pendingProps,o=e.memoizedState,i=o.element,cx(t,e),Tl(e,r,null,n);var a=e.memoizedState;if(r=a.element,o.isDehydrated)if(o={element:r,isDehydrated:!1,cache:a.cache,pendingSuspenseBoundaries:a.pendingSuspenseBoundaries,transitions:a.transitions},e.updateQueue.baseState=o,e.memoizedState=o,e.flags&256){i=qi(Error(j(423)),e),e=Gg(t,e,r,n,i);break t}else if(r!==i){i=qi(Error(j(424)),e),e=Gg(t,e,r,n,i);break t}else for(Ee=sr(e.stateNode.containerInfo.firstChild),Pe=e,wt=!0,Je=null,n=lx(e,null,r,n),e.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if($i(),r===i){e=Un(t,e,n);break t}se(t,e,r,n)}e=e.child}return e;case 5:return dx(e),t===null&&Hd(e),r=e.type,i=e.pendingProps,o=t!==null?t.memoizedProps:null,a=i.children,Vd(r,i)?a=null:o!==null&&Vd(r,o)&&(e.flags|=32),_x(t,e),se(t,e,a,n),e.child;case 6:return t===null&&Hd(e),null;case 13:return Fx(t,e,n);case 4:return ef(e,e.stateNode.containerInfo),r=e.pendingProps,t===null?e.child=Hi(e,null,r,n):se(t,e,r,n),e.child;case 11:return r=e.type,i=e.pendingProps,i=e.elementType===r?i:Ge(r,i),Yg(t,e,r,i,n);case 7:return se(t,e,e.pendingProps,n),e.child;case 8:return se(t,e,e.pendingProps.children,n),e.child;case 12:return se(t,e,e.pendingProps.children,n),e.child;case 10:t:{if(r=e.type._context,i=e.pendingProps,o=e.memoizedProps,a=i.value,mt(kl,r._currentValue),r._currentValue=a,o!==null)if(nn(o.value,a)){if(o.children===i.children&&!ve.current){e=Un(t,e,n);break t}}else for(o=e.child,o!==null&&(o.return=e);o!==null;){var s=o.dependencies;if(s!==null){a=o.child;for(var l=s.firstContext;l!==null;){if(l.context===r){if(o.tag===1){l=Dn(-1,n&-n),l.tag=2;var u=o.updateQueue;if(u!==null){u=u.shared;var c=u.pending;c===null?l.next=l:(l.next=c.next,c.next=l),u.pending=l}}o.lanes|=n,l=o.alternate,l!==null&&(l.lanes|=n),Wd(o.return,n,e),s.lanes|=n;break}l=l.next}}else if(o.tag===10)a=o.type===e.type?null:o.child;else if(o.tag===18){if(a=o.return,a===null)throw Error(j(341));a.lanes|=n,s=a.alternate,s!==null&&(s.lanes|=n),Wd(a,n,e),a=o.sibling}else a=o.child;if(a!==null)a.return=o;else for(a=o;a!==null;){if(a===e){a=null;break}if(o=a.sibling,o!==null){o.return=a.return,a=o;break}a=a.return}o=a}se(t,e,i.children,n),e=e.child}return e;case 9:return i=e.type,r=e.pendingProps.children,Fi(e,n),i=We(i),r=r(i),e.flags|=1,se(t,e,r,n),e.child;case 14:return r=e.type,i=Ge(r,e.pendingProps),i=Ge(r.type,i),Kg(t,e,r,i,n);case 15:return jx(t,e,e.type,e.pendingProps,n);case 17:return r=e.type,i=e.pendingProps,i=e.elementType===r?i:Ge(r,i),Ks(t,e),e.tag=1,ye(r)?(t=!0,bl(e)):t=!1,Fi(e,n),Rx(e,r,i),Yd(e,r,i,n),Gd(null,e,r,!0,t,n);case 19:return Vx(t,e,n);case 22:return Ox(t,e,n)}throw Error(j(156,e.tag))};function nw(t,e){return Ab(t,e)}function u2(t,e,n,r){this.tag=t,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=e,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Ue(t,e,n,r){return new u2(t,e,n,r)}function vf(t){return t=t.prototype,!(!t||!t.isReactComponent)}function c2(t){if(typeof t=="function")return vf(t)?1:0;if(t!=null){if(t=t.$$typeof,t===Op)return 11;if(t===_p)return 14}return 2}function dr(t,e){var n=t.alternate;return n===null?(n=Ue(t.tag,e,t.key,t.mode),n.elementType=t.elementType,n.type=t.type,n.stateNode=t.stateNode,n.alternate=t,t.alternate=n):(n.pendingProps=e,n.type=t.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=t.flags&14680064,n.childLanes=t.childLanes,n.lanes=t.lanes,n.child=t.child,n.memoizedProps=t.memoizedProps,n.memoizedState=t.memoizedState,n.updateQueue=t.updateQueue,e=t.dependencies,n.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext},n.sibling=t.sibling,n.index=t.index,n.ref=t.ref,n}function Qs(t,e,n,r,i,o){var a=2;if(r=t,typeof t=="function")vf(t)&&(a=1);else if(typeof t=="string")a=5;else t:switch(t){case pi:return $r(n.children,i,o,e);case jp:a=8,i|=8;break;case vd:return t=Ue(12,n,e,i|2),t.elementType=vd,t.lanes=o,t;case yd:return t=Ue(13,n,e,i),t.elementType=yd,t.lanes=o,t;case bd:return t=Ue(19,n,e,i),t.elementType=bd,t.lanes=o,t;case db:return Su(n,i,o,e);default:if(typeof t=="object"&&t!==null)switch(t.$$typeof){case ub:a=10;break t;case cb:a=9;break t;case Op:a=11;break t;case _p:a=14;break t;case Gn:a=16,r=null;break t}throw Error(j(130,t==null?t:typeof t,""))}return e=Ue(a,n,e,i),e.elementType=t,e.type=r,e.lanes=o,e}function $r(t,e,n,r){return t=Ue(7,t,r,e),t.lanes=n,t}function Su(t,e,n,r){return t=Ue(22,t,r,e),t.elementType=db,t.lanes=n,t.stateNode={isHidden:!1},t}function bc(t,e,n){return t=Ue(6,t,null,e),t.lanes=n,t}function xc(t,e,n){return e=Ue(4,t.children!==null?t.children:[],t.key,e),e.lanes=n,e.stateNode={containerInfo:t.containerInfo,pendingChildren:null,implementation:t.implementation},e}function d2(t,e,n,r,i){this.tag=e,this.containerInfo=t,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=rc(0),this.expirationTimes=rc(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=rc(0),this.identifierPrefix=r,this.onRecoverableError=i,this.mutableSourceEagerHydrationData=null}function yf(t,e,n,r,i,o,a,s,l){return t=new d2(t,e,n,s,l),e===1?(e=1,o===!0&&(e|=8)):e=0,o=Ue(3,null,null,e),t.current=o,o.stateNode=t,o.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},tf(o),t}function h2(t,e,n){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:hi,key:r==null?null:""+r,children:t,containerInfo:e,implementation:n}}function rw(t){if(!t)return pr;t=t._reactInternals;t:{if(ei(t)!==t||t.tag!==1)throw Error(j(170));var e=t;do{switch(e.tag){case 3:e=e.stateNode.context;break t;case 1:if(ye(e.type)){e=e.stateNode.__reactInternalMemoizedMergedChildContext;break t}}e=e.return}while(e!==null);throw Error(j(171))}if(t.tag===1){var n=t.type;if(ye(n))return nx(t,n,e)}return e}function iw(t,e,n,r,i,o,a,s,l){return t=yf(n,r,!0,t,i,o,a,s,l),t.context=rw(null),n=t.current,r=ue(),i=cr(n),o=Dn(r,i),o.callback=e??null,lr(n,o,i),t.current.lanes=i,Ha(t,i,r),be(t,r),t}function Tu(t,e,n,r){var i=e.current,o=ue(),a=cr(i);return n=rw(n),e.context===null?e.context=n:e.pendingContext=n,e=Dn(o,a),e.payload={element:t},r=r===void 0?null:r,r!==null&&(e.callback=r),t=lr(i,e,a),t!==null&&(tn(t,i,a,o),Ws(t,i,a)),a}function Il(t){if(t=t.current,!t.child)return null;switch(t.child.tag){case 5:return t.child.stateNode;default:return t.child.stateNode}}function av(t,e){if(t=t.memoizedState,t!==null&&t.dehydrated!==null){var n=t.retryLane;t.retryLane=n!==0&&n<e?n:e}}function bf(t,e){av(t,e),(t=t.alternate)&&av(t,e)}function p2(){return null}var ow=typeof reportError=="function"?reportError:function(t){console.error(t)};function xf(t){this._internalRoot=t}Eu.prototype.render=xf.prototype.render=function(t){var e=this._internalRoot;if(e===null)throw Error(j(409));Tu(t,e,null,null)};Eu.prototype.unmount=xf.prototype.unmount=function(){var t=this._internalRoot;if(t!==null){this._internalRoot=null;var e=t.containerInfo;Qr(function(){Tu(null,t,null,null)}),e[zn]=null}};function Eu(t){this._internalRoot=t}Eu.prototype.unstable_scheduleHydration=function(t){if(t){var e=Ob();t={blockedOn:null,target:t,priority:e};for(var n=0;n<Jn.length&&e!==0&&e<Jn[n].priority;n++);Jn.splice(n,0,t),n===0&&Nb(t)}};function wf(t){return!(!t||t.nodeType!==1&&t.nodeType!==9&&t.nodeType!==11)}function Cu(t){return!(!t||t.nodeType!==1&&t.nodeType!==9&&t.nodeType!==11&&(t.nodeType!==8||t.nodeValue!==" react-mount-point-unstable "))}function sv(){}function f2(t,e,n,r,i){if(i){if(typeof r=="function"){var o=r;r=function(){var u=Il(a);o.call(u)}}var a=iw(e,r,t,0,null,!1,!1,"",sv);return t._reactRootContainer=a,t[zn]=a.current,la(t.nodeType===8?t.parentNode:t),Qr(),a}for(;i=t.lastChild;)t.removeChild(i);if(typeof r=="function"){var s=r;r=function(){var u=Il(l);s.call(u)}}var l=yf(t,0,!1,null,null,!1,!1,"",sv);return t._reactRootContainer=l,t[zn]=l.current,la(t.nodeType===8?t.parentNode:t),Qr(function(){Tu(e,l,n,r)}),l}function Pu(t,e,n,r,i){var o=n._reactRootContainer;if(o){var a=o;if(typeof i=="function"){var s=i;i=function(){var l=Il(a);s.call(l)}}Tu(e,a,t,i)}else a=f2(n,e,t,i,r);return Il(a)}Lb=function(t){switch(t.tag){case 3:var e=t.stateNode;if(e.current.memoizedState.isDehydrated){var n=Ro(e.pendingLanes);n!==0&&(Vp(e,n|1),be(e,Lt()),!(ot&6)&&(Yi=Lt()+500,Sr()))}break;case 13:Qr(function(){var r=Bn(t,1);if(r!==null){var i=ue();tn(r,t,1,i)}}),bf(t,1)}};zp=function(t){if(t.tag===13){var e=Bn(t,134217728);if(e!==null){var n=ue();tn(e,t,134217728,n)}bf(t,134217728)}};jb=function(t){if(t.tag===13){var e=cr(t),n=Bn(t,e);if(n!==null){var r=ue();tn(n,t,e,r)}bf(t,e)}};Ob=function(){return ut};_b=function(t,e){var n=ut;try{return ut=t,e()}finally{ut=n}};Md=function(t,e,n){switch(e){case"input":if(kd(t,n),e=n.name,n.type==="radio"&&e!=null){for(n=t;n.parentNode;)n=n.parentNode;for(n=n.querySelectorAll("input[name="+JSON.stringify(""+e)+'][type="radio"]'),e=0;e<n.length;e++){var r=n[e];if(r!==t&&r.form===t.form){var i=vu(r);if(!i)throw Error(j(90));pb(r),kd(r,i)}}}break;case"textarea":mb(t,n);break;case"select":e=n.value,e!=null&&ji(t,!!n.multiple,e,!1)}};kb=ff;Sb=Qr;var m2={usingClientEntryPoint:!1,Events:[qa,vi,vu,xb,wb,ff]},wo={findFiberByHostInstance:Nr,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},g2={bundleType:wo.bundleType,version:wo.version,rendererPackageName:wo.rendererPackageName,rendererConfig:wo.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:Hn.ReactCurrentDispatcher,findHostInstanceByFiber:function(t){return t=Cb(t),t===null?null:t.stateNode},findFiberByHostInstance:wo.findFiberByHostInstance||p2,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null,reconcilerVersion:"18.3.1-next-f1338f8080-20240426"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&(ko=__REACT_DEVTOOLS_GLOBAL_HOOK__,!ko.isDisabled&&ko.supportsFiber))try{pu=ko.inject(g2),dn=ko}catch{}var ko;Re.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=m2;Re.createPortal=function(t,e){var n=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!wf(e))throw Error(j(200));return h2(t,e,null,n)};Re.createRoot=function(t,e){if(!wf(t))throw Error(j(299));var n=!1,r="",i=ow;return e!=null&&(e.unstable_strictMode===!0&&(n=!0),e.identifierPrefix!==void 0&&(r=e.identifierPrefix),e.onRecoverableError!==void 0&&(i=e.onRecoverableError)),e=yf(t,1,!1,null,null,n,!1,r,i),t[zn]=e.current,la(t.nodeType===8?t.parentNode:t),new xf(e)};Re.findDOMNode=function(t){if(t==null)return null;if(t.nodeType===1)return t;var e=t._reactInternals;if(e===void 0)throw typeof t.render=="function"?Error(j(188)):(t=Object.keys(t).join(","),Error(j(268,t)));return t=Cb(e),t=t===null?null:t.stateNode,t};Re.flushSync=function(t){return Qr(t)};Re.hydrate=function(t,e,n){if(!Cu(e))throw Error(j(200));return Pu(null,t,e,!0,n)};Re.hydrateRoot=function(t,e,n){if(!wf(t))throw Error(j(405));var r=n!=null&&n.hydratedSources||null,i=!1,o="",a=ow;if(n!=null&&(n.unstable_strictMode===!0&&(i=!0),n.identifierPrefix!==void 0&&(o=n.identifierPrefix),n.onRecoverableError!==void 0&&(a=n.onRecoverableError)),e=iw(e,null,t,1,n??null,i,!1,o,a),t[zn]=e.current,la(t),r)for(t=0;t<r.length;t++)n=r[t],i=n._getVersion,i=i(n._source),e.mutableSourceEagerHydrationData==null?e.mutableSourceEagerHydrationData=[n,i]:e.mutableSourceEagerHydrationData.push(n,i);return new Eu(e)};Re.render=function(t,e,n){if(!Cu(e))throw Error(j(200));return Pu(null,t,e,!1,n)};Re.unmountComponentAtNode=function(t){if(!Cu(t))throw Error(j(40));return t._reactRootContainer?(Qr(function(){Pu(null,null,t,!1,function(){t._reactRootContainer=null,t[zn]=null})}),!0):!1};Re.unstable_batchedUpdates=ff;Re.unstable_renderSubtreeIntoContainer=function(t,e,n,r){if(!Cu(n))throw Error(j(200));if(t==null||t._reactInternals===void 0)throw Error(j(38));return Pu(t,e,n,!1,r)};Re.version="18.3.1-next-f1338f8080-20240426";function aw(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(aw)}catch(t){console.error(t)}}aw(),ob.exports=Re;var v2=ob.exports,lv=v2;md.createRoot=lv.createRoot,md.hydrateRoot=lv.hydrateRoot;function Au(t,e){window.dispatchEvent(new StorageEvent("storage",{key:t,newValue:e}))}var uv=(t,e)=>{let n=JSON.stringify(e);window.localStorage.setItem(t,n),Au(t,n)},y2=t=>{window.localStorage.removeItem(t),Au(t,null)},cv=t=>window.localStorage.getItem(t),b2=t=>(window.addEventListener("storage",t),()=>window.removeEventListener("storage",t)),x2=()=>{throw Error("useLocalStorage is a client-only hook")};function w2(t,e){let n=()=>cv(t),r=S.useSyncExternalStore(b2,n,x2),i=S.useCallback(o=>{try{let a=typeof o=="function"?o(JSON.parse(r)):o;a==null?y2(t):uv(t,a)}catch(a){console.warn(a)}},[t,r]);return S.useEffect(()=>{cv(t)===null&&typeof e<"u"&&uv(t,e)},[t,e]),[r?JSON.parse(r):e,i]}var dv=(t,e)=>{let n=JSON.stringify(e);window.sessionStorage.setItem(t,n),Au(t,n)},k2=t=>{window.sessionStorage.removeItem(t),Au(t,null)},hv=t=>window.sessionStorage.getItem(t),S2=t=>(window.addEventListener("storage",t),()=>window.removeEventListener("storage",t)),T2=()=>{throw Error("useSessionStorage is a client-only hook")};function Nt(t,e){let n=()=>hv(t),r=S.useSyncExternalStore(S2,n,T2),i=S.useCallback(o=>{try{let a=typeof o=="function"?o(JSON.parse(r)):o;a==null?k2(t):dv(t,a)}catch(a){console.warn(a)}},[t,r]);return S.useEffect(()=>{hv(t)===null&&typeof e<"u"&&dv(t,e)},[t,e]),[r?JSON.parse(r):e,i]}async function E2(t){return await(await fetch(`https://api.leoai.hu/buttons/${t}`)).json()}async function C2(t){return await(await fetch(`https://api.leoai.hu/articles/${t}`)).json()}async function P2(t){return await(await fetch(`https://api.leoai.hu/chatbots/${t}`)).json()}var sw=S.createContext({});function A2(t){let[e,n]=S.useState(null);S.useEffect(()=>{var y;let w=parseInt(((y=document.querySelector("script[data-chatbot-id]"))==null?void 0:y.getAttribute("data-chatbot-id"))??"1");n(w)},[]);let[r,i]=Nt("leoaiv3.6-chatbot-settings",null),[o,a]=Nt("leoaiv3.6-chatbot-name",null),[s,l]=Nt("leoaiv3.6-chatbot-texts",null),[u,c]=Nt("leoaiv3.6-chatbot-links",null),[d,h]=Nt("leoaiv3.6-chatbot-css-variables",null),[p,m]=Nt("leoaiv3.6-chatbot-product-search",!1),[v,b]=Nt("leoaiv3.6-chatbot-automated-message-strategy",null),[f,g]=S.useState(!0);return S.useEffect(()=>{(async()=>{if(e&&(!r||!r.enabled)){let y=await P2(e);(!y||!y.enabled)&&g(!1),i(y)}})()},[e,r]),S.useEffect(()=>{r&&(a(r.name),m(r.productSearch),h(r.cssVariables),l(r.texts),c(r.links),b(r.automatedMessageStrategy),Object.entries(r.cssVariables).forEach(([y,w])=>{var C;(C=document.getElementById("leoai-wrapper"))==null||C.style.setProperty(`--${y}`,w)}))},[r]),A.jsx(sw.Provider,{value:{chatbotId:e,name:o,cssVariables:d,texts:s,links:u,productSearch:p,enabled:f,automatedMessageStrategy:v},...t})}function we(){return S.useContext(sw)}var lw=S.createContext({});function M2(t){let[e,n]=Nt("leoaiv3.6-opened",!1),[r,i]=Nt("leoaiv3.6-view","chat");return A.jsx(lw.Provider,{value:{opened:e,setOpened:n,view:r,setView:i},...t})}function Le(){return S.useContext(lw)}var uw=S.createContext({});function D2(t){let{chatbotId:e}=we(),{view:n,setView:r}=Le(),[i,o]=Nt("leoaiv3.6-articles",null),[a,s]=S.useState(null);return S.useEffect(()=>{var l;if(!e||i&&i.length>0)return;let u=async()=>{let c=await C2(e);o(c)};e&&(!i||((l=i?.[0])==null?void 0:l.chatbotId)!==e)&&u()},[e,i,o]),S.useEffect(()=>{if(n==="article"){if(!a)return;r("article")}},[n]),A.jsx(uw.Provider,{value:{articles:i,selectedArticle:a,setSelectedArticle:s},...t})}function cw(){return S.useContext(uw)}function R2({children:t}){return A.jsx(A2,{children:A.jsx(JM,{children:A.jsx(M2,{children:A.jsx(D2,{children:A.jsxs(KM,{children:[A.jsx(GM,{children:t})," "]})})})})})}var dw="vercel.ai.error",I2=Symbol.for(dw),hw,L2=class pw extends Error{constructor({name:e,message:n,cause:r}){super(n),this[hw]=!0,this.name=e,this.cause=r}static isInstance(e){return pw.hasMarker(e,dw)}static hasMarker(e,n){let r=Symbol.for(n);return e!=null&&typeof e=="object"&&r in e&&typeof e[r]=="boolean"&&e[r]===!0}};hw=I2;var Ki=L2;function fw(t){return t==null?"unknown error":typeof t=="string"?t:t instanceof Error?t.message:JSON.stringify(t)}var mw="AI_InvalidArgumentError",gw=`vercel.ai.error.${mw}`,j2=Symbol.for(gw),vw,O2=class extends Ki{constructor({message:t,cause:e,argument:n}){super({name:mw,message:t,cause:e}),this[vw]=!0,this.argument=n}static isInstance(t){return Ki.hasMarker(t,gw)}};vw=j2;var yw="AI_JSONParseError",bw=`vercel.ai.error.${yw}`,_2=Symbol.for(bw),xw,pv=class extends Ki{constructor({text:t,cause:e}){super({name:yw,message:`JSON parsing failed: Text: ${t}.
Error message: ${fw(e)}`,cause:e}),this[xw]=!0,this.text=t}static isInstance(t){return Ki.hasMarker(t,bw)}};xw=_2;var ww="AI_TypeValidationError",kw=`vercel.ai.error.${ww}`,N2=Symbol.for(kw),Sw,F2=class sh extends Ki{constructor({value:e,cause:n}){super({name:ww,message:`Type validation failed: Value: ${JSON.stringify(e)}.
Error message: ${fw(n)}`,cause:n}),this[Sw]=!0,this.value=e}static isInstance(e){return Ki.hasMarker(e,kw)}static wrap({value:e,cause:n}){return sh.isInstance(n)&&n.value===e?n:new sh({value:e,cause:n})}};Sw=N2;var fv=F2,V2=(t,e=21)=>(n=e)=>{let r="",i=n;for(;i--;)r+=t[Math.random()*t.length|0];return r},ao={exports:{}},z2=typeof Buffer<"u",mv=/"(?:_|\\u005[Ff])(?:_|\\u005[Ff])(?:p|\\u0070)(?:r|\\u0072)(?:o|\\u006[Ff])(?:t|\\u0074)(?:o|\\u006[Ff])(?:_|\\u005[Ff])(?:_|\\u005[Ff])"\s*:/,gv=/"(?:c|\\u0063)(?:o|\\u006[Ff])(?:n|\\u006[Ee])(?:s|\\u0073)(?:t|\\u0074)(?:r|\\u0072)(?:u|\\u0075)(?:c|\\u0063)(?:t|\\u0074)(?:o|\\u006[Ff])(?:r|\\u0072)"\s*:/;function Tw(t,e,n){n==null&&e!==null&&typeof e=="object"&&(n=e,e=void 0),z2&&Buffer.isBuffer(t)&&(t=t.toString()),t&&t.charCodeAt(0)===65279&&(t=t.slice(1));let r=JSON.parse(t,e);if(r===null||typeof r!="object")return r;let i=n&&n.protoAction||"error",o=n&&n.constructorAction||"error";if(i==="ignore"&&o==="ignore")return r;if(i!=="ignore"&&o!=="ignore"){if(mv.test(t)===!1&&gv.test(t)===!1)return r}else if(i!=="ignore"&&o==="ignore"){if(mv.test(t)===!1)return r}else if(gv.test(t)===!1)return r;return Ew(r,{protoAction:i,constructorAction:o,safe:n&&n.safe})}function Ew(t,{protoAction:e="error",constructorAction:n="error",safe:r}={}){let i=[t];for(;i.length;){let o=i;i=[];for(let a of o){if(e!=="ignore"&&Object.prototype.hasOwnProperty.call(a,"__proto__")){if(r===!0)return null;if(e==="error")throw new SyntaxError("Object contains forbidden prototype property");delete a.__proto__}if(n!=="ignore"&&Object.prototype.hasOwnProperty.call(a,"constructor")&&Object.prototype.hasOwnProperty.call(a.constructor,"prototype")){if(r===!0)return null;if(n==="error")throw new SyntaxError("Object contains forbidden prototype property");delete a.constructor}for(let s in a){let l=a[s];l&&typeof l=="object"&&i.push(l)}}}return t}function kf(t,e,n){let r=Error.stackTraceLimit;Error.stackTraceLimit=0;try{return Tw(t,e,n)}finally{Error.stackTraceLimit=r}}function B2(t,e){let n=Error.stackTraceLimit;Error.stackTraceLimit=0;try{return Tw(t,e,{safe:!0})}catch{return null}finally{Error.stackTraceLimit=n}}ao.exports=kf;ao.exports.default=kf;ao.exports.parse=kf;ao.exports.safeParse=B2;ao.exports.scan=Ew;var U2=ao.exports,$2=du(U2),H2=({prefix:t,size:e=16,alphabet:n="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz",separator:r="-"}={})=>{let i=V2(n,e);if(t==null)return i;if(n.includes(r))throw new O2({argument:"separator",message:`The separator "${r}" must not be part of the alphabet "${n}".`});return o=>`${t}${r}${i(o)}`},Cw=H2(),lh=Symbol.for("vercel.ai.validator");function W2(t){return{[lh]:!0,validate:t}}function q2(t){return typeof t=="object"&&t!==null&&lh in t&&t[lh]===!0&&"validate"in t}function Y2(t){return q2(t)?t:K2(t)}function K2(t){return W2(e=>{let n=t.safeParse(e);return n.success?{success:!0,value:n.data}:{success:!1,error:n.error}})}function X2({value:t,schema:e}){let n=Y2(e);try{if(n.validate==null)return{success:!0,value:t};let r=n.validate(t);return r.success?r:{success:!1,error:fv.wrap({value:t,cause:r.error})}}catch(r){return{success:!1,error:fv.wrap({value:t,cause:r})}}}function vv({text:t,schema:e}){try{let n=$2.parse(t);return e==null?{success:!0,value:n}:X2({value:n,schema:e})}catch(n){return{success:!1,error:pv.isInstance(n)?n:new pv({text:t,cause:n})}}}var Ll={code:"0",name:"text",parse:t=>{if(typeof t!="string")throw new Error('"text" parts expect a string value.');return{type:"text",value:t}}},jl={code:"3",name:"error",parse:t=>{if(typeof t!="string")throw new Error('"error" parts expect a string value.');return{type:"error",value:t}}},Ol={code:"4",name:"assistant_message",parse:t=>{if(t==null||typeof t!="object"||!("id"in t)||!("role"in t)||!("content"in t)||typeof t.id!="string"||typeof t.role!="string"||t.role!=="assistant"||!Array.isArray(t.content)||!t.content.every(e=>e!=null&&typeof e=="object"&&"type"in e&&e.type==="text"&&"text"in e&&e.text!=null&&typeof e.text=="object"&&"value"in e.text&&typeof e.text.value=="string"))throw new Error('"assistant_message" parts expect an object with an "id", "role", and "content" property.');return{type:"assistant_message",value:t}}},_l={code:"5",name:"assistant_control_data",parse:t=>{if(t==null||typeof t!="object"||!("threadId"in t)||!("messageId"in t)||typeof t.threadId!="string"||typeof t.messageId!="string")throw new Error('"assistant_control_data" parts expect an object with a "threadId" and "messageId" property.');return{type:"assistant_control_data",value:{threadId:t.threadId,messageId:t.messageId}}}},Nl={code:"6",name:"data_message",parse:t=>{if(t==null||typeof t!="object"||!("role"in t)||!("data"in t)||typeof t.role!="string"||t.role!=="data")throw new Error('"data_message" parts expect an object with a "role" and "data" property.');return{type:"data_message",value:t}}},G2=[Ll,jl,Ol,_l,Nl];Ll.code+"",jl.code+"",Ol.code+"",_l.code+"",Nl.code+"";Ll.name+"",Ll.code,jl.name+"",jl.code,Ol.name+"",Ol.code,_l.name+"",_l.code,Nl.name+"",Nl.code;G2.map(t=>t.code);function Q2(t){let e=["ROOT"],n=-1,r=null;function i(l,u,c){switch(l){case'"':{n=u,e.pop(),e.push(c),e.push("INSIDE_STRING");break}case"f":case"t":case"n":{n=u,r=u,e.pop(),e.push(c),e.push("INSIDE_LITERAL");break}case"-":{e.pop(),e.push(c),e.push("INSIDE_NUMBER");break}case"0":case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":{n=u,e.pop(),e.push(c),e.push("INSIDE_NUMBER");break}case"{":{n=u,e.pop(),e.push(c),e.push("INSIDE_OBJECT_START");break}case"[":{n=u,e.pop(),e.push(c),e.push("INSIDE_ARRAY_START");break}}}function o(l,u){switch(l){case",":{e.pop(),e.push("INSIDE_OBJECT_AFTER_COMMA");break}case"}":{n=u,e.pop();break}}}function a(l,u){switch(l){case",":{e.pop(),e.push("INSIDE_ARRAY_AFTER_COMMA");break}case"]":{n=u,e.pop();break}}}for(let l=0;l<t.length;l++){let u=t[l];switch(e[e.length-1]){case"ROOT":i(u,l,"FINISH");break;case"INSIDE_OBJECT_START":{switch(u){case'"':{e.pop(),e.push("INSIDE_OBJECT_KEY");break}case"}":{n=l,e.pop();break}}break}case"INSIDE_OBJECT_AFTER_COMMA":{switch(u){case'"':{e.pop(),e.push("INSIDE_OBJECT_KEY");break}}break}case"INSIDE_OBJECT_KEY":{switch(u){case'"':{e.pop(),e.push("INSIDE_OBJECT_AFTER_KEY");break}}break}case"INSIDE_OBJECT_AFTER_KEY":{switch(u){case":":{e.pop(),e.push("INSIDE_OBJECT_BEFORE_VALUE");break}}break}case"INSIDE_OBJECT_BEFORE_VALUE":{i(u,l,"INSIDE_OBJECT_AFTER_VALUE");break}case"INSIDE_OBJECT_AFTER_VALUE":{o(u,l);break}case"INSIDE_STRING":{switch(u){case'"':{e.pop(),n=l;break}case"\\":{e.push("INSIDE_STRING_ESCAPE");break}default:n=l}break}case"INSIDE_ARRAY_START":{switch(u){case"]":{n=l,e.pop();break}default:{n=l,i(u,l,"INSIDE_ARRAY_AFTER_VALUE");break}}break}case"INSIDE_ARRAY_AFTER_VALUE":{switch(u){case",":{e.pop(),e.push("INSIDE_ARRAY_AFTER_COMMA");break}case"]":{n=l,e.pop();break}default:{n=l;break}}break}case"INSIDE_ARRAY_AFTER_COMMA":{i(u,l,"INSIDE_ARRAY_AFTER_VALUE");break}case"INSIDE_STRING_ESCAPE":{e.pop(),n=l;break}case"INSIDE_NUMBER":{switch(u){case"0":case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":{n=l;break}case"e":case"E":case"-":case".":break;case",":{e.pop(),e[e.length-1]==="INSIDE_ARRAY_AFTER_VALUE"&&a(u,l),e[e.length-1]==="INSIDE_OBJECT_AFTER_VALUE"&&o(u,l);break}case"}":{e.pop(),e[e.length-1]==="INSIDE_OBJECT_AFTER_VALUE"&&o(u,l);break}case"]":{e.pop(),e[e.length-1]==="INSIDE_ARRAY_AFTER_VALUE"&&a(u,l);break}default:{e.pop();break}}break}case"INSIDE_LITERAL":{let c=t.substring(r,l+1);!"false".startsWith(c)&&!"true".startsWith(c)&&!"null".startsWith(c)?(e.pop(),e[e.length-1]==="INSIDE_OBJECT_AFTER_VALUE"?o(u,l):e[e.length-1]==="INSIDE_ARRAY_AFTER_VALUE"&&a(u,l)):n=l;break}}}let s=t.slice(0,n+1);for(let l=e.length-1;l>=0;l--)switch(e[l]){case"INSIDE_STRING":{s+='"';break}case"INSIDE_OBJECT_KEY":case"INSIDE_OBJECT_AFTER_KEY":case"INSIDE_OBJECT_AFTER_COMMA":case"INSIDE_OBJECT_START":case"INSIDE_OBJECT_BEFORE_VALUE":case"INSIDE_OBJECT_AFTER_VALUE":{s+="}";break}case"INSIDE_ARRAY_START":case"INSIDE_ARRAY_AFTER_COMMA":case"INSIDE_ARRAY_AFTER_VALUE":{s+="]";break}case"INSIDE_LITERAL":{let u=t.substring(r,t.length);"true".startsWith(u)?s+="true".slice(u.length):"false".startsWith(u)?s+="false".slice(u.length):"null".startsWith(u)&&(s+="null".slice(u.length))}}return s}function J2(t){if(t===void 0)return{value:void 0,state:"undefined-input"};let e=vv({text:t});return e.success?{value:e.value,state:"successful-parse"}:(e=vv({text:Q2(t)}),e.success?{value:e.value,state:"repaired-parse"}:{value:void 0,state:"failed-parse"})}var va={code:"0",name:"text",parse:t=>{if(typeof t!="string")throw new Error('"text" parts expect a string value.');return{type:"text",value:t}}},ya={code:"2",name:"data",parse:t=>{if(!Array.isArray(t))throw new Error('"data" parts expect an array value.');return{type:"data",value:t}}},ba={code:"3",name:"error",parse:t=>{if(typeof t!="string")throw new Error('"error" parts expect a string value.');return{type:"error",value:t}}},xa={code:"8",name:"message_annotations",parse:t=>{if(!Array.isArray(t))throw new Error('"message_annotations" parts expect an array value.');return{type:"message_annotations",value:t}}},wa={code:"9",name:"tool_call",parse:t=>{if(t==null||typeof t!="object"||!("toolCallId"in t)||typeof t.toolCallId!="string"||!("toolName"in t)||typeof t.toolName!="string"||!("args"in t)||typeof t.args!="object")throw new Error('"tool_call" parts expect an object with a "toolCallId", "toolName", and "args" property.');return{type:"tool_call",value:t}}},ka={code:"a",name:"tool_result",parse:t=>{if(t==null||typeof t!="object"||!("toolCallId"in t)||typeof t.toolCallId!="string"||!("result"in t))throw new Error('"tool_result" parts expect an object with a "toolCallId" and a "result" property.');return{type:"tool_result",value:t}}},Sa={code:"b",name:"tool_call_streaming_start",parse:t=>{if(t==null||typeof t!="object"||!("toolCallId"in t)||typeof t.toolCallId!="string"||!("toolName"in t)||typeof t.toolName!="string")throw new Error('"tool_call_streaming_start" parts expect an object with a "toolCallId" and "toolName" property.');return{type:"tool_call_streaming_start",value:t}}},Ta={code:"c",name:"tool_call_delta",parse:t=>{if(t==null||typeof t!="object"||!("toolCallId"in t)||typeof t.toolCallId!="string"||!("argsTextDelta"in t)||typeof t.argsTextDelta!="string")throw new Error('"tool_call_delta" parts expect an object with a "toolCallId" and "argsTextDelta" property.');return{type:"tool_call_delta",value:t}}},Ea={code:"d",name:"finish_message",parse:t=>{if(t==null||typeof t!="object"||!("finishReason"in t)||typeof t.finishReason!="string")throw new Error('"finish_message" parts expect an object with a "finishReason" property.');let e={finishReason:t.finishReason};return"usage"in t&&t.usage!=null&&typeof t.usage=="object"&&"promptTokens"in t.usage&&"completionTokens"in t.usage&&(e.usage={promptTokens:typeof t.usage.promptTokens=="number"?t.usage.promptTokens:Number.NaN,completionTokens:typeof t.usage.completionTokens=="number"?t.usage.completionTokens:Number.NaN}),{type:"finish_message",value:e}}},Ca={code:"e",name:"finish_step",parse:t=>{if(t==null||typeof t!="object"||!("finishReason"in t)||typeof t.finishReason!="string")throw new Error('"finish_step" parts expect an object with a "finishReason" property.');let e={finishReason:t.finishReason,isContinued:!1};return"usage"in t&&t.usage!=null&&typeof t.usage=="object"&&"promptTokens"in t.usage&&"completionTokens"in t.usage&&(e.usage={promptTokens:typeof t.usage.promptTokens=="number"?t.usage.promptTokens:Number.NaN,completionTokens:typeof t.usage.completionTokens=="number"?t.usage.completionTokens:Number.NaN}),"isContinued"in t&&typeof t.isContinued=="boolean"&&(e.isContinued=t.isContinued),{type:"finish_step",value:e}}},Z2=[va,ya,ba,xa,wa,ka,Sa,Ta,Ea,Ca],tA={[va.code]:va,[ya.code]:ya,[ba.code]:ba,[xa.code]:xa,[wa.code]:wa,[ka.code]:ka,[Sa.code]:Sa,[Ta.code]:Ta,[Ea.code]:Ea,[Ca.code]:Ca};va.name+"",va.code,ya.name+"",ya.code,ba.name+"",ba.code,xa.name+"",xa.code,wa.name+"",wa.code,ka.name+"",ka.code,Sa.name+"",Sa.code,Ta.name+"",Ta.code,Ea.name+"",Ea.code,Ca.name+"",Ca.code;var eA=Z2.map(t=>t.code),nA=t=>{let e=t.indexOf(":");if(e===-1)throw new Error("Failed to parse stream string. No separator found.");let n=t.slice(0,e);if(!eA.includes(n))throw new Error(`Failed to parse stream string. Invalid code ${n}.`);let r=n,i=t.slice(e+1),o=JSON.parse(i);return tA[r].parse(o)},rA=10;function iA(t,e){let n=new Uint8Array(e),r=0;for(let i of t)n.set(i,r),r+=i.length;return t.length=0,n}async function oA({stream:t,onTextPart:e,onDataPart:n,onErrorPart:r,onToolCallStreamingStartPart:i,onToolCallDeltaPart:o,onToolCallPart:a,onToolResultPart:s,onMessageAnnotationsPart:l,onFinishMessagePart:u,onFinishStepPart:c}){let d=t.getReader(),h=new TextDecoder,p=[],m=0;for(;;){let{value:v}=await d.read();if(v&&(p.push(v),m+=v.length,v[v.length-1]!==rA))continue;if(p.length===0)break;let b=iA(p,m);m=0;let f=h.decode(b,{stream:!0}).split(`
`).filter(g=>g!=="").map(nA);for(let{type:g,value:y}of f)switch(g){case"text":await e?.(y);break;case"data":await n?.(y);break;case"error":await r?.(y);break;case"message_annotations":await l?.(y);break;case"tool_call_streaming_start":await i?.(y);break;case"tool_call_delta":await o?.(y);break;case"tool_call":await a?.(y);break;case"tool_result":await s?.(y);break;case"finish_message":await u?.(y);break;case"finish_step":await c?.(y);break;default:{let w=g;throw new Error(`Unknown stream part type: ${w}`)}}}}function aA({promptTokens:t,completionTokens:e}){return{promptTokens:t,completionTokens:e,totalTokens:t+e}}async function sA({stream:t,update:e,onToolCall:n,onFinish:r,generateId:i=Cw,getCurrentDate:o=()=>new Date}){let a=o(),s,l=!0,u=[],c=[],d,h={},p={completionTokens:NaN,promptTokens:NaN,totalTokens:NaN},m="unknown";function v(){let f=[...c];if(s==null){e(u,f);return}d!=null&&d.length&&(s.annotations=d);let g={...s,revisionId:i()};e([...u,g],f)}function b(){return(l||s==null)&&(s!=null&&u.push(s),l=!1,s={id:i(),role:"assistant",content:"",createdAt:a}),s}await oA({stream:t,onTextPart(f){let g=b();s={...g,content:g.content+f},v()},onToolCallStreamingStartPart(f){let g=b();g.toolInvocations==null&&(g.toolInvocations=[]),h[f.toolCallId]={text:"",toolName:f.toolName,index:g.toolInvocations.length},g.toolInvocations.push({state:"partial-call",toolCallId:f.toolCallId,toolName:f.toolName,args:void 0}),v()},onToolCallDeltaPart(f){let g=b(),y=h[f.toolCallId];y.text+=f.argsTextDelta;let{value:w}=J2(y.text);g.toolInvocations[y.index]={state:"partial-call",toolCallId:f.toolCallId,toolName:y.toolName,args:w},v()},async onToolCallPart(f){let g=b();if(h[f.toolCallId]!=null?g.toolInvocations[h[f.toolCallId].index]={state:"call",...f}:(g.toolInvocations==null&&(g.toolInvocations=[]),g.toolInvocations.push({state:"call",...f})),n){let y=await n({toolCall:f});y!=null&&(g.toolInvocations[g.toolInvocations.length-1]={state:"result",...f,result:y})}v()},onToolResultPart(f){let g=b().toolInvocations;if(g==null)throw new Error("tool_result must be preceded by a tool_call");let y=g.findIndex(w=>w.toolCallId===f.toolCallId);if(y===-1)throw new Error("tool_result must be preceded by a tool_call with the same toolCallId");g[y]={...g[y],state:"result",...f},v()},onDataPart(f){c.push(...f),v()},onMessageAnnotationsPart(f){d==null?d=[...f]:d.push(...f),v()},onFinishStepPart(f){l=!f.isContinued},onFinishMessagePart(f){m=f.finishReason,f.usage!=null&&(p=aA(f.usage))},onErrorPart(f){throw new Error(f)}}),r?.({message:s,finishReason:m,usage:p})}async function lA({stream:t,onTextPart:e}){let n=t.pipeThrough(new TextDecoderStream).getReader();for(;;){let{done:r,value:i}=await n.read();if(r)break;await e(i)}}var uA=()=>fetch;async function cA({api:t,body:e,streamProtocol:n="data",credentials:r,headers:i,abortController:o,restoreMessagesOnFailure:a,onResponse:s,onUpdate:l,onFinish:u,onToolCall:c,generateId:d,fetch:h=uA()}){var p,m;let v=await h(t,{method:"POST",body:JSON.stringify(e),headers:{"Content-Type":"application/json",...i},signal:(p=o?.())==null?void 0:p.signal,credentials:r}).catch(b=>{throw a(),b});if(s)try{await s(v)}catch(b){throw b}if(!v.ok)throw a(),new Error((m=await v.text())!=null?m:"Failed to fetch the chat response.");if(!v.body)throw new Error("The response body is empty.");switch(n){case"text":{let b={id:d(),createdAt:new Date,role:"assistant",content:""};await lA({stream:v.body,onTextPart:f=>{b.content+=f,l([{...b}],[])}}),u?.(b,{usage:{completionTokens:NaN,promptTokens:NaN,totalTokens:NaN},finishReason:"unknown"});return}case"data":{await sA({stream:v.body,update:l,onToolCall:c,onFinish({message:b,finishReason:f,usage:g}){u&&b!=null&&u(b,{usage:g,finishReason:f})},generateId:d});return}default:{let b=n;throw new Error(`Unknown stream protocol: ${b}`)}}}var Pw={exports:{}},Aw={};var Xi=S;function dA(t,e){return t===e&&(t!==0||1/t===1/e)||t!==t&&e!==e}var hA=typeof Object.is=="function"?Object.is:dA,pA=Xi.useState,fA=Xi.useEffect,mA=Xi.useLayoutEffect,gA=Xi.useDebugValue;function vA(t,e){var n=e(),r=pA({inst:{value:n,getSnapshot:e}}),i=r[0].inst,o=r[1];return mA(function(){i.value=n,i.getSnapshot=e,wc(i)&&o({inst:i})},[t,n,e]),fA(function(){return wc(i)&&o({inst:i}),t(function(){wc(i)&&o({inst:i})})},[t]),gA(n),n}function wc(t){var e=t.getSnapshot;t=t.value;try{var n=e();return!hA(t,n)}catch{return!0}}function yA(t,e){return e()}var bA=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?yA:vA;Aw.useSyncExternalStore=Xi.useSyncExternalStore!==void 0?Xi.useSyncExternalStore:bA;Pw.exports=Aw;var xA=Pw.exports,rr=()=>{},me=rr(),kc=Object,st=t=>t===me,cn=t=>typeof t=="function",fr=(t,e)=>({...t,...e}),wA=t=>cn(t.then),Cs=new WeakMap,kA=0,Pa=t=>{let e=typeof t,n=t&&t.constructor,r=n==Date,i,o;if(kc(t)===t&&!r&&n!=RegExp){if(i=Cs.get(t),i)return i;if(i=++kA+"~",Cs.set(t,i),n==Array){for(i="@",o=0;o<t.length;o++)i+=Pa(t[o])+",";Cs.set(t,i)}if(n==kc){i="#";let a=kc.keys(t).sort();for(;!st(o=a.pop());)st(t[o])||(i+=o+":"+Pa(t[o])+",");Cs.set(t,i)}}else i=r?t.toJSON():e=="symbol"?t.toString():e=="string"?JSON.stringify(t):""+t;return i},En=new WeakMap,Sc={},Ps={},Sf="undefined",Mu=typeof window!=Sf,uh=typeof document!=Sf,SA=()=>Mu&&typeof window.requestAnimationFrame!=Sf,Mw=(t,e)=>{let n=En.get(t);return[()=>!st(e)&&t.get(e)||Sc,r=>{if(!st(e)){let i=t.get(e);e in Ps||(Ps[e]=i),n[5](e,fr(i,r),i||Sc)}},n[6],()=>!st(e)&&e in Ps?Ps[e]:!st(e)&&t.get(e)||Sc]},ch=!0,TA=()=>ch,[dh,hh]=Mu&&window.addEventListener?[window.addEventListener.bind(window),window.removeEventListener.bind(window)]:[rr,rr],EA=()=>{let t=uh&&document.visibilityState;return st(t)||t!=="hidden"},CA=t=>(uh&&document.addEventListener("visibilitychange",t),dh("focus",t),()=>{uh&&document.removeEventListener("visibilitychange",t),hh("focus",t)}),PA=t=>{let e=()=>{ch=!0,t()},n=()=>{ch=!1};return dh("online",e),dh("offline",n),()=>{hh("online",e),hh("offline",n)}},AA={isOnline:TA,isVisible:EA},MA={initFocus:CA,initReconnect:PA},yv=!Dp.useId,Aa=!Mu||"Deno"in window,DA=t=>SA()?window.requestAnimationFrame(t):setTimeout(t,1),Tc=Aa?S.useEffect:S.useLayoutEffect,Ec=typeof navigator<"u"&&navigator.connection,bv=!Aa&&Ec&&(["slow-2g","2g"].includes(Ec.effectiveType)||Ec.saveData),Tf=t=>{if(cn(t))try{t=t()}catch{t=""}let e=t;return t=typeof t=="string"?t:(Array.isArray(t)?t.length:t)?Pa(t):"",[t,e]},RA=0,ph=()=>++RA,Dw=0,Rw=1,Iw=2,IA=3,So={__proto__:null,ERROR_REVALIDATE_EVENT:IA,FOCUS_EVENT:Dw,MUTATE_EVENT:Iw,RECONNECT_EVENT:Rw};async function Lw(...t){let[e,n,r,i]=t,o=fr({populateCache:!0,throwOnError:!0},typeof i=="boolean"?{revalidate:i}:i||{}),a=o.populateCache,s=o.rollbackOnError,l=o.optimisticData,u=h=>typeof s=="function"?s(h):s!==!1,c=o.throwOnError;if(cn(n)){let h=n,p=[],m=e.keys();for(let v of m)!/^\$(inf|sub)\$/.test(v)&&h(e.get(v)._k)&&p.push(v);return Promise.all(p.map(d))}return d(n);async function d(h){let[p]=Tf(h);if(!p)return;let[m,v]=Mw(e,p),[b,f,g,y]=En.get(e),w=()=>{let B=b[p];return(cn(o.revalidate)?o.revalidate(m().data,h):o.revalidate!==!1)&&(delete g[p],delete y[p],B&&B[0])?B[0](Iw).then(()=>m().data):m().data};if(t.length<3)return w();let C=r,k,M=ph();f[p]=[M,0];let P=!st(l),R=m(),E=R.data,L=R._c,N=st(L)?E:L;if(P&&(l=cn(l)?l(N,E):l,v({data:l,_c:N})),cn(C))try{C=C(N)}catch(B){k=B}if(C&&wA(C))if(C=await C.catch(B=>{k=B}),M!==f[p][0]){if(k)throw k;return C}else k&&P&&u(k)&&(a=!0,v({data:N,_c:me}));if(a&&!k)if(cn(a)){let B=a(C,N);v({data:B,error:me,_c:me})}else v({data:C,error:me,_c:me});if(f[p][1]=ph(),Promise.resolve(w()).then(()=>{v({_c:me})}),k){if(c)throw k;return}return C}}var xv=(t,e)=>{for(let n in t)t[n][0]&&t[n][0](e)},LA=(t,e)=>{if(!En.has(t)){let n=fr(MA,e),r={},i=Lw.bind(me,t),o=rr,a={},s=(c,d)=>{let h=a[c]||[];return a[c]=h,h.push(d),()=>h.splice(h.indexOf(d),1)},l=(c,d,h)=>{t.set(c,d);let p=a[c];if(p)for(let m of p)m(d,h)},u=()=>{if(!En.has(t)&&(En.set(t,[r,{},{},{},i,l,s]),!Aa)){let c=n.initFocus(setTimeout.bind(me,xv.bind(me,r,Dw))),d=n.initReconnect(setTimeout.bind(me,xv.bind(me,r,Rw)));o=()=>{c&&c(),d&&d(),En.delete(t)}}};return u(),[t,i,u,o]}return[t,En.get(t)[4]]},jA=(t,e,n,r,i)=>{let o=n.errorRetryCount,a=i.retryCount,s=~~((Math.random()+.5)*(1<<(a<8?a:8)))*n.errorRetryInterval;!st(o)&&a>o||setTimeout(r,s,i)},OA=(t,e)=>Pa(t)==Pa(e),[jw,_A]=LA(new Map),NA=fr({onLoadingSlow:rr,onSuccess:rr,onError:rr,onErrorRetry:jA,onDiscarded:rr,revalidateOnFocus:!0,revalidateOnReconnect:!0,revalidateIfStale:!0,shouldRetryOnError:!0,errorRetryInterval:bv?1e4:5e3,focusThrottleInterval:5*1e3,dedupingInterval:2*1e3,loadingTimeout:bv?5e3:3e3,compare:OA,isPaused:()=>!1,cache:jw,mutate:_A,fallback:{}},AA),FA=(t,e)=>{let n=fr(t,e);if(e){let{use:r,fallback:i}=t,{use:o,fallback:a}=e;r&&o&&(n.use=r.concat(o)),i&&a&&(n.fallback=fr(i,a))}return n},VA=S.createContext({}),zA="$inf$",Ow=Mu&&window.__SWR_DEVTOOLS_USE__,BA=Ow?window.__SWR_DEVTOOLS_USE__:[],UA=()=>{Ow&&(window.__SWR_DEVTOOLS_REACT__=Dp)},$A=t=>cn(t[1])?[t[0],t[1],t[2]||{}]:[t[0],null,(t[1]===null?t[2]:t[1])||{}],HA=()=>fr(NA,S.useContext(VA)),WA=t=>(e,n,r)=>t(e,n&&((...i)=>{let[o]=Tf(e),[,,,a]=En.get(jw);if(o.startsWith(zA))return n(...i);let s=a[o];return st(s)?n(...i):(delete a[o],s)}),r),qA=BA.concat(WA),YA=t=>function(...e){let n=HA(),[r,i,o]=$A(e),a=FA(n,o),s=t,{use:l}=a,u=(l||[]).concat(qA);for(let c=u.length;c--;)s=u[c](s);return s(r,i||a.fetcher||null,a)},KA=(t,e,n)=>{let r=e[t]||(e[t]=[]);return r.push(n),()=>{let i=r.indexOf(n);i>=0&&(r[i]=r[r.length-1],r.pop())}};UA();var wv=Dp.use||(t=>{if(t.status==="pending")throw t;if(t.status==="fulfilled")return t.value;throw t.status==="rejected"?t.reason:(t.status="pending",t.then(e=>{t.status="fulfilled",t.value=e},e=>{t.status="rejected",t.reason=e}),t)}),Cc={dedupe:!0},XA=(t,e,n)=>{let{cache:r,compare:i,suspense:o,fallbackData:a,revalidateOnMount:s,revalidateIfStale:l,refreshInterval:u,refreshWhenHidden:c,refreshWhenOffline:d,keepPreviousData:h}=n,[p,m,v,b]=En.get(r),[f,g]=Tf(t),y=S.useRef(!1),w=S.useRef(!1),C=S.useRef(f),k=S.useRef(e),M=S.useRef(n),P=()=>M.current,R=()=>P().isVisible()&&P().isOnline(),[E,L,N,B]=Mw(r,f),U=S.useRef({}).current,F=st(a)?n.fallback[f]:a,K=(Y,nt)=>{for(let xt in U){let rt=xt;if(rt==="data"){if(!i(Y[rt],nt[rt])&&(!st(Y[rt])||!i(Mt,nt[rt])))return!1}else if(nt[rt]!==Y[rt])return!1}return!0},Q=S.useMemo(()=>{let Y=!f||!e?!1:st(s)?P().isPaused()||o?!1:st(l)?!0:l:s,nt=Vt=>{let Ye=fr(Vt);return delete Ye._k,Y?{isValidating:!0,isLoading:!0,...Ye}:Ye},xt=E(),rt=B(),je=nt(xt),rn=xt===rt?je:nt(rt),Kt=je;return[()=>{let Vt=nt(E());return K(Vt,Kt)?(Kt.data=Vt.data,Kt.isLoading=Vt.isLoading,Kt.isValidating=Vt.isValidating,Kt.error=Vt.error,Kt):(Kt=Vt,Vt)},()=>rn]},[r,f]),I=xA.useSyncExternalStore(S.useCallback(Y=>N(f,(nt,xt)=>{K(xt,nt)||Y()}),[r,f]),Q[0],Q[1]),z=!y.current,x=p[f]&&p[f].length>0,X=I.data,Z=st(X)?F:X,T=I.error,bt=S.useRef(Z),Mt=h?st(X)?bt.current:X:Z,at=x&&!st(T)?!1:z&&!st(s)?s:P().isPaused()?!1:o?st(Z)?!1:l:st(Z)||l,ae=!!(f&&e&&z&&at),J=st(I.isValidating)?ae:I.isValidating,kt=st(I.isLoading)?ae:I.isLoading,lt=S.useCallback(async Y=>{let nt=k.current;if(!f||!nt||w.current||P().isPaused())return!1;let xt,rt,je=!0,rn=Y||{},Kt=!v[f]||!rn.dedupe,Vt=()=>yv?!w.current&&f===C.current&&y.current:f===C.current,Ye={isValidating:!1,isLoading:!1},rs=()=>{L(Ye)},is=()=>{let he=v[f];he&&he[1]===rt&&delete v[f]},os={isValidating:!0};st(E().data)&&(os.isLoading=!0);try{if(Kt&&(L(os),n.loadingTimeout&&st(E().data)&&setTimeout(()=>{je&&Vt()&&P().onLoadingSlow(f,n)},n.loadingTimeout),v[f]=[nt(g),ph()]),[xt,rt]=v[f],xt=await xt,Kt&&setTimeout(is,n.dedupingInterval),!v[f]||v[f][1]!==rt)return Kt&&Vt()&&P().onDiscarded(f),!1;Ye.error=me;let he=m[f];if(!st(he)&&(rt<=he[0]||rt<=he[1]||he[1]===0))return rs(),Kt&&Vt()&&P().onDiscarded(f),!1;let Ke=E().data;Ye.data=i(Ke,xt)?Ke:xt,Kt&&Vt()&&P().onSuccess(xt,f,n)}catch(he){is();let Ke=P(),{shouldRetryOnError:D}=Ke;Ke.isPaused()||(Ye.error=he,Kt&&Vt()&&(Ke.onError(he,f,Ke),(D===!0||cn(D)&&D(he))&&(!P().revalidateOnFocus||!P().revalidateOnReconnect||R())&&Ke.onErrorRetry(he,f,Ke,_=>{let H=p[f];H&&H[0]&&H[0](So.ERROR_REVALIDATE_EVENT,_)},{retryCount:(rn.retryCount||0)+1,dedupe:!0})))}return je=!1,rs(),!0},[f,r]),St=S.useCallback((...Y)=>Lw(r,C.current,...Y),[]);if(Tc(()=>{k.current=e,M.current=n,st(X)||(bt.current=X)}),Tc(()=>{if(!f)return;let Y=lt.bind(me,Cc),nt=0,xt=KA(f,p,(rt,je={})=>{if(rt==So.FOCUS_EVENT){let rn=Date.now();P().revalidateOnFocus&&rn>nt&&R()&&(nt=rn+P().focusThrottleInterval,Y())}else if(rt==So.RECONNECT_EVENT)P().revalidateOnReconnect&&R()&&Y();else{if(rt==So.MUTATE_EVENT)return lt();if(rt==So.ERROR_REVALIDATE_EVENT)return lt(je)}});return w.current=!1,C.current=f,y.current=!0,L({_k:g}),at&&(st(Z)||Aa?Y():DA(Y)),()=>{w.current=!0,xt()}},[f]),Tc(()=>{let Y;function nt(){let rt=cn(u)?u(E().data):u;rt&&Y!==-1&&(Y=setTimeout(xt,rt))}function xt(){!E().error&&(c||P().isVisible())&&(d||P().isOnline())?lt(Cc).then(nt):nt()}return nt(),()=>{Y&&(clearTimeout(Y),Y=-1)}},[u,c,d,f]),S.useDebugValue(Mt),o&&st(Z)&&f){if(!yv&&Aa)throw new Error("Fallback data is required when using suspense in SSR.");k.current=e,M.current=n,w.current=!1;let Y=b[f];if(!st(Y)){let nt=St(Y);wv(nt)}if(st(T)){let nt=lt(Cc);st(Mt)||(nt.status="fulfilled",nt.value=!0),wv(nt)}else throw T}return{mutate:St,get data(){return U.data=!0,Mt},get error(){return U.error=!0,T},get isValidating(){return U.isValidating=!0,J},get isLoading(){return U.isLoading=!0,kt}}},As=YA(XA);function GA(t,e){if(typeof t!="function")throw new TypeError(`Expected the first argument to be a \`function\`, got \`${typeof t}\`.`);let n,r=0;return function(...i){clearTimeout(n);let o=Date.now(),a=o-r,s=e-a;s<=0?(r=o,t.apply(this,i)):n=setTimeout(()=>{r=Date.now(),t.apply(this,i)},s)}}var QA=GA,JA=du(QA);function kv(t,e){return e!=null?JA(t,e):t}var ZA=async(t,e,n,r,i,o,a,s,l,u,c,d,h,p,m,v,b)=>{var f;let g=a.current;n(e.messages,!1);let y=p?e.messages:e.messages.map(({role:C,content:k,experimental_attachments:M,data:P,annotations:R,toolInvocations:E})=>({role:C,content:k,...M!==void 0&&{experimental_attachments:M},...P!==void 0&&{data:P},...R!==void 0&&{annotations:R},...E!==void 0&&{toolInvocations:E}})),w=i.current;return await cA({api:t,body:(f=m?.({messages:e.messages,requestData:e.data,requestBody:e.body}))!=null?f:{messages:y,data:e.data,...o.current.body,...e.body},streamProtocol:u,credentials:o.current.credentials,headers:{...o.current.headers,...e.headers},abortController:()=>s.current,restoreMessagesOnFailure(){b||n(g,!1)},onResponse:d,onUpdate(C,k){n([...e.messages,...C],!1),k!=null&&k.length&&r([...w??[],...k],!1)},onToolCall:h,onFinish:c,generateId:l,fetch:v})};function tM({api:t="/api/chat",id:e,initialMessages:n,initialInput:r="",sendExtraMessageFields:i,onToolCall:o,experimental_prepareRequestBody:a,maxSteps:s=1,streamProtocol:l="data",onResponse:u,onFinish:c,onError:d,credentials:h,headers:p,body:m,generateId:v=Cw,fetch:b,keepLastMessageOnError:f=!0,experimental_throttle:g}={}){let y=S.useId(),w=e??y,C=typeof t=="string"?[t,w]:w,[k]=S.useState([]),{data:M,mutate:P}=As([C,"messages"],null,{fallbackData:n??k}),R=S.useRef(M||[]);S.useEffect(()=>{R.current=M||[]},[M]);let{data:E,mutate:L}=As([C,"streamData"],null),N=S.useRef(E);S.useEffect(()=>{N.current=E},[E]);let{data:B=!1,mutate:U}=As([C,"loading"],null),{data:F=void 0,mutate:K}=As([C,"error"],null),Q=S.useRef(null),I=S.useRef({credentials:h,headers:p,body:m});S.useEffect(()=>{I.current={credentials:h,headers:p,body:m}},[h,p,m]);let z=S.useCallback(async J=>{let kt=R.current.length;try{U(!0),K(void 0);let Y=new AbortController;Q.current=Y,await ZA(t,J,kv(P,g),kv(L,g),N,I,R,Q,v,l,c,u,o,i,a,b,f),Q.current=null}catch(Y){if(Y.name==="AbortError")return Q.current=null,null;d&&Y instanceof Error&&d(Y),K(Y)}finally{U(!1)}let lt=R.current,St=lt[lt.length-1];lt.length>kt&&St!=null&&s>1&&Sv(St)&&eM(lt)<s&&await z({messages:lt})},[P,U,t,I,u,c,d,K,L,N,l,i,a,o,s,R,Q,v,b,f,g]),x=S.useCallback(async(J,{data:kt,headers:lt,body:St,experimental_attachments:Y}={})=>{var nt,xt;J.id||(J.id=v());let rt=await Tv(Y),je=R.current.concat({...J,id:(nt=J.id)!=null?nt:v(),createdAt:(xt=J.createdAt)!=null?xt:new Date,experimental_attachments:rt.length>0?rt:void 0});return z({messages:je,headers:lt,body:St,data:kt})},[z,v]),X=S.useCallback(async({data:J,headers:kt,body:lt}={})=>{let St=R.current;if(St.length===0)return null;let Y=St[St.length-1];return z({messages:Y.role==="assistant"?St.slice(0,-1):St,headers:kt,body:lt,data:J})},[z]),Z=S.useCallback(()=>{Q.current&&(Q.current.abort(),Q.current=null)},[]),T=S.useCallback(J=>{typeof J=="function"&&(J=J(R.current)),P(J,!1),R.current=J},[P]),bt=S.useCallback(J=>{typeof J=="function"&&(J=J(N.current)),L(J,!1),N.current=J},[L]),[Mt,at]=S.useState(r),ae=S.useCallback(async(J,kt={},lt)=>{var St;if((St=J?.preventDefault)==null||St.call(J),!Mt&&!kt.allowEmptySubmit)return;lt&&(I.current={...I.current,...lt});let Y=await Tv(kt.experimental_attachments),nt={messages:!Mt&&!Y.length&&kt.allowEmptySubmit?R.current:R.current.concat({id:v(),createdAt:new Date,role:"user",content:Mt,experimental_attachments:Y.length>0?Y:void 0}),headers:kt.headers,body:kt.body,data:kt.data};z(nt),at("")},[Mt,v,z]);return{messages:M||[],setMessages:T,data:E,setData:bt,error:F,append:x,reload:X,stop:Z,input:Mt,setInput:at,handleInputChange:J=>{at(J.target.value)},handleSubmit:ae,isLoading:B,addToolResult:({toolCallId:J,result:kt})=>{let lt=R.current.map((Y,nt,xt)=>nt===xt.length-1&&Y.role==="assistant"&&Y.toolInvocations?{...Y,toolInvocations:Y.toolInvocations.map(rt=>rt.toolCallId===J?{...rt,result:kt}:rt)}:Y);P(lt,!1);let St=lt[lt.length-1];Sv(St)&&z({messages:lt})}}}function Sv(t){return t.role==="assistant"&&t.toolInvocations&&t.toolInvocations.length>0&&t.toolInvocations.every(e=>"result"in e)}function eM(t){let e=0;for(let n=t.length-1;n>=0&&t[n].role==="assistant";n--)e++;return e}async function Tv(t){if(t==null)return[];if(t instanceof FileList)return Promise.all(Array.from(t).map(async e=>{let{name:n,type:r}=e,i=await new Promise((o,a)=>{let s=new FileReader;s.onload=l=>{var u;o((u=l.target)==null?void 0:u.result)},s.onerror=l=>a(l),s.readAsDataURL(e)});return{name:n,contentType:r,url:i}}));if(Array.isArray(t))return t;throw new Error("Invalid attachments type")}var nM=tM;async function rM(t,e,n,r){let i=n?new Date(n).toISOString():new Date().toISOString();return await fetch("https://api.leoai.hu/events",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({sessionId:t,type:e,createdAt:i,metadata:r})})}async function iM({chatbotId:t,metadata:e}){return await(await fetch("https://api.leoai.hu/sessions",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({chatbotId:t,metadata:e})})).json()}var oM={data:""},aM=t=>typeof window=="object"?((t?t.querySelector("#_goober"):window._goober)||Object.assign((t||document.head).appendChild(document.createElement("style")),{innerHTML:" ",id:"_goober"})).firstChild:t||oM,sM=/(?:([\u0080-\uFFFF\w-%@]+) *:? *([^{;]+?);|([^;}{]*?) *{)|(}\s*)/g,lM=/\/\*[^]*?\*\/|  +/g,Ev=/\n+/g,tr=(t,e)=>{let n="",r="",i="";for(let o in t){let a=t[o];o[0]=="@"?o[1]=="i"?n=o+" "+a+";":r+=o[1]=="f"?tr(a,o):o+"{"+tr(a,o[1]=="k"?"":e)+"}":typeof a=="object"?r+=tr(a,e?e.replace(/([^,])+/g,s=>o.replace(/([^,]*:\S+\([^)]*\))|([^,])+/g,l=>/&/.test(l)?l.replace(/&/g,s):s?s+" "+l:l)):o):a!=null&&(o=/^--/.test(o)?o:o.replace(/[A-Z]/g,"-$&").toLowerCase(),i+=tr.p?tr.p(o,a):o+":"+a+";")}return n+(e&&i?e+"{"+i+"}":i)+r},kn={},_w=t=>{if(typeof t=="object"){let e="";for(let n in t)e+=n+_w(t[n]);return e}return t},uM=(t,e,n,r,i)=>{let o=_w(t),a=kn[o]||(kn[o]=(l=>{let u=0,c=11;for(;u<l.length;)c=101*c+l.charCodeAt(u++)>>>0;return"go"+c})(o));if(!kn[a]){let l=o!==t?t:(u=>{let c,d,h=[{}];for(;c=sM.exec(u.replace(lM,""));)c[4]?h.shift():c[3]?(d=c[3].replace(Ev," ").trim(),h.unshift(h[0][d]=h[0][d]||{})):h[0][c[1]]=c[2].replace(Ev," ").trim();return h[0]})(t);kn[a]=tr(i?{["@keyframes "+a]:l}:l,n?"":"."+a)}let s=n&&kn.g?kn.g:null;return n&&(kn.g=kn[a]),((l,u,c,d)=>{d?u.data=u.data.replace(d,l):u.data.indexOf(l)===-1&&(u.data=c?l+u.data:u.data+l)})(kn[a],e,r,s),a},cM=(t,e,n)=>t.reduce((r,i,o)=>{let a=e[o];if(a&&a.call){let s=a(n),l=s&&s.props&&s.props.className||/^go/.test(s)&&s;a=l?"."+l:s&&typeof s=="object"?s.props?"":tr(s,""):s===!1?"":s}return r+i+(a??"")},"");function Du(t){let e=this||{},n=t.call?t(e.p):t;return uM(n.unshift?n.raw?cM(n,[].slice.call(arguments,1),e.p):n.reduce((r,i)=>Object.assign(r,i&&i.call?i(e.p):i),{}):n,aM(e.target),e.g,e.o,e.k)}var Nw,fh,mh;Du.bind({g:1});var $n=Du.bind({k:1});function dM(t,e,n,r){tr.p=e,Nw=t,fh=n,mh=r}function Tr(t,e){let n=this||{};return function(){let r=arguments;function i(o,a){let s=Object.assign({},o),l=s.className||i.className;n.p=Object.assign({theme:fh&&fh()},s),n.o=/ *go\d+/.test(l),s.className=Du.apply(n,r)+(l?" "+l:"");let u=t;return t[0]&&(u=s.as||t,delete s.as),mh&&u[0]&&mh(s),Nw(u,s)}return i}}var hM=t=>typeof t=="function",Fl=(t,e)=>hM(t)?t(e):t,pM=(()=>{let t=0;return()=>(++t).toString()})(),Fw=(()=>{let t;return()=>{if(t===void 0&&typeof window<"u"){let e=matchMedia("(prefers-reduced-motion: reduce)");t=!e||e.matches}return t}})(),fM=20,Js=new Map,mM=1e3,Cv=t=>{if(Js.has(t))return;let e=setTimeout(()=>{Js.delete(t),ni({type:4,toastId:t})},mM);Js.set(t,e)},gM=t=>{let e=Js.get(t);e&&clearTimeout(e)},gh=(t,e)=>{switch(e.type){case 0:return{...t,toasts:[e.toast,...t.toasts].slice(0,fM)};case 1:return e.toast.id&&gM(e.toast.id),{...t,toasts:t.toasts.map(o=>o.id===e.toast.id?{...o,...e.toast}:o)};case 2:let{toast:n}=e;return t.toasts.find(o=>o.id===n.id)?gh(t,{type:1,toast:n}):gh(t,{type:0,toast:n});case 3:let{toastId:r}=e;return r?Cv(r):t.toasts.forEach(o=>{Cv(o.id)}),{...t,toasts:t.toasts.map(o=>o.id===r||r===void 0?{...o,visible:!1}:o)};case 4:return e.toastId===void 0?{...t,toasts:[]}:{...t,toasts:t.toasts.filter(o=>o.id!==e.toastId)};case 5:return{...t,pausedAt:e.time};case 6:let i=e.time-(t.pausedAt||0);return{...t,pausedAt:void 0,toasts:t.toasts.map(o=>({...o,pauseDuration:o.pauseDuration+i}))}}},Zs=[],tl={toasts:[],pausedAt:void 0},ni=t=>{tl=gh(tl,t),Zs.forEach(e=>{e(tl)})},vM={blank:4e3,error:4e3,success:2e3,loading:1/0,custom:4e3},Vw=(t={})=>{let[e,n]=S.useState(tl);S.useEffect(()=>(Zs.push(n),()=>{let i=Zs.indexOf(n);i>-1&&Zs.splice(i,1)}),[e]);let r=e.toasts.map(i=>{var o,a;return{...t,...t[i.type],...i,duration:i.duration||((o=t[i.type])==null?void 0:o.duration)||t?.duration||vM[i.type],style:{...t.style,...(a=t[i.type])==null?void 0:a.style,...i.style}}});return{...e,toasts:r}},yM=(t,e="blank",n)=>({createdAt:Date.now(),visible:!0,type:e,ariaProps:{role:"status","aria-live":"polite"},message:t,pauseDuration:0,...n,id:n?.id||pM()}),Ka=t=>(e,n)=>{let r=yM(e,t,n);return ni({type:2,toast:r}),r.id},Ce=(t,e)=>Ka("blank")(t,e);Ce.error=Ka("error");Ce.success=Ka("success");Ce.loading=Ka("loading");Ce.custom=Ka("custom");Ce.dismiss=t=>{ni({type:3,toastId:t})};Ce.remove=t=>ni({type:4,toastId:t});Ce.promise=(t,e,n)=>{let r=Ce.loading(e.loading,{...n,...n?.loading});return t.then(i=>(Ce.success(Fl(e.success,i),{id:r,...n,...n?.success}),i)).catch(i=>{Ce.error(Fl(e.error,i),{id:r,...n,...n?.error})}),t};var bM=(t,e)=>{ni({type:1,toast:{id:t,height:e}})},xM=()=>{ni({type:5,time:Date.now()})},wM=t=>{let{toasts:e,pausedAt:n}=Vw(t);S.useEffect(()=>{if(n)return;let o=Date.now(),a=e.map(s=>{if(s.duration===1/0)return;let l=(s.duration||0)+s.pauseDuration-(o-s.createdAt);if(l<0){s.visible&&Ce.dismiss(s.id);return}return setTimeout(()=>Ce.dismiss(s.id),l)});return()=>{a.forEach(s=>s&&clearTimeout(s))}},[e,n]);let r=S.useCallback(()=>{n&&ni({type:6,time:Date.now()})},[n]),i=S.useCallback((o,a)=>{let{reverseOrder:s=!1,gutter:l=8,defaultPosition:u}=a||{},c=e.filter(p=>(p.position||u)===(o.position||u)&&p.height),d=c.findIndex(p=>p.id===o.id),h=c.filter((p,m)=>m<d&&p.visible).length;return c.filter(p=>p.visible).slice(...s?[h+1]:[0,h]).reduce((p,m)=>p+(m.height||0)+l,0)},[e]);return{toasts:e,handlers:{updateHeight:bM,startPause:xM,endPause:r,calculateOffset:i}}},kM=$n`
from {
  transform: scale(0) rotate(45deg);
	opacity: 0;
}
to {
 transform: scale(1) rotate(45deg);
  opacity: 1;
}`,SM=$n`
from {
  transform: scale(0);
  opacity: 0;
}
to {
  transform: scale(1);
  opacity: 1;
}`,TM=$n`
from {
  transform: scale(0) rotate(90deg);
	opacity: 0;
}
to {
  transform: scale(1) rotate(90deg);
	opacity: 1;
}`,EM=Tr("div")`
  width: 20px;
  opacity: 0;
  height: 20px;
  border-radius: 10px;
  background: ${t=>t.primary||"#ff4b4b"};
  position: relative;
  transform: rotate(45deg);

  animation: ${kM} 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275)
    forwards;
  animation-delay: 100ms;

  &:after,
  &:before {
    content: '';
    animation: ${SM} 0.15s ease-out forwards;
    animation-delay: 150ms;
    position: absolute;
    border-radius: 3px;
    opacity: 0;
    background: ${t=>t.secondary||"#fff"};
    bottom: 9px;
    left: 4px;
    height: 2px;
    width: 12px;
  }

  &:before {
    animation: ${TM} 0.15s ease-out forwards;
    animation-delay: 180ms;
    transform: rotate(90deg);
  }
`,CM=$n`
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
`,PM=Tr("div")`
  width: 12px;
  height: 12px;
  box-sizing: border-box;
  border: 2px solid;
  border-radius: 100%;
  border-color: ${t=>t.secondary||"#e0e0e0"};
  border-right-color: ${t=>t.primary||"#616161"};
  animation: ${CM} 1s linear infinite;
`,AM=$n`
from {
  transform: scale(0) rotate(45deg);
	opacity: 0;
}
to {
  transform: scale(1) rotate(45deg);
	opacity: 1;
}`,MM=$n`
0% {
	height: 0;
	width: 0;
	opacity: 0;
}
40% {
  height: 0;
	width: 6px;
	opacity: 1;
}
100% {
  opacity: 1;
  height: 10px;
}`,DM=Tr("div")`
  width: 20px;
  opacity: 0;
  height: 20px;
  border-radius: 10px;
  background: ${t=>t.primary||"#61d345"};
  position: relative;
  transform: rotate(45deg);

  animation: ${AM} 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275)
    forwards;
  animation-delay: 100ms;
  &:after {
    content: '';
    box-sizing: border-box;
    animation: ${MM} 0.2s ease-out forwards;
    opacity: 0;
    animation-delay: 200ms;
    position: absolute;
    border-right: 2px solid;
    border-bottom: 2px solid;
    border-color: ${t=>t.secondary||"#fff"};
    bottom: 6px;
    left: 6px;
    height: 10px;
    width: 6px;
  }
`,RM=Tr("div")`
  position: absolute;
`,IM=Tr("div")`
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  min-width: 20px;
  min-height: 20px;
`,LM=$n`
from {
  transform: scale(0.6);
  opacity: 0.4;
}
to {
  transform: scale(1);
  opacity: 1;
}`,jM=Tr("div")`
  position: relative;
  transform: scale(0.6);
  opacity: 0.4;
  min-width: 20px;
  animation: ${LM} 0.3s 0.12s cubic-bezier(0.175, 0.885, 0.32, 1.275)
    forwards;
`,OM=({toast:t})=>{let{icon:e,type:n,iconTheme:r}=t;return e!==void 0?typeof e=="string"?S.createElement(jM,null,e):e:n==="blank"?null:S.createElement(IM,null,S.createElement(PM,{...r}),n!=="loading"&&S.createElement(RM,null,n==="error"?S.createElement(EM,{...r}):S.createElement(DM,{...r})))},_M=t=>`
0% {transform: translate3d(0,${t*-200}%,0) scale(.6); opacity:.5;}
100% {transform: translate3d(0,0,0) scale(1); opacity:1;}
`,NM=t=>`
0% {transform: translate3d(0,0,-1px) scale(1); opacity:1;}
100% {transform: translate3d(0,${t*-150}%,-1px) scale(.6); opacity:0;}
`,FM="0%{opacity:0;} 100%{opacity:1;}",VM="0%{opacity:1;} 100%{opacity:0;}",zM=Tr("div")`
  display: flex;
  align-items: center;
  background: #fff;
  color: #363636;
  line-height: 1.3;
  will-change: transform;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1), 0 3px 3px rgba(0, 0, 0, 0.05);
  max-width: 350px;
  pointer-events: auto;
  padding: 8px 10px;
  border-radius: 8px;
`,BM=Tr("div")`
  display: flex;
  justify-content: center;
  margin: 4px 10px;
  color: inherit;
  flex: 1 1 auto;
  white-space: pre-line;
`,UM=(t,e)=>{let n=t.includes("top")?1:-1,[r,i]=Fw()?[FM,VM]:[_M(n),NM(n)];return{animation:e?`${$n(r)} 0.35s cubic-bezier(.21,1.02,.73,1) forwards`:`${$n(i)} 0.4s forwards cubic-bezier(.06,.71,.55,1)`}},$M=S.memo(({toast:t,position:e,style:n,children:r})=>{let i=t.height?UM(t.position||e||"top-center",t.visible):{opacity:0},o=S.createElement(OM,{toast:t}),a=S.createElement(BM,{...t.ariaProps},Fl(t.message,t));return S.createElement(zM,{className:t.className,style:{...i,...n,...t.style}},typeof r=="function"?r({icon:o,message:a}):S.createElement(S.Fragment,null,o,a))});dM(S.createElement);var HM=({id:t,className:e,style:n,onHeightUpdate:r,children:i})=>{let o=S.useCallback(a=>{if(a){let s=()=>{let l=a.getBoundingClientRect().height;r(t,l)};s(),new MutationObserver(s).observe(a,{subtree:!0,childList:!0,characterData:!0})}},[t,r]);return S.createElement("div",{ref:o,className:e,style:n},i)},WM=(t,e)=>{let n=t.includes("top"),r=n?{top:0}:{bottom:0},i=t.includes("center")?{justifyContent:"center"}:t.includes("right")?{justifyContent:"flex-end"}:{};return{left:0,right:0,display:"flex",position:"absolute",transition:Fw()?void 0:"all 230ms cubic-bezier(.21,1.02,.73,1)",transform:`translateY(${e*(n?1:-1)}px)`,...r,...i}},qM=Du`
  z-index: 9999;
  > * {
    pointer-events: auto;
  }
`,Ms=16,YM=({reverseOrder:t,position:e="top-center",toastOptions:n,gutter:r,children:i,containerStyle:o,containerClassName:a})=>{let{toasts:s,handlers:l}=wM(n);return S.createElement("div",{style:{position:"fixed",zIndex:9999,top:Ms,left:Ms,right:Ms,bottom:Ms,pointerEvents:"none",...o},className:a,onMouseEnter:l.startPause,onMouseLeave:l.endPause},s.map(u=>{let c=u.position||e,d=l.calculateOffset(u,{reverseOrder:t,gutter:r,defaultPosition:e}),h=WM(c,d);return S.createElement(HM,{id:u.id,key:u.id,onHeightUpdate:l.updateHeight,className:u.visible?qM:"",style:h},u.type==="custom"?Fl(u.message,u):i?i(u):S.createElement($M,{toast:u,position:c}))}))},Ef=Ce,zw=S.createContext({});function KM(t){let{chatbotId:e}=we(),{opened:n,view:r}=Le(),[i,o]=S.useState(!0),[a,s]=S.useState(!1),l=S.useRef(null),u=S.useRef(null),[c,d]=S.useState(0),[h,p]=Nt("leoaiv3.6-chat-session",null),[m,v]=Nt("leoaiv3.6-chat-messages",[]),[b,f]=Nt("leoaiv3.6-chat-seen",!0),[g,y]=S.useState(null);S.useEffect(()=>{async function U(){let F=await iM({chatbotId:e});F&&(y(!0),p(F))}!h&&e&&U()},[e,h]),S.useEffect(()=>{g===null&&h&&y(!1)},[h,g]);let{messages:w,setMessages:C,append:k,input:M,setInput:P,handleInputChange:R,handleSubmit:E,isLoading:L,stop:N}=nM({initialMessages:m,api:"https://api.leoai.hu/chat/answer",id:h?.id,body:{chatbotId:e,sessionId:h?.id},onError:()=>{Ef.error("Hiba t\xF6rt\xE9nt a v\xE1laszad\xE1s sor\xE1n!"),C(U=>{let F=U[U.length-1];return F&&F.role==="user"?U.slice(0,-1):U})}});S.useEffect(()=>{w.length>0&&w!=m&&v(w)},[w,L]);let B=S.useCallback(async U=>{h&&await rM(h.id,U.type,U.created_at??new Date().toISOString(),U.metadata)},[h]);return S.useEffect(()=>{n&&r==="chat"&&f(!0)},[n,r]),A.jsx(zw.Provider,{value:{shouldFocusInput:a,setShouldFocusInput:s,session:h,scrollAnchor:u,scrollAnchorPosition:c,setScrollAnchorPosition:d,shouldAutoScroll:i,setShouldAutoScroll:o,handleNewEvent:B,messages:w,setMessages:C,append:k,handleInputChange:R,input:M,inputRef:l,setInput:P,handleSubmit:E,isLoading:L,stop:N,didSync:g,seen:b,setSeen:f},...t})}function yn(){return S.useContext(zw)}async function XM({chatbotId:t,messages:e,fallback:n}){console.log(t,e,n);try{let r=await fetch("https://api.leoai.hu/chat/quick-replies",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({chatbotId:t,messages:e,fallback:n})});if(!r.ok)throw new Error(`HTTP error! status: ${r.status}`);return await r.json()}catch(r){return console.error("Error fetching quick replies:",r),null}}var Bw=S.createContext({});function GM(t){let{messages:e,isLoading:n}=yn(),{chatbotId:r,automatedMessageStrategy:i}=we(),[o,a]=Nt("leoaiv3.6-quickReplies",null),[s,l]=S.useState(!1),[u,c]=S.useState(null);return S.useEffect(()=>{var d,h;if(!e||!e.length||n)return;let p=null;for(let b=e.length-1;b>=0;b--)if(e[b].role==="user"||e[b].role==="assistant"){p=e[b];break}if(!r||!p||p.role!=="assistant"||p.id===u)return;let m=i.messages.find(b=>b.id===p.id),v;m&&((d=m.message)==null?void 0:d.type)!=="dynamic"||(v=(h=m?.message)==null?void 0:h.fallback.quickReplies,console.log("quick replies state use effect: looks like the conditions are met, generating..."),c(p.id),l(!0),(async()=>{a(null);let b=await XM({chatbotId:r,messages:e,fallback:v});a(b)})(),l(!1))},[e,u,s,n,r]),A.jsx(Bw.Provider,{value:{quickReplies:o,setQuickReplies:a,isLoading:s,setIsLoading:l},...t})}function Cf(){return S.useContext(Bw)}var QM=S.createContext({});function JM(t){let[e,n]=w2("leoaiv3.6-user",null),r=S.useCallback(o=>{n(a=>({phone:a?.phone??null,email:o}))},[e]),i=S.useCallback(o=>{n(a=>({email:a?.email??null,phone:o}))},[e]);return A.jsx(QM.Provider,{value:{user:e,setUser:n,setUserEmail:r,setUserPhone:i},...t})}function ZM(t){if(typeof Proxy>"u")return t;let e=new Map,n=(...r)=>t(...r);return new Proxy(n,{get:(r,i)=>i==="create"?t:(e.has(i)||e.set(i,t(i)),e.get(i))})}function Ru(t){return t!==null&&typeof t=="object"&&typeof t.start=="function"}var vh=t=>Array.isArray(t);function Uw(t,e){if(!Array.isArray(e))return!1;let n=e.length;if(n!==t.length)return!1;for(let r=0;r<n;r++)if(e[r]!==t[r])return!1;return!0}function Ma(t){return typeof t=="string"||Array.isArray(t)}function Pv(t){let e=[{},{}];return t?.values.forEach((n,r)=>{e[0][r]=n.get(),e[1][r]=n.getVelocity()}),e}function Pf(t,e,n,r){if(typeof e=="function"){let[i,o]=Pv(r);e=e(n!==void 0?n:t.custom,i,o)}if(typeof e=="string"&&(e=t.variants&&t.variants[e]),typeof e=="function"){let[i,o]=Pv(r);e=e(n!==void 0?n:t.custom,i,o)}return e}function Iu(t,e,n){let r=t.getProps();return Pf(r,e,n!==void 0?n:r.custom,t)}var Af=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],Mf=["initial",...Af],Xa=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],ri=new Set(Xa),Rn=t=>t*1e3,In=t=>t/1e3,tD={type:"spring",stiffness:500,damping:25,restSpeed:10},eD=t=>({type:"spring",stiffness:550,damping:t===0?2*Math.sqrt(550):30,restSpeed:10}),nD={type:"keyframes",duration:.8},rD={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},iD=(t,{keyframes:e})=>e.length>2?nD:ri.has(t)?t.startsWith("scale")?eD(e[1]):tD:rD;function Df(t,e){return t?t[e]||t.default||t:void 0}var oD={skipAnimations:!1,useManualTiming:!1},aD=t=>t!==null;function Lu(t,{repeat:e,repeatType:n="loop"},r){let i=t.filter(aD),o=e&&n!=="loop"&&e%2===1?0:i.length-1;return!o||r===void 0?i[o]:r}var re=t=>t;function sD(t){let e=new Set,n=new Set,r=!1,i=!1,o=new WeakSet,a={delta:0,timestamp:0,isProcessing:!1};function s(u){o.has(u)&&(l.schedule(u),t()),u(a)}let l={schedule:(u,c=!1,d=!1)=>{let h=d&&r?e:n;return c&&o.add(u),h.has(u)||h.add(u),u},cancel:u=>{n.delete(u),o.delete(u)},process:u=>{if(a=u,r){i=!0;return}r=!0,[e,n]=[n,e],n.clear(),e.forEach(s),r=!1,i&&(i=!1,l.process(u))}};return l}var Ds=["read","resolveKeyframes","update","preRender","render","postRender"],lD=40;function $w(t,e){let n=!1,r=!0,i={delta:0,timestamp:0,isProcessing:!1},o=()=>n=!0,a=Ds.reduce((v,b)=>(v[b]=sD(o),v),{}),{read:s,resolveKeyframes:l,update:u,preRender:c,render:d,postRender:h}=a,p=()=>{let v=performance.now();n=!1,i.delta=r?1e3/60:Math.max(Math.min(v-i.timestamp,lD),1),i.timestamp=v,i.isProcessing=!0,s.process(i),l.process(i),u.process(i),c.process(i),d.process(i),h.process(i),i.isProcessing=!1,n&&e&&(r=!1,t(p))},m=()=>{n=!0,r=!0,i.isProcessing||t(p)};return{schedule:Ds.reduce((v,b)=>{let f=a[b];return v[b]=(g,y=!1,w=!1)=>(n||m(),f.schedule(g,y,w)),v},{}),cancel:v=>{for(let b=0;b<Ds.length;b++)a[Ds[b]].cancel(v)},state:i,steps:a}}var{schedule:ct,cancel:mr,state:Ht,steps:Pc}=$w(typeof requestAnimationFrame<"u"?requestAnimationFrame:re,!0),Hw=(t,e,n)=>(((1-3*n+3*e)*t+(3*n-6*e))*t+3*e)*t,uD=1e-7,cD=12;function dD(t,e,n,r,i){let o,a,s=0;do a=e+(n-e)/2,o=Hw(a,r,i)-t,o>0?n=a:e=a;while(Math.abs(o)>uD&&++s<cD);return a}function Ga(t,e,n,r){if(t===e&&n===r)return re;let i=o=>dD(o,0,1,t,n);return o=>o===0||o===1?o:Hw(i(o),e,r)}var Ww=t=>e=>e<=.5?t(2*e)/2:(2-t(2*(1-e)))/2,qw=t=>e=>1-t(1-e),Yw=Ga(.33,1.53,.69,.99),Rf=qw(Yw),Kw=Ww(Rf),Xw=t=>(t*=2)<1?.5*Rf(t):.5*(2-Math.pow(2,-10*(t-1))),If=t=>1-Math.sin(Math.acos(t)),Gw=qw(If),Qw=Ww(If),Jw=t=>/^0[^.\s]+$/u.test(t);function hD(t){return typeof t=="number"?t===0:t!==null?t==="none"||t==="0"||Jw(t):!0}var yh=re,Zw=t=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(t),tk=t=>e=>typeof e=="string"&&e.startsWith(t),ek=tk("--"),pD=tk("var(--"),Lf=t=>pD(t)?fD.test(t.split("/*")[0].trim()):!1,fD=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu,mD=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function gD(t){let e=mD.exec(t);if(!e)return[,];let[,n,r,i]=e;return[`--${n??r}`,i]}function nk(t,e,n=1){let[r,i]=gD(t);if(!r)return;let o=window.getComputedStyle(e).getPropertyValue(r);if(o){let a=o.trim();return Zw(a)?parseFloat(a):a}return Lf(i)?nk(i,e,n+1):i}var gr=(t,e,n)=>n>e?e:n<t?t:n,so={test:t=>typeof t=="number",parse:parseFloat,transform:t=>t},Da={...so,transform:t=>gr(0,1,t)},Rs={...so,default:1},Qa=t=>({test:e=>typeof e=="string"&&e.endsWith(t)&&e.split(" ").length===1,parse:parseFloat,transform:e=>`${e}${t}`}),Kn=Qa("deg"),pn=Qa("%"),W=Qa("px"),vD=Qa("vh"),yD=Qa("vw"),Av={...pn,parse:t=>pn.parse(t)/100,transform:t=>pn.transform(t*100)},bD=new Set(["width","height","top","left","right","bottom","x","y","translateX","translateY"]),Mv=t=>t===so||t===W,Dv=(t,e)=>parseFloat(t.split(", ")[e]),Rv=(t,e)=>(n,{transform:r})=>{if(r==="none"||!r)return 0;let i=r.match(/^matrix3d\((.+)\)$/u);if(i)return Dv(i[1],e);{let o=r.match(/^matrix\((.+)\)$/u);return o?Dv(o[1],t):0}},xD=new Set(["x","y","z"]),wD=Xa.filter(t=>!xD.has(t));function kD(t){let e=[];return wD.forEach(n=>{let r=t.getValue(n);r!==void 0&&(e.push([n,r.get()]),r.set(n.startsWith("scale")?1:0))}),e}var Gi={width:({x:t},{paddingLeft:e="0",paddingRight:n="0"})=>t.max-t.min-parseFloat(e)-parseFloat(n),height:({y:t},{paddingTop:e="0",paddingBottom:n="0"})=>t.max-t.min-parseFloat(e)-parseFloat(n),top:(t,{top:e})=>parseFloat(e),left:(t,{left:e})=>parseFloat(e),bottom:({y:t},{top:e})=>parseFloat(e)+(t.max-t.min),right:({x:t},{left:e})=>parseFloat(e)+(t.max-t.min),x:Rv(4,13),y:Rv(5,14)};Gi.translateX=Gi.x;Gi.translateY=Gi.y;var rk=t=>e=>e.test(t),SD={test:t=>t==="auto",parse:t=>t},ik=[so,W,pn,Kn,yD,vD,SD],Iv=t=>ik.find(rk(t)),Hr=new Set,bh=!1,xh=!1;function ok(){if(xh){let t=Array.from(Hr).filter(r=>r.needsMeasurement),e=new Set(t.map(r=>r.element)),n=new Map;e.forEach(r=>{let i=kD(r);i.length&&(n.set(r,i),r.render())}),t.forEach(r=>r.measureInitialState()),e.forEach(r=>{r.render();let i=n.get(r);i&&i.forEach(([o,a])=>{var s;(s=r.getValue(o))===null||s===void 0||s.set(a)})}),t.forEach(r=>r.measureEndState()),t.forEach(r=>{r.suspendedScrollY!==void 0&&window.scrollTo(0,r.suspendedScrollY)})}xh=!1,bh=!1,Hr.forEach(t=>t.complete()),Hr.clear()}function ak(){Hr.forEach(t=>{t.readKeyframes(),t.needsMeasurement&&(xh=!0)})}function TD(){ak(),ok()}var jf=class{constructor(t,e,n,r,i,o=!1){this.isComplete=!1,this.isAsync=!1,this.needsMeasurement=!1,this.isScheduled=!1,this.unresolvedKeyframes=[...t],this.onComplete=e,this.name=n,this.motionValue=r,this.element=i,this.isAsync=o}scheduleResolve(){this.isScheduled=!0,this.isAsync?(Hr.add(this),bh||(bh=!0,ct.read(ak),ct.resolveKeyframes(ok))):(this.readKeyframes(),this.complete())}readKeyframes(){let{unresolvedKeyframes:t,name:e,element:n,motionValue:r}=this;for(let i=0;i<t.length;i++)if(t[i]===null)if(i===0){let o=r?.get(),a=t[t.length-1];if(o!==void 0)t[0]=o;else if(n&&e){let s=n.readValue(e,a);s!=null&&(t[0]=s)}t[0]===void 0&&(t[0]=a),r&&o===void 0&&r.set(t[0])}else t[i]=t[i-1]}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(){this.isComplete=!0,this.onComplete(this.unresolvedKeyframes,this.finalKeyframe),Hr.delete(this)}cancel(){this.isComplete||(this.isScheduled=!1,Hr.delete(this))}resume(){this.isComplete||this.scheduleResolve()}},qo=t=>Math.round(t*1e5)/1e5,Of=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function ED(t){return t==null}var CD=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,_f=(t,e)=>n=>!!(typeof n=="string"&&CD.test(n)&&n.startsWith(t)||e&&!ED(n)&&Object.prototype.hasOwnProperty.call(n,e)),sk=(t,e,n)=>r=>{if(typeof r!="string")return r;let[i,o,a,s]=r.match(Of);return{[t]:parseFloat(i),[e]:parseFloat(o),[n]:parseFloat(a),alpha:s!==void 0?parseFloat(s):1}},PD=t=>gr(0,255,t),Ac={...so,transform:t=>Math.round(PD(t))},zr={test:_f("rgb","red"),parse:sk("red","green","blue"),transform:({red:t,green:e,blue:n,alpha:r=1})=>"rgba("+Ac.transform(t)+", "+Ac.transform(e)+", "+Ac.transform(n)+", "+qo(Da.transform(r))+")"};function AD(t){let e="",n="",r="",i="";return t.length>5?(e=t.substring(1,3),n=t.substring(3,5),r=t.substring(5,7),i=t.substring(7,9)):(e=t.substring(1,2),n=t.substring(2,3),r=t.substring(3,4),i=t.substring(4,5),e+=e,n+=n,r+=r,i+=i),{red:parseInt(e,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:i?parseInt(i,16)/255:1}}var wh={test:_f("#"),parse:AD,transform:zr.transform},Ti={test:_f("hsl","hue"),parse:sk("hue","saturation","lightness"),transform:({hue:t,saturation:e,lightness:n,alpha:r=1})=>"hsla("+Math.round(t)+", "+pn.transform(qo(e))+", "+pn.transform(qo(n))+", "+qo(Da.transform(r))+")"},Qt={test:t=>zr.test(t)||wh.test(t)||Ti.test(t),parse:t=>zr.test(t)?zr.parse(t):Ti.test(t)?Ti.parse(t):wh.parse(t),transform:t=>typeof t=="string"?t:t.hasOwnProperty("red")?zr.transform(t):Ti.transform(t)},MD=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function DD(t){var e,n;return isNaN(t)&&typeof t=="string"&&(((e=t.match(Of))===null||e===void 0?void 0:e.length)||0)+(((n=t.match(MD))===null||n===void 0?void 0:n.length)||0)>0}var lk="number",uk="color",RD="var",ID="var(",Lv="${}",LD=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function Ra(t){let e=t.toString(),n=[],r={color:[],number:[],var:[]},i=[],o=0,a=e.replace(LD,s=>(Qt.test(s)?(r.color.push(o),i.push(uk),n.push(Qt.parse(s))):s.startsWith(ID)?(r.var.push(o),i.push(RD),n.push(s)):(r.number.push(o),i.push(lk),n.push(parseFloat(s))),++o,Lv)).split(Lv);return{values:n,split:a,indexes:r,types:i}}function ck(t){return Ra(t).values}function dk(t){let{split:e,types:n}=Ra(t),r=e.length;return i=>{let o="";for(let a=0;a<r;a++)if(o+=e[a],i[a]!==void 0){let s=n[a];s===lk?o+=qo(i[a]):s===uk?o+=Qt.transform(i[a]):o+=i[a]}return o}}var jD=t=>typeof t=="number"?0:t;function OD(t){let e=ck(t);return dk(t)(e.map(jD))}var vr={test:DD,parse:ck,createTransformer:dk,getAnimatableNone:OD},_D=new Set(["brightness","contrast","saturate","opacity"]);function ND(t){let[e,n]=t.slice(0,-1).split("(");if(e==="drop-shadow")return t;let[r]=n.match(Of)||[];if(!r)return t;let i=n.replace(r,""),o=_D.has(e)?1:0;return r!==n&&(o*=100),e+"("+o+i+")"}var FD=/\b([a-z-]*)\(.*?\)/gu,kh={...vr,getAnimatableNone:t=>{let e=t.match(FD);return e?e.map(ND).join(" "):t}},VD={borderWidth:W,borderTopWidth:W,borderRightWidth:W,borderBottomWidth:W,borderLeftWidth:W,borderRadius:W,radius:W,borderTopLeftRadius:W,borderTopRightRadius:W,borderBottomRightRadius:W,borderBottomLeftRadius:W,width:W,maxWidth:W,height:W,maxHeight:W,top:W,right:W,bottom:W,left:W,padding:W,paddingTop:W,paddingRight:W,paddingBottom:W,paddingLeft:W,margin:W,marginTop:W,marginRight:W,marginBottom:W,marginLeft:W,backgroundPositionX:W,backgroundPositionY:W},zD={rotate:Kn,rotateX:Kn,rotateY:Kn,rotateZ:Kn,scale:Rs,scaleX:Rs,scaleY:Rs,scaleZ:Rs,skew:Kn,skewX:Kn,skewY:Kn,distance:W,translateX:W,translateY:W,translateZ:W,x:W,y:W,z:W,perspective:W,transformPerspective:W,opacity:Da,originX:Av,originY:Av,originZ:W},jv={...so,transform:Math.round},Nf={...VD,...zD,zIndex:jv,size:W,fillOpacity:Da,strokeOpacity:Da,numOctaves:jv},BD={...Nf,color:Qt,backgroundColor:Qt,outlineColor:Qt,fill:Qt,stroke:Qt,borderColor:Qt,borderTopColor:Qt,borderRightColor:Qt,borderBottomColor:Qt,borderLeftColor:Qt,filter:kh,WebkitFilter:kh},Ff=t=>BD[t];function hk(t,e){let n=Ff(t);return n!==kh&&(n=vr),n.getAnimatableNone?n.getAnimatableNone(e):void 0}var UD=new Set(["auto","none","0"]);function $D(t,e,n){let r=0,i;for(;r<t.length&&!i;){let o=t[r];typeof o=="string"&&!UD.has(o)&&Ra(o).values.length&&(i=t[r]),r++}if(i&&n)for(let o of e)t[o]=hk(n,i)}var pk=class extends jf{constructor(t,e,n,r,i){super(t,e,n,r,i,!0)}readKeyframes(){let{unresolvedKeyframes:t,element:e,name:n}=this;if(!e||!e.current)return;super.readKeyframes();for(let s=0;s<t.length;s++){let l=t[s];if(typeof l=="string"&&(l=l.trim(),Lf(l))){let u=nk(l,e.current);u!==void 0&&(t[s]=u),s===t.length-1&&(this.finalKeyframe=l)}}if(this.resolveNoneKeyframes(),!bD.has(n)||t.length!==2)return;let[r,i]=t,o=Iv(r),a=Iv(i);if(o!==a)if(Mv(o)&&Mv(a))for(let s=0;s<t.length;s++){let l=t[s];typeof l=="string"&&(t[s]=parseFloat(l))}else this.needsMeasurement=!0}resolveNoneKeyframes(){let{unresolvedKeyframes:t,name:e}=this,n=[];for(let r=0;r<t.length;r++)hD(t[r])&&n.push(r);n.length&&$D(t,n,e)}measureInitialState(){let{element:t,unresolvedKeyframes:e,name:n}=this;if(!t||!t.current)return;n==="height"&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=Gi[n](t.measureViewportBox(),window.getComputedStyle(t.current)),e[0]=this.measuredOrigin;let r=e[e.length-1];r!==void 0&&t.getValue(n,r).jump(r,!1)}measureEndState(){var t;let{element:e,name:n,unresolvedKeyframes:r}=this;if(!e||!e.current)return;let i=e.getValue(n);i&&i.jump(this.measuredOrigin,!1);let o=r.length-1,a=r[o];r[o]=Gi[n](e.measureViewportBox(),window.getComputedStyle(e.current)),a!==null&&this.finalKeyframe===void 0&&(this.finalKeyframe=a),!((t=this.removedTransforms)===null||t===void 0)&&t.length&&this.removedTransforms.forEach(([s,l])=>{e.getValue(s).set(l)}),this.resolveNoneKeyframes()}};function Vf(t){return typeof t=="function"}var el;function HD(){el=void 0}var fn={now:()=>(el===void 0&&fn.set(Ht.isProcessing||oD.useManualTiming?Ht.timestamp:performance.now()),el),set:t=>{el=t,queueMicrotask(HD)}},Ov=(t,e)=>e==="zIndex"?!1:!!(typeof t=="number"||Array.isArray(t)||typeof t=="string"&&(vr.test(t)||t==="0")&&!t.startsWith("url("));function WD(t){let e=t[0];if(t.length===1)return!0;for(let n=0;n<t.length;n++)if(t[n]!==e)return!0}function qD(t,e,n,r){let i=t[0];if(i===null)return!1;if(e==="display"||e==="visibility")return!0;let o=t[t.length-1],a=Ov(i,e),s=Ov(o,e);return!a||!s?!1:WD(t)||(n==="spring"||Vf(n))&&r}var YD=40,fk=class{constructor({autoplay:t=!0,delay:e=0,type:n="keyframes",repeat:r=0,repeatDelay:i=0,repeatType:o="loop",...a}){this.isStopped=!1,this.hasAttemptedResolve=!1,this.createdAt=fn.now(),this.options={autoplay:t,delay:e,type:n,repeat:r,repeatDelay:i,repeatType:o,...a},this.updateFinishedPromise()}calcStartTime(){return this.resolvedAt?this.resolvedAt-this.createdAt>YD?this.resolvedAt:this.createdAt:this.createdAt}get resolved(){return!this._resolved&&!this.hasAttemptedResolve&&TD(),this._resolved}onKeyframesResolved(t,e){this.resolvedAt=fn.now(),this.hasAttemptedResolve=!0;let{name:n,type:r,velocity:i,delay:o,onComplete:a,onUpdate:s,isGenerator:l}=this.options;if(!l&&!qD(t,n,r,i))if(o)this.options.duration=0;else{s?.(Lu(t,this.options,e)),a?.(),this.resolveFinishedPromise();return}let u=this.initPlayback(t,e);u!==!1&&(this._resolved={keyframes:t,finalKeyframe:e,...u},this.onPostResolved())}onPostResolved(){}then(t,e){return this.currentFinishedPromise.then(t,e)}updateFinishedPromise(){this.currentFinishedPromise=new Promise(t=>{this.resolveFinishedPromise=t})}};function mk(t,e){return e?t*(1e3/e):0}var KD=5;function gk(t,e,n){let r=Math.max(e-KD,0);return mk(n-t(r),e-r)}var Mc=.001,XD=.01,GD=10,QD=.05,JD=1;function ZD({duration:t=800,bounce:e=.25,velocity:n=0,mass:r=1}){let i,o,a=1-e;a=gr(QD,JD,a),t=gr(XD,GD,In(t)),a<1?(i=u=>{let c=u*a,d=c*t,h=c-n,p=Sh(u,a),m=Math.exp(-d);return Mc-h/p*m},o=u=>{let c=u*a*t,d=c*n+n,h=Math.pow(a,2)*Math.pow(u,2)*t,p=Math.exp(-c),m=Sh(Math.pow(u,2),a);return(-i(u)+Mc>0?-1:1)*((d-h)*p)/m}):(i=u=>{let c=Math.exp(-u*t),d=(u-n)*t+1;return-Mc+c*d},o=u=>{let c=Math.exp(-u*t),d=(n-u)*(t*t);return c*d});let s=5/t,l=eR(i,o,s);if(t=Rn(t),isNaN(l))return{stiffness:100,damping:10,duration:t};{let u=Math.pow(l,2)*r;return{stiffness:u,damping:a*2*Math.sqrt(r*u),duration:t}}}var tR=12;function eR(t,e,n){let r=n;for(let i=1;i<tR;i++)r=r-t(r)/e(r);return r}function Sh(t,e){return t*Math.sqrt(1-e*e)}var nR=["duration","bounce"],rR=["stiffness","damping","mass"];function _v(t,e){return e.some(n=>t[n]!==void 0)}function iR(t){let e={velocity:0,stiffness:100,damping:10,mass:1,isResolvedFromDuration:!1,...t};if(!_v(t,rR)&&_v(t,nR)){let n=ZD(t);e={...e,...n,mass:1},e.isResolvedFromDuration=!0}return e}function vk({keyframes:t,restDelta:e,restSpeed:n,...r}){let i=t[0],o=t[t.length-1],a={done:!1,value:i},{stiffness:s,damping:l,mass:u,duration:c,velocity:d,isResolvedFromDuration:h}=iR({...r,velocity:-In(r.velocity||0)}),p=d||0,m=l/(2*Math.sqrt(s*u)),v=o-i,b=In(Math.sqrt(s/u)),f=Math.abs(v)<5;n||(n=f?.01:2),e||(e=f?.005:.5);let g;if(m<1){let y=Sh(b,m);g=w=>{let C=Math.exp(-m*b*w);return o-C*((p+m*b*v)/y*Math.sin(y*w)+v*Math.cos(y*w))}}else if(m===1)g=y=>o-Math.exp(-b*y)*(v+(p+b*v)*y);else{let y=b*Math.sqrt(m*m-1);g=w=>{let C=Math.exp(-m*b*w),k=Math.min(y*w,300);return o-C*((p+m*b*v)*Math.sinh(k)+y*v*Math.cosh(k))/y}}return{calculatedDuration:h&&c||null,next:y=>{let w=g(y);if(h)a.done=y>=c;else{let C=0;m<1&&(C=y===0?Rn(p):gk(g,y,w));let k=Math.abs(C)<=n,M=Math.abs(o-w)<=e;a.done=k&&M}return a.value=a.done?o:w,a}}}function Nv({keyframes:t,velocity:e=0,power:n=.8,timeConstant:r=325,bounceDamping:i=10,bounceStiffness:o=500,modifyTarget:a,min:s,max:l,restDelta:u=.5,restSpeed:c}){let d=t[0],h={done:!1,value:d},p=P=>s!==void 0&&P<s||l!==void 0&&P>l,m=P=>s===void 0?l:l===void 0||Math.abs(s-P)<Math.abs(l-P)?s:l,v=n*e,b=d+v,f=a===void 0?b:a(b);f!==b&&(v=f-d);let g=P=>-v*Math.exp(-P/r),y=P=>f+g(P),w=P=>{let R=g(P),E=y(P);h.done=Math.abs(R)<=u,h.value=h.done?f:E},C,k,M=P=>{p(h.value)&&(C=P,k=vk({keyframes:[h.value,m(h.value)],velocity:gk(y,P,h.value),damping:i,stiffness:o,restDelta:u,restSpeed:c}))};return M(0),{calculatedDuration:null,next:P=>{let R=!1;return!k&&C===void 0&&(R=!0,w(P),M(P)),C!==void 0&&P>=C?k.next(P-C):(!R&&w(P),h)}}}var oR=Ga(.42,0,1,1),aR=Ga(0,0,.58,1),yk=Ga(.42,0,.58,1),sR=t=>Array.isArray(t)&&typeof t[0]!="number",zf=t=>Array.isArray(t)&&typeof t[0]=="number",Fv={linear:re,easeIn:oR,easeInOut:yk,easeOut:aR,circIn:If,circInOut:Qw,circOut:Gw,backIn:Rf,backInOut:Kw,backOut:Yw,anticipate:Xw},Vv=t=>{if(zf(t)){yh(t.length===4);let[e,n,r,i]=t;return Ga(e,n,r,i)}else if(typeof t=="string")return yh(Fv[t]!==void 0),Fv[t];return t},lR=(t,e)=>n=>e(t(n)),Ln=(...t)=>t.reduce(lR),Qi=(t,e,n)=>{let r=e-t;return r===0?1:(n-t)/r},Et=(t,e,n)=>t+(e-t)*n;function Dc(t,e,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?t+(e-t)*6*n:n<1/2?e:n<2/3?t+(e-t)*(2/3-n)*6:t}function uR({hue:t,saturation:e,lightness:n,alpha:r}){t/=360,e/=100,n/=100;let i=0,o=0,a=0;if(!e)i=o=a=n;else{let s=n<.5?n*(1+e):n+e-n*e,l=2*n-s;i=Dc(l,s,t+1/3),o=Dc(l,s,t),a=Dc(l,s,t-1/3)}return{red:Math.round(i*255),green:Math.round(o*255),blue:Math.round(a*255),alpha:r}}function Vl(t,e){return n=>n>0?e:t}var Rc=(t,e,n)=>{let r=t*t,i=n*(e*e-r)+r;return i<0?0:Math.sqrt(i)},cR=[wh,zr,Ti],dR=t=>cR.find(e=>e.test(t));function zv(t){let e=dR(t);if(!e)return!1;let n=e.parse(t);return e===Ti&&(n=uR(n)),n}var Bv=(t,e)=>{let n=zv(t),r=zv(e);if(!n||!r)return Vl(t,e);let i={...n};return o=>(i.red=Rc(n.red,r.red,o),i.green=Rc(n.green,r.green,o),i.blue=Rc(n.blue,r.blue,o),i.alpha=Et(n.alpha,r.alpha,o),zr.transform(i))},Th=new Set(["none","hidden"]);function hR(t,e){return Th.has(t)?n=>n<=0?t:e:n=>n>=1?e:t}function pR(t,e){return n=>Et(t,e,n)}function Bf(t){return typeof t=="number"?pR:typeof t=="string"?Lf(t)?Vl:Qt.test(t)?Bv:gR:Array.isArray(t)?bk:typeof t=="object"?Qt.test(t)?Bv:fR:Vl}function bk(t,e){let n=[...t],r=n.length,i=t.map((o,a)=>Bf(o)(o,e[a]));return o=>{for(let a=0;a<r;a++)n[a]=i[a](o);return n}}function fR(t,e){let n={...t,...e},r={};for(let i in n)t[i]!==void 0&&e[i]!==void 0&&(r[i]=Bf(t[i])(t[i],e[i]));return i=>{for(let o in r)n[o]=r[o](i);return n}}function mR(t,e){var n;let r=[],i={color:0,var:0,number:0};for(let o=0;o<e.values.length;o++){let a=e.types[o],s=t.indexes[a][i[a]],l=(n=t.values[s])!==null&&n!==void 0?n:0;r[o]=l,i[a]++}return r}var gR=(t,e)=>{let n=vr.createTransformer(e),r=Ra(t),i=Ra(e);return r.indexes.var.length===i.indexes.var.length&&r.indexes.color.length===i.indexes.color.length&&r.indexes.number.length>=i.indexes.number.length?Th.has(t)&&!i.values.length||Th.has(e)&&!r.values.length?hR(t,e):Ln(bk(mR(r,i),i.values),n):Vl(t,e)};function xk(t,e,n){return typeof t=="number"&&typeof e=="number"&&typeof n=="number"?Et(t,e,n):Bf(t)(t,e)}function vR(t,e,n){let r=[],i=n||xk,o=t.length-1;for(let a=0;a<o;a++){let s=i(t[a],t[a+1]);if(e){let l=Array.isArray(e)?e[a]||re:e;s=Ln(l,s)}r.push(s)}return r}function yR(t,e,{clamp:n=!0,ease:r,mixer:i}={}){let o=t.length;if(yh(o===e.length),o===1)return()=>e[0];if(o===2&&t[0]===t[1])return()=>e[1];t[0]>t[o-1]&&(t=[...t].reverse(),e=[...e].reverse());let a=vR(e,r,i),s=a.length,l=u=>{let c=0;if(s>1)for(;c<t.length-2&&!(u<t[c+1]);c++);let d=Qi(t[c],t[c+1],u);return a[c](d)};return n?u=>l(gr(t[0],t[o-1],u)):l}function bR(t,e){let n=t[t.length-1];for(let r=1;r<=e;r++){let i=Qi(0,e,r);t.push(Et(n,1,i))}}function xR(t){let e=[0];return bR(e,t.length-1),e}function wR(t,e){return t.map(n=>n*e)}function kR(t,e){return t.map(()=>e||yk).splice(0,t.length-1)}function zl({duration:t=300,keyframes:e,times:n,ease:r="easeInOut"}){let i=sR(r)?r.map(Vv):Vv(r),o={done:!1,value:e[0]},a=wR(n&&n.length===e.length?n:xR(e),t),s=yR(a,e,{ease:Array.isArray(i)?i:kR(e,i)});return{calculatedDuration:t,next:l=>(o.value=s(l),o.done=l>=t,o)}}var Uv=2e4;function SR(t){let e=0,n=50,r=t.next(e);for(;!r.done&&e<Uv;)e+=n,r=t.next(e);return e>=Uv?1/0:e}var TR=t=>{let e=({timestamp:n})=>t(n);return{start:()=>ct.update(e,!0),stop:()=>mr(e),now:()=>Ht.isProcessing?Ht.timestamp:fn.now()}},ER={decay:Nv,inertia:Nv,tween:zl,keyframes:zl,spring:vk},CR=t=>t/100,Uf=class extends fk{constructor(t){super(t),this.holdTime=null,this.cancelTime=null,this.currentTime=0,this.playbackSpeed=1,this.pendingPlayState="running",this.startTime=null,this.state="idle",this.stop=()=>{if(this.resolver.cancel(),this.isStopped=!0,this.state==="idle")return;this.teardown();let{onStop:s}=this.options;s&&s()};let{name:e,motionValue:n,element:r,keyframes:i}=this.options,o=r?.KeyframeResolver||jf,a=(s,l)=>this.onKeyframesResolved(s,l);this.resolver=new o(i,a,e,n,r),this.resolver.scheduleResolve()}initPlayback(t){let{type:e="keyframes",repeat:n=0,repeatDelay:r=0,repeatType:i,velocity:o=0}=this.options,a=Vf(e)?e:ER[e]||zl,s,l;a!==zl&&typeof t[0]!="number"&&(s=Ln(CR,xk(t[0],t[1])),t=[0,100]);let u=a({...this.options,keyframes:t});i==="mirror"&&(l=a({...this.options,keyframes:[...t].reverse(),velocity:-o})),u.calculatedDuration===null&&(u.calculatedDuration=SR(u));let{calculatedDuration:c}=u,d=c+r,h=d*(n+1)-r;return{generator:u,mirroredGenerator:l,mapPercentToKeyframes:s,calculatedDuration:c,resolvedDuration:d,totalDuration:h}}onPostResolved(){let{autoplay:t=!0}=this.options;this.play(),this.pendingPlayState==="paused"||!t?this.pause():this.state=this.pendingPlayState}tick(t,e=!1){let{resolved:n}=this;if(!n){let{keyframes:M}=this.options;return{done:!0,value:M[M.length-1]}}let{finalKeyframe:r,generator:i,mirroredGenerator:o,mapPercentToKeyframes:a,keyframes:s,calculatedDuration:l,totalDuration:u,resolvedDuration:c}=n;if(this.startTime===null)return i.next(0);let{delay:d,repeat:h,repeatType:p,repeatDelay:m,onUpdate:v}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-u/this.speed,this.startTime)),e?this.currentTime=t:this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=Math.round(t-this.startTime)*this.speed;let b=this.currentTime-d*(this.speed>=0?1:-1),f=this.speed>=0?b<0:b>u;this.currentTime=Math.max(b,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=u);let g=this.currentTime,y=i;if(h){let M=Math.min(this.currentTime,u)/c,P=Math.floor(M),R=M%1;!R&&M>=1&&(R=1),R===1&&P--,P=Math.min(P,h+1),P%2&&(p==="reverse"?(R=1-R,m&&(R-=m/c)):p==="mirror"&&(y=o)),g=gr(0,1,R)*c}let w=f?{done:!1,value:s[0]}:y.next(g);a&&(w.value=a(w.value));let{done:C}=w;!f&&l!==null&&(C=this.speed>=0?this.currentTime>=u:this.currentTime<=0);let k=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&C);return k&&r!==void 0&&(w.value=Lu(s,this.options,r)),v&&v(w.value),k&&this.finish(),w}get duration(){let{resolved:t}=this;return t?In(t.calculatedDuration):0}get time(){return In(this.currentTime)}set time(t){t=Rn(t),this.currentTime=t,this.holdTime!==null||this.speed===0?this.holdTime=t:this.driver&&(this.startTime=this.driver.now()-t/this.speed)}get speed(){return this.playbackSpeed}set speed(t){let e=this.playbackSpeed!==t;this.playbackSpeed=t,e&&(this.time=In(this.currentTime))}play(){if(this.resolver.isScheduled||this.resolver.resume(),!this._resolved){this.pendingPlayState="running";return}if(this.isStopped)return;let{driver:t=TR,onPlay:e,startTime:n}=this.options;this.driver||(this.driver=t(i=>this.tick(i))),e&&e();let r=this.driver.now();this.holdTime!==null?this.startTime=r-this.holdTime:this.startTime?this.state==="finished"&&(this.startTime=r):this.startTime=n??this.calcStartTime(),this.state==="finished"&&this.updateFinishedPromise(),this.cancelTime=this.startTime,this.holdTime=null,this.state="running",this.driver.start()}pause(){var t;if(!this._resolved){this.pendingPlayState="paused";return}this.state="paused",this.holdTime=(t=this.currentTime)!==null&&t!==void 0?t:0}complete(){this.state!=="running"&&this.play(),this.pendingPlayState=this.state="finished",this.holdTime=null}finish(){this.teardown(),this.state="finished";let{onComplete:t}=this.options;t&&t()}cancel(){this.cancelTime!==null&&this.tick(this.cancelTime),this.teardown(),this.updateFinishedPromise()}teardown(){this.state="idle",this.stopDriver(),this.resolveFinishedPromise(),this.updateFinishedPromise(),this.startTime=this.cancelTime=null,this.resolver.cancel()}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(t){return this.startTime=0,this.tick(t,!0)}},PR=new Set(["opacity","clipPath","filter","transform"]),AR=10,MR=(t,e)=>{let n="",r=Math.max(Math.round(e/AR),2);for(let i=0;i<r;i++)n+=t(Qi(0,r-1,i))+", ";return`linear(${n.substring(0,n.length-2)})`};function $f(t){let e;return()=>(e===void 0&&(e=t()),e)}var DR={linearEasing:void 0};function RR(t,e){let n=$f(t);return()=>{var r;return(r=DR[e])!==null&&r!==void 0?r:n()}}var Bl=RR(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing");function wk(t){return!!(typeof t=="function"&&Bl()||!t||typeof t=="string"&&(t in Eh||Bl())||zf(t)||Array.isArray(t)&&t.every(wk))}var Lo=([t,e,n,r])=>`cubic-bezier(${t}, ${e}, ${n}, ${r})`,Eh={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:Lo([0,.65,.55,1]),circOut:Lo([.55,0,1,.45]),backIn:Lo([.31,.01,.66,-.59]),backOut:Lo([.33,1.53,.69,.99])};function kk(t,e){if(t)return typeof t=="function"&&Bl()?MR(t,e):zf(t)?Lo(t):Array.isArray(t)?t.map(n=>kk(n,e)||Eh.easeOut):Eh[t]}function IR(t,e,n,{delay:r=0,duration:i=300,repeat:o=0,repeatType:a="loop",ease:s="easeInOut",times:l}={}){let u={[e]:n};l&&(u.offset=l);let c=kk(s,i);return Array.isArray(c)&&(u.easing=c),t.animate(u,{delay:r,duration:i,easing:Array.isArray(c)?"linear":c,fill:"both",iterations:o+1,direction:a==="reverse"?"alternate":"normal"})}function $v(t,e){t.timeline=e,t.onfinish=null}var LR=$f(()=>Object.hasOwnProperty.call(Element.prototype,"animate")),Ul=10,jR=2e4;function OR(t){return Vf(t.type)||t.type==="spring"||!wk(t.ease)}function _R(t,e){let n=new Uf({...e,keyframes:t,repeat:0,delay:0,isGenerator:!0}),r={done:!1,value:t[0]},i=[],o=0;for(;!r.done&&o<jR;)r=n.sample(o),i.push(r.value),o+=Ul;return{times:void 0,keyframes:i,duration:o-Ul,ease:"linear"}}var Sk={anticipate:Xw,backInOut:Kw,circInOut:Qw};function NR(t){return t in Sk}var Hv=class extends fk{constructor(t){super(t);let{name:e,motionValue:n,element:r,keyframes:i}=this.options;this.resolver=new pk(i,(o,a)=>this.onKeyframesResolved(o,a),e,n,r),this.resolver.scheduleResolve()}initPlayback(t,e){var n;let{duration:r=300,times:i,ease:o,type:a,motionValue:s,name:l,startTime:u}=this.options;if(!(!((n=s.owner)===null||n===void 0)&&n.current))return!1;if(typeof o=="string"&&Bl()&&NR(o)&&(o=Sk[o]),OR(this.options)){let{onComplete:d,onUpdate:h,motionValue:p,element:m,...v}=this.options,b=_R(t,v);t=b.keyframes,t.length===1&&(t[1]=t[0]),r=b.duration,i=b.times,o=b.ease,a="keyframes"}let c=IR(s.owner.current,l,t,{...this.options,duration:r,times:i,ease:o});return c.startTime=u??this.calcStartTime(),this.pendingTimeline?($v(c,this.pendingTimeline),this.pendingTimeline=void 0):c.onfinish=()=>{let{onComplete:d}=this.options;s.set(Lu(t,this.options,e)),d&&d(),this.cancel(),this.resolveFinishedPromise()},{animation:c,duration:r,times:i,type:a,ease:o,keyframes:t}}get duration(){let{resolved:t}=this;if(!t)return 0;let{duration:e}=t;return In(e)}get time(){let{resolved:t}=this;if(!t)return 0;let{animation:e}=t;return In(e.currentTime||0)}set time(t){let{resolved:e}=this;if(!e)return;let{animation:n}=e;n.currentTime=Rn(t)}get speed(){let{resolved:t}=this;if(!t)return 1;let{animation:e}=t;return e.playbackRate}set speed(t){let{resolved:e}=this;if(!e)return;let{animation:n}=e;n.playbackRate=t}get state(){let{resolved:t}=this;if(!t)return"idle";let{animation:e}=t;return e.playState}get startTime(){let{resolved:t}=this;if(!t)return null;let{animation:e}=t;return e.startTime}attachTimeline(t){if(!this._resolved)this.pendingTimeline=t;else{let{resolved:e}=this;if(!e)return re;let{animation:n}=e;$v(n,t)}return re}play(){if(this.isStopped)return;let{resolved:t}=this;if(!t)return;let{animation:e}=t;e.playState==="finished"&&this.updateFinishedPromise(),e.play()}pause(){let{resolved:t}=this;if(!t)return;let{animation:e}=t;e.pause()}stop(){if(this.resolver.cancel(),this.isStopped=!0,this.state==="idle")return;this.resolveFinishedPromise(),this.updateFinishedPromise();let{resolved:t}=this;if(!t)return;let{animation:e,keyframes:n,duration:r,type:i,ease:o,times:a}=t;if(e.playState==="idle"||e.playState==="finished")return;if(this.time){let{motionValue:l,onUpdate:u,onComplete:c,element:d,...h}=this.options,p=new Uf({...h,keyframes:n,duration:r,type:i,ease:o,times:a,isGenerator:!0}),m=Rn(this.time);l.setWithVelocity(p.sample(m-Ul).value,p.sample(m).value,Ul)}let{onStop:s}=this.options;s&&s(),this.cancel()}complete(){let{resolved:t}=this;t&&t.animation.finish()}cancel(){let{resolved:t}=this;t&&t.animation.cancel()}static supports(t){let{motionValue:e,name:n,repeatDelay:r,repeatType:i,damping:o,type:a}=t;return LR()&&n&&PR.has(n)&&e&&e.owner&&e.owner.current instanceof HTMLElement&&!e.owner.getProps().onUpdate&&!r&&i!=="mirror"&&o!==0&&a!=="inertia"}},FR=$f(()=>window.ScrollTimeline!==void 0),VR=class{constructor(t){this.stop=()=>this.runAll("stop"),this.animations=t.filter(Boolean)}then(t,e){return Promise.all(this.animations).then(t).catch(e)}getAll(t){return this.animations[0][t]}setAll(t,e){for(let n=0;n<this.animations.length;n++)this.animations[n][t]=e}attachTimeline(t,e){let n=this.animations.map(r=>FR()&&r.attachTimeline?r.attachTimeline(t):e(r));return()=>{n.forEach((r,i)=>{r&&r(),this.animations[i].stop()})}}get time(){return this.getAll("time")}set time(t){this.setAll("time",t)}get speed(){return this.getAll("speed")}set speed(t){this.setAll("speed",t)}get startTime(){return this.getAll("startTime")}get duration(){let t=0;for(let e=0;e<this.animations.length;e++)t=Math.max(t,this.animations[e].duration);return t}runAll(t){this.animations.forEach(e=>e[t]())}play(){this.runAll("play")}pause(){this.runAll("pause")}cancel(){this.runAll("cancel")}complete(){this.runAll("complete")}};function zR({when:t,delay:e,delayChildren:n,staggerChildren:r,staggerDirection:i,repeat:o,repeatType:a,repeatDelay:s,from:l,elapsed:u,...c}){return!!Object.keys(c).length}var Hf=(t,e,n,r={},i,o)=>a=>{let s=Df(r,t)||{},l=s.delay||r.delay||0,{elapsed:u=0}=r;u=u-Rn(l);let c={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:e.getVelocity(),...s,delay:-u,onUpdate:h=>{e.set(h),s.onUpdate&&s.onUpdate(h)},onComplete:()=>{a(),s.onComplete&&s.onComplete()},name:t,motionValue:e,element:o?void 0:i};zR(s)||(c={...c,...iD(t,c)}),c.duration&&(c.duration=Rn(c.duration)),c.repeatDelay&&(c.repeatDelay=Rn(c.repeatDelay)),c.from!==void 0&&(c.keyframes[0]=c.from);let d=!1;if((c.type===!1||c.duration===0&&!c.repeatDelay)&&(c.duration=0,c.delay===0&&(d=!0)),d&&!o&&e.get()!==void 0){let h=Lu(c.keyframes,s);if(h!==void 0)return ct.update(()=>{c.onUpdate(h),c.onComplete()}),new VR([])}return!o&&Hv.supports(c)?new Hv(c):new Uf(c)},BR=t=>!!(t&&typeof t=="object"&&t.mix&&t.toValue),UR=t=>vh(t)?t[t.length-1]||0:t;function Wf(t,e){t.indexOf(e)===-1&&t.push(e)}function qf(t,e){let n=t.indexOf(e);n>-1&&t.splice(n,1)}var Yf=class{constructor(){this.subscriptions=[]}add(t){return Wf(this.subscriptions,t),()=>qf(this.subscriptions,t)}notify(t,e,n){let r=this.subscriptions.length;if(r)if(r===1)this.subscriptions[0](t,e,n);else for(let i=0;i<r;i++){let o=this.subscriptions[i];o&&o(t,e,n)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}},Wv=30,$R=t=>!isNaN(parseFloat(t)),HR=class{constructor(t,e={}){this.version="11.11.15",this.canTrackVelocity=null,this.events={},this.updateAndNotify=(n,r=!0)=>{let i=fn.now();this.updatedAt!==i&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(n),this.current!==this.prev&&this.events.change&&this.events.change.notify(this.current),r&&this.events.renderRequest&&this.events.renderRequest.notify(this.current)},this.hasAnimated=!1,this.setCurrent(t),this.owner=e.owner}setCurrent(t){this.current=t,this.updatedAt=fn.now(),this.canTrackVelocity===null&&t!==void 0&&(this.canTrackVelocity=$R(this.current))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return this.on("change",t)}on(t,e){this.events[t]||(this.events[t]=new Yf);let n=this.events[t].add(e);return t==="change"?()=>{n(),ct.read(()=>{this.events.change.getSize()||this.stop()})}:n}clearListeners(){for(let t in this.events)this.events[t].clear()}attach(t,e){this.passiveEffect=t,this.stopPassiveEffect=e}set(t,e=!0){!e||!this.passiveEffect?this.updateAndNotify(t,e):this.passiveEffect(t,this.updateAndNotify)}setWithVelocity(t,e,n){this.set(e),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-n}jump(t,e=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,e&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}get(){return this.current}getPrevious(){return this.prev}getVelocity(){let t=fn.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||t-this.updatedAt>Wv)return 0;let e=Math.min(this.updatedAt-this.prevUpdatedAt,Wv);return mk(parseFloat(this.current)-parseFloat(this.prevFrameValue),e)}start(t){return this.stop(),new Promise(e=>{this.hasAnimated=!0,this.animation=t(e),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}};function Ia(t,e){return new HR(t,e)}function WR(t,e,n){t.hasValue(e)?t.getValue(e).set(n):t.addValue(e,Ia(n))}function qR(t,e){let n=Iu(t,e),{transitionEnd:r={},transition:i={},...o}=n||{};o={...o,...r};for(let a in o){let s=UR(o[a]);WR(t,a,s)}}var Kf=t=>t.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase(),YR="framerAppearId",Tk="data-"+Kf(YR);function Ek(t){return t.props[Tk]}var te=t=>!!(t&&t.getVelocity);function KR(t){return!!(te(t)&&t.add)}function Ch(t,e){let n=t.getValue("willChange");if(KR(n))return n.add(e)}function XR({protectedKeys:t,needsAnimating:e},n){let r=t.hasOwnProperty(n)&&e[n]!==!0;return e[n]=!1,r}function Ck(t,e,{delay:n=0,transitionOverride:r,type:i}={}){var o;let{transition:a=t.getDefaultTransition(),transitionEnd:s,...l}=e;r&&(a=r);let u=[],c=i&&t.animationState&&t.animationState.getState()[i];for(let d in l){let h=t.getValue(d,(o=t.latestValues[d])!==null&&o!==void 0?o:null),p=l[d];if(p===void 0||c&&XR(c,d))continue;let m={delay:n,...Df(a||{},d)},v=!1;if(window.MotionHandoffAnimation){let f=Ek(t);if(f){let g=window.MotionHandoffAnimation(f,d,ct);g!==null&&(m.startTime=g,v=!0)}}Ch(t,d),h.start(Hf(d,h,p,t.shouldReduceMotion&&ri.has(d)?{type:!1}:m,t,v));let b=h.animation;b&&u.push(b)}return s&&Promise.all(u).then(()=>{ct.update(()=>{s&&qR(t,s)})}),u}function Ph(t,e,n={}){var r;let i=Iu(t,e,n.type==="exit"?(r=t.presenceContext)===null||r===void 0?void 0:r.custom:void 0),{transition:o=t.getDefaultTransition()||{}}=i||{};n.transitionOverride&&(o=n.transitionOverride);let a=i?()=>Promise.all(Ck(t,i,n)):()=>Promise.resolve(),s=t.variantChildren&&t.variantChildren.size?(u=0)=>{let{delayChildren:c=0,staggerChildren:d,staggerDirection:h}=o;return GR(t,e,c+u,d,h,n)}:()=>Promise.resolve(),{when:l}=o;if(l){let[u,c]=l==="beforeChildren"?[a,s]:[s,a];return u().then(()=>c())}else return Promise.all([a(),s(n.delay)])}function GR(t,e,n=0,r=0,i=1,o){let a=[],s=(t.variantChildren.size-1)*r,l=i===1?(u=0)=>u*r:(u=0)=>s-u*r;return Array.from(t.variantChildren).sort(QR).forEach((u,c)=>{u.notify("AnimationStart",e),a.push(Ph(u,e,{...o,delay:n+l(c)}).then(()=>u.notify("AnimationComplete",e)))}),Promise.all(a)}function QR(t,e){return t.sortNodePosition(e)}function JR(t,e,n={}){t.notify("AnimationStart",e);let r;if(Array.isArray(e)){let i=e.map(o=>Ph(t,o,n));r=Promise.all(i)}else if(typeof e=="string")r=Ph(t,e,n);else{let i=typeof e=="function"?Iu(t,e,n.custom):e;r=Promise.all(Ck(t,i,n))}return r.then(()=>{t.notify("AnimationComplete",e)})}var ZR=Mf.length;function Pk(t){if(!t)return;if(!t.isControllingVariants){let n=t.parent?Pk(t.parent)||{}:{};return t.props.initial!==void 0&&(n.initial=t.props.initial),n}let e={};for(let n=0;n<ZR;n++){let r=Mf[n],i=t.props[r];(Ma(i)||i===!1)&&(e[r]=i)}return e}var tI=[...Af].reverse(),eI=Af.length;function nI(t){return e=>Promise.all(e.map(({animation:n,options:r})=>JR(t,n,r)))}function rI(t){let e=nI(t),n=qv(),r=!0,i=l=>(u,c)=>{var d;let h=Iu(t,c,l==="exit"?(d=t.presenceContext)===null||d===void 0?void 0:d.custom:void 0);if(h){let{transition:p,transitionEnd:m,...v}=h;u={...u,...v,...m}}return u};function o(l){e=l(t)}function a(l){let{props:u}=t,c=Pk(t.parent)||{},d=[],h=new Set,p={},m=1/0;for(let b=0;b<eI;b++){let f=tI[b],g=n[f],y=u[f]!==void 0?u[f]:c[f],w=Ma(y),C=f===l?g.isActive:null;C===!1&&(m=b);let k=y===c[f]&&y!==u[f]&&w;if(k&&r&&t.manuallyAnimateOnMount&&(k=!1),g.protectedKeys={...p},!g.isActive&&C===null||!y&&!g.prevProp||Ru(y)||typeof y=="boolean")continue;let M=iI(g.prevProp,y),P=M||f===l&&g.isActive&&!k&&w||b>m&&w,R=!1,E=Array.isArray(y)?y:[y],L=E.reduce(i(f),{});C===!1&&(L={});let{prevResolvedValues:N={}}=g,B={...N,...L},U=F=>{P=!0,h.has(F)&&(R=!0,h.delete(F)),g.needsAnimating[F]=!0;let K=t.getValue(F);K&&(K.liveStyle=!1)};for(let F in B){let K=L[F],Q=N[F];if(p.hasOwnProperty(F))continue;let I=!1;vh(K)&&vh(Q)?I=!Uw(K,Q):I=K!==Q,I?K!=null?U(F):h.add(F):K!==void 0&&h.has(F)?U(F):g.protectedKeys[F]=!0}g.prevProp=y,g.prevResolvedValues=L,g.isActive&&(p={...p,...L}),r&&t.blockInitialAnimation&&(P=!1),P&&(!(k&&M)||R)&&d.push(...E.map(F=>({animation:F,options:{type:f}})))}if(h.size){let b={};h.forEach(f=>{let g=t.getBaseTarget(f),y=t.getValue(f);y&&(y.liveStyle=!0),b[f]=g??null}),d.push({animation:b})}let v=!!d.length;return r&&(u.initial===!1||u.initial===u.animate)&&!t.manuallyAnimateOnMount&&(v=!1),r=!1,v?e(d):Promise.resolve()}function s(l,u){var c;if(n[l].isActive===u)return Promise.resolve();(c=t.variantChildren)===null||c===void 0||c.forEach(h=>{var p;return(p=h.animationState)===null||p===void 0?void 0:p.setActive(l,u)}),n[l].isActive=u;let d=a(l);for(let h in n)n[h].protectedKeys={};return d}return{animateChanges:a,setActive:s,setAnimateFunction:o,getState:()=>n,reset:()=>{n=qv(),r=!0}}}function iI(t,e){return typeof e=="string"?e!==t:Array.isArray(e)?!Uw(e,t):!1}function Pr(t=!1){return{isActive:t,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function qv(){return{animate:Pr(!0),whileInView:Pr(),whileHover:Pr(),whileTap:Pr(),whileDrag:Pr(),whileFocus:Pr(),exit:Pr()}}var Er=class{constructor(t){this.isMounted=!1,this.node=t}update(){}},oI=class extends Er{constructor(t){super(t),t.animationState||(t.animationState=rI(t))}updateAnimationControlsSubscription(){let{animate:t}=this.node.getProps();Ru(t)&&(this.unmountControls=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){let{animate:t}=this.node.getProps(),{animate:e}=this.node.prevProps||{};t!==e&&this.updateAnimationControlsSubscription()}unmount(){var t;this.node.animationState.reset(),(t=this.unmountControls)===null||t===void 0||t.call(this)}},aI=0,sI=class extends Er{constructor(){super(...arguments),this.id=aI++}update(){if(!this.node.presenceContext)return;let{isPresent:t,onExitComplete:e}=this.node.presenceContext,{isPresent:n}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===n)return;let r=this.node.animationState.setActive("exit",!t);e&&!t&&r.then(()=>e(this.id))}mount(){let{register:t}=this.node.presenceContext||{};t&&(this.unmount=t(this.id))}unmount(){}},lI={animation:{Feature:oI},exit:{Feature:sI}},Ak=t=>t.pointerType==="mouse"?typeof t.button!="number"||t.button<=0:t.isPrimary!==!1;function ju(t,e="page"){return{point:{x:t[`${e}X`],y:t[`${e}Y`]}}}var uI=t=>e=>Ak(e)&&t(e,ju(e));function An(t,e,n,r={passive:!0}){return t.addEventListener(e,n,r),()=>t.removeEventListener(e,n)}function jn(t,e,n,r){return An(t,e,uI(n),r)}var Yv=(t,e)=>Math.abs(t-e);function cI(t,e){let n=Yv(t.x,e.x),r=Yv(t.y,e.y);return Math.sqrt(n**2+r**2)}var Mk=class{constructor(t,e,{transformPagePoint:n,contextWindow:r,dragSnapToOrigin:i=!1}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;let c=Lc(this.lastMoveEventInfo,this.history),d=this.startEvent!==null,h=cI(c.offset,{x:0,y:0})>=3;if(!d&&!h)return;let{point:p}=c,{timestamp:m}=Ht;this.history.push({...p,timestamp:m});let{onStart:v,onMove:b}=this.handlers;d||(v&&v(this.lastMoveEvent,c),this.startEvent=this.lastMoveEvent),b&&b(this.lastMoveEvent,c)},this.handlePointerMove=(c,d)=>{this.lastMoveEvent=c,this.lastMoveEventInfo=Ic(d,this.transformPagePoint),ct.update(this.updatePoint,!0)},this.handlePointerUp=(c,d)=>{this.end();let{onEnd:h,onSessionEnd:p,resumeAnimation:m}=this.handlers;if(this.dragSnapToOrigin&&m&&m(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;let v=Lc(c.type==="pointercancel"?this.lastMoveEventInfo:Ic(d,this.transformPagePoint),this.history);this.startEvent&&h&&h(c,v),p&&p(c,v)},!Ak(t))return;this.dragSnapToOrigin=i,this.handlers=e,this.transformPagePoint=n,this.contextWindow=r||window;let o=ju(t),a=Ic(o,this.transformPagePoint),{point:s}=a,{timestamp:l}=Ht;this.history=[{...s,timestamp:l}];let{onSessionStart:u}=e;u&&u(t,Lc(a,this.history)),this.removeListeners=Ln(jn(this.contextWindow,"pointermove",this.handlePointerMove),jn(this.contextWindow,"pointerup",this.handlePointerUp),jn(this.contextWindow,"pointercancel",this.handlePointerUp))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),mr(this.updatePoint)}};function Ic(t,e){return e?{point:e(t.point)}:t}function Kv(t,e){return{x:t.x-e.x,y:t.y-e.y}}function Lc({point:t},e){return{point:t,delta:Kv(t,Dk(e)),offset:Kv(t,dI(e)),velocity:hI(e,.1)}}function dI(t){return t[0]}function Dk(t){return t[t.length-1]}function hI(t,e){if(t.length<2)return{x:0,y:0};let n=t.length-1,r=null,i=Dk(t);for(;n>=0&&(r=t[n],!(i.timestamp-r.timestamp>Rn(e)));)n--;if(!r)return{x:0,y:0};let o=In(i.timestamp-r.timestamp);if(o===0)return{x:0,y:0};let a={x:(i.x-r.x)/o,y:(i.y-r.y)/o};return a.x===1/0&&(a.x=0),a.y===1/0&&(a.y=0),a}function Rk(t){let e=null;return()=>{let n=()=>{e=null};return e===null?(e=t,n):!1}}var Xv=Rk("dragHorizontal"),Gv=Rk("dragVertical");function Ik(t){let e=!1;if(t==="y")e=Gv();else if(t==="x")e=Xv();else{let n=Xv(),r=Gv();n&&r?e=()=>{n(),r()}:(n&&n(),r&&r())}return e}function Lk(){let t=Ik(!0);return t?(t(),!1):!0}function Ei(t){return t&&typeof t=="object"&&Object.prototype.hasOwnProperty.call(t,"current")}var jk=1e-4,pI=1-jk,fI=1+jk,Ok=.01,mI=0-Ok,gI=0+Ok;function Me(t){return t.max-t.min}function vI(t,e,n){return Math.abs(t-e)<=n}function Qv(t,e,n,r=.5){t.origin=r,t.originPoint=Et(e.min,e.max,t.origin),t.scale=Me(n)/Me(e),t.translate=Et(n.min,n.max,t.origin)-t.originPoint,(t.scale>=pI&&t.scale<=fI||isNaN(t.scale))&&(t.scale=1),(t.translate>=mI&&t.translate<=gI||isNaN(t.translate))&&(t.translate=0)}function Yo(t,e,n,r){Qv(t.x,e.x,n.x,r?r.originX:void 0),Qv(t.y,e.y,n.y,r?r.originY:void 0)}function Jv(t,e,n){t.min=n.min+e.min,t.max=t.min+Me(e)}function yI(t,e,n){Jv(t.x,e.x,n.x),Jv(t.y,e.y,n.y)}function Zv(t,e,n){t.min=e.min-n.min,t.max=t.min+Me(e)}function Ko(t,e,n){Zv(t.x,e.x,n.x),Zv(t.y,e.y,n.y)}function bI(t,{min:e,max:n},r){return e!==void 0&&t<e?t=r?Et(e,t,r.min):Math.max(t,e):n!==void 0&&t>n&&(t=r?Et(n,t,r.max):Math.min(t,n)),t}function ty(t,e,n){return{min:e!==void 0?t.min+e:void 0,max:n!==void 0?t.max+n-(t.max-t.min):void 0}}function xI(t,{top:e,left:n,bottom:r,right:i}){return{x:ty(t.x,n,i),y:ty(t.y,e,r)}}function ey(t,e){let n=e.min-t.min,r=e.max-t.max;return e.max-e.min<t.max-t.min&&([n,r]=[r,n]),{min:n,max:r}}function wI(t,e){return{x:ey(t.x,e.x),y:ey(t.y,e.y)}}function kI(t,e){let n=.5,r=Me(t),i=Me(e);return i>r?n=Qi(e.min,e.max-r,t.min):r>i&&(n=Qi(t.min,t.max-i,e.min)),gr(0,1,n)}function SI(t,e){let n={};return e.min!==void 0&&(n.min=e.min-t.min),e.max!==void 0&&(n.max=e.max-t.min),n}var Ah=.35;function TI(t=Ah){return t===!1?t=0:t===!0&&(t=Ah),{x:ny(t,"left","right"),y:ny(t,"top","bottom")}}function ny(t,e,n){return{min:ry(t,e),max:ry(t,n)}}function ry(t,e){return typeof t=="number"?t:t[e]||0}var iy=()=>({translate:0,scale:1,origin:0,originPoint:0}),Ci=()=>({x:iy(),y:iy()}),oy=()=>({min:0,max:0}),Rt=()=>({x:oy(),y:oy()});function Ne(t){return[t("x"),t("y")]}function _k({top:t,left:e,right:n,bottom:r}){return{x:{min:e,max:n},y:{min:t,max:r}}}function EI({x:t,y:e}){return{top:e.min,right:t.max,bottom:e.max,left:t.min}}function CI(t,e){if(!e)return t;let n=e({x:t.left,y:t.top}),r=e({x:t.right,y:t.bottom});return{top:n.y,left:n.x,bottom:r.y,right:r.x}}function jc(t){return t===void 0||t===1}function Mh({scale:t,scaleX:e,scaleY:n}){return!jc(t)||!jc(e)||!jc(n)}function Ir(t){return Mh(t)||Nk(t)||t.z||t.rotate||t.rotateX||t.rotateY||t.skewX||t.skewY}function Nk(t){return ay(t.x)||ay(t.y)}function ay(t){return t&&t!=="0%"}function $l(t,e,n){let r=t-n,i=e*r;return n+i}function sy(t,e,n,r,i){return i!==void 0&&(t=$l(t,i,r)),$l(t,n,r)+e}function Dh(t,e=0,n=1,r,i){t.min=sy(t.min,e,n,r,i),t.max=sy(t.max,e,n,r,i)}function Fk(t,{x:e,y:n}){Dh(t.x,e.translate,e.scale,e.originPoint),Dh(t.y,n.translate,n.scale,n.originPoint)}var ly=.999999999999,uy=1.0000000000001;function PI(t,e,n,r=!1){let i=n.length;if(!i)return;e.x=e.y=1;let o,a;for(let s=0;s<i;s++){o=n[s],a=o.projectionDelta;let{visualElement:l}=o.options;l&&l.props.style&&l.props.style.display==="contents"||(r&&o.options.layoutScroll&&o.scroll&&o!==o.root&&Ai(t,{x:-o.scroll.offset.x,y:-o.scroll.offset.y}),a&&(e.x*=a.x.scale,e.y*=a.y.scale,Fk(t,a)),r&&Ir(o.latestValues)&&Ai(t,o.latestValues))}e.x<uy&&e.x>ly&&(e.x=1),e.y<uy&&e.y>ly&&(e.y=1)}function Pi(t,e){t.min=t.min+e,t.max=t.max+e}function cy(t,e,n,r,i=.5){let o=Et(t.min,t.max,i);Dh(t,e,n,o,r)}function Ai(t,e){cy(t.x,e.x,e.scaleX,e.scale,e.originX),cy(t.y,e.y,e.scaleY,e.scale,e.originY)}function Vk(t,e){return _k(CI(t.getBoundingClientRect(),e))}function AI(t,e,n){let r=Vk(t,n),{scroll:i}=e;return i&&(Pi(r.x,i.offset.x),Pi(r.y,i.offset.y)),r}var zk=({current:t})=>t?t.ownerDocument.defaultView:null,MI=new WeakMap,DI=class{constructor(t){this.openGlobalLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=Rt(),this.visualElement=t}start(t,{snapToCursor:e=!1}={}){let{presenceContext:n}=this.visualElement;if(n&&n.isPresent===!1)return;let r=u=>{let{dragSnapToOrigin:c}=this.getProps();c?this.pauseAnimation():this.stopAnimation(),e&&this.snapToCursor(ju(u,"page").point)},i=(u,c)=>{let{drag:d,dragPropagation:h,onDragStart:p}=this.getProps();if(d&&!h&&(this.openGlobalLock&&this.openGlobalLock(),this.openGlobalLock=Ik(d),!this.openGlobalLock))return;this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),Ne(v=>{let b=this.getAxisMotionValue(v).get()||0;if(pn.test(b)){let{projection:f}=this.visualElement;if(f&&f.layout){let g=f.layout.layoutBox[v];g&&(b=Me(g)*(parseFloat(b)/100))}}this.originPoint[v]=b}),p&&ct.postRender(()=>p(u,c)),Ch(this.visualElement,"transform");let{animationState:m}=this.visualElement;m&&m.setActive("whileDrag",!0)},o=(u,c)=>{let{dragPropagation:d,dragDirectionLock:h,onDirectionLock:p,onDrag:m}=this.getProps();if(!d&&!this.openGlobalLock)return;let{offset:v}=c;if(h&&this.currentDirection===null){this.currentDirection=RI(v),this.currentDirection!==null&&p&&p(this.currentDirection);return}this.updateAxis("x",c.point,v),this.updateAxis("y",c.point,v),this.visualElement.render(),m&&m(u,c)},a=(u,c)=>this.stop(u,c),s=()=>Ne(u=>{var c;return this.getAnimationState(u)==="paused"&&((c=this.getAxisMotionValue(u).animation)===null||c===void 0?void 0:c.play())}),{dragSnapToOrigin:l}=this.getProps();this.panSession=new Mk(t,{onSessionStart:r,onStart:i,onMove:o,onSessionEnd:a,resumeAnimation:s},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:l,contextWindow:zk(this.visualElement)})}stop(t,e){let n=this.isDragging;if(this.cancel(),!n)return;let{velocity:r}=e;this.startAnimation(r);let{onDragEnd:i}=this.getProps();i&&ct.postRender(()=>i(t,e))}cancel(){this.isDragging=!1;let{projection:t,animationState:e}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;let{dragPropagation:n}=this.getProps();!n&&this.openGlobalLock&&(this.openGlobalLock(),this.openGlobalLock=null),e&&e.setActive("whileDrag",!1)}updateAxis(t,e,n){let{drag:r}=this.getProps();if(!n||!Is(t,r,this.currentDirection))return;let i=this.getAxisMotionValue(t),o=this.originPoint[t]+n[t];this.constraints&&this.constraints[t]&&(o=bI(o,this.constraints[t],this.elastic[t])),i.set(o)}resolveConstraints(){var t;let{dragConstraints:e,dragElastic:n}=this.getProps(),r=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):(t=this.visualElement.projection)===null||t===void 0?void 0:t.layout,i=this.constraints;e&&Ei(e)?this.constraints||(this.constraints=this.resolveRefConstraints()):e&&r?this.constraints=xI(r.layoutBox,e):this.constraints=!1,this.elastic=TI(n),i!==this.constraints&&r&&this.constraints&&!this.hasMutatedConstraints&&Ne(o=>{this.constraints!==!1&&this.getAxisMotionValue(o)&&(this.constraints[o]=SI(r.layoutBox[o],this.constraints[o]))})}resolveRefConstraints(){let{dragConstraints:t,onMeasureDragConstraints:e}=this.getProps();if(!t||!Ei(t))return!1;let n=t.current,{projection:r}=this.visualElement;if(!r||!r.layout)return!1;let i=AI(n,r.root,this.visualElement.getTransformPagePoint()),o=wI(r.layout.layoutBox,i);if(e){let a=e(EI(o));this.hasMutatedConstraints=!!a,a&&(o=_k(a))}return o}startAnimation(t){let{drag:e,dragMomentum:n,dragElastic:r,dragTransition:i,dragSnapToOrigin:o,onDragTransitionEnd:a}=this.getProps(),s=this.constraints||{},l=Ne(u=>{if(!Is(u,e,this.currentDirection))return;let c=s&&s[u]||{};o&&(c={min:0,max:0});let d=r?200:1e6,h=r?40:1e7,p={type:"inertia",velocity:n?t[u]:0,bounceStiffness:d,bounceDamping:h,timeConstant:750,restDelta:1,restSpeed:10,...i,...c};return this.startAxisValueAnimation(u,p)});return Promise.all(l).then(a)}startAxisValueAnimation(t,e){let n=this.getAxisMotionValue(t);return Ch(this.visualElement,t),n.start(Hf(t,n,0,e,this.visualElement,!1))}stopAnimation(){Ne(t=>this.getAxisMotionValue(t).stop())}pauseAnimation(){Ne(t=>{var e;return(e=this.getAxisMotionValue(t).animation)===null||e===void 0?void 0:e.pause()})}getAnimationState(t){var e;return(e=this.getAxisMotionValue(t).animation)===null||e===void 0?void 0:e.state}getAxisMotionValue(t){let e=`_drag${t.toUpperCase()}`,n=this.visualElement.getProps();return n[e]||this.visualElement.getValue(t,(n.initial?n.initial[t]:void 0)||0)}snapToCursor(t){Ne(e=>{let{drag:n}=this.getProps();if(!Is(e,n,this.currentDirection))return;let{projection:r}=this.visualElement,i=this.getAxisMotionValue(e);if(r&&r.layout){let{min:o,max:a}=r.layout.layoutBox[e];i.set(t[e]-Et(o,a,.5))}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;let{drag:t,dragConstraints:e}=this.getProps(),{projection:n}=this.visualElement;if(!Ei(e)||!n||!this.constraints)return;this.stopAnimation();let r={x:0,y:0};Ne(o=>{let a=this.getAxisMotionValue(o);if(a&&this.constraints!==!1){let s=a.get();r[o]=kI({min:s,max:s},this.constraints[o])}});let{transformTemplate:i}=this.visualElement.getProps();this.visualElement.current.style.transform=i?i({},""):"none",n.root&&n.root.updateScroll(),n.updateLayout(),this.resolveConstraints(),Ne(o=>{if(!Is(o,t,null))return;let a=this.getAxisMotionValue(o),{min:s,max:l}=this.constraints[o];a.set(Et(s,l,r[o]))})}addListeners(){if(!this.visualElement.current)return;MI.set(this.visualElement,this);let t=this.visualElement.current,e=jn(t,"pointerdown",s=>{let{drag:l,dragListener:u=!0}=this.getProps();l&&u&&this.start(s)}),n=()=>{let{dragConstraints:s}=this.getProps();Ei(s)&&s.current&&(this.constraints=this.resolveRefConstraints())},{projection:r}=this.visualElement,i=r.addEventListener("measure",n);r&&!r.layout&&(r.root&&r.root.updateScroll(),r.updateLayout()),ct.read(n);let o=An(window,"resize",()=>this.scalePositionWithinConstraints()),a=r.addEventListener("didUpdate",({delta:s,hasLayoutChanged:l})=>{this.isDragging&&l&&(Ne(u=>{let c=this.getAxisMotionValue(u);c&&(this.originPoint[u]+=s[u].translate,c.set(c.get()+s[u].translate))}),this.visualElement.render())});return()=>{o(),e(),i(),a&&a()}}getProps(){let t=this.visualElement.getProps(),{drag:e=!1,dragDirectionLock:n=!1,dragPropagation:r=!1,dragConstraints:i=!1,dragElastic:o=Ah,dragMomentum:a=!0}=t;return{...t,drag:e,dragDirectionLock:n,dragPropagation:r,dragConstraints:i,dragElastic:o,dragMomentum:a}}};function Is(t,e,n){return(e===!0||e===t)&&(n===null||n===t)}function RI(t,e=10){let n=null;return Math.abs(t.y)>e?n="y":Math.abs(t.x)>e&&(n="x"),n}var II=class extends Er{constructor(t){super(t),this.removeGroupControls=re,this.removeListeners=re,this.controls=new DI(t)}mount(){let{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||re}unmount(){this.removeGroupControls(),this.removeListeners()}},dy=t=>(e,n)=>{t&&ct.postRender(()=>t(e,n))},LI=class extends Er{constructor(){super(...arguments),this.removePointerDownListener=re}onPointerDown(t){this.session=new Mk(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:zk(this.node)})}createPanHandlers(){let{onPanSessionStart:t,onPanStart:e,onPan:n,onPanEnd:r}=this.node.getProps();return{onSessionStart:dy(t),onStart:dy(e),onMove:n,onEnd:(i,o)=>{delete this.session,r&&ct.postRender(()=>r(i,o))}}}mount(){this.removePointerDownListener=jn(this.node.current,"pointerdown",t=>this.onPointerDown(t))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}},Xf=S.createContext(null);function jI(){let t=S.useContext(Xf);if(t===null)return[!0,null];let{isPresent:e,onExitComplete:n,register:r}=t,i=S.useId();S.useEffect(()=>r(i),[]);let o=S.useCallback(()=>n&&n(i),[i,n]);return!e&&n?[!1,o]:[!0]}var Bk=S.createContext({}),Uk=S.createContext({}),nl={hasAnimatedSinceResize:!0,hasEverUpdated:!1};function hy(t,e){return e.max===e.min?0:t/(e.max-e.min)*100}var To={correct:(t,e)=>{if(!e.target)return t;if(typeof t=="string")if(W.test(t))t=parseFloat(t);else return t;let n=hy(t,e.target.x),r=hy(t,e.target.y);return`${n}% ${r}%`}},OI={correct:(t,{treeScale:e,projectionDelta:n})=>{let r=t,i=vr.parse(t);if(i.length>5)return r;let o=vr.createTransformer(t),a=typeof i[0]!="number"?1:0,s=n.x.scale*e.x,l=n.y.scale*e.y;i[0+a]/=s,i[1+a]/=l;let u=Et(s,l,.5);return typeof i[2+a]=="number"&&(i[2+a]/=u),typeof i[3+a]=="number"&&(i[3+a]/=u),o(i)}},Hl={};function _I(t){Object.assign(Hl,t)}var{schedule:Gf,cancel:KB}=$w(queueMicrotask,!1),NI=class extends S.Component{componentDidMount(){let{visualElement:t,layoutGroup:e,switchLayoutGroup:n,layoutId:r}=this.props,{projection:i}=t;_I(FI),i&&(e.group&&e.group.add(i),n&&n.register&&r&&n.register(i),i.root.didUpdate(),i.addEventListener("animationComplete",()=>{this.safeToRemove()}),i.setOptions({...i.options,onExitComplete:()=>this.safeToRemove()})),nl.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){let{layoutDependency:e,visualElement:n,drag:r,isPresent:i}=this.props,o=n.projection;return o&&(o.isPresent=i,r||t.layoutDependency!==e||e===void 0?o.willUpdate():this.safeToRemove(),t.isPresent!==i&&(i?o.promote():o.relegate()||ct.postRender(()=>{let a=o.getStack();(!a||!a.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){let{projection:t}=this.props.visualElement;t&&(t.root.didUpdate(),Gf.postRender(()=>{!t.currentAnimation&&t.isLead()&&this.safeToRemove()}))}componentWillUnmount(){let{visualElement:t,layoutGroup:e,switchLayoutGroup:n}=this.props,{projection:r}=t;r&&(r.scheduleCheckAfterUnmount(),e&&e.group&&e.group.remove(r),n&&n.deregister&&n.deregister(r))}safeToRemove(){let{safeToRemove:t}=this.props;t&&t()}render(){return null}};function $k(t){let[e,n]=jI(),r=S.useContext(Bk);return A.jsx(NI,{...t,layoutGroup:r,switchLayoutGroup:S.useContext(Uk),isPresent:e,safeToRemove:n})}var FI={borderRadius:{...To,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:To,borderTopRightRadius:To,borderBottomLeftRadius:To,borderBottomRightRadius:To,boxShadow:OI},Hk=["TopLeft","TopRight","BottomLeft","BottomRight"],VI=Hk.length,py=t=>typeof t=="string"?parseFloat(t):t,fy=t=>typeof t=="number"||W.test(t);function zI(t,e,n,r,i,o){i?(t.opacity=Et(0,n.opacity!==void 0?n.opacity:1,BI(r)),t.opacityExit=Et(e.opacity!==void 0?e.opacity:1,0,UI(r))):o&&(t.opacity=Et(e.opacity!==void 0?e.opacity:1,n.opacity!==void 0?n.opacity:1,r));for(let a=0;a<VI;a++){let s=`border${Hk[a]}Radius`,l=my(e,s),u=my(n,s);l===void 0&&u===void 0||(l||(l=0),u||(u=0),l===0||u===0||fy(l)===fy(u)?(t[s]=Math.max(Et(py(l),py(u),r),0),(pn.test(u)||pn.test(l))&&(t[s]+="%")):t[s]=u)}(e.rotate||n.rotate)&&(t.rotate=Et(e.rotate||0,n.rotate||0,r))}function my(t,e){return t[e]!==void 0?t[e]:t.borderRadius}var BI=Wk(0,.5,Gw),UI=Wk(.5,.95,re);function Wk(t,e,n){return r=>r<t?0:r>e?1:n(Qi(t,e,r))}function gy(t,e){t.min=e.min,t.max=e.max}function Oe(t,e){gy(t.x,e.x),gy(t.y,e.y)}function vy(t,e){t.translate=e.translate,t.scale=e.scale,t.originPoint=e.originPoint,t.origin=e.origin}function yy(t,e,n,r,i){return t-=e,t=$l(t,1/n,r),i!==void 0&&(t=$l(t,1/i,r)),t}function $I(t,e=0,n=1,r=.5,i,o=t,a=t){if(pn.test(e)&&(e=parseFloat(e),e=Et(a.min,a.max,e/100)-a.min),typeof e!="number")return;let s=Et(o.min,o.max,r);t===o&&(s-=e),t.min=yy(t.min,e,n,s,i),t.max=yy(t.max,e,n,s,i)}function by(t,e,[n,r,i],o,a){$I(t,e[n],e[r],e[i],e.scale,o,a)}var HI=["x","scaleX","originX"],WI=["y","scaleY","originY"];function xy(t,e,n,r){by(t.x,e,HI,n?n.x:void 0,r?r.x:void 0),by(t.y,e,WI,n?n.y:void 0,r?r.y:void 0)}function wy(t){return t.translate===0&&t.scale===1}function qk(t){return wy(t.x)&&wy(t.y)}function ky(t,e){return t.min===e.min&&t.max===e.max}function qI(t,e){return ky(t.x,e.x)&&ky(t.y,e.y)}function Sy(t,e){return Math.round(t.min)===Math.round(e.min)&&Math.round(t.max)===Math.round(e.max)}function Yk(t,e){return Sy(t.x,e.x)&&Sy(t.y,e.y)}function Ty(t){return Me(t.x)/Me(t.y)}function Ey(t,e){return t.translate===e.translate&&t.scale===e.scale&&t.originPoint===e.originPoint}var YI=class{constructor(){this.members=[]}add(t){Wf(this.members,t),t.scheduleRender()}remove(t){if(qf(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){let e=this.members[this.members.length-1];e&&this.promote(e)}}relegate(t){let e=this.members.findIndex(r=>t===r);if(e===0)return!1;let n;for(let r=e;r>=0;r--){let i=this.members[r];if(i.isPresent!==!1){n=i;break}}return n?(this.promote(n),!0):!1}promote(t,e){let n=this.lead;if(t!==n&&(this.prevLead=n,this.lead=t,t.show(),n)){n.instance&&n.scheduleRender(),t.scheduleRender(),t.resumeFrom=n,e&&(t.resumeFrom.preserveOpacity=!0),n.snapshot&&(t.snapshot=n.snapshot,t.snapshot.latestValues=n.animationValues||n.latestValues),t.root&&t.root.isUpdating&&(t.isLayoutDirty=!0);let{crossfade:r}=t.options;r===!1&&n.hide()}}exitAnimationComplete(){this.members.forEach(t=>{let{options:e,resumingFrom:n}=t;e.onExitComplete&&e.onExitComplete(),n&&n.options.onExitComplete&&n.options.onExitComplete()})}scheduleRender(){this.members.forEach(t=>{t.instance&&t.scheduleRender(!1)})}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}};function KI(t,e,n){let r="",i=t.x.translate/e.x,o=t.y.translate/e.y,a=n?.z||0;if((i||o||a)&&(r=`translate3d(${i}px, ${o}px, ${a}px) `),(e.x!==1||e.y!==1)&&(r+=`scale(${1/e.x}, ${1/e.y}) `),n){let{transformPerspective:u,rotate:c,rotateX:d,rotateY:h,skewX:p,skewY:m}=n;u&&(r=`perspective(${u}px) ${r}`),c&&(r+=`rotate(${c}deg) `),d&&(r+=`rotateX(${d}deg) `),h&&(r+=`rotateY(${h}deg) `),p&&(r+=`skewX(${p}deg) `),m&&(r+=`skewY(${m}deg) `)}let s=t.x.scale*e.x,l=t.y.scale*e.y;return(s!==1||l!==1)&&(r+=`scale(${s}, ${l})`),r||"none"}var XI=(t,e)=>t.depth-e.depth,GI=class{constructor(){this.children=[],this.isDirty=!1}add(t){Wf(this.children,t),this.isDirty=!0}remove(t){qf(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(XI),this.isDirty=!1,this.children.forEach(t)}};function rl(t){let e=te(t)?t.get():t;return BR(e)?e.toValue():e}function QI(t,e){let n=fn.now(),r=({timestamp:i})=>{let o=i-n;o>=e&&(mr(r),t(o-e))};return ct.read(r,!0),()=>mr(r)}function JI(t){return t instanceof SVGElement&&t.tagName!=="svg"}function ZI(t,e,n){let r=te(t)?t:Ia(t);return r.start(Hf("",r,e,n)),r.animation}var Lr={type:"projectionFrame",totalNodes:0,resolvedTargetDeltas:0,recalculatedProjection:0},jo=typeof window<"u"&&window.MotionDebug!==void 0,Oc=["","X","Y","Z"],tL={visibility:"hidden"},Cy=1e3,eL=0;function _c(t,e,n,r){let{latestValues:i}=e;i[t]&&(n[t]=i[t],e.setStaticValue(t,0),r&&(r[t]=0))}function Kk(t){if(t.hasCheckedOptimisedAppear=!0,t.root===t)return;let{visualElement:e}=t.options;if(!e)return;let n=Ek(e);if(window.MotionHasOptimisedAnimation(n,"transform")){let{layout:i,layoutId:o}=t.options;window.MotionCancelOptimisedAnimation(n,"transform",ct,!(i||o))}let{parent:r}=t;r&&!r.hasCheckedOptimisedAppear&&Kk(r)}function Xk({attachResizeListener:t,defaultParent:e,measureScroll:n,checkIsScrollRoot:r,resetTransform:i}){return class{constructor(o={},a=e?.()){this.id=eL++,this.animationId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,jo&&(Lr.totalNodes=Lr.resolvedTargetDeltas=Lr.recalculatedProjection=0),this.nodes.forEach(iL),this.nodes.forEach(uL),this.nodes.forEach(cL),this.nodes.forEach(oL),jo&&window.MotionDebug.record(Lr)},this.resolvedRelativeTargetAt=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=o,this.root=a?a.root||a:this,this.path=a?[...a.path,a]:[],this.parent=a,this.depth=a?a.depth+1:0;for(let s=0;s<this.path.length;s++)this.path[s].shouldResetTransform=!0;this.root===this&&(this.nodes=new GI)}addEventListener(o,a){return this.eventHandlers.has(o)||this.eventHandlers.set(o,new Yf),this.eventHandlers.get(o).add(a)}notifyListeners(o,...a){let s=this.eventHandlers.get(o);s&&s.notify(...a)}hasListeners(o){return this.eventHandlers.has(o)}mount(o,a=this.root.hasTreeAnimated){if(this.instance)return;this.isSVG=JI(o),this.instance=o;let{layoutId:s,layout:l,visualElement:u}=this.options;if(u&&!u.current&&u.mount(o),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),a&&(l||s)&&(this.isLayoutDirty=!0),t){let c,d=()=>this.root.updateBlockedByResize=!1;t(o,()=>{this.root.updateBlockedByResize=!0,c&&c(),c=QI(d,250),nl.hasAnimatedSinceResize&&(nl.hasAnimatedSinceResize=!1,this.nodes.forEach(Ay))})}s&&this.root.registerSharedNode(s,this),this.options.animate!==!1&&u&&(s||l)&&this.addEventListener("didUpdate",({delta:c,hasLayoutChanged:d,hasRelativeTargetChanged:h,layout:p})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}let m=this.options.transition||u.getDefaultTransition()||mL,{onLayoutAnimationStart:v,onLayoutAnimationComplete:b}=u.getProps(),f=!this.targetLayout||!Yk(this.targetLayout,p)||h,g=!d&&h;if(this.options.layoutRoot||this.resumeFrom&&this.resumeFrom.instance||g||d&&(f||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0),this.setAnimationOrigin(c,g);let y={...Df(m,"layout"),onPlay:v,onComplete:b};(u.shouldReduceMotion||this.options.layoutRoot)&&(y.delay=0,y.type=!1),this.startAnimation(y)}else d||Ay(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=p})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);let o=this.getStack();o&&o.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,mr(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(dL),this.animationId++)}getTransformTemplate(){let{visualElement:o}=this.options;return o&&o.getProps().transformTemplate}willUpdate(o=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&Kk(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let u=0;u<this.path.length;u++){let c=this.path[u];c.shouldResetTransform=!0,c.updateScroll("snapshot"),c.options.layoutRoot&&c.willUpdate(!1)}let{layoutId:a,layout:s}=this.options;if(a===void 0&&!s)return;let l=this.getTransformTemplate();this.prevTransformTemplateValue=l?l(this.latestValues,""):void 0,this.updateSnapshot(),o&&this.notifyListeners("willUpdate")}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){this.unblockUpdate(),this.clearAllSnapshots(),this.nodes.forEach(Py);return}this.isUpdating||this.nodes.forEach(sL),this.isUpdating=!1,this.nodes.forEach(lL),this.nodes.forEach(nL),this.nodes.forEach(rL),this.clearAllSnapshots();let o=fn.now();Ht.delta=gr(0,1e3/60,o-Ht.timestamp),Ht.timestamp=o,Ht.isProcessing=!0,Pc.update.process(Ht),Pc.preRender.process(Ht),Pc.render.process(Ht),Ht.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,Gf.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(aL),this.sharedNodes.forEach(hL)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,ct.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){ct.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure())}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let s=0;s<this.path.length;s++)this.path[s].updateScroll();let o=this.layout;this.layout=this.measure(!1),this.layoutCorrected=Rt(),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);let{visualElement:a}=this.options;a&&a.notify("LayoutMeasure",this.layout.layoutBox,o?o.layoutBox:void 0)}updateScroll(o="measure"){let a=!!(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===o&&(a=!1),a){let s=r(this.instance);this.scroll={animationId:this.root.animationId,phase:o,isRoot:s,offset:n(this.instance),wasRoot:this.scroll?this.scroll.isRoot:s}}}resetTransform(){if(!i)return;let o=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,a=this.projectionDelta&&!qk(this.projectionDelta),s=this.getTransformTemplate(),l=s?s(this.latestValues,""):void 0,u=l!==this.prevTransformTemplateValue;o&&(a||Ir(this.latestValues)||u)&&(i(this.instance,l),this.shouldResetTransform=!1,this.scheduleRender())}measure(o=!0){let a=this.measurePageBox(),s=this.removeElementScroll(a);return o&&(s=this.removeTransform(s)),gL(s),{animationId:this.root.animationId,measuredBox:a,layoutBox:s,latestValues:{},source:this.id}}measurePageBox(){var o;let{visualElement:a}=this.options;if(!a)return Rt();let s=a.measureViewportBox();if(!(!((o=this.scroll)===null||o===void 0)&&o.wasRoot||this.path.some(vL))){let{scroll:l}=this.root;l&&(Pi(s.x,l.offset.x),Pi(s.y,l.offset.y))}return s}removeElementScroll(o){var a;let s=Rt();if(Oe(s,o),!((a=this.scroll)===null||a===void 0)&&a.wasRoot)return s;for(let l=0;l<this.path.length;l++){let u=this.path[l],{scroll:c,options:d}=u;u!==this.root&&c&&d.layoutScroll&&(c.wasRoot&&Oe(s,o),Pi(s.x,c.offset.x),Pi(s.y,c.offset.y))}return s}applyTransform(o,a=!1){let s=Rt();Oe(s,o);for(let l=0;l<this.path.length;l++){let u=this.path[l];!a&&u.options.layoutScroll&&u.scroll&&u!==u.root&&Ai(s,{x:-u.scroll.offset.x,y:-u.scroll.offset.y}),Ir(u.latestValues)&&Ai(s,u.latestValues)}return Ir(this.latestValues)&&Ai(s,this.latestValues),s}removeTransform(o){let a=Rt();Oe(a,o);for(let s=0;s<this.path.length;s++){let l=this.path[s];if(!l.instance||!Ir(l.latestValues))continue;Mh(l.latestValues)&&l.updateSnapshot();let u=Rt(),c=l.measurePageBox();Oe(u,c),xy(a,l.latestValues,l.snapshot?l.snapshot.layoutBox:void 0,u)}return Ir(this.latestValues)&&xy(a,this.latestValues),a}setTargetDelta(o){this.targetDelta=o,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(o){this.options={...this.options,...o,crossfade:o.crossfade!==void 0?o.crossfade:!0}}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==Ht.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(o=!1){var a;let s=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=s.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=s.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=s.isSharedProjectionDirty);let l=!!this.resumingFrom||this!==s;if(!(o||l&&this.isSharedProjectionDirty||this.isProjectionDirty||!((a=this.parent)===null||a===void 0)&&a.isProjectionDirty||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;let{layout:u,layoutId:c}=this.options;if(!(!this.layout||!(u||c))){if(this.resolvedRelativeTargetAt=Ht.timestamp,!this.targetDelta&&!this.relativeTarget){let d=this.getClosestProjectingParent();d&&d.layout&&this.animationProgress!==1?(this.relativeParent=d,this.forceRelativeParentToResolveTarget(),this.relativeTarget=Rt(),this.relativeTargetOrigin=Rt(),Ko(this.relativeTargetOrigin,this.layout.layoutBox,d.layout.layoutBox),Oe(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}if(!(!this.relativeTarget&&!this.targetDelta)){if(this.target||(this.target=Rt(),this.targetWithTransforms=Rt()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),yI(this.target,this.relativeTarget,this.relativeParent.target)):this.targetDelta?(this.resumingFrom?this.target=this.applyTransform(this.layout.layoutBox):Oe(this.target,this.layout.layoutBox),Fk(this.target,this.targetDelta)):Oe(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget){this.attemptToResolveRelativeTarget=!1;let d=this.getClosestProjectingParent();d&&!!d.resumingFrom==!!this.resumingFrom&&!d.options.layoutScroll&&d.target&&this.animationProgress!==1?(this.relativeParent=d,this.forceRelativeParentToResolveTarget(),this.relativeTarget=Rt(),this.relativeTargetOrigin=Rt(),Ko(this.relativeTargetOrigin,this.target,d.target),Oe(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}jo&&Lr.resolvedTargetDeltas++}}}getClosestProjectingParent(){if(!(!this.parent||Mh(this.parent.latestValues)||Nk(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}calcProjection(){var o;let a=this.getLead(),s=!!this.resumingFrom||this!==a,l=!0;if((this.isProjectionDirty||!((o=this.parent)===null||o===void 0)&&o.isProjectionDirty)&&(l=!1),s&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(l=!1),this.resolvedRelativeTargetAt===Ht.timestamp&&(l=!1),l)return;let{layout:u,layoutId:c}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(u||c))return;Oe(this.layoutCorrected,this.layout.layoutBox);let d=this.treeScale.x,h=this.treeScale.y;PI(this.layoutCorrected,this.treeScale,this.path,s),a.layout&&!a.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(a.target=a.layout.layoutBox,a.targetWithTransforms=Rt());let{target:p}=a;if(!p){this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender());return}!this.projectionDelta||!this.prevProjectionDelta?this.createProjectionDeltas():(vy(this.prevProjectionDelta.x,this.projectionDelta.x),vy(this.prevProjectionDelta.y,this.projectionDelta.y)),Yo(this.projectionDelta,this.layoutCorrected,p,this.latestValues),(this.treeScale.x!==d||this.treeScale.y!==h||!Ey(this.projectionDelta.x,this.prevProjectionDelta.x)||!Ey(this.projectionDelta.y,this.prevProjectionDelta.y))&&(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",p)),jo&&Lr.recalculatedProjection++}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(o=!0){var a;if((a=this.options.visualElement)===null||a===void 0||a.scheduleRender(),o){let s=this.getStack();s&&s.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=Ci(),this.projectionDelta=Ci(),this.projectionDeltaWithTransform=Ci()}setAnimationOrigin(o,a=!1){let s=this.snapshot,l=s?s.latestValues:{},u={...this.latestValues},c=Ci();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!a;let d=Rt(),h=s?s.source:void 0,p=this.layout?this.layout.source:void 0,m=h!==p,v=this.getStack(),b=!v||v.members.length<=1,f=!!(m&&!b&&this.options.crossfade===!0&&!this.path.some(fL));this.animationProgress=0;let g;this.mixTargetDelta=y=>{let w=y/1e3;My(c.x,o.x,w),My(c.y,o.y,w),this.setTargetDelta(c),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(Ko(d,this.layout.layoutBox,this.relativeParent.layout.layoutBox),pL(this.relativeTarget,this.relativeTargetOrigin,d,w),g&&qI(this.relativeTarget,g)&&(this.isProjectionDirty=!1),g||(g=Rt()),Oe(g,this.relativeTarget)),m&&(this.animationValues=u,zI(u,l,this.latestValues,w,f,b)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=w},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(o){this.notifyListeners("animationStart"),this.currentAnimation&&this.currentAnimation.stop(),this.resumingFrom&&this.resumingFrom.currentAnimation&&this.resumingFrom.currentAnimation.stop(),this.pendingAnimation&&(mr(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=ct.update(()=>{nl.hasAnimatedSinceResize=!0,this.currentAnimation=ZI(0,Cy,{...o,onUpdate:a=>{this.mixTargetDelta(a),o.onUpdate&&o.onUpdate(a)},onComplete:()=>{o.onComplete&&o.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);let o=this.getStack();o&&o.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(Cy),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){let o=this.getLead(),{targetWithTransforms:a,target:s,layout:l,latestValues:u}=o;if(!(!a||!s||!l)){if(this!==o&&this.layout&&l&&Gk(this.options.animationType,this.layout.layoutBox,l.layoutBox)){s=this.target||Rt();let c=Me(this.layout.layoutBox.x);s.x.min=o.target.x.min,s.x.max=s.x.min+c;let d=Me(this.layout.layoutBox.y);s.y.min=o.target.y.min,s.y.max=s.y.min+d}Oe(a,s),Ai(a,u),Yo(this.projectionDeltaWithTransform,this.layoutCorrected,a,u)}}registerSharedNode(o,a){this.sharedNodes.has(o)||this.sharedNodes.set(o,new YI),this.sharedNodes.get(o).add(a);let s=a.options.initialPromotionConfig;a.promote({transition:s?s.transition:void 0,preserveFollowOpacity:s&&s.shouldPreserveFollowOpacity?s.shouldPreserveFollowOpacity(a):void 0})}isLead(){let o=this.getStack();return o?o.lead===this:!0}getLead(){var o;let{layoutId:a}=this.options;return a?((o=this.getStack())===null||o===void 0?void 0:o.lead)||this:this}getPrevLead(){var o;let{layoutId:a}=this.options;return a?(o=this.getStack())===null||o===void 0?void 0:o.prevLead:void 0}getStack(){let{layoutId:o}=this.options;if(o)return this.root.sharedNodes.get(o)}promote({needsReset:o,transition:a,preserveFollowOpacity:s}={}){let l=this.getStack();l&&l.promote(this,s),o&&(this.projectionDelta=void 0,this.needsReset=!0),a&&this.setOptions({transition:a})}relegate(){let o=this.getStack();return o?o.relegate(this):!1}resetSkewAndRotation(){let{visualElement:o}=this.options;if(!o)return;let a=!1,{latestValues:s}=o;if((s.z||s.rotate||s.rotateX||s.rotateY||s.rotateZ||s.skewX||s.skewY)&&(a=!0),!a)return;let l={};s.z&&_c("z",o,l,this.animationValues);for(let u=0;u<Oc.length;u++)_c(`rotate${Oc[u]}`,o,l,this.animationValues),_c(`skew${Oc[u]}`,o,l,this.animationValues);o.render();for(let u in l)o.setStaticValue(u,l[u]),this.animationValues&&(this.animationValues[u]=l[u]);o.scheduleRender()}getProjectionStyles(o){var a,s;if(!this.instance||this.isSVG)return;if(!this.isVisible)return tL;let l={visibility:""},u=this.getTransformTemplate();if(this.needsReset)return this.needsReset=!1,l.opacity="",l.pointerEvents=rl(o?.pointerEvents)||"",l.transform=u?u(this.latestValues,""):"none",l;let c=this.getLead();if(!this.projectionDelta||!this.layout||!c.target){let m={};return this.options.layoutId&&(m.opacity=this.latestValues.opacity!==void 0?this.latestValues.opacity:1,m.pointerEvents=rl(o?.pointerEvents)||""),this.hasProjected&&!Ir(this.latestValues)&&(m.transform=u?u({},""):"none",this.hasProjected=!1),m}let d=c.animationValues||c.latestValues;this.applyTransformsToTarget(),l.transform=KI(this.projectionDeltaWithTransform,this.treeScale,d),u&&(l.transform=u(d,l.transform));let{x:h,y:p}=this.projectionDelta;l.transformOrigin=`${h.origin*100}% ${p.origin*100}% 0`,c.animationValues?l.opacity=c===this?(s=(a=d.opacity)!==null&&a!==void 0?a:this.latestValues.opacity)!==null&&s!==void 0?s:1:this.preserveOpacity?this.latestValues.opacity:d.opacityExit:l.opacity=c===this?d.opacity!==void 0?d.opacity:"":d.opacityExit!==void 0?d.opacityExit:0;for(let m in Hl){if(d[m]===void 0)continue;let{correct:v,applyTo:b}=Hl[m],f=l.transform==="none"?d[m]:v(d[m],c);if(b){let g=b.length;for(let y=0;y<g;y++)l[b[y]]=f}else l[m]=f}return this.options.layoutId&&(l.pointerEvents=c===this?rl(o?.pointerEvents)||"":"none"),l}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(o=>{var a;return(a=o.currentAnimation)===null||a===void 0?void 0:a.stop()}),this.root.nodes.forEach(Py),this.root.sharedNodes.clear()}}}function nL(t){t.updateLayout()}function rL(t){var e;let n=((e=t.resumeFrom)===null||e===void 0?void 0:e.snapshot)||t.snapshot;if(t.isLead()&&t.layout&&n&&t.hasListeners("didUpdate")){let{layoutBox:r,measuredBox:i}=t.layout,{animationType:o}=t.options,a=n.source!==t.layout.source;o==="size"?Ne(d=>{let h=a?n.measuredBox[d]:n.layoutBox[d],p=Me(h);h.min=r[d].min,h.max=h.min+p}):Gk(o,n.layoutBox,r)&&Ne(d=>{let h=a?n.measuredBox[d]:n.layoutBox[d],p=Me(r[d]);h.max=h.min+p,t.relativeTarget&&!t.currentAnimation&&(t.isProjectionDirty=!0,t.relativeTarget[d].max=t.relativeTarget[d].min+p)});let s=Ci();Yo(s,r,n.layoutBox);let l=Ci();a?Yo(l,t.applyTransform(i,!0),n.measuredBox):Yo(l,r,n.layoutBox);let u=!qk(s),c=!1;if(!t.resumeFrom){let d=t.getClosestProjectingParent();if(d&&!d.resumeFrom){let{snapshot:h,layout:p}=d;if(h&&p){let m=Rt();Ko(m,n.layoutBox,h.layoutBox);let v=Rt();Ko(v,r,p.layoutBox),Yk(m,v)||(c=!0),d.options.layoutRoot&&(t.relativeTarget=v,t.relativeTargetOrigin=m,t.relativeParent=d)}}}t.notifyListeners("didUpdate",{layout:r,snapshot:n,delta:l,layoutDelta:s,hasLayoutChanged:u,hasRelativeTargetChanged:c})}else if(t.isLead()){let{onExitComplete:r}=t.options;r&&r()}t.options.transition=void 0}function iL(t){jo&&Lr.totalNodes++,t.parent&&(t.isProjecting()||(t.isProjectionDirty=t.parent.isProjectionDirty),t.isSharedProjectionDirty||(t.isSharedProjectionDirty=!!(t.isProjectionDirty||t.parent.isProjectionDirty||t.parent.isSharedProjectionDirty)),t.isTransformDirty||(t.isTransformDirty=t.parent.isTransformDirty))}function oL(t){t.isProjectionDirty=t.isSharedProjectionDirty=t.isTransformDirty=!1}function aL(t){t.clearSnapshot()}function Py(t){t.clearMeasurements()}function sL(t){t.isLayoutDirty=!1}function lL(t){let{visualElement:e}=t.options;e&&e.getProps().onBeforeLayoutMeasure&&e.notify("BeforeLayoutMeasure"),t.resetTransform()}function Ay(t){t.finishAnimation(),t.targetDelta=t.relativeTarget=t.target=void 0,t.isProjectionDirty=!0}function uL(t){t.resolveTargetDelta()}function cL(t){t.calcProjection()}function dL(t){t.resetSkewAndRotation()}function hL(t){t.removeLeadSnapshot()}function My(t,e,n){t.translate=Et(e.translate,0,n),t.scale=Et(e.scale,1,n),t.origin=e.origin,t.originPoint=e.originPoint}function Dy(t,e,n,r){t.min=Et(e.min,n.min,r),t.max=Et(e.max,n.max,r)}function pL(t,e,n,r){Dy(t.x,e.x,n.x,r),Dy(t.y,e.y,n.y,r)}function fL(t){return t.animationValues&&t.animationValues.opacityExit!==void 0}var mL={duration:.45,ease:[.4,0,.1,1]},Ry=t=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(t),Iy=Ry("applewebkit/")&&!Ry("chrome/")?Math.round:re;function Ly(t){t.min=Iy(t.min),t.max=Iy(t.max)}function gL(t){Ly(t.x),Ly(t.y)}function Gk(t,e,n){return t==="position"||t==="preserve-aspect"&&!vI(Ty(e),Ty(n),.2)}function vL(t){var e;return t!==t.root&&((e=t.scroll)===null||e===void 0?void 0:e.wasRoot)}var yL=Xk({attachResizeListener:(t,e)=>An(t,"resize",e),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),Nc={current:void 0},Qk=Xk({measureScroll:t=>({x:t.scrollLeft,y:t.scrollTop}),defaultParent:()=>{if(!Nc.current){let t=new yL({});t.mount(window),t.setOptions({layoutScroll:!0}),Nc.current=t}return Nc.current},resetTransform:(t,e)=>{t.style.transform=e!==void 0?e:"none"},checkIsScrollRoot:t=>window.getComputedStyle(t).position==="fixed"}),bL={pan:{Feature:LI},drag:{Feature:II,ProjectionNode:Qk,MeasureLayout:$k}};function jy(t,e){let n=e?"pointerenter":"pointerleave",r=e?"onHoverStart":"onHoverEnd",i=(o,a)=>{if(o.pointerType==="touch"||Lk())return;let s=t.getProps();t.animationState&&s.whileHover&&t.animationState.setActive("whileHover",e);let l=s[r];l&&ct.postRender(()=>l(o,a))};return jn(t.current,n,i,{passive:!t.getProps()[r]})}var xL=class extends Er{mount(){this.unmount=Ln(jy(this.node,!0),jy(this.node,!1))}unmount(){}},wL=class extends Er{constructor(){super(...arguments),this.isActive=!1}onFocus(){let t=!1;try{t=this.node.current.matches(":focus-visible")}catch{t=!0}!t||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){!this.isActive||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=Ln(An(this.node.current,"focus",()=>this.onFocus()),An(this.node.current,"blur",()=>this.onBlur()))}unmount(){}},Jk=(t,e)=>e?t===e?!0:Jk(t,e.parentElement):!1;function Fc(t,e){if(!e)return;let n=new PointerEvent("pointer"+t);e(n,ju(n))}var kL=class extends Er{constructor(){super(...arguments),this.removeStartListeners=re,this.removeEndListeners=re,this.removeAccessibleListeners=re,this.startPointerPress=(t,e)=>{if(this.isPressing)return;this.removeEndListeners();let n=this.node.getProps(),r=jn(window,"pointerup",(o,a)=>{if(!this.checkPressEnd())return;let{onTap:s,onTapCancel:l,globalTapTarget:u}=this.node.getProps(),c=!u&&!Jk(this.node.current,o.target)?l:s;c&&ct.update(()=>c(o,a))},{passive:!(n.onTap||n.onPointerUp)}),i=jn(window,"pointercancel",(o,a)=>this.cancelPress(o,a),{passive:!(n.onTapCancel||n.onPointerCancel)});this.removeEndListeners=Ln(r,i),this.startPress(t,e)},this.startAccessiblePress=()=>{let t=i=>{if(i.key!=="Enter"||this.isPressing)return;let o=a=>{a.key!=="Enter"||!this.checkPressEnd()||Fc("up",(s,l)=>{let{onTap:u}=this.node.getProps();u&&ct.postRender(()=>u(s,l))})};this.removeEndListeners(),this.removeEndListeners=An(this.node.current,"keyup",o),Fc("down",(a,s)=>{this.startPress(a,s)})},e=An(this.node.current,"keydown",t),n=()=>{this.isPressing&&Fc("cancel",(i,o)=>this.cancelPress(i,o))},r=An(this.node.current,"blur",n);this.removeAccessibleListeners=Ln(e,r)}}startPress(t,e){this.isPressing=!0;let{onTapStart:n,whileTap:r}=this.node.getProps();r&&this.node.animationState&&this.node.animationState.setActive("whileTap",!0),n&&ct.postRender(()=>n(t,e))}checkPressEnd(){return this.removeEndListeners(),this.isPressing=!1,this.node.getProps().whileTap&&this.node.animationState&&this.node.animationState.setActive("whileTap",!1),!Lk()}cancelPress(t,e){if(!this.checkPressEnd())return;let{onTapCancel:n}=this.node.getProps();n&&ct.postRender(()=>n(t,e))}mount(){let t=this.node.getProps(),e=jn(t.globalTapTarget?window:this.node.current,"pointerdown",this.startPointerPress,{passive:!(t.onTapStart||t.onPointerStart)}),n=An(this.node.current,"focus",this.startAccessiblePress);this.removeStartListeners=Ln(e,n)}unmount(){this.removeStartListeners(),this.removeEndListeners(),this.removeAccessibleListeners()}},Rh=new WeakMap,Vc=new WeakMap,SL=t=>{let e=Rh.get(t.target);e&&e(t)},TL=t=>{t.forEach(SL)};function EL({root:t,...e}){let n=t||document;Vc.has(n)||Vc.set(n,{});let r=Vc.get(n),i=JSON.stringify(e);return r[i]||(r[i]=new IntersectionObserver(TL,{root:t,...e})),r[i]}function CL(t,e,n){let r=EL(e);return Rh.set(t,n),r.observe(t),()=>{Rh.delete(t),r.unobserve(t)}}var PL={some:0,all:1},AL=class extends Er{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();let{viewport:t={}}=this.node.getProps(),{root:e,margin:n,amount:r="some",once:i}=t,o={root:e?e.current:void 0,rootMargin:n,threshold:typeof r=="number"?r:PL[r]},a=s=>{let{isIntersecting:l}=s;if(this.isInView===l||(this.isInView=l,i&&!l&&this.hasEnteredView))return;l&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",l);let{onViewportEnter:u,onViewportLeave:c}=this.node.getProps(),d=l?u:c;d&&d(s)};return CL(this.node.current,o,a)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;let{props:t,prevProps:e}=this.node;["amount","margin","root"].some(ML(t,e))&&this.startObserver()}unmount(){}};function ML({viewport:t={}},{viewport:e={}}={}){return n=>t[n]!==e[n]}var DL={inView:{Feature:AL},tap:{Feature:kL},focus:{Feature:wL},hover:{Feature:xL}},RL={layout:{ProjectionNode:Qk,MeasureLayout:$k}},Zk=S.createContext({transformPagePoint:t=>t,isStatic:!1,reducedMotion:"never"}),Ou=S.createContext({}),Qf=typeof window<"u",IL=Qf?S.useLayoutEffect:S.useEffect,tS=S.createContext({strict:!1});function LL(t,e,n,r,i){var o,a;let{visualElement:s}=S.useContext(Ou),l=S.useContext(tS),u=S.useContext(Xf),c=S.useContext(Zk).reducedMotion,d=S.useRef();r=r||l.renderer,!d.current&&r&&(d.current=r(t,{visualState:e,parent:s,props:n,presenceContext:u,blockInitialAnimation:u?u.initial===!1:!1,reducedMotionConfig:c}));let h=d.current,p=S.useContext(Uk);h&&!h.projection&&i&&(h.type==="html"||h.type==="svg")&&jL(d.current,n,i,p);let m=S.useRef(!1);S.useInsertionEffect(()=>{h&&m.current&&h.update(n,u)});let v=n[Tk],b=S.useRef(!!v&&!(!((o=window.MotionHandoffIsComplete)===null||o===void 0)&&o.call(window,v))&&((a=window.MotionHasOptimisedAnimation)===null||a===void 0?void 0:a.call(window,v)));return IL(()=>{h&&(m.current=!0,window.MotionIsMounted=!0,h.updateFeatures(),Gf.render(h.render),b.current&&h.animationState&&h.animationState.animateChanges())}),S.useEffect(()=>{h&&(!b.current&&h.animationState&&h.animationState.animateChanges(),b.current&&(queueMicrotask(()=>{var f;(f=window.MotionHandoffMarkAsComplete)===null||f===void 0||f.call(window,v)}),b.current=!1))}),h}function jL(t,e,n,r){let{layoutId:i,layout:o,drag:a,dragConstraints:s,layoutScroll:l,layoutRoot:u}=e;t.projection=new n(t.latestValues,e["data-framer-portal-id"]?void 0:eS(t.parent)),t.projection.setOptions({layoutId:i,layout:o,alwaysMeasureLayout:!!a||s&&Ei(s),visualElement:t,animationType:typeof o=="string"?o:"both",initialPromotionConfig:r,layoutScroll:l,layoutRoot:u})}function eS(t){if(t)return t.options.allowProjection!==!1?t.projection:eS(t.parent)}function OL(t,e,n){return S.useCallback(r=>{r&&t.mount&&t.mount(r),e&&(r?e.mount(r):e.unmount()),n&&(typeof n=="function"?n(r):Ei(n)&&(n.current=r))},[e])}function _u(t){return Ru(t.animate)||Mf.some(e=>Ma(t[e]))}function nS(t){return!!(_u(t)||t.variants)}function _L(t,e){if(_u(t)){let{initial:n,animate:r}=t;return{initial:n===!1||Ma(n)?n:void 0,animate:Ma(r)?r:void 0}}return t.inherit!==!1?e:{}}function NL(t){let{initial:e,animate:n}=_L(t,S.useContext(Ou));return S.useMemo(()=>({initial:e,animate:n}),[Oy(e),Oy(n)])}function Oy(t){return Array.isArray(t)?t.join(" "):t}var _y={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]},Ji={};for(let t in _y)Ji[t]={isEnabled:e=>_y[t].some(n=>!!e[n])};function FL(t){for(let e in t)Ji[e]={...Ji[e],...t[e]}}var VL=Symbol.for("motionComponentSymbol");function zL({preloadedFeatures:t,createVisualElement:e,useRender:n,useVisualState:r,Component:i}){t&&FL(t);function o(s,l){let u,c={...S.useContext(Zk),...s,layoutId:BL(s)},{isStatic:d}=c,h=NL(s),p=r(s,d);if(!d&&Qf){UL();let m=$L(c);u=m.MeasureLayout,h.visualElement=LL(i,p,c,e,m.ProjectionNode)}return A.jsxs(Ou.Provider,{value:h,children:[u&&h.visualElement?A.jsx(u,{visualElement:h.visualElement,...c}):null,n(i,s,OL(p,h.visualElement,l),p,d,h.visualElement)]})}let a=S.forwardRef(o);return a[VL]=i,a}function BL({layoutId:t}){let e=S.useContext(Bk).id;return e&&t!==void 0?e+"-"+t:t}function UL(t,e){S.useContext(tS).strict}function $L(t){let{drag:e,layout:n}=Ji;if(!e&&!n)return{};let r={...e,...n};return{MeasureLayout:e!=null&&e.isEnabled(t)||n!=null&&n.isEnabled(t)?r.MeasureLayout:void 0,ProjectionNode:r.ProjectionNode}}var HL=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function Jf(t){return typeof t!="string"||t.includes("-")?!1:!!(HL.indexOf(t)>-1||/[A-Z]/u.test(t))}function rS(t,{style:e,vars:n},r,i){Object.assign(t.style,e,i&&i.getProjectionStyles(r));for(let o in n)t.style.setProperty(o,n[o])}var iS=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]);function oS(t,e,n,r){rS(t,e,void 0,r);for(let i in e.attrs)t.setAttribute(iS.has(i)?i:Kf(i),e.attrs[i])}function aS(t,{layout:e,layoutId:n}){return ri.has(t)||t.startsWith("origin")||(e||n!==void 0)&&(!!Hl[t]||t==="opacity")}function Zf(t,e,n){var r;let{style:i}=t,o={};for(let a in i)(te(i[a])||e.style&&te(e.style[a])||aS(a,t)||((r=n?.getValue(a))===null||r===void 0?void 0:r.liveStyle)!==void 0)&&(o[a]=i[a]);return o}function sS(t,e,n){let r=Zf(t,e,n);for(let i in t)if(te(t[i])||te(e[i])){let o=Xa.indexOf(i)!==-1?"attr"+i.charAt(0).toUpperCase()+i.substring(1):i;r[o]=t[i]}return r}function WL(t){let e=S.useRef(null);return e.current===null&&(e.current=t()),e.current}function qL({scrapeMotionValuesFromProps:t,createRenderState:e,onMount:n},r,i,o){let a={latestValues:YL(r,i,o,t),renderState:e()};return n&&(a.mount=s=>n(r,s,a)),a}var lS=t=>(e,n)=>{let r=S.useContext(Ou),i=S.useContext(Xf),o=()=>qL(t,e,r,i);return n?o():WL(o)};function YL(t,e,n,r){let i={},o=r(t,{});for(let h in o)i[h]=rl(o[h]);let{initial:a,animate:s}=t,l=_u(t),u=nS(t);e&&u&&!l&&t.inherit!==!1&&(a===void 0&&(a=e.initial),s===void 0&&(s=e.animate));let c=n?n.initial===!1:!1;c=c||a===!1;let d=c?s:a;if(d&&typeof d!="boolean"&&!Ru(d)){let h=Array.isArray(d)?d:[d];for(let p=0;p<h.length;p++){let m=Pf(t,h[p]);if(m){let{transitionEnd:v,transition:b,...f}=m;for(let g in f){let y=f[g];if(Array.isArray(y)){let w=c?y.length-1:0;y=y[w]}y!==null&&(i[g]=y)}for(let g in v)i[g]=v[g]}}}return i}var tm=()=>({style:{},transform:{},transformOrigin:{},vars:{}}),uS=()=>({...tm(),attrs:{}}),cS=(t,e)=>e&&typeof t=="number"?e.transform(t):t,KL={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},XL=Xa.length;function GL(t,e,n){let r="",i=!0;for(let o=0;o<XL;o++){let a=Xa[o],s=t[a];if(s===void 0)continue;let l=!0;if(typeof s=="number"?l=s===(a.startsWith("scale")?1:0):l=parseFloat(s)===0,!l||n){let u=cS(s,Nf[a]);if(!l){i=!1;let c=KL[a]||a;r+=`${c}(${u}) `}n&&(e[a]=u)}}return r=r.trim(),n?r=n(e,i?"":r):i&&(r="none"),r}function em(t,e,n){let{style:r,vars:i,transformOrigin:o}=t,a=!1,s=!1;for(let l in e){let u=e[l];if(ri.has(l)){a=!0;continue}else if(ek(l)){i[l]=u;continue}else{let c=cS(u,Nf[l]);l.startsWith("origin")?(s=!0,o[l]=c):r[l]=c}}if(e.transform||(a||n?r.transform=GL(e,t.transform,n):r.transform&&(r.transform="none")),s){let{originX:l="50%",originY:u="50%",originZ:c=0}=o;r.transformOrigin=`${l} ${u} ${c}`}}function Ny(t,e,n){return typeof t=="string"?t:W.transform(e+n*t)}function QL(t,e,n){let r=Ny(e,t.x,t.width),i=Ny(n,t.y,t.height);return`${r} ${i}`}var JL={offset:"stroke-dashoffset",array:"stroke-dasharray"},ZL={offset:"strokeDashoffset",array:"strokeDasharray"};function t3(t,e,n=1,r=0,i=!0){t.pathLength=1;let o=i?JL:ZL;t[o.offset]=W.transform(-r);let a=W.transform(e),s=W.transform(n);t[o.array]=`${a} ${s}`}function nm(t,{attrX:e,attrY:n,attrScale:r,originX:i,originY:o,pathLength:a,pathSpacing:s=1,pathOffset:l=0,...u},c,d){if(em(t,u,d),c){t.style.viewBox&&(t.attrs.viewBox=t.style.viewBox);return}t.attrs=t.style,t.style={};let{attrs:h,style:p,dimensions:m}=t;h.transform&&(m&&(p.transform=h.transform),delete h.transform),m&&(i!==void 0||o!==void 0||p.transform)&&(p.transformOrigin=QL(m,i!==void 0?i:.5,o!==void 0?o:.5)),e!==void 0&&(h.x=e),n!==void 0&&(h.y=n),r!==void 0&&(h.scale=r),a!==void 0&&t3(h,a,s,l,!1)}var rm=t=>typeof t=="string"&&t.toLowerCase()==="svg",e3={useVisualState:lS({scrapeMotionValuesFromProps:sS,createRenderState:uS,onMount:(t,e,{renderState:n,latestValues:r})=>{ct.read(()=>{try{n.dimensions=typeof e.getBBox=="function"?e.getBBox():e.getBoundingClientRect()}catch{n.dimensions={x:0,y:0,width:0,height:0}}}),ct.render(()=>{nm(n,r,rm(e.tagName),t.transformTemplate),oS(e,n)})}})},n3={useVisualState:lS({scrapeMotionValuesFromProps:Zf,createRenderState:tm})};function dS(t,e,n){for(let r in e)!te(e[r])&&!aS(r,n)&&(t[r]=e[r])}function r3({transformTemplate:t},e){return S.useMemo(()=>{let n=tm();return em(n,e,t),Object.assign({},n.vars,n.style)},[e])}function i3(t,e){let n=t.style||{},r={};return dS(r,n,t),Object.assign(r,r3(t,e)),r}function o3(t,e){let n={},r=i3(t,e);return t.drag&&t.dragListener!==!1&&(n.draggable=!1,r.userSelect=r.WebkitUserSelect=r.WebkitTouchCallout="none",r.touchAction=t.drag===!0?"none":`pan-${t.drag==="x"?"y":"x"}`),t.tabIndex===void 0&&(t.onTap||t.onTapStart||t.whileTap)&&(n.tabIndex=0),n.style=r,n}var a3=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function Wl(t){return t.startsWith("while")||t.startsWith("drag")&&t!=="draggable"||t.startsWith("layout")||t.startsWith("onTap")||t.startsWith("onPan")||t.startsWith("onLayout")||a3.has(t)}var hS=t=>!Wl(t);function s3(t){t&&(hS=e=>e.startsWith("on")?!Wl(e):t(e))}try{s3(Qm("@emotion/is-prop-valid").default)}catch{}function l3(t,e,n){let r={};for(let i in t)i==="values"&&typeof t.values=="object"||(hS(i)||n===!0&&Wl(i)||!e&&!Wl(i)||t.draggable&&i.startsWith("onDrag"))&&(r[i]=t[i]);return r}function u3(t,e,n,r){let i=S.useMemo(()=>{let o=uS();return nm(o,e,rm(r),t.transformTemplate),{...o.attrs,style:{...o.style}}},[e]);if(t.style){let o={};dS(o,t.style,t),i.style={...o,...i.style}}return i}function c3(t=!1){return(e,n,r,{latestValues:i},o)=>{let a=(Jf(e)?u3:o3)(n,i,o,e),s=l3(n,typeof e=="string",t),l=e!==S.Fragment?{...s,...a,ref:r}:{},{children:u}=n,c=S.useMemo(()=>te(u)?u.get():u,[u]);return S.createElement(e,{...l,children:c})}}function d3(t,e){return function(n,{forwardMotionProps:r}={forwardMotionProps:!1}){let i={...Jf(n)?e3:n3,preloadedFeatures:t,useRender:c3(r),createVisualElement:e,Component:n};return zL(i)}}var Ih={current:null},pS={current:!1};function h3(){if(pS.current=!0,!!Qf)if(window.matchMedia){let t=window.matchMedia("(prefers-reduced-motion)"),e=()=>Ih.current=t.matches;t.addListener(e),e()}else Ih.current=!1}function p3(t,e,n){for(let r in e){let i=e[r],o=n[r];if(te(i))t.addValue(r,i);else if(te(o))t.addValue(r,Ia(i,{owner:t}));else if(o!==i)if(t.hasValue(r)){let a=t.getValue(r);a.liveStyle===!0?a.jump(i):a.hasAnimated||a.set(i)}else{let a=t.getStaticValue(r);t.addValue(r,Ia(a!==void 0?a:i,{owner:t}))}}for(let r in n)e[r]===void 0&&t.removeValue(r);return e}var Fy=new WeakMap,f3=[...ik,Qt,vr],m3=t=>f3.find(rk(t)),Vy=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"],g3=class{scrapeMotionValuesFromProps(t,e,n){return{}}constructor({parent:t,props:e,presenceContext:n,reducedMotionConfig:r,blockInitialAnimation:i,visualState:o},a={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=jf,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{let d=fn.now();this.renderScheduledAt<d&&(this.renderScheduledAt=d,ct.render(this.render,!1,!0))};let{latestValues:s,renderState:l}=o;this.latestValues=s,this.baseTarget={...s},this.initialValues=e.initial?{...s}:{},this.renderState=l,this.parent=t,this.props=e,this.presenceContext=n,this.depth=t?t.depth+1:0,this.reducedMotionConfig=r,this.options=a,this.blockInitialAnimation=!!i,this.isControllingVariants=_u(e),this.isVariantNode=nS(e),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(t&&t.current);let{willChange:u,...c}=this.scrapeMotionValuesFromProps(e,{},this);for(let d in c){let h=c[d];s[d]!==void 0&&te(h)&&h.set(s[d],!1)}}mount(t){this.current=t,Fy.set(t,this),this.projection&&!this.projection.instance&&this.projection.mount(t),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((e,n)=>this.bindToMotionValue(n,e)),pS.current||h3(),this.shouldReduceMotion=this.reducedMotionConfig==="never"?!1:this.reducedMotionConfig==="always"?!0:Ih.current,this.parent&&this.parent.children.add(this),this.update(this.props,this.presenceContext)}unmount(){Fy.delete(this.current),this.projection&&this.projection.unmount(),mr(this.notifyUpdate),mr(this.render),this.valueSubscriptions.forEach(t=>t()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent&&this.parent.children.delete(this);for(let t in this.events)this.events[t].clear();for(let t in this.features){let e=this.features[t];e&&(e.unmount(),e.isMounted=!1)}this.current=null}bindToMotionValue(t,e){this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)();let n=ri.has(t),r=e.on("change",a=>{this.latestValues[t]=a,this.props.onUpdate&&ct.preRender(this.notifyUpdate),n&&this.projection&&(this.projection.isTransformDirty=!0)}),i=e.on("renderRequest",this.scheduleRender),o;window.MotionCheckAppearSync&&(o=window.MotionCheckAppearSync(this,t,e)),this.valueSubscriptions.set(t,()=>{r(),i(),o&&o(),e.owner&&e.stop()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}updateFeatures(){let t="animation";for(t in Ji){let e=Ji[t];if(!e)continue;let{isEnabled:n,Feature:r}=e;if(!this.features[t]&&r&&n(this.props)&&(this.features[t]=new r(this)),this.features[t]){let i=this.features[t];i.isMounted?i.update():(i.mount(),i.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):Rt()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,e){this.latestValues[t]=e}update(t,e){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=e;for(let n=0;n<Vy.length;n++){let r=Vy[n];this.propEventSubscriptions[r]&&(this.propEventSubscriptions[r](),delete this.propEventSubscriptions[r]);let i="on"+r,o=t[i];o&&(this.propEventSubscriptions[r]=this.on(r,o))}this.prevMotionValues=p3(this,this.scrapeMotionValuesFromProps(t,this.prevProps,this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(t){return this.props.variants?this.props.variants[t]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}addVariantChild(t){let e=this.getClosestVariantNode();if(e)return e.variantChildren&&e.variantChildren.add(t),()=>e.variantChildren.delete(t)}addValue(t,e){let n=this.values.get(t);e!==n&&(n&&this.removeValue(t),this.bindToMotionValue(t,e),this.values.set(t,e),this.latestValues[t]=e.get())}removeValue(t){this.values.delete(t);let e=this.valueSubscriptions.get(t);e&&(e(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,e){if(this.props.values&&this.props.values[t])return this.props.values[t];let n=this.values.get(t);return n===void 0&&e!==void 0&&(n=Ia(e===null?void 0:e,{owner:this}),this.addValue(t,n)),n}readValue(t,e){var n;let r=this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:(n=this.getBaseTargetFromProps(this.props,t))!==null&&n!==void 0?n:this.readValueFromInstance(this.current,t,this.options);return r!=null&&(typeof r=="string"&&(Zw(r)||Jw(r))?r=parseFloat(r):!m3(r)&&vr.test(e)&&(r=hk(t,e)),this.setBaseTarget(t,te(r)?r.get():r)),te(r)?r.get():r}setBaseTarget(t,e){this.baseTarget[t]=e}getBaseTarget(t){var e;let{initial:n}=this.props,r;if(typeof n=="string"||typeof n=="object"){let o=Pf(this.props,n,(e=this.presenceContext)===null||e===void 0?void 0:e.custom);o&&(r=o[t])}if(n&&r!==void 0)return r;let i=this.getBaseTargetFromProps(this.props,t);return i!==void 0&&!te(i)?i:this.initialValues[t]!==void 0&&r===void 0?void 0:this.baseTarget[t]}on(t,e){return this.events[t]||(this.events[t]=new Yf),this.events[t].add(e)}notify(t,...e){this.events[t]&&this.events[t].notify(...e)}},fS=class extends g3{constructor(){super(...arguments),this.KeyframeResolver=pk}sortInstanceNodePosition(t,e){return t.compareDocumentPosition(e)&2?1:-1}getBaseTargetFromProps(t,e){return t.style?t.style[e]:void 0}removeValueFromRenderState(t,{vars:e,style:n}){delete e[t],delete n[t]}};function v3(t){return window.getComputedStyle(t)}var y3=class extends fS{constructor(){super(...arguments),this.type="html",this.renderInstance=rS}readValueFromInstance(t,e){if(ri.has(e)){let n=Ff(e);return n&&n.default||0}else{let n=v3(t),r=(ek(e)?n.getPropertyValue(e):n[e])||0;return typeof r=="string"?r.trim():r}}measureInstanceViewportBox(t,{transformPagePoint:e}){return Vk(t,e)}build(t,e,n){em(t,e,n.transformTemplate)}scrapeMotionValuesFromProps(t,e,n){return Zf(t,e,n)}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);let{children:t}=this.props;te(t)&&(this.childSubscription=t.on("change",e=>{this.current&&(this.current.textContent=`${e}`)}))}},b3=class extends fS{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=Rt}getBaseTargetFromProps(t,e){return t[e]}readValueFromInstance(t,e){if(ri.has(e)){let n=Ff(e);return n&&n.default||0}return e=iS.has(e)?e:Kf(e),t.getAttribute(e)}scrapeMotionValuesFromProps(t,e,n){return sS(t,e,n)}build(t,e,n){nm(t,e,this.isSVGTag,n.transformTemplate)}renderInstance(t,e,n,r){oS(t,e,n,r)}mount(t){this.isSVGTag=rm(t.tagName),super.mount(t)}},x3=(t,e)=>Jf(t)?new b3(e):new y3(e,{allowProjection:t!==S.Fragment}),w3=d3({...lI,...DL,...bL,...RL},x3),mS=ZM(w3),k3=1;function S3({children:t}){let{opened:e}=Le(),{toasts:n}=Vw();return S.useEffect(()=>{n.filter(r=>r.visible).filter((r,i)=>i>=k3).forEach(r=>Ef.dismiss(r.id))},[n]),A.jsx(mS.div,{initial:{y:"10%",opacity:0},animate:{y:e?0:"10%",opacity:e?1:0},exit:{y:"10%",opacity:0},transition:{duration:.3,ease:"easeInOut"},className:`leoai-window ${e?"open":""}`,children:A.jsxs("div",{className:"leoai-window-border",children:[A.jsx(YM,{containerStyle:{position:"absolute",top:"8px",left:"50%",transform:"translateX(-50%)",width:"100%"},toastOptions:{className:"leoai-hot-toast"}}),t]})})}var T3=t=>t.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),gS=(...t)=>t.filter((e,n,r)=>!!e&&e.trim()!==""&&r.indexOf(e)===n).join(" ").trim();var E3={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};var C3=S.forwardRef(({color:t="currentColor",size:e=24,strokeWidth:n=2,absoluteStrokeWidth:r,className:i="",children:o,iconNode:a,...s},l)=>S.createElement("svg",{ref:l,...E3,width:e,height:e,stroke:t,strokeWidth:r?Number(n)*24/Number(e):n,className:gS("lucide",i),...s},[...a.map(([u,c])=>S.createElement(u,c)),...Array.isArray(o)?o:[o]]));var lo=(t,e)=>{let n=S.forwardRef(({className:r,...i},o)=>S.createElement(C3,{ref:o,iconNode:e,className:gS(`lucide-${T3(t)}`,r),...i}));return n.displayName=`${t}`,n};var P3=lo("Bot",[["path",{d:"M12 8V4H8",key:"hb8ula"}],["rect",{width:"16",height:"12",x:"4",y:"8",rx:"2",key:"enze0r"}],["path",{d:"M2 14h2",key:"vft8re"}],["path",{d:"M20 14h2",key:"4cs60a"}],["path",{d:"M15 13v2",key:"1xurst"}],["path",{d:"M9 13v2",key:"rq6x2g"}]]);var A3=lo("Calendar",[["path",{d:"M8 2v4",key:"1cmpym"}],["path",{d:"M16 2v4",key:"4m81vk"}],["rect",{width:"18",height:"18",x:"3",y:"4",rx:"2",key:"1hopcy"}],["path",{d:"M3 10h18",key:"8toen8"}]]);var M3=lo("ChevronLeft",[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]]);var D3=lo("LoaderCircle",[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]]);var R3=lo("SendHorizontal",[["path",{d:"M3.714 3.048a.498.498 0 0 0-.683.627l2.843 7.627a2 2 0 0 1 0 1.396l-2.842 7.627a.498.498 0 0 0 .682.627l18-8.5a.5.5 0 0 0 0-.904z",key:"117uat"}],["path",{d:"M6 12h16",key:"s4cdu5"}]]);var ql=lo("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]);function I3(){let{opened:t,setView:e,setOpened:n}=Le();return A.jsx("button",{onClick:()=>{e("home"),n(!t)},className:`open-leoai-button ${t?"open":""}`,type:"button",children:t?A.jsx(ql,{size:32}):A.jsx(P3,{size:36,strokeWidth:2})})}function im({size:t=24,color:e="currentColor",strokeWidth:n=2}){return A.jsxs("svg",{width:t,height:t,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[A.jsx("path",{d:"M12.354 8.08984H20.1763C21.3539 8.08984 22.3096 9.04558 22.3096 10.2232V16.6232C22.3096 17.8008 21.3539 18.7565 20.1763 18.7565H19.4651V22.3121L15.554 18.7565H12.354C11.1764 18.7565 10.2207 17.8008 10.2207 16.6232V10.2232C10.2207 9.04558 11.1764 8.08984 12.354 8.08984Z",stroke:e,strokeWidth:n,strokeLinecap:"round",strokeLinejoin:"round"}),A.jsx("path",{d:"M16.1776 4.53372C15.8619 3.30777 14.7483 2.40039 13.4228 2.40039H4.5339C2.96234 2.40039 1.68945 3.67328 1.68945 5.24484V12.3574C1.68945 13.9275 2.96376 15.2018 4.5339 15.2004V19.4671L6.66723 17.1403",stroke:e,strokeWidth:n,strokeLinecap:"round",strokeLinejoin:"round"})]})}function L3(){let{append:t}=yn(),{chatbotId:e}=we(),{setView:n}=Le(),[r,i]=Nt("leoaiv3.6-home-buttons",null);return S.useEffect(()=>{!e||r&&r?.length>0||(async()=>{try{let o=await E2(e);if(!o)return;i(o?.filter(a=>a.visibility.home===!0))}catch(o){console.error("Error fetching home buttons:",o)}})()},[e,r]),A.jsx("div",{className:"leoai-home-secondary-button-container",children:r?.map(o=>A.jsx("button",{className:"leoai-quick-button home",onClick:()=>{n("chat"),t({role:"user",content:o.messageText,data:{homeButton:{id:o.id}}})},children:A.jsx("span",{dangerouslySetInnerHTML:{__html:o.buttonText}})},o.id))})}function j3(){let{articles:t,setSelectedArticle:e}=cw(),{setView:n}=Le(),{handleNewEvent:r}=yn();return A.jsx("div",{className:"leoai-home-articles-container",children:t?.filter(i=>i.isPublished&&i.pinned).map(i=>A.jsxs("button",{className:"leoai-article-card",onClick:async()=>{e(i),await r({type:"ARTICLE_OPEN",metadata:{article_id:i.id}}),e(i),n("article")},children:[A.jsx("div",{className:"leoai-article-thumbnail-container",children:A.jsx("img",{className:"leoai-article-thumbnail",src:i.thumbnail,alt:i.title})}),A.jsxs("div",{className:"leoai-article-info",children:[A.jsx("p",{className:"leoai-article-title",children:i.title}),A.jsx("p",{className:"leoai-article-description",children:i.description})]})]},i.id))})}function om({children:t}){let{links:e,name:n}=we(),{setOpened:r,setView:i,view:o}=Le();return A.jsx(A.Fragment,{children:o==="home"?A.jsxs("div",{className:"leoai-view-header home",children:[A.jsx("img",{src:e?.logo,alt:n,className:"leoai-header-logo"}),A.jsx("button",{className:"leoai-header-button home close",onClick:()=>r(!1),children:A.jsx(ql,{size:28,strokeWidth:2})})]}):A.jsxs("div",{className:"leoai-view-header",children:[A.jsxs("div",{className:"leoai-header-left-side",children:[A.jsx("button",{className:"leoai-header-button",onClick:()=>i("home"),children:A.jsx(M3,{size:28,strokeWidth:2})}),t]}),A.jsx("button",{className:"leoai-header-button close",onClick:()=>r(!1),children:A.jsx(ql,{size:28,strokeWidth:2})})]})})}function O3({width:t,height:e}){return A.jsxs("svg",{width:t,height:e,viewBox:"0 0 64 64",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[A.jsx("rect",{width:"64",height:"64",rx:"16",fill:"url(#paint0_linear_635_124)"}),A.jsx("path",{d:"M32 23V15H24",stroke:"white",strokeWidth:"4.5",strokeLinecap:"round",strokeLinejoin:"round"}),A.jsx("path",{d:"M44 23H20C17.7909 23 16 24.7909 16 27V43C16 45.2091 17.7909 47 20 47H44C46.2091 47 48 45.2091 48 43V27C48 24.7909 46.2091 23 44 23Z",stroke:"white",strokeWidth:"4.5",strokeLinecap:"round",strokeLinejoin:"round"}),A.jsx("path",{d:"M12 35H16",stroke:"white",strokeWidth:"4.5",strokeLinecap:"round",strokeLinejoin:"round"}),A.jsx("path",{d:"M48 35H52",stroke:"white",strokeWidth:"4.5",strokeLinecap:"round",strokeLinejoin:"round"}),A.jsx("path",{d:"M38 33V37",stroke:"white",strokeWidth:"4.5",strokeLinecap:"round",strokeLinejoin:"round"}),A.jsx("path",{d:"M26 33V37",stroke:"white",strokeWidth:"4.5",strokeLinecap:"round",strokeLinejoin:"round"}),A.jsx("defs",{children:A.jsxs("linearGradient",{id:"paint0_linear_635_124",x1:"0",y1:"64",x2:"64",y2:"0",gradientUnits:"userSpaceOnUse",children:[A.jsx("stop",{stopColor:"#6D28D9"}),A.jsx("stop",{offset:"1",stopColor:"#0EA5E9"})]})})]})}function _3(){return A.jsxs("div",{className:"leoai-watermark",children:["\xDCzemeltet\u0151"," ",A.jsxs("a",{href:"https://leoai.hu?ref=chatjs",rel:"external",className:"link",target:"_blank",children:[A.jsx(O3,{width:16,height:16}),A.jsx("span",{children:"LeoAI"})]})]})}function Nu({children:t}){return A.jsxs("div",{className:"leoai-footer-container",children:[t,A.jsx(_3,{})]})}function vS(){return A.jsxs("div",{className:"leoai-loading-overlay",children:[A.jsx(D3,{className:"loading-spinner",size:44,strokeWidth:1.6}),A.jsx(Nu,{})]})}function N3(){let{texts:t}=we(),{setView:e}=Le(),[n,r]=Nt("leoaiv3.6-is-home-loading",!0);return S.useEffect(()=>{if(n===!1)return;let i=setTimeout(()=>{r(!1)},600);return()=>clearTimeout(i)},[]),A.jsxs(A.Fragment,{children:[n&&A.jsx(vS,{}),A.jsxs("div",{className:"leoai-home-view leoai-view-container",children:[A.jsx(om,{}),A.jsxs("div",{className:"leoai-home-content",children:[A.jsx("div",{className:"leoai-home-intro",children:t?.views.home.welcome_texts.map((i,o)=>A.jsx("p",{children:i},o))}),A.jsxs("div",{className:"leoai-home-buttons-container",children:[A.jsxs("button",{className:"leoai-cta-button",onClick:()=>{e("chat")},children:[t?.common.open_chat_view_button_text,A.jsx(im,{size:24,strokeWidth:2})]}),A.jsx(L3,{})]}),A.jsx(j3,{})]}),A.jsx(Nu,{})]})]})}function F3(){let{links:t,texts:e,name:n}=we();return A.jsx(om,{children:A.jsxs("div",{className:"leoai-chat-profile",children:[A.jsx("img",{src:t?.icon,alt:n,className:"leoai-header-icon"}),A.jsxs("div",{className:"leoai-profile-texts",children:[A.jsx("span",{className:"leoai-profile-name",children:n}),A.jsx("span",{className:"leoai-role-description",children:e?.common.role_description})]})]})})}function V3(t,e){let n={};return(t[t.length-1]===""?[...t,""]:t).join((n.padRight?" ":"")+","+(n.padLeft===!1?"":" ")).trim()}var z3=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,B3=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,U3={};function zy(t,e){return(U3.jsx?B3:z3).test(t)}var $3=/[ \t\n\f\r]/g;function H3(t){return typeof t=="object"?t.type==="text"?By(t.value):!1:By(t)}function By(t){return t.replace($3,"")===""}var Jr=class{constructor(e,n,r){this.property=e,this.normal=n,r&&(this.space=r)}};Jr.prototype.property={};Jr.prototype.normal={};Jr.prototype.space=null;function yS(t,e){let n={},r={},i=-1;for(;++i<t.length;)Object.assign(n,t[i].property),Object.assign(r,t[i].normal);return new Jr(n,r,e)}function Lh(t){return t.toLowerCase()}var xe=class{constructor(e,n){this.property=e,this.attribute=n}};xe.prototype.space=null;xe.prototype.boolean=!1;xe.prototype.booleanish=!1;xe.prototype.overloadedBoolean=!1;xe.prototype.number=!1;xe.prototype.commaSeparated=!1;xe.prototype.spaceSeparated=!1;xe.prototype.commaOrSpaceSeparated=!1;xe.prototype.mustUseProperty=!1;xe.prototype.defined=!1;var W3=0,G=ii(),jt=ii(),bS=ii(),O=ii(),ft=ii(),zi=ii(),Se=ii();function ii(){return 2**++W3}var jh=Object.freeze(Object.defineProperty({__proto__:null,boolean:G,booleanish:jt,commaOrSpaceSeparated:Se,commaSeparated:zi,number:O,overloadedBoolean:bS,spaceSeparated:ft},Symbol.toStringTag,{value:"Module"})),zc=Object.keys(jh),La=class extends xe{constructor(e,n,r,i){let o=-1;if(super(e,n),Uy(this,"space",i),typeof r=="number")for(;++o<zc.length;){let a=zc[o];Uy(this,zc[o],(r&jh[a])===jh[a])}}};La.prototype.defined=!0;function Uy(t,e,n){n&&(t[e]=n)}var q3={}.hasOwnProperty;function uo(t){let e={},n={},r;for(r in t.properties)if(q3.call(t.properties,r)){let i=t.properties[r],o=new La(r,t.transform(t.attributes||{},r),i,t.space);t.mustUseProperty&&t.mustUseProperty.includes(r)&&(o.mustUseProperty=!0),e[r]=o,n[Lh(r)]=r,n[Lh(o.attribute)]=r}return new Jr(e,n,t.space)}var xS=uo({space:"xlink",transform(t,e){return"xlink:"+e.slice(5).toLowerCase()},properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null}}),wS=uo({space:"xml",transform(t,e){return"xml:"+e.slice(3).toLowerCase()},properties:{xmlLang:null,xmlBase:null,xmlSpace:null}});function kS(t,e){return e in t?t[e]:e}function SS(t,e){return kS(t,e.toLowerCase())}var TS=uo({space:"xmlns",attributes:{xmlnsxlink:"xmlns:xlink"},transform:SS,properties:{xmlns:null,xmlnsXLink:null}}),ES=uo({transform(t,e){return e==="role"?e:"aria-"+e.slice(4).toLowerCase()},properties:{ariaActiveDescendant:null,ariaAtomic:jt,ariaAutoComplete:null,ariaBusy:jt,ariaChecked:jt,ariaColCount:O,ariaColIndex:O,ariaColSpan:O,ariaControls:ft,ariaCurrent:null,ariaDescribedBy:ft,ariaDetails:null,ariaDisabled:jt,ariaDropEffect:ft,ariaErrorMessage:null,ariaExpanded:jt,ariaFlowTo:ft,ariaGrabbed:jt,ariaHasPopup:null,ariaHidden:jt,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:ft,ariaLevel:O,ariaLive:null,ariaModal:jt,ariaMultiLine:jt,ariaMultiSelectable:jt,ariaOrientation:null,ariaOwns:ft,ariaPlaceholder:null,ariaPosInSet:O,ariaPressed:jt,ariaReadOnly:jt,ariaRelevant:null,ariaRequired:jt,ariaRoleDescription:ft,ariaRowCount:O,ariaRowIndex:O,ariaRowSpan:O,ariaSelected:jt,ariaSetSize:O,ariaSort:null,ariaValueMax:O,ariaValueMin:O,ariaValueNow:O,ariaValueText:null,role:null}}),Y3=uo({space:"html",attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},transform:SS,mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:zi,acceptCharset:ft,accessKey:ft,action:null,allow:null,allowFullScreen:G,allowPaymentRequest:G,allowUserMedia:G,alt:null,as:null,async:G,autoCapitalize:null,autoComplete:ft,autoFocus:G,autoPlay:G,blocking:ft,capture:null,charSet:null,checked:G,cite:null,className:ft,cols:O,colSpan:null,content:null,contentEditable:jt,controls:G,controlsList:ft,coords:O|zi,crossOrigin:null,data:null,dateTime:null,decoding:null,default:G,defer:G,dir:null,dirName:null,disabled:G,download:bS,draggable:jt,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:G,formTarget:null,headers:ft,height:O,hidden:G,high:O,href:null,hrefLang:null,htmlFor:ft,httpEquiv:ft,id:null,imageSizes:null,imageSrcSet:null,inert:G,inputMode:null,integrity:null,is:null,isMap:G,itemId:null,itemProp:ft,itemRef:ft,itemScope:G,itemType:ft,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:G,low:O,manifest:null,max:null,maxLength:O,media:null,method:null,min:null,minLength:O,multiple:G,muted:G,name:null,nonce:null,noModule:G,noValidate:G,onAbort:null,onAfterPrint:null,onAuxClick:null,onBeforeMatch:null,onBeforePrint:null,onBeforeToggle:null,onBeforeUnload:null,onBlur:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onContextLost:null,onContextMenu:null,onContextRestored:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnded:null,onError:null,onFocus:null,onFormData:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLanguageChange:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadEnd:null,onLoadStart:null,onMessage:null,onMessageError:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRejectionHandled:null,onReset:null,onResize:null,onScroll:null,onScrollEnd:null,onSecurityPolicyViolation:null,onSeeked:null,onSeeking:null,onSelect:null,onSlotChange:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnhandledRejection:null,onUnload:null,onVolumeChange:null,onWaiting:null,onWheel:null,open:G,optimum:O,pattern:null,ping:ft,placeholder:null,playsInline:G,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:G,referrerPolicy:null,rel:ft,required:G,reversed:G,rows:O,rowSpan:O,sandbox:ft,scope:null,scoped:G,seamless:G,selected:G,shadowRootClonable:G,shadowRootDelegatesFocus:G,shadowRootMode:null,shape:null,size:O,sizes:null,slot:null,span:O,spellCheck:jt,src:null,srcDoc:null,srcLang:null,srcSet:null,start:O,step:null,style:null,tabIndex:O,target:null,title:null,translate:null,type:null,typeMustMatch:G,useMap:null,value:jt,width:O,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:ft,axis:null,background:null,bgColor:null,border:O,borderColor:null,bottomMargin:O,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:G,declare:G,event:null,face:null,frame:null,frameBorder:null,hSpace:O,leftMargin:O,link:null,longDesc:null,lowSrc:null,marginHeight:O,marginWidth:O,noResize:G,noHref:G,noShade:G,noWrap:G,object:null,profile:null,prompt:null,rev:null,rightMargin:O,rules:null,scheme:null,scrolling:jt,standby:null,summary:null,text:null,topMargin:O,valueType:null,version:null,vAlign:null,vLink:null,vSpace:O,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:G,disableRemotePlayback:G,prefix:null,property:null,results:O,security:null,unselectable:null}}),K3=uo({space:"svg",attributes:{accentHeight:"accent-height",alignmentBaseline:"alignment-baseline",arabicForm:"arabic-form",baselineShift:"baseline-shift",capHeight:"cap-height",className:"class",clipPath:"clip-path",clipRule:"clip-rule",colorInterpolation:"color-interpolation",colorInterpolationFilters:"color-interpolation-filters",colorProfile:"color-profile",colorRendering:"color-rendering",crossOrigin:"crossorigin",dataType:"datatype",dominantBaseline:"dominant-baseline",enableBackground:"enable-background",fillOpacity:"fill-opacity",fillRule:"fill-rule",floodColor:"flood-color",floodOpacity:"flood-opacity",fontFamily:"font-family",fontSize:"font-size",fontSizeAdjust:"font-size-adjust",fontStretch:"font-stretch",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",glyphName:"glyph-name",glyphOrientationHorizontal:"glyph-orientation-horizontal",glyphOrientationVertical:"glyph-orientation-vertical",hrefLang:"hreflang",horizAdvX:"horiz-adv-x",horizOriginX:"horiz-origin-x",horizOriginY:"horiz-origin-y",imageRendering:"image-rendering",letterSpacing:"letter-spacing",lightingColor:"lighting-color",markerEnd:"marker-end",markerMid:"marker-mid",markerStart:"marker-start",navDown:"nav-down",navDownLeft:"nav-down-left",navDownRight:"nav-down-right",navLeft:"nav-left",navNext:"nav-next",navPrev:"nav-prev",navRight:"nav-right",navUp:"nav-up",navUpLeft:"nav-up-left",navUpRight:"nav-up-right",onAbort:"onabort",onActivate:"onactivate",onAfterPrint:"onafterprint",onBeforePrint:"onbeforeprint",onBegin:"onbegin",onCancel:"oncancel",onCanPlay:"oncanplay",onCanPlayThrough:"oncanplaythrough",onChange:"onchange",onClick:"onclick",onClose:"onclose",onCopy:"oncopy",onCueChange:"oncuechange",onCut:"oncut",onDblClick:"ondblclick",onDrag:"ondrag",onDragEnd:"ondragend",onDragEnter:"ondragenter",onDragExit:"ondragexit",onDragLeave:"ondragleave",onDragOver:"ondragover",onDragStart:"ondragstart",onDrop:"ondrop",onDurationChange:"ondurationchange",onEmptied:"onemptied",onEnd:"onend",onEnded:"onended",onError:"onerror",onFocus:"onfocus",onFocusIn:"onfocusin",onFocusOut:"onfocusout",onHashChange:"onhashchange",onInput:"oninput",onInvalid:"oninvalid",onKeyDown:"onkeydown",onKeyPress:"onkeypress",onKeyUp:"onkeyup",onLoad:"onload",onLoadedData:"onloadeddata",onLoadedMetadata:"onloadedmetadata",onLoadStart:"onloadstart",onMessage:"onmessage",onMouseDown:"onmousedown",onMouseEnter:"onmouseenter",onMouseLeave:"onmouseleave",onMouseMove:"onmousemove",onMouseOut:"onmouseout",onMouseOver:"onmouseover",onMouseUp:"onmouseup",onMouseWheel:"onmousewheel",onOffline:"onoffline",onOnline:"ononline",onPageHide:"onpagehide",onPageShow:"onpageshow",onPaste:"onpaste",onPause:"onpause",onPlay:"onplay",onPlaying:"onplaying",onPopState:"onpopstate",onProgress:"onprogress",onRateChange:"onratechange",onRepeat:"onrepeat",onReset:"onreset",onResize:"onresize",onScroll:"onscroll",onSeeked:"onseeked",onSeeking:"onseeking",onSelect:"onselect",onShow:"onshow",onStalled:"onstalled",onStorage:"onstorage",onSubmit:"onsubmit",onSuspend:"onsuspend",onTimeUpdate:"ontimeupdate",onToggle:"ontoggle",onUnload:"onunload",onVolumeChange:"onvolumechange",onWaiting:"onwaiting",onZoom:"onzoom",overlinePosition:"overline-position",overlineThickness:"overline-thickness",paintOrder:"paint-order",panose1:"panose-1",pointerEvents:"pointer-events",referrerPolicy:"referrerpolicy",renderingIntent:"rendering-intent",shapeRendering:"shape-rendering",stopColor:"stop-color",stopOpacity:"stop-opacity",strikethroughPosition:"strikethrough-position",strikethroughThickness:"strikethrough-thickness",strokeDashArray:"stroke-dasharray",strokeDashOffset:"stroke-dashoffset",strokeLineCap:"stroke-linecap",strokeLineJoin:"stroke-linejoin",strokeMiterLimit:"stroke-miterlimit",strokeOpacity:"stroke-opacity",strokeWidth:"stroke-width",tabIndex:"tabindex",textAnchor:"text-anchor",textDecoration:"text-decoration",textRendering:"text-rendering",transformOrigin:"transform-origin",typeOf:"typeof",underlinePosition:"underline-position",underlineThickness:"underline-thickness",unicodeBidi:"unicode-bidi",unicodeRange:"unicode-range",unitsPerEm:"units-per-em",vAlphabetic:"v-alphabetic",vHanging:"v-hanging",vIdeographic:"v-ideographic",vMathematical:"v-mathematical",vectorEffect:"vector-effect",vertAdvY:"vert-adv-y",vertOriginX:"vert-origin-x",vertOriginY:"vert-origin-y",wordSpacing:"word-spacing",writingMode:"writing-mode",xHeight:"x-height",playbackOrder:"playbackorder",timelineBegin:"timelinebegin"},transform:kS,properties:{about:Se,accentHeight:O,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:O,amplitude:O,arabicForm:null,ascent:O,attributeName:null,attributeType:null,azimuth:O,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:O,by:null,calcMode:null,capHeight:O,className:ft,clip:null,clipPath:null,clipPathUnits:null,clipRule:null,color:null,colorInterpolation:null,colorInterpolationFilters:null,colorProfile:null,colorRendering:null,content:null,contentScriptType:null,contentStyleType:null,crossOrigin:null,cursor:null,cx:null,cy:null,d:null,dataType:null,defaultAction:null,descent:O,diffuseConstant:O,direction:null,display:null,dur:null,divisor:O,dominantBaseline:null,download:G,dx:null,dy:null,edgeMode:null,editable:null,elevation:O,enableBackground:null,end:null,event:null,exponent:O,externalResourcesRequired:null,fill:null,fillOpacity:O,fillRule:null,filter:null,filterRes:null,filterUnits:null,floodColor:null,floodOpacity:null,focusable:null,focusHighlight:null,fontFamily:null,fontSize:null,fontSizeAdjust:null,fontStretch:null,fontStyle:null,fontVariant:null,fontWeight:null,format:null,fr:null,from:null,fx:null,fy:null,g1:zi,g2:zi,glyphName:zi,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:O,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:O,horizOriginX:O,horizOriginY:O,id:null,ideographic:O,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:O,k:O,k1:O,k2:O,k3:O,k4:O,kernelMatrix:Se,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:O,local:null,markerEnd:null,markerMid:null,markerStart:null,markerHeight:null,markerUnits:null,markerWidth:null,mask:null,maskContentUnits:null,maskUnits:null,mathematical:null,max:null,media:null,mediaCharacterEncoding:null,mediaContentEncodings:null,mediaSize:O,mediaTime:null,method:null,min:null,mode:null,name:null,navDown:null,navDownLeft:null,navDownRight:null,navLeft:null,navNext:null,navPrev:null,navRight:null,navUp:null,navUpLeft:null,navUpRight:null,numOctaves:null,observer:null,offset:null,onAbort:null,onActivate:null,onAfterPrint:null,onBeforePrint:null,onBegin:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnd:null,onEnded:null,onError:null,onFocus:null,onFocusIn:null,onFocusOut:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadStart:null,onMessage:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onMouseWheel:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRepeat:null,onReset:null,onResize:null,onScroll:null,onSeeked:null,onSeeking:null,onSelect:null,onShow:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnload:null,onVolumeChange:null,onWaiting:null,onZoom:null,opacity:null,operator:null,order:null,orient:null,orientation:null,origin:null,overflow:null,overlay:null,overlinePosition:O,overlineThickness:O,paintOrder:null,panose1:null,path:null,pathLength:O,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:ft,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:O,pointsAtY:O,pointsAtZ:O,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:Se,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:Se,rev:Se,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:Se,requiredFeatures:Se,requiredFonts:Se,requiredFormats:Se,resource:null,restart:null,result:null,rotate:null,rx:null,ry:null,scale:null,seed:null,shapeRendering:null,side:null,slope:null,snapshotTime:null,specularConstant:O,specularExponent:O,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:O,strikethroughThickness:O,string:null,stroke:null,strokeDashArray:Se,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:O,strokeOpacity:O,strokeWidth:null,style:null,surfaceScale:O,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:Se,tabIndex:O,tableValues:null,target:null,targetX:O,targetY:O,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:Se,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:O,underlineThickness:O,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:O,values:null,vAlphabetic:O,vMathematical:O,vectorEffect:null,vHanging:O,vIdeographic:O,version:null,vertAdvY:O,vertOriginX:O,vertOriginY:O,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:O,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null}}),X3=/^data[-\w.:]+$/i,$y=/-[a-z]/g,G3=/[A-Z]/g;function Q3(t,e){let n=Lh(e),r=e,i=xe;if(n in t.normal)return t.property[t.normal[n]];if(n.length>4&&n.slice(0,4)==="data"&&X3.test(e)){if(e.charAt(4)==="-"){let o=e.slice(5).replace($y,Z3);r="data"+o.charAt(0).toUpperCase()+o.slice(1)}else{let o=e.slice(4);if(!$y.test(o)){let a=o.replace(G3,J3);a.charAt(0)!=="-"&&(a="-"+a),e="data"+a}}i=La}return new i(r,e)}function J3(t){return"-"+t.toLowerCase()}function Z3(t){return t.charAt(1).toUpperCase()}var tj={classId:"classID",dataType:"datatype",itemId:"itemID",strokeDashArray:"strokeDasharray",strokeDashOffset:"strokeDashoffset",strokeLineCap:"strokeLinecap",strokeLineJoin:"strokeLinejoin",strokeMiterLimit:"strokeMiterlimit",typeOf:"typeof",xLinkActuate:"xlinkActuate",xLinkArcRole:"xlinkArcrole",xLinkHref:"xlinkHref",xLinkRole:"xlinkRole",xLinkShow:"xlinkShow",xLinkTitle:"xlinkTitle",xLinkType:"xlinkType",xmlnsXLink:"xmlnsXlink"},ej=yS([wS,xS,TS,ES,Y3],"html"),am=yS([wS,xS,TS,ES,K3],"svg");function nj(t){let e=String(t||"").trim();return e?e.split(/[ \t\n\r\f]+/g):[]}function rj(t){return t.join(" ").trim()}var CS={},Hy=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,ij=/\n/g,oj=/^\s*/,aj=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,sj=/^:\s*/,lj=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,uj=/^[;\s]*/,cj=/^\s+|\s+$/g,dj=`
`,Wy="/",qy="*",_r="",hj="comment",pj="declaration",fj=function(t,e){if(typeof t!="string")throw new TypeError("First argument must be a string");if(!t)return[];e=e||{};var n=1,r=1;function i(m){var v=m.match(ij);v&&(n+=v.length);var b=m.lastIndexOf(dj);r=~b?m.length-b:r+m.length}function o(){var m={line:n,column:r};return function(v){return v.position=new a(m),u(),v}}function a(m){this.start=m,this.end={line:n,column:r},this.source=e.source}a.prototype.content=t;function s(m){var v=new Error(e.source+":"+n+":"+r+": "+m);if(v.reason=m,v.filename=e.source,v.line=n,v.column=r,v.source=t,!e.silent)throw v}function l(m){var v=m.exec(t);if(v){var b=v[0];return i(b),t=t.slice(b.length),v}}function u(){l(oj)}function c(m){var v;for(m=m||[];v=d();)v!==!1&&m.push(v);return m}function d(){var m=o();if(!(Wy!=t.charAt(0)||qy!=t.charAt(1))){for(var v=2;_r!=t.charAt(v)&&(qy!=t.charAt(v)||Wy!=t.charAt(v+1));)++v;if(v+=2,_r===t.charAt(v-1))return s("End of comment missing");var b=t.slice(2,v-2);return r+=2,i(b),t=t.slice(v),r+=2,m({type:hj,comment:b})}}function h(){var m=o(),v=l(aj);if(v){if(d(),!l(sj))return s("property missing ':'");var b=l(lj),f=m({type:pj,property:Yy(v[0].replace(Hy,_r)),value:b?Yy(b[0].replace(Hy,_r)):_r});return l(uj),f}}function p(){var m=[];c(m);for(var v;v=h();)v!==!1&&(m.push(v),c(m));return m}return u(),p()};function Yy(t){return t?t.replace(cj,_r):_r}var mj=Jm&&Jm.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(CS,"__esModule",{value:!0});var Ky=CS.default=vj,gj=mj(fj);function vj(t,e){var n=null;if(!t||typeof t!="string")return n;var r=(0,gj.default)(t),i=typeof e=="function";return r.forEach(function(o){if(o.type==="declaration"){var a=o.property,s=o.value;i?e(a,s,o):s&&(n=n||{},n[a]=s)}}),n}var yj=Ky.default||Ky,PS=AS("end"),sm=AS("start");function AS(t){return e;function e(n){let r=n&&n.position&&n.position[t]||{};if(typeof r.line=="number"&&r.line>0&&typeof r.column=="number"&&r.column>0)return{line:r.line,column:r.column,offset:typeof r.offset=="number"&&r.offset>-1?r.offset:void 0}}}function bj(t){let e=sm(t),n=PS(t);if(e&&n)return{start:e,end:n}}function Xo(t){return!t||typeof t!="object"?"":"position"in t||"type"in t?Xy(t.position):"start"in t||"end"in t?Xy(t):"line"in t||"column"in t?Oh(t):""}function Oh(t){return Gy(t&&t.line)+":"+Gy(t&&t.column)}function Xy(t){return Oh(t&&t.start)+"-"+Oh(t&&t.end)}function Gy(t){return t&&typeof t=="number"?t:1}var Ut=class extends Error{constructor(e,n,r){super(),typeof n=="string"&&(r=n,n=void 0);let i="",o={},a=!1;if(n&&("line"in n&&"column"in n?o={place:n}:"start"in n&&"end"in n?o={place:n}:"type"in n?o={ancestors:[n],place:n.position}:o={...n}),typeof e=="string"?i=e:!o.cause&&e&&(a=!0,i=e.message,o.cause=e),!o.ruleId&&!o.source&&typeof r=="string"){let l=r.indexOf(":");l===-1?o.ruleId=r:(o.source=r.slice(0,l),o.ruleId=r.slice(l+1))}if(!o.place&&o.ancestors&&o.ancestors){let l=o.ancestors[o.ancestors.length-1];l&&(o.place=l.position)}let s=o.place&&"start"in o.place?o.place.start:o.place;this.ancestors=o.ancestors||void 0,this.cause=o.cause||void 0,this.column=s?s.column:void 0,this.fatal=void 0,this.file,this.message=i,this.line=s?s.line:void 0,this.name=Xo(o.place)||"1:1",this.place=o.place||void 0,this.reason=this.message,this.ruleId=o.ruleId||void 0,this.source=o.source||void 0,this.stack=a&&o.cause&&typeof o.cause.stack=="string"?o.cause.stack:"",this.actual,this.expected,this.note,this.url}};Ut.prototype.file="";Ut.prototype.name="";Ut.prototype.reason="";Ut.prototype.message="";Ut.prototype.stack="";Ut.prototype.column=void 0;Ut.prototype.line=void 0;Ut.prototype.ancestors=void 0;Ut.prototype.cause=void 0;Ut.prototype.fatal=void 0;Ut.prototype.place=void 0;Ut.prototype.ruleId=void 0;Ut.prototype.source=void 0;var lm={}.hasOwnProperty,xj=new Map,wj=/[A-Z]/g,kj=/-([a-z])/g,Sj=new Set(["table","tbody","thead","tfoot","tr"]),Tj=new Set(["td","th"]),MS="https://github.com/syntax-tree/hast-util-to-jsx-runtime";function Ej(t,e){if(!e||e.Fragment===void 0)throw new TypeError("Expected `Fragment` in options");let n=e.filePath||void 0,r;if(e.development){if(typeof e.jsxDEV!="function")throw new TypeError("Expected `jsxDEV` in options when `development: true`");r=Lj(n,e.jsxDEV)}else{if(typeof e.jsx!="function")throw new TypeError("Expected `jsx` in production options");if(typeof e.jsxs!="function")throw new TypeError("Expected `jsxs` in production options");r=Ij(n,e.jsx,e.jsxs)}let i={Fragment:e.Fragment,ancestors:[],components:e.components||{},create:r,elementAttributeNameCase:e.elementAttributeNameCase||"react",evaluater:e.createEvaluater?e.createEvaluater():void 0,filePath:n,ignoreInvalidStyle:e.ignoreInvalidStyle||!1,passKeys:e.passKeys!==!1,passNode:e.passNode||!1,schema:e.space==="svg"?am:ej,stylePropertyNameCase:e.stylePropertyNameCase||"dom",tableCellAlignToStyle:e.tableCellAlignToStyle!==!1},o=DS(i,t,void 0);return o&&typeof o!="string"?o:i.create(t,i.Fragment,{children:o||void 0},void 0)}function DS(t,e,n){if(e.type==="element")return Cj(t,e,n);if(e.type==="mdxFlowExpression"||e.type==="mdxTextExpression")return Pj(t,e);if(e.type==="mdxJsxFlowElement"||e.type==="mdxJsxTextElement")return Mj(t,e,n);if(e.type==="mdxjsEsm")return Aj(t,e);if(e.type==="root")return Dj(t,e,n);if(e.type==="text")return Rj(t,e)}function Cj(t,e,n){let r=t.schema,i=r;e.tagName.toLowerCase()==="svg"&&r.space==="html"&&(i=am,t.schema=i),t.ancestors.push(e);let o=IS(t,e.tagName,!1),a=jj(t,e),s=cm(t,e);return Sj.has(e.tagName)&&(s=s.filter(function(l){return typeof l=="string"?!H3(l):!0})),RS(t,a,o,e),um(a,s),t.ancestors.pop(),t.schema=r,t.create(e,o,a,n)}function Pj(t,e){if(e.data&&e.data.estree&&t.evaluater){let n=e.data.estree.body[0];return n.type,t.evaluater.evaluateExpression(n.expression)}ja(t,e.position)}function Aj(t,e){if(e.data&&e.data.estree&&t.evaluater)return t.evaluater.evaluateProgram(e.data.estree);ja(t,e.position)}function Mj(t,e,n){let r=t.schema,i=r;e.name==="svg"&&r.space==="html"&&(i=am,t.schema=i),t.ancestors.push(e);let o=e.name===null?t.Fragment:IS(t,e.name,!0),a=Oj(t,e),s=cm(t,e);return RS(t,a,o,e),um(a,s),t.ancestors.pop(),t.schema=r,t.create(e,o,a,n)}function Dj(t,e,n){let r={};return um(r,cm(t,e)),t.create(e,t.Fragment,r,n)}function Rj(t,e){return e.value}function RS(t,e,n,r){typeof n!="string"&&n!==t.Fragment&&t.passNode&&(e.node=r)}function um(t,e){if(e.length>0){let n=e.length>1?e:e[0];n&&(t.children=n)}}function Ij(t,e,n){return r;function r(i,o,a,s){let l=Array.isArray(a.children)?n:e;return s?l(o,a,s):l(o,a)}}function Lj(t,e){return n;function n(r,i,o,a){let s=Array.isArray(o.children),l=sm(r);return e(i,o,a,s,{columnNumber:l?l.column-1:void 0,fileName:t,lineNumber:l?l.line:void 0},void 0)}}function jj(t,e){let n={},r,i;for(i in e.properties)if(i!=="children"&&lm.call(e.properties,i)){let o=_j(t,i,e.properties[i]);if(o){let[a,s]=o;t.tableCellAlignToStyle&&a==="align"&&typeof s=="string"&&Tj.has(e.tagName)?r=s:n[a]=s}}if(r){let o=n.style||(n.style={});o[t.stylePropertyNameCase==="css"?"text-align":"textAlign"]=r}return n}function Oj(t,e){let n={};for(let r of e.attributes)if(r.type==="mdxJsxExpressionAttribute")if(r.data&&r.data.estree&&t.evaluater){let i=r.data.estree.body[0];i.type;let o=i.expression;o.type;let a=o.properties[0];a.type,Object.assign(n,t.evaluater.evaluateExpression(a.argument))}else ja(t,e.position);else{let i=r.name,o;if(r.value&&typeof r.value=="object")if(r.value.data&&r.value.data.estree&&t.evaluater){let a=r.value.data.estree.body[0];a.type,o=t.evaluater.evaluateExpression(a.expression)}else ja(t,e.position);else o=r.value===null?!0:r.value;n[i]=o}return n}function cm(t,e){let n=[],r=-1,i=t.passKeys?new Map:xj;for(;++r<e.children.length;){let o=e.children[r],a;if(t.passKeys){let l=o.type==="element"?o.tagName:o.type==="mdxJsxFlowElement"||o.type==="mdxJsxTextElement"?o.name:void 0;if(l){let u=i.get(l)||0;a=l+"-"+u,i.set(l,u+1)}}let s=DS(t,o,a);s!==void 0&&n.push(s)}return n}function _j(t,e,n){let r=Q3(t.schema,e);if(!(n==null||typeof n=="number"&&Number.isNaN(n))){if(Array.isArray(n)&&(n=r.commaSeparated?V3(n):rj(n)),r.property==="style"){let i=typeof n=="object"?n:Nj(t,String(n));return t.stylePropertyNameCase==="css"&&(i=Fj(i)),["style",i]}return[t.elementAttributeNameCase==="react"&&r.space?tj[r.property]||r.property:r.attribute,n]}}function Nj(t,e){let n={};try{yj(e,r)}catch(i){if(!t.ignoreInvalidStyle){let o=i,a=new Ut("Cannot parse `style` attribute",{ancestors:t.ancestors,cause:o,ruleId:"style",source:"hast-util-to-jsx-runtime"});throw a.file=t.filePath||void 0,a.url=MS+"#cannot-parse-style-attribute",a}}return n;function r(i,o){let a=i;a.slice(0,2)!=="--"&&(a.slice(0,4)==="-ms-"&&(a="ms-"+a.slice(4)),a=a.replace(kj,zj)),n[a]=o}}function IS(t,e,n){let r;if(!n)r={type:"Literal",value:e};else if(e.includes(".")){let i=e.split("."),o=-1,a;for(;++o<i.length;){let s=zy(i[o])?{type:"Identifier",name:i[o]}:{type:"Literal",value:i[o]};a=a?{type:"MemberExpression",object:a,property:s,computed:!!(o&&s.type==="Literal"),optional:!1}:s}r=a}else r=zy(e)&&!/^[a-z]/.test(e)?{type:"Identifier",name:e}:{type:"Literal",value:e};if(r.type==="Literal"){let i=r.value;return lm.call(t.components,i)?t.components[i]:i}if(t.evaluater)return t.evaluater.evaluateExpression(r);ja(t)}function ja(t,e){let n=new Ut("Cannot handle MDX estrees without `createEvaluater`",{ancestors:t.ancestors,place:e,ruleId:"mdx-estree",source:"hast-util-to-jsx-runtime"});throw n.file=t.filePath||void 0,n.url=MS+"#cannot-handle-mdx-estrees-without-createevaluater",n}function Fj(t){let e={},n;for(n in t)lm.call(t,n)&&(e[Vj(n)]=t[n]);return e}function Vj(t){let e=t.replace(wj,Bj);return e.slice(0,3)==="ms-"&&(e="-"+e),e}function zj(t,e){return e.toUpperCase()}function Bj(t){return"-"+t.toLowerCase()}var Bc={action:["form"],cite:["blockquote","del","ins","q"],data:["object"],formAction:["button","input"],href:["a","area","base","link"],icon:["menuitem"],itemId:null,manifest:["html"],ping:["a","area"],poster:["video"],src:["audio","embed","iframe","img","input","script","source","track","video"]},Uj={};function dm(t,e){let n=Uj,r=typeof n.includeImageAlt=="boolean"?n.includeImageAlt:!0,i=typeof n.includeHtml=="boolean"?n.includeHtml:!0;return LS(t,r,i)}function LS(t,e,n){if($j(t)){if("value"in t)return t.type==="html"&&!n?"":t.value;if(e&&"alt"in t&&t.alt)return t.alt;if("children"in t)return Qy(t.children,e,n)}return Array.isArray(t)?Qy(t,e,n):""}function Qy(t,e,n){let r=[],i=-1;for(;++i<t.length;)r[i]=LS(t[i],e,n);return r.join("")}function $j(t){return!!(t&&typeof t=="object")}var Jy=document.createElement("i");function hm(t){let e="&"+t+";";Jy.innerHTML=e;let n=Jy.textContent;return n.charCodeAt(n.length-1)===59&&t!=="semi"||n===e?!1:n}function He(t,e,n,r){let i=t.length,o=0,a;if(e<0?e=-e>i?0:i+e:e=e>i?i:e,n=n>0?n:0,r.length<1e4)a=Array.from(r),a.unshift(e,n),t.splice(...a);else for(n&&t.splice(e,n);o<r.length;)a=r.slice(o,o+1e4),a.unshift(e,0),t.splice(...a),o+=1e4,e+=1e4}function Be(t,e){return t.length>0?(He(t,t.length,0,e),t):e}var Zy={}.hasOwnProperty;function jS(t){let e={},n=-1;for(;++n<t.length;)Hj(e,t[n]);return e}function Hj(t,e){let n;for(n in e){let r=(Zy.call(t,n)?t[n]:void 0)||(t[n]={}),i=e[n],o;if(i)for(o in i){Zy.call(r,o)||(r[o]=[]);let a=i[o];Wj(r[o],Array.isArray(a)?a:a?[a]:[])}}}function Wj(t,e){let n=-1,r=[];for(;++n<e.length;)(e[n].add==="after"?t:r).push(e[n]);He(t,0,0,r)}function OS(t,e){let n=Number.parseInt(t,e);return n<9||n===11||n>13&&n<32||n>126&&n<160||n>55295&&n<57344||n>64975&&n<65008||(n&65535)===65535||(n&65535)===65534||n>1114111?"\uFFFD":String.fromCodePoint(n)}function en(t){return t.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}var le=Cr(/[A-Za-z]/),ee=Cr(/[\dA-Za-z]/),qj=Cr(/[#-'*+\--9=?A-Z^-~]/);function Yl(t){return t!==null&&(t<32||t===127)}var _h=Cr(/\d/),Yj=Cr(/[\dA-Fa-f]/),Kj=Cr(/[!-/:-@[-`{-~]/);function $(t){return t!==null&&t<-2}function pt(t){return t!==null&&(t<0||t===32)}function tt(t){return t===-2||t===-1||t===32}var Fu=Cr(new RegExp("\\p{P}|\\p{S}","u")),Zr=Cr(/\s/);function Cr(t){return e;function e(n){return n!==null&&n>-1&&t.test(String.fromCharCode(n))}}function co(t){let e=[],n=-1,r=0,i=0;for(;++n<t.length;){let o=t.charCodeAt(n),a="";if(o===37&&ee(t.charCodeAt(n+1))&&ee(t.charCodeAt(n+2)))i=2;else if(o<128)/[!#$&-;=?-Z_a-z~]/.test(String.fromCharCode(o))||(a=String.fromCharCode(o));else if(o>55295&&o<57344){let s=t.charCodeAt(n+1);o<56320&&s>56319&&s<57344?(a=String.fromCharCode(o,s),i=1):a="\uFFFD"}else a=String.fromCharCode(o);a&&(e.push(t.slice(r,n),encodeURIComponent(a)),r=n+i+1,a=""),i&&(n+=i,i=0)}return e.join("")+t.slice(r)}function it(t,e,n,r){let i=r?r-1:Number.POSITIVE_INFINITY,o=0;return a;function a(l){return tt(l)?(t.enter(n),s(l)):e(l)}function s(l){return tt(l)&&o++<i?(t.consume(l),s):(t.exit(n),e(l))}}var Xj={tokenize:Gj};function Gj(t){let e=t.attempt(this.parser.constructs.contentInitial,r,i),n;return e;function r(s){if(s===null){t.consume(s);return}return t.enter("lineEnding"),t.consume(s),t.exit("lineEnding"),it(t,e,"linePrefix")}function i(s){return t.enter("paragraph"),o(s)}function o(s){let l=t.enter("chunkText",{contentType:"text",previous:n});return n&&(n.next=l),n=l,a(s)}function a(s){if(s===null){t.exit("chunkText"),t.exit("paragraph"),t.consume(s);return}return $(s)?(t.consume(s),t.exit("chunkText"),o):(t.consume(s),a)}}var Qj={tokenize:Jj},t0={tokenize:Zj};function Jj(t){let e=this,n=[],r=0,i,o,a;return s;function s(y){if(r<n.length){let w=n[r];return e.containerState=w[1],t.attempt(w[0].continuation,l,u)(y)}return u(y)}function l(y){if(r++,e.containerState._closeFlow){e.containerState._closeFlow=void 0,i&&g();let w=e.events.length,C=w,k;for(;C--;)if(e.events[C][0]==="exit"&&e.events[C][1].type==="chunkFlow"){k=e.events[C][1].end;break}f(r);let M=w;for(;M<e.events.length;)e.events[M][1].end=Object.assign({},k),M++;return He(e.events,C+1,0,e.events.slice(w)),e.events.length=M,u(y)}return s(y)}function u(y){if(r===n.length){if(!i)return h(y);if(i.currentConstruct&&i.currentConstruct.concrete)return m(y);e.interrupt=!!(i.currentConstruct&&!i._gfmTableDynamicInterruptHack)}return e.containerState={},t.check(t0,c,d)(y)}function c(y){return i&&g(),f(r),h(y)}function d(y){return e.parser.lazy[e.now().line]=r!==n.length,a=e.now().offset,m(y)}function h(y){return e.containerState={},t.attempt(t0,p,m)(y)}function p(y){return r++,n.push([e.currentConstruct,e.containerState]),h(y)}function m(y){if(y===null){i&&g(),f(0),t.consume(y);return}return i=i||e.parser.flow(e.now()),t.enter("chunkFlow",{contentType:"flow",previous:o,_tokenizer:i}),v(y)}function v(y){if(y===null){b(t.exit("chunkFlow"),!0),f(0),t.consume(y);return}return $(y)?(t.consume(y),b(t.exit("chunkFlow")),r=0,e.interrupt=void 0,s):(t.consume(y),v)}function b(y,w){let C=e.sliceStream(y);if(w&&C.push(null),y.previous=o,o&&(o.next=y),o=y,i.defineSkip(y.start),i.write(C),e.parser.lazy[y.start.line]){let k=i.events.length;for(;k--;)if(i.events[k][1].start.offset<a&&(!i.events[k][1].end||i.events[k][1].end.offset>a))return;let M=e.events.length,P=M,R,E;for(;P--;)if(e.events[P][0]==="exit"&&e.events[P][1].type==="chunkFlow"){if(R){E=e.events[P][1].end;break}R=!0}for(f(r),k=M;k<e.events.length;)e.events[k][1].end=Object.assign({},E),k++;He(e.events,P+1,0,e.events.slice(M)),e.events.length=k}}function f(y){let w=n.length;for(;w-- >y;){let C=n[w];e.containerState=C[1],C[0].exit.call(e,t)}n.length=y}function g(){i.write([null]),o=void 0,i=void 0,e.containerState._closeFlow=void 0}}function Zj(t,e,n){return it(t,t.attempt(this.parser.constructs.document,e,n),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}function Zi(t){if(t===null||pt(t)||Zr(t))return 1;if(Fu(t))return 2}function Vu(t,e,n){let r=[],i=-1;for(;++i<t.length;){let o=t[i].resolveAll;o&&!r.includes(o)&&(e=o(e,n),r.push(o))}return e}var Nh={name:"attention",tokenize:e4,resolveAll:t4};function t4(t,e){let n=-1,r,i,o,a,s,l,u,c;for(;++n<t.length;)if(t[n][0]==="enter"&&t[n][1].type==="attentionSequence"&&t[n][1]._close){for(r=n;r--;)if(t[r][0]==="exit"&&t[r][1].type==="attentionSequence"&&t[r][1]._open&&e.sliceSerialize(t[r][1]).charCodeAt(0)===e.sliceSerialize(t[n][1]).charCodeAt(0)){if((t[r][1]._close||t[n][1]._open)&&(t[n][1].end.offset-t[n][1].start.offset)%3&&!((t[r][1].end.offset-t[r][1].start.offset+t[n][1].end.offset-t[n][1].start.offset)%3))continue;l=t[r][1].end.offset-t[r][1].start.offset>1&&t[n][1].end.offset-t[n][1].start.offset>1?2:1;let d=Object.assign({},t[r][1].end),h=Object.assign({},t[n][1].start);e0(d,-l),e0(h,l),a={type:l>1?"strongSequence":"emphasisSequence",start:d,end:Object.assign({},t[r][1].end)},s={type:l>1?"strongSequence":"emphasisSequence",start:Object.assign({},t[n][1].start),end:h},o={type:l>1?"strongText":"emphasisText",start:Object.assign({},t[r][1].end),end:Object.assign({},t[n][1].start)},i={type:l>1?"strong":"emphasis",start:Object.assign({},a.start),end:Object.assign({},s.end)},t[r][1].end=Object.assign({},a.start),t[n][1].start=Object.assign({},s.end),u=[],t[r][1].end.offset-t[r][1].start.offset&&(u=Be(u,[["enter",t[r][1],e],["exit",t[r][1],e]])),u=Be(u,[["enter",i,e],["enter",a,e],["exit",a,e],["enter",o,e]]),u=Be(u,Vu(e.parser.constructs.insideSpan.null,t.slice(r+1,n),e)),u=Be(u,[["exit",o,e],["enter",s,e],["exit",s,e],["exit",i,e]]),t[n][1].end.offset-t[n][1].start.offset?(c=2,u=Be(u,[["enter",t[n][1],e],["exit",t[n][1],e]])):c=0,He(t,r-1,n-r+3,u),n=r+u.length-c-2;break}}for(n=-1;++n<t.length;)t[n][1].type==="attentionSequence"&&(t[n][1].type="data");return t}function e4(t,e){let n=this.parser.constructs.attentionMarkers.null,r=this.previous,i=Zi(r),o;return a;function a(l){return o=l,t.enter("attentionSequence"),s(l)}function s(l){if(l===o)return t.consume(l),s;let u=t.exit("attentionSequence"),c=Zi(l),d=!c||c===2&&i||n.includes(l),h=!i||i===2&&c||n.includes(r);return u._open=!!(o===42?d:d&&(i||!h)),u._close=!!(o===42?h:h&&(c||!d)),e(l)}}function e0(t,e){t.column+=e,t.offset+=e,t._bufferIndex+=e}var n4={name:"autolink",tokenize:r4};function r4(t,e,n){let r=0;return i;function i(p){return t.enter("autolink"),t.enter("autolinkMarker"),t.consume(p),t.exit("autolinkMarker"),t.enter("autolinkProtocol"),o}function o(p){return le(p)?(t.consume(p),a):p===64?n(p):u(p)}function a(p){return p===43||p===45||p===46||ee(p)?(r=1,s(p)):u(p)}function s(p){return p===58?(t.consume(p),r=0,l):(p===43||p===45||p===46||ee(p))&&r++<32?(t.consume(p),s):(r=0,u(p))}function l(p){return p===62?(t.exit("autolinkProtocol"),t.enter("autolinkMarker"),t.consume(p),t.exit("autolinkMarker"),t.exit("autolink"),e):p===null||p===32||p===60||Yl(p)?n(p):(t.consume(p),l)}function u(p){return p===64?(t.consume(p),c):qj(p)?(t.consume(p),u):n(p)}function c(p){return ee(p)?d(p):n(p)}function d(p){return p===46?(t.consume(p),r=0,c):p===62?(t.exit("autolinkProtocol").type="autolinkEmail",t.enter("autolinkMarker"),t.consume(p),t.exit("autolinkMarker"),t.exit("autolink"),e):h(p)}function h(p){if((p===45||ee(p))&&r++<63){let m=p===45?h:d;return t.consume(p),m}return n(p)}}var Ja={tokenize:i4,partial:!0};function i4(t,e,n){return r;function r(o){return tt(o)?it(t,i,"linePrefix")(o):i(o)}function i(o){return o===null||$(o)?e(o):n(o)}}var _S={name:"blockQuote",tokenize:o4,continuation:{tokenize:a4},exit:s4};function o4(t,e,n){let r=this;return i;function i(a){if(a===62){let s=r.containerState;return s.open||(t.enter("blockQuote",{_container:!0}),s.open=!0),t.enter("blockQuotePrefix"),t.enter("blockQuoteMarker"),t.consume(a),t.exit("blockQuoteMarker"),o}return n(a)}function o(a){return tt(a)?(t.enter("blockQuotePrefixWhitespace"),t.consume(a),t.exit("blockQuotePrefixWhitespace"),t.exit("blockQuotePrefix"),e):(t.exit("blockQuotePrefix"),e(a))}}function a4(t,e,n){let r=this;return i;function i(a){return tt(a)?it(t,o,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(a):o(a)}function o(a){return t.attempt(_S,e,n)(a)}}function s4(t){t.exit("blockQuote")}var NS={name:"characterEscape",tokenize:l4};function l4(t,e,n){return r;function r(o){return t.enter("characterEscape"),t.enter("escapeMarker"),t.consume(o),t.exit("escapeMarker"),i}function i(o){return Kj(o)?(t.enter("characterEscapeValue"),t.consume(o),t.exit("characterEscapeValue"),t.exit("characterEscape"),e):n(o)}}var FS={name:"characterReference",tokenize:u4};function u4(t,e,n){let r=this,i=0,o,a;return s;function s(d){return t.enter("characterReference"),t.enter("characterReferenceMarker"),t.consume(d),t.exit("characterReferenceMarker"),l}function l(d){return d===35?(t.enter("characterReferenceMarkerNumeric"),t.consume(d),t.exit("characterReferenceMarkerNumeric"),u):(t.enter("characterReferenceValue"),o=31,a=ee,c(d))}function u(d){return d===88||d===120?(t.enter("characterReferenceMarkerHexadecimal"),t.consume(d),t.exit("characterReferenceMarkerHexadecimal"),t.enter("characterReferenceValue"),o=6,a=Yj,c):(t.enter("characterReferenceValue"),o=7,a=_h,c(d))}function c(d){if(d===59&&i){let h=t.exit("characterReferenceValue");return a===ee&&!hm(r.sliceSerialize(h))?n(d):(t.enter("characterReferenceMarker"),t.consume(d),t.exit("characterReferenceMarker"),t.exit("characterReference"),e)}return a(d)&&i++<o?(t.consume(d),c):n(d)}}var n0={tokenize:d4,partial:!0},r0={name:"codeFenced",tokenize:c4,concrete:!0};function c4(t,e,n){let r=this,i={tokenize:C,partial:!0},o=0,a=0,s;return l;function l(k){return u(k)}function u(k){let M=r.events[r.events.length-1];return o=M&&M[1].type==="linePrefix"?M[2].sliceSerialize(M[1],!0).length:0,s=k,t.enter("codeFenced"),t.enter("codeFencedFence"),t.enter("codeFencedFenceSequence"),c(k)}function c(k){return k===s?(a++,t.consume(k),c):a<3?n(k):(t.exit("codeFencedFenceSequence"),tt(k)?it(t,d,"whitespace")(k):d(k))}function d(k){return k===null||$(k)?(t.exit("codeFencedFence"),r.interrupt?e(k):t.check(n0,v,w)(k)):(t.enter("codeFencedFenceInfo"),t.enter("chunkString",{contentType:"string"}),h(k))}function h(k){return k===null||$(k)?(t.exit("chunkString"),t.exit("codeFencedFenceInfo"),d(k)):tt(k)?(t.exit("chunkString"),t.exit("codeFencedFenceInfo"),it(t,p,"whitespace")(k)):k===96&&k===s?n(k):(t.consume(k),h)}function p(k){return k===null||$(k)?d(k):(t.enter("codeFencedFenceMeta"),t.enter("chunkString",{contentType:"string"}),m(k))}function m(k){return k===null||$(k)?(t.exit("chunkString"),t.exit("codeFencedFenceMeta"),d(k)):k===96&&k===s?n(k):(t.consume(k),m)}function v(k){return t.attempt(i,w,b)(k)}function b(k){return t.enter("lineEnding"),t.consume(k),t.exit("lineEnding"),f}function f(k){return o>0&&tt(k)?it(t,g,"linePrefix",o+1)(k):g(k)}function g(k){return k===null||$(k)?t.check(n0,v,w)(k):(t.enter("codeFlowValue"),y(k))}function y(k){return k===null||$(k)?(t.exit("codeFlowValue"),g(k)):(t.consume(k),y)}function w(k){return t.exit("codeFenced"),e(k)}function C(k,M,P){let R=0;return E;function E(F){return k.enter("lineEnding"),k.consume(F),k.exit("lineEnding"),L}function L(F){return k.enter("codeFencedFence"),tt(F)?it(k,N,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(F):N(F)}function N(F){return F===s?(k.enter("codeFencedFenceSequence"),B(F)):P(F)}function B(F){return F===s?(R++,k.consume(F),B):R>=a?(k.exit("codeFencedFenceSequence"),tt(F)?it(k,U,"whitespace")(F):U(F)):P(F)}function U(F){return F===null||$(F)?(k.exit("codeFencedFence"),M(F)):P(F)}}}function d4(t,e,n){let r=this;return i;function i(a){return a===null?n(a):(t.enter("lineEnding"),t.consume(a),t.exit("lineEnding"),o)}function o(a){return r.parser.lazy[r.now().line]?n(a):e(a)}}var Uc={name:"codeIndented",tokenize:p4},h4={tokenize:f4,partial:!0};function p4(t,e,n){let r=this;return i;function i(u){return t.enter("codeIndented"),it(t,o,"linePrefix",5)(u)}function o(u){let c=r.events[r.events.length-1];return c&&c[1].type==="linePrefix"&&c[2].sliceSerialize(c[1],!0).length>=4?a(u):n(u)}function a(u){return u===null?l(u):$(u)?t.attempt(h4,a,l)(u):(t.enter("codeFlowValue"),s(u))}function s(u){return u===null||$(u)?(t.exit("codeFlowValue"),a(u)):(t.consume(u),s)}function l(u){return t.exit("codeIndented"),e(u)}}function f4(t,e,n){let r=this;return i;function i(a){return r.parser.lazy[r.now().line]?n(a):$(a)?(t.enter("lineEnding"),t.consume(a),t.exit("lineEnding"),i):it(t,o,"linePrefix",5)(a)}function o(a){let s=r.events[r.events.length-1];return s&&s[1].type==="linePrefix"&&s[2].sliceSerialize(s[1],!0).length>=4?e(a):$(a)?i(a):n(a)}}var m4={name:"codeText",tokenize:y4,resolve:g4,previous:v4};function g4(t){let e=t.length-4,n=3,r,i;if((t[n][1].type==="lineEnding"||t[n][1].type==="space")&&(t[e][1].type==="lineEnding"||t[e][1].type==="space")){for(r=n;++r<e;)if(t[r][1].type==="codeTextData"){t[n][1].type="codeTextPadding",t[e][1].type="codeTextPadding",n+=2,e-=2;break}}for(r=n-1,e++;++r<=e;)i===void 0?r!==e&&t[r][1].type!=="lineEnding"&&(i=r):(r===e||t[r][1].type==="lineEnding")&&(t[i][1].type="codeTextData",r!==i+2&&(t[i][1].end=t[r-1][1].end,t.splice(i+2,r-i-2),e-=r-i-2,r=i+2),i=void 0);return t}function v4(t){return t!==96||this.events[this.events.length-1][1].type==="characterEscape"}function y4(t,e,n){let r=0,i,o;return a;function a(d){return t.enter("codeText"),t.enter("codeTextSequence"),s(d)}function s(d){return d===96?(t.consume(d),r++,s):(t.exit("codeTextSequence"),l(d))}function l(d){return d===null?n(d):d===32?(t.enter("space"),t.consume(d),t.exit("space"),l):d===96?(o=t.enter("codeTextSequence"),i=0,c(d)):$(d)?(t.enter("lineEnding"),t.consume(d),t.exit("lineEnding"),l):(t.enter("codeTextData"),u(d))}function u(d){return d===null||d===32||d===96||$(d)?(t.exit("codeTextData"),l(d)):(t.consume(d),u)}function c(d){return d===96?(t.consume(d),i++,c):i===r?(t.exit("codeTextSequence"),t.exit("codeText"),e(d)):(o.type="codeTextData",u(d))}}var Fh=class{constructor(e){this.left=e?[...e]:[],this.right=[]}get(e){if(e<0||e>=this.left.length+this.right.length)throw new RangeError("Cannot access index `"+e+"` in a splice buffer of size `"+(this.left.length+this.right.length)+"`");return e<this.left.length?this.left[e]:this.right[this.right.length-e+this.left.length-1]}get length(){return this.left.length+this.right.length}shift(){return this.setCursor(0),this.right.pop()}slice(e,n){let r=n??Number.POSITIVE_INFINITY;return r<this.left.length?this.left.slice(e,r):e>this.left.length?this.right.slice(this.right.length-r+this.left.length,this.right.length-e+this.left.length).reverse():this.left.slice(e).concat(this.right.slice(this.right.length-r+this.left.length).reverse())}splice(e,n,r){let i=n||0;this.setCursor(Math.trunc(e));let o=this.right.splice(this.right.length-i,Number.POSITIVE_INFINITY);return r&&Eo(this.left,r),o.reverse()}pop(){return this.setCursor(Number.POSITIVE_INFINITY),this.left.pop()}push(e){this.setCursor(Number.POSITIVE_INFINITY),this.left.push(e)}pushMany(e){this.setCursor(Number.POSITIVE_INFINITY),Eo(this.left,e)}unshift(e){this.setCursor(0),this.right.push(e)}unshiftMany(e){this.setCursor(0),Eo(this.right,e.reverse())}setCursor(e){if(!(e===this.left.length||e>this.left.length&&this.right.length===0||e<0&&this.left.length===0))if(e<this.left.length){let n=this.left.splice(e,Number.POSITIVE_INFINITY);Eo(this.right,n.reverse())}else{let n=this.right.splice(this.left.length+this.right.length-e,Number.POSITIVE_INFINITY);Eo(this.left,n.reverse())}}};function Eo(t,e){let n=0;if(e.length<1e4)t.push(...e);else for(;n<e.length;)t.push(...e.slice(n,n+1e4)),n+=1e4}function VS(t){let e={},n=-1,r,i,o,a,s,l,u,c=new Fh(t);for(;++n<c.length;){for(;n in e;)n=e[n];if(r=c.get(n),n&&r[1].type==="chunkFlow"&&c.get(n-1)[1].type==="listItemPrefix"&&(l=r[1]._tokenizer.events,o=0,o<l.length&&l[o][1].type==="lineEndingBlank"&&(o+=2),o<l.length&&l[o][1].type==="content"))for(;++o<l.length&&l[o][1].type!=="content";)l[o][1].type==="chunkText"&&(l[o][1]._isInFirstContentOfListItem=!0,o++);if(r[0]==="enter")r[1].contentType&&(Object.assign(e,b4(c,n)),n=e[n],u=!0);else if(r[1]._container){for(o=n,i=void 0;o--&&(a=c.get(o),a[1].type==="lineEnding"||a[1].type==="lineEndingBlank");)a[0]==="enter"&&(i&&(c.get(i)[1].type="lineEndingBlank"),a[1].type="lineEnding",i=o);i&&(r[1].end=Object.assign({},c.get(i)[1].start),s=c.slice(i,n),s.unshift(r),c.splice(i,n-i+1,s))}}return He(t,0,Number.POSITIVE_INFINITY,c.slice(0)),!u}function b4(t,e){let n=t.get(e)[1],r=t.get(e)[2],i=e-1,o=[],a=n._tokenizer||r.parser[n.contentType](n.start),s=a.events,l=[],u={},c,d,h=-1,p=n,m=0,v=0,b=[v];for(;p;){for(;t.get(++i)[1]!==p;);o.push(i),p._tokenizer||(c=r.sliceStream(p),p.next||c.push(null),d&&a.defineSkip(p.start),p._isInFirstContentOfListItem&&(a._gfmTasklistFirstContentOfListItem=!0),a.write(c),p._isInFirstContentOfListItem&&(a._gfmTasklistFirstContentOfListItem=void 0)),d=p,p=p.next}for(p=n;++h<s.length;)s[h][0]==="exit"&&s[h-1][0]==="enter"&&s[h][1].type===s[h-1][1].type&&s[h][1].start.line!==s[h][1].end.line&&(v=h+1,b.push(v),p._tokenizer=void 0,p.previous=void 0,p=p.next);for(a.events=[],p?(p._tokenizer=void 0,p.previous=void 0):b.pop(),h=b.length;h--;){let f=s.slice(b[h],b[h+1]),g=o.pop();l.push([g,g+f.length-1]),t.splice(g,2,f)}for(l.reverse(),h=-1;++h<l.length;)u[m+l[h][0]]=m+l[h][1],m+=l[h][1]-l[h][0]-1;return u}var x4={tokenize:S4,resolve:k4},w4={tokenize:T4,partial:!0};function k4(t){return VS(t),t}function S4(t,e){let n;return r;function r(s){return t.enter("content"),n=t.enter("chunkContent",{contentType:"content"}),i(s)}function i(s){return s===null?o(s):$(s)?t.check(w4,a,o)(s):(t.consume(s),i)}function o(s){return t.exit("chunkContent"),t.exit("content"),e(s)}function a(s){return t.consume(s),t.exit("chunkContent"),n.next=t.enter("chunkContent",{contentType:"content",previous:n}),n=n.next,i}}function T4(t,e,n){let r=this;return i;function i(a){return t.exit("chunkContent"),t.enter("lineEnding"),t.consume(a),t.exit("lineEnding"),it(t,o,"linePrefix")}function o(a){if(a===null||$(a))return n(a);let s=r.events[r.events.length-1];return!r.parser.constructs.disable.null.includes("codeIndented")&&s&&s[1].type==="linePrefix"&&s[2].sliceSerialize(s[1],!0).length>=4?e(a):t.interrupt(r.parser.constructs.flow,n,e)(a)}}function zS(t,e,n,r,i,o,a,s,l){let u=l||Number.POSITIVE_INFINITY,c=0;return d;function d(f){return f===60?(t.enter(r),t.enter(i),t.enter(o),t.consume(f),t.exit(o),h):f===null||f===32||f===41||Yl(f)?n(f):(t.enter(r),t.enter(a),t.enter(s),t.enter("chunkString",{contentType:"string"}),v(f))}function h(f){return f===62?(t.enter(o),t.consume(f),t.exit(o),t.exit(i),t.exit(r),e):(t.enter(s),t.enter("chunkString",{contentType:"string"}),p(f))}function p(f){return f===62?(t.exit("chunkString"),t.exit(s),h(f)):f===null||f===60||$(f)?n(f):(t.consume(f),f===92?m:p)}function m(f){return f===60||f===62||f===92?(t.consume(f),p):p(f)}function v(f){return!c&&(f===null||f===41||pt(f))?(t.exit("chunkString"),t.exit(s),t.exit(a),t.exit(r),e(f)):c<u&&f===40?(t.consume(f),c++,v):f===41?(t.consume(f),c--,v):f===null||f===32||f===40||Yl(f)?n(f):(t.consume(f),f===92?b:v)}function b(f){return f===40||f===41||f===92?(t.consume(f),v):v(f)}}function BS(t,e,n,r,i,o){let a=this,s=0,l;return u;function u(p){return t.enter(r),t.enter(i),t.consume(p),t.exit(i),t.enter(o),c}function c(p){return s>999||p===null||p===91||p===93&&!l||p===94&&!s&&"_hiddenFootnoteSupport"in a.parser.constructs?n(p):p===93?(t.exit(o),t.enter(i),t.consume(p),t.exit(i),t.exit(r),e):$(p)?(t.enter("lineEnding"),t.consume(p),t.exit("lineEnding"),c):(t.enter("chunkString",{contentType:"string"}),d(p))}function d(p){return p===null||p===91||p===93||$(p)||s++>999?(t.exit("chunkString"),c(p)):(t.consume(p),l||(l=!tt(p)),p===92?h:d)}function h(p){return p===91||p===92||p===93?(t.consume(p),s++,d):d(p)}}function US(t,e,n,r,i,o){let a;return s;function s(h){return h===34||h===39||h===40?(t.enter(r),t.enter(i),t.consume(h),t.exit(i),a=h===40?41:h,l):n(h)}function l(h){return h===a?(t.enter(i),t.consume(h),t.exit(i),t.exit(r),e):(t.enter(o),u(h))}function u(h){return h===a?(t.exit(o),l(a)):h===null?n(h):$(h)?(t.enter("lineEnding"),t.consume(h),t.exit("lineEnding"),it(t,u,"linePrefix")):(t.enter("chunkString",{contentType:"string"}),c(h))}function c(h){return h===a||h===null||$(h)?(t.exit("chunkString"),u(h)):(t.consume(h),h===92?d:c)}function d(h){return h===a||h===92?(t.consume(h),c):c(h)}}function Go(t,e){let n;return r;function r(i){return $(i)?(t.enter("lineEnding"),t.consume(i),t.exit("lineEnding"),n=!0,r):tt(i)?it(t,r,n?"linePrefix":"lineSuffix")(i):e(i)}}var E4={name:"definition",tokenize:P4},C4={tokenize:A4,partial:!0};function P4(t,e,n){let r=this,i;return o;function o(p){return t.enter("definition"),a(p)}function a(p){return BS.call(r,t,s,n,"definitionLabel","definitionLabelMarker","definitionLabelString")(p)}function s(p){return i=en(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)),p===58?(t.enter("definitionMarker"),t.consume(p),t.exit("definitionMarker"),l):n(p)}function l(p){return pt(p)?Go(t,u)(p):u(p)}function u(p){return zS(t,c,n,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString")(p)}function c(p){return t.attempt(C4,d,d)(p)}function d(p){return tt(p)?it(t,h,"whitespace")(p):h(p)}function h(p){return p===null||$(p)?(t.exit("definition"),r.parser.defined.push(i),e(p)):n(p)}}function A4(t,e,n){return r;function r(s){return pt(s)?Go(t,i)(s):n(s)}function i(s){return US(t,o,n,"definitionTitle","definitionTitleMarker","definitionTitleString")(s)}function o(s){return tt(s)?it(t,a,"whitespace")(s):a(s)}function a(s){return s===null||$(s)?e(s):n(s)}}var M4={name:"hardBreakEscape",tokenize:D4};function D4(t,e,n){return r;function r(o){return t.enter("hardBreakEscape"),t.consume(o),i}function i(o){return $(o)?(t.exit("hardBreakEscape"),e(o)):n(o)}}var R4={name:"headingAtx",tokenize:L4,resolve:I4};function I4(t,e){let n=t.length-2,r=3,i,o;return t[r][1].type==="whitespace"&&(r+=2),n-2>r&&t[n][1].type==="whitespace"&&(n-=2),t[n][1].type==="atxHeadingSequence"&&(r===n-1||n-4>r&&t[n-2][1].type==="whitespace")&&(n-=r+1===n?2:4),n>r&&(i={type:"atxHeadingText",start:t[r][1].start,end:t[n][1].end},o={type:"chunkText",start:t[r][1].start,end:t[n][1].end,contentType:"text"},He(t,r,n-r+1,[["enter",i,e],["enter",o,e],["exit",o,e],["exit",i,e]])),t}function L4(t,e,n){let r=0;return i;function i(c){return t.enter("atxHeading"),o(c)}function o(c){return t.enter("atxHeadingSequence"),a(c)}function a(c){return c===35&&r++<6?(t.consume(c),a):c===null||pt(c)?(t.exit("atxHeadingSequence"),s(c)):n(c)}function s(c){return c===35?(t.enter("atxHeadingSequence"),l(c)):c===null||$(c)?(t.exit("atxHeading"),e(c)):tt(c)?it(t,s,"whitespace")(c):(t.enter("atxHeadingText"),u(c))}function l(c){return c===35?(t.consume(c),l):(t.exit("atxHeadingSequence"),s(c))}function u(c){return c===null||c===35||pt(c)?(t.exit("atxHeadingText"),s(c)):(t.consume(c),u)}}var j4=["address","article","aside","base","basefont","blockquote","body","caption","center","col","colgroup","dd","details","dialog","dir","div","dl","dt","fieldset","figcaption","figure","footer","form","frame","frameset","h1","h2","h3","h4","h5","h6","head","header","hr","html","iframe","legend","li","link","main","menu","menuitem","nav","noframes","ol","optgroup","option","p","param","search","section","summary","table","tbody","td","tfoot","th","thead","title","tr","track","ul"],i0=["pre","script","style","textarea"],O4={name:"htmlFlow",tokenize:V4,resolveTo:F4,concrete:!0},_4={tokenize:B4,partial:!0},N4={tokenize:z4,partial:!0};function F4(t){let e=t.length;for(;e--&&!(t[e][0]==="enter"&&t[e][1].type==="htmlFlow"););return e>1&&t[e-2][1].type==="linePrefix"&&(t[e][1].start=t[e-2][1].start,t[e+1][1].start=t[e-2][1].start,t.splice(e-2,2)),t}function V4(t,e,n){let r=this,i,o,a,s,l;return u;function u(T){return c(T)}function c(T){return t.enter("htmlFlow"),t.enter("htmlFlowData"),t.consume(T),d}function d(T){return T===33?(t.consume(T),h):T===47?(t.consume(T),o=!0,v):T===63?(t.consume(T),i=3,r.interrupt?e:x):le(T)?(t.consume(T),a=String.fromCharCode(T),b):n(T)}function h(T){return T===45?(t.consume(T),i=2,p):T===91?(t.consume(T),i=5,s=0,m):le(T)?(t.consume(T),i=4,r.interrupt?e:x):n(T)}function p(T){return T===45?(t.consume(T),r.interrupt?e:x):n(T)}function m(T){let bt="CDATA[";return T===bt.charCodeAt(s++)?(t.consume(T),s===bt.length?r.interrupt?e:N:m):n(T)}function v(T){return le(T)?(t.consume(T),a=String.fromCharCode(T),b):n(T)}function b(T){if(T===null||T===47||T===62||pt(T)){let bt=T===47,Mt=a.toLowerCase();return!bt&&!o&&i0.includes(Mt)?(i=1,r.interrupt?e(T):N(T)):j4.includes(a.toLowerCase())?(i=6,bt?(t.consume(T),f):r.interrupt?e(T):N(T)):(i=7,r.interrupt&&!r.parser.lazy[r.now().line]?n(T):o?g(T):y(T))}return T===45||ee(T)?(t.consume(T),a+=String.fromCharCode(T),b):n(T)}function f(T){return T===62?(t.consume(T),r.interrupt?e:N):n(T)}function g(T){return tt(T)?(t.consume(T),g):E(T)}function y(T){return T===47?(t.consume(T),E):T===58||T===95||le(T)?(t.consume(T),w):tt(T)?(t.consume(T),y):E(T)}function w(T){return T===45||T===46||T===58||T===95||ee(T)?(t.consume(T),w):C(T)}function C(T){return T===61?(t.consume(T),k):tt(T)?(t.consume(T),C):y(T)}function k(T){return T===null||T===60||T===61||T===62||T===96?n(T):T===34||T===39?(t.consume(T),l=T,M):tt(T)?(t.consume(T),k):P(T)}function M(T){return T===l?(t.consume(T),l=null,R):T===null||$(T)?n(T):(t.consume(T),M)}function P(T){return T===null||T===34||T===39||T===47||T===60||T===61||T===62||T===96||pt(T)?C(T):(t.consume(T),P)}function R(T){return T===47||T===62||tt(T)?y(T):n(T)}function E(T){return T===62?(t.consume(T),L):n(T)}function L(T){return T===null||$(T)?N(T):tt(T)?(t.consume(T),L):n(T)}function N(T){return T===45&&i===2?(t.consume(T),K):T===60&&i===1?(t.consume(T),Q):T===62&&i===4?(t.consume(T),X):T===63&&i===3?(t.consume(T),x):T===93&&i===5?(t.consume(T),z):$(T)&&(i===6||i===7)?(t.exit("htmlFlowData"),t.check(_4,Z,B)(T)):T===null||$(T)?(t.exit("htmlFlowData"),B(T)):(t.consume(T),N)}function B(T){return t.check(N4,U,Z)(T)}function U(T){return t.enter("lineEnding"),t.consume(T),t.exit("lineEnding"),F}function F(T){return T===null||$(T)?B(T):(t.enter("htmlFlowData"),N(T))}function K(T){return T===45?(t.consume(T),x):N(T)}function Q(T){return T===47?(t.consume(T),a="",I):N(T)}function I(T){if(T===62){let bt=a.toLowerCase();return i0.includes(bt)?(t.consume(T),X):N(T)}return le(T)&&a.length<8?(t.consume(T),a+=String.fromCharCode(T),I):N(T)}function z(T){return T===93?(t.consume(T),x):N(T)}function x(T){return T===62?(t.consume(T),X):T===45&&i===2?(t.consume(T),x):N(T)}function X(T){return T===null||$(T)?(t.exit("htmlFlowData"),Z(T)):(t.consume(T),X)}function Z(T){return t.exit("htmlFlow"),e(T)}}function z4(t,e,n){let r=this;return i;function i(a){return $(a)?(t.enter("lineEnding"),t.consume(a),t.exit("lineEnding"),o):n(a)}function o(a){return r.parser.lazy[r.now().line]?n(a):e(a)}}function B4(t,e,n){return r;function r(i){return t.enter("lineEnding"),t.consume(i),t.exit("lineEnding"),t.attempt(Ja,e,n)}}var U4={name:"htmlText",tokenize:$4};function $4(t,e,n){let r=this,i,o,a;return s;function s(x){return t.enter("htmlText"),t.enter("htmlTextData"),t.consume(x),l}function l(x){return x===33?(t.consume(x),u):x===47?(t.consume(x),C):x===63?(t.consume(x),y):le(x)?(t.consume(x),P):n(x)}function u(x){return x===45?(t.consume(x),c):x===91?(t.consume(x),o=0,m):le(x)?(t.consume(x),g):n(x)}function c(x){return x===45?(t.consume(x),p):n(x)}function d(x){return x===null?n(x):x===45?(t.consume(x),h):$(x)?(a=d,Q(x)):(t.consume(x),d)}function h(x){return x===45?(t.consume(x),p):d(x)}function p(x){return x===62?K(x):x===45?h(x):d(x)}function m(x){let X="CDATA[";return x===X.charCodeAt(o++)?(t.consume(x),o===X.length?v:m):n(x)}function v(x){return x===null?n(x):x===93?(t.consume(x),b):$(x)?(a=v,Q(x)):(t.consume(x),v)}function b(x){return x===93?(t.consume(x),f):v(x)}function f(x){return x===62?K(x):x===93?(t.consume(x),f):v(x)}function g(x){return x===null||x===62?K(x):$(x)?(a=g,Q(x)):(t.consume(x),g)}function y(x){return x===null?n(x):x===63?(t.consume(x),w):$(x)?(a=y,Q(x)):(t.consume(x),y)}function w(x){return x===62?K(x):y(x)}function C(x){return le(x)?(t.consume(x),k):n(x)}function k(x){return x===45||ee(x)?(t.consume(x),k):M(x)}function M(x){return $(x)?(a=M,Q(x)):tt(x)?(t.consume(x),M):K(x)}function P(x){return x===45||ee(x)?(t.consume(x),P):x===47||x===62||pt(x)?R(x):n(x)}function R(x){return x===47?(t.consume(x),K):x===58||x===95||le(x)?(t.consume(x),E):$(x)?(a=R,Q(x)):tt(x)?(t.consume(x),R):K(x)}function E(x){return x===45||x===46||x===58||x===95||ee(x)?(t.consume(x),E):L(x)}function L(x){return x===61?(t.consume(x),N):$(x)?(a=L,Q(x)):tt(x)?(t.consume(x),L):R(x)}function N(x){return x===null||x===60||x===61||x===62||x===96?n(x):x===34||x===39?(t.consume(x),i=x,B):$(x)?(a=N,Q(x)):tt(x)?(t.consume(x),N):(t.consume(x),U)}function B(x){return x===i?(t.consume(x),i=void 0,F):x===null?n(x):$(x)?(a=B,Q(x)):(t.consume(x),B)}function U(x){return x===null||x===34||x===39||x===60||x===61||x===96?n(x):x===47||x===62||pt(x)?R(x):(t.consume(x),U)}function F(x){return x===47||x===62||pt(x)?R(x):n(x)}function K(x){return x===62?(t.consume(x),t.exit("htmlTextData"),t.exit("htmlText"),e):n(x)}function Q(x){return t.exit("htmlTextData"),t.enter("lineEnding"),t.consume(x),t.exit("lineEnding"),I}function I(x){return tt(x)?it(t,z,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(x):z(x)}function z(x){return t.enter("htmlTextData"),a(x)}}var pm={name:"labelEnd",tokenize:X4,resolveTo:K4,resolveAll:Y4},H4={tokenize:G4},W4={tokenize:Q4},q4={tokenize:J4};function Y4(t){let e=-1;for(;++e<t.length;){let n=t[e][1];(n.type==="labelImage"||n.type==="labelLink"||n.type==="labelEnd")&&(t.splice(e+1,n.type==="labelImage"?4:2),n.type="data",e++)}return t}function K4(t,e){let n=t.length,r=0,i,o,a,s;for(;n--;)if(i=t[n][1],o){if(i.type==="link"||i.type==="labelLink"&&i._inactive)break;t[n][0]==="enter"&&i.type==="labelLink"&&(i._inactive=!0)}else if(a){if(t[n][0]==="enter"&&(i.type==="labelImage"||i.type==="labelLink")&&!i._balanced&&(o=n,i.type!=="labelLink")){r=2;break}}else i.type==="labelEnd"&&(a=n);let l={type:t[o][1].type==="labelLink"?"link":"image",start:Object.assign({},t[o][1].start),end:Object.assign({},t[t.length-1][1].end)},u={type:"label",start:Object.assign({},t[o][1].start),end:Object.assign({},t[a][1].end)},c={type:"labelText",start:Object.assign({},t[o+r+2][1].end),end:Object.assign({},t[a-2][1].start)};return s=[["enter",l,e],["enter",u,e]],s=Be(s,t.slice(o+1,o+r+3)),s=Be(s,[["enter",c,e]]),s=Be(s,Vu(e.parser.constructs.insideSpan.null,t.slice(o+r+4,a-3),e)),s=Be(s,[["exit",c,e],t[a-2],t[a-1],["exit",u,e]]),s=Be(s,t.slice(a+1)),s=Be(s,[["exit",l,e]]),He(t,o,t.length,s),t}function X4(t,e,n){let r=this,i=r.events.length,o,a;for(;i--;)if((r.events[i][1].type==="labelImage"||r.events[i][1].type==="labelLink")&&!r.events[i][1]._balanced){o=r.events[i][1];break}return s;function s(h){return o?o._inactive?d(h):(a=r.parser.defined.includes(en(r.sliceSerialize({start:o.end,end:r.now()}))),t.enter("labelEnd"),t.enter("labelMarker"),t.consume(h),t.exit("labelMarker"),t.exit("labelEnd"),l):n(h)}function l(h){return h===40?t.attempt(H4,c,a?c:d)(h):h===91?t.attempt(W4,c,a?u:d)(h):a?c(h):d(h)}function u(h){return t.attempt(q4,c,d)(h)}function c(h){return e(h)}function d(h){return o._balanced=!0,n(h)}}function G4(t,e,n){return r;function r(d){return t.enter("resource"),t.enter("resourceMarker"),t.consume(d),t.exit("resourceMarker"),i}function i(d){return pt(d)?Go(t,o)(d):o(d)}function o(d){return d===41?c(d):zS(t,a,s,"resourceDestination","resourceDestinationLiteral","resourceDestinationLiteralMarker","resourceDestinationRaw","resourceDestinationString",32)(d)}function a(d){return pt(d)?Go(t,l)(d):c(d)}function s(d){return n(d)}function l(d){return d===34||d===39||d===40?US(t,u,n,"resourceTitle","resourceTitleMarker","resourceTitleString")(d):c(d)}function u(d){return pt(d)?Go(t,c)(d):c(d)}function c(d){return d===41?(t.enter("resourceMarker"),t.consume(d),t.exit("resourceMarker"),t.exit("resource"),e):n(d)}}function Q4(t,e,n){let r=this;return i;function i(s){return BS.call(r,t,o,a,"reference","referenceMarker","referenceString")(s)}function o(s){return r.parser.defined.includes(en(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)))?e(s):n(s)}function a(s){return n(s)}}function J4(t,e,n){return r;function r(o){return t.enter("reference"),t.enter("referenceMarker"),t.consume(o),t.exit("referenceMarker"),i}function i(o){return o===93?(t.enter("referenceMarker"),t.consume(o),t.exit("referenceMarker"),t.exit("reference"),e):n(o)}}var Z4={name:"labelStartImage",tokenize:tO,resolveAll:pm.resolveAll};function tO(t,e,n){let r=this;return i;function i(s){return t.enter("labelImage"),t.enter("labelImageMarker"),t.consume(s),t.exit("labelImageMarker"),o}function o(s){return s===91?(t.enter("labelMarker"),t.consume(s),t.exit("labelMarker"),t.exit("labelImage"),a):n(s)}function a(s){return s===94&&"_hiddenFootnoteSupport"in r.parser.constructs?n(s):e(s)}}var eO={name:"labelStartLink",tokenize:nO,resolveAll:pm.resolveAll};function nO(t,e,n){let r=this;return i;function i(a){return t.enter("labelLink"),t.enter("labelMarker"),t.consume(a),t.exit("labelMarker"),t.exit("labelLink"),o}function o(a){return a===94&&"_hiddenFootnoteSupport"in r.parser.constructs?n(a):e(a)}}var $c={name:"lineEnding",tokenize:rO};function rO(t,e){return n;function n(r){return t.enter("lineEnding"),t.consume(r),t.exit("lineEnding"),it(t,e,"linePrefix")}}var il={name:"thematicBreak",tokenize:iO};function iO(t,e,n){let r=0,i;return o;function o(u){return t.enter("thematicBreak"),a(u)}function a(u){return i=u,s(u)}function s(u){return u===i?(t.enter("thematicBreakSequence"),l(u)):r>=3&&(u===null||$(u))?(t.exit("thematicBreak"),e(u)):n(u)}function l(u){return u===i?(t.consume(u),r++,l):(t.exit("thematicBreakSequence"),tt(u)?it(t,s,"whitespace")(u):s(u))}}var pe={name:"list",tokenize:sO,continuation:{tokenize:lO},exit:cO},oO={tokenize:dO,partial:!0},aO={tokenize:uO,partial:!0};function sO(t,e,n){let r=this,i=r.events[r.events.length-1],o=i&&i[1].type==="linePrefix"?i[2].sliceSerialize(i[1],!0).length:0,a=0;return s;function s(p){let m=r.containerState.type||(p===42||p===43||p===45?"listUnordered":"listOrdered");if(m==="listUnordered"?!r.containerState.marker||p===r.containerState.marker:_h(p)){if(r.containerState.type||(r.containerState.type=m,t.enter(m,{_container:!0})),m==="listUnordered")return t.enter("listItemPrefix"),p===42||p===45?t.check(il,n,u)(p):u(p);if(!r.interrupt||p===49)return t.enter("listItemPrefix"),t.enter("listItemValue"),l(p)}return n(p)}function l(p){return _h(p)&&++a<10?(t.consume(p),l):(!r.interrupt||a<2)&&(r.containerState.marker?p===r.containerState.marker:p===41||p===46)?(t.exit("listItemValue"),u(p)):n(p)}function u(p){return t.enter("listItemMarker"),t.consume(p),t.exit("listItemMarker"),r.containerState.marker=r.containerState.marker||p,t.check(Ja,r.interrupt?n:c,t.attempt(oO,h,d))}function c(p){return r.containerState.initialBlankLine=!0,o++,h(p)}function d(p){return tt(p)?(t.enter("listItemPrefixWhitespace"),t.consume(p),t.exit("listItemPrefixWhitespace"),h):n(p)}function h(p){return r.containerState.size=o+r.sliceSerialize(t.exit("listItemPrefix"),!0).length,e(p)}}function lO(t,e,n){let r=this;return r.containerState._closeFlow=void 0,t.check(Ja,i,o);function i(s){return r.containerState.furtherBlankLines=r.containerState.furtherBlankLines||r.containerState.initialBlankLine,it(t,e,"listItemIndent",r.containerState.size+1)(s)}function o(s){return r.containerState.furtherBlankLines||!tt(s)?(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,a(s)):(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,t.attempt(aO,e,a)(s))}function a(s){return r.containerState._closeFlow=!0,r.interrupt=void 0,it(t,t.attempt(pe,e,n),"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(s)}}function uO(t,e,n){let r=this;return it(t,i,"listItemIndent",r.containerState.size+1);function i(o){let a=r.events[r.events.length-1];return a&&a[1].type==="listItemIndent"&&a[2].sliceSerialize(a[1],!0).length===r.containerState.size?e(o):n(o)}}function cO(t){t.exit(this.containerState.type)}function dO(t,e,n){let r=this;return it(t,i,"listItemPrefixWhitespace",r.parser.constructs.disable.null.includes("codeIndented")?void 0:5);function i(o){let a=r.events[r.events.length-1];return!tt(o)&&a&&a[1].type==="listItemPrefixWhitespace"?e(o):n(o)}}var o0={name:"setextUnderline",tokenize:pO,resolveTo:hO};function hO(t,e){let n=t.length,r,i,o;for(;n--;)if(t[n][0]==="enter"){if(t[n][1].type==="content"){r=n;break}t[n][1].type==="paragraph"&&(i=n)}else t[n][1].type==="content"&&t.splice(n,1),!o&&t[n][1].type==="definition"&&(o=n);let a={type:"setextHeading",start:Object.assign({},t[i][1].start),end:Object.assign({},t[t.length-1][1].end)};return t[i][1].type="setextHeadingText",o?(t.splice(i,0,["enter",a,e]),t.splice(o+1,0,["exit",t[r][1],e]),t[r][1].end=Object.assign({},t[o][1].end)):t[r][1]=a,t.push(["exit",a,e]),t}function pO(t,e,n){let r=this,i;return o;function o(u){let c=r.events.length,d;for(;c--;)if(r.events[c][1].type!=="lineEnding"&&r.events[c][1].type!=="linePrefix"&&r.events[c][1].type!=="content"){d=r.events[c][1].type==="paragraph";break}return!r.parser.lazy[r.now().line]&&(r.interrupt||d)?(t.enter("setextHeadingLine"),i=u,a(u)):n(u)}function a(u){return t.enter("setextHeadingLineSequence"),s(u)}function s(u){return u===i?(t.consume(u),s):(t.exit("setextHeadingLineSequence"),tt(u)?it(t,l,"lineSuffix")(u):l(u))}function l(u){return u===null||$(u)?(t.exit("setextHeadingLine"),e(u)):n(u)}}var fO={tokenize:mO};function mO(t){let e=this,n=t.attempt(Ja,r,t.attempt(this.parser.constructs.flowInitial,i,it(t,t.attempt(this.parser.constructs.flow,i,t.attempt(x4,i)),"linePrefix")));return n;function r(o){if(o===null){t.consume(o);return}return t.enter("lineEndingBlank"),t.consume(o),t.exit("lineEndingBlank"),e.currentConstruct=void 0,n}function i(o){if(o===null){t.consume(o);return}return t.enter("lineEnding"),t.consume(o),t.exit("lineEnding"),e.currentConstruct=void 0,n}}var gO={resolveAll:HS()},vO=$S("string"),yO=$S("text");function $S(t){return{tokenize:e,resolveAll:HS(t==="text"?bO:void 0)};function e(n){let r=this,i=this.parser.constructs[t],o=n.attempt(i,a,s);return a;function a(c){return u(c)?o(c):s(c)}function s(c){if(c===null){n.consume(c);return}return n.enter("data"),n.consume(c),l}function l(c){return u(c)?(n.exit("data"),o(c)):(n.consume(c),l)}function u(c){if(c===null)return!0;let d=i[c],h=-1;if(d)for(;++h<d.length;){let p=d[h];if(!p.previous||p.previous.call(r,r.previous))return!0}return!1}}}function HS(t){return e;function e(n,r){let i=-1,o;for(;++i<=n.length;)o===void 0?n[i]&&n[i][1].type==="data"&&(o=i,i++):(!n[i]||n[i][1].type!=="data")&&(i!==o+2&&(n[o][1].end=n[i-1][1].end,n.splice(o+2,i-o-2),i=o+2),o=void 0);return t?t(n,r):n}}function bO(t,e){let n=0;for(;++n<=t.length;)if((n===t.length||t[n][1].type==="lineEnding")&&t[n-1][1].type==="data"){let r=t[n-1][1],i=e.sliceStream(r),o=i.length,a=-1,s=0,l;for(;o--;){let u=i[o];if(typeof u=="string"){for(a=u.length;u.charCodeAt(a-1)===32;)s++,a--;if(a)break;a=-1}else if(u===-2)l=!0,s++;else if(u!==-1){o++;break}}if(s){let u={type:n===t.length||l||s<2?"lineSuffix":"hardBreakTrailing",start:{line:r.end.line,column:r.end.column-s,offset:r.end.offset-s,_index:r.start._index+o,_bufferIndex:o?a:r.start._bufferIndex+a},end:Object.assign({},r.end)};r.end=Object.assign({},u.start),r.start.offset===r.end.offset?Object.assign(r,u):(t.splice(n,0,["enter",u,e],["exit",u,e]),n+=2)}n++}return t}function xO(t,e,n){let r=Object.assign(n?Object.assign({},n):{line:1,column:1,offset:0},{_index:0,_bufferIndex:-1}),i={},o=[],a=[],s=[],l={consume:g,enter:y,exit:w,attempt:M(C),check:M(k),interrupt:M(k,{interrupt:!0})},u={previous:null,code:null,containerState:{},events:[],parser:t,sliceStream:p,sliceSerialize:h,now:m,defineSkip:v,write:d},c=e.tokenize.call(u,l);return e.resolveAll&&o.push(e),u;function d(L){return a=Be(a,L),b(),a[a.length-1]!==null?[]:(P(e,0),u.events=Vu(o,u.events,u),u.events)}function h(L,N){return kO(p(L),N)}function p(L){return wO(a,L)}function m(){let{line:L,column:N,offset:B,_index:U,_bufferIndex:F}=r;return{line:L,column:N,offset:B,_index:U,_bufferIndex:F}}function v(L){i[L.line]=L.column,E()}function b(){let L;for(;r._index<a.length;){let N=a[r._index];if(typeof N=="string")for(L=r._index,r._bufferIndex<0&&(r._bufferIndex=0);r._index===L&&r._bufferIndex<N.length;)f(N.charCodeAt(r._bufferIndex));else f(N)}}function f(L){c=c(L)}function g(L){$(L)?(r.line++,r.column=1,r.offset+=L===-3?2:1,E()):L!==-1&&(r.column++,r.offset++),r._bufferIndex<0?r._index++:(r._bufferIndex++,r._bufferIndex===a[r._index].length&&(r._bufferIndex=-1,r._index++)),u.previous=L}function y(L,N){let B=N||{};return B.type=L,B.start=m(),u.events.push(["enter",B,u]),s.push(B),B}function w(L){let N=s.pop();return N.end=m(),u.events.push(["exit",N,u]),N}function C(L,N){P(L,N.from)}function k(L,N){N.restore()}function M(L,N){return B;function B(U,F,K){let Q,I,z,x;return Array.isArray(U)?Z(U):"tokenize"in U?Z([U]):X(U);function X(at){return ae;function ae(J){let kt=J!==null&&at[J],lt=J!==null&&at.null,St=[...Array.isArray(kt)?kt:kt?[kt]:[],...Array.isArray(lt)?lt:lt?[lt]:[]];return Z(St)(J)}}function Z(at){return Q=at,I=0,at.length===0?K:T(at[I])}function T(at){return ae;function ae(J){return x=R(),z=at,at.partial||(u.currentConstruct=at),at.name&&u.parser.constructs.disable.null.includes(at.name)?Mt():at.tokenize.call(N?Object.assign(Object.create(u),N):u,l,bt,Mt)(J)}}function bt(at){return L(z,x),F}function Mt(at){return x.restore(),++I<Q.length?T(Q[I]):K}}}function P(L,N){L.resolveAll&&!o.includes(L)&&o.push(L),L.resolve&&He(u.events,N,u.events.length-N,L.resolve(u.events.slice(N),u)),L.resolveTo&&(u.events=L.resolveTo(u.events,u))}function R(){let L=m(),N=u.previous,B=u.currentConstruct,U=u.events.length,F=Array.from(s);return{restore:K,from:U};function K(){r=L,u.previous=N,u.currentConstruct=B,u.events.length=U,s=F,E()}}function E(){r.line in i&&r.column<2&&(r.column=i[r.line],r.offset+=i[r.line]-1)}}function wO(t,e){let n=e.start._index,r=e.start._bufferIndex,i=e.end._index,o=e.end._bufferIndex,a;if(n===i)a=[t[n].slice(r,o)];else{if(a=t.slice(n,i),r>-1){let s=a[0];typeof s=="string"?a[0]=s.slice(r):a.shift()}o>0&&a.push(t[i].slice(0,o))}return a}function kO(t,e){let n=-1,r=[],i;for(;++n<t.length;){let o=t[n],a;if(typeof o=="string")a=o;else switch(o){case-5:{a="\r";break}case-4:{a=`
`;break}case-3:{a=`\r
`;break}case-2:{a=e?" ":"	";break}case-1:{if(!e&&i)continue;a=" ";break}default:a=String.fromCharCode(o)}i=o===-2,r.push(a)}return r.join("")}var SO={42:pe,43:pe,45:pe,48:pe,49:pe,50:pe,51:pe,52:pe,53:pe,54:pe,55:pe,56:pe,57:pe,62:_S},TO={91:E4},EO={[-2]:Uc,[-1]:Uc,32:Uc},CO={35:R4,42:il,45:[o0,il],60:O4,61:o0,95:il,96:r0,126:r0},PO={38:FS,92:NS},AO={[-5]:$c,[-4]:$c,[-3]:$c,33:Z4,38:FS,42:Nh,60:[n4,U4],91:eO,92:[M4,NS],93:pm,95:Nh,96:m4},MO={null:[Nh,gO]},DO={null:[42,95]},RO={null:[]},IO=Object.freeze(Object.defineProperty({__proto__:null,attentionMarkers:DO,contentInitial:TO,disable:RO,document:SO,flow:CO,flowInitial:EO,insideSpan:MO,string:PO,text:AO},Symbol.toStringTag,{value:"Module"}));function LO(t){let e=jS([IO,...(t||{}).extensions||[]]),n={defined:[],lazy:{},constructs:e,content:r(Xj),document:r(Qj),flow:r(fO),string:r(vO),text:r(yO)};return n;function r(i){return o;function o(a){return xO(n,i,a)}}}function jO(t){for(;!VS(t););return t}var a0=/[\0\t\n\r]/g;function OO(){let t=1,e="",n=!0,r;return i;function i(o,a,s){let l=[],u,c,d,h,p;for(o=e+(typeof o=="string"?o.toString():new TextDecoder(a||void 0).decode(o)),d=0,e="",n&&(o.charCodeAt(0)===65279&&d++,n=void 0);d<o.length;){if(a0.lastIndex=d,u=a0.exec(o),h=u&&u.index!==void 0?u.index:o.length,p=o.charCodeAt(h),!u){e=o.slice(d);break}if(p===10&&d===h&&r)l.push(-3),r=void 0;else switch(r&&(l.push(-5),r=void 0),d<h&&(l.push(o.slice(d,h)),t+=h-d),p){case 0:{l.push(65533),t++;break}case 9:{for(c=Math.ceil(t/4)*4,l.push(-2);t++<c;)l.push(-1);break}case 10:{l.push(-4),t=1;break}default:r=!0,t=1}d=h+1}return s&&(r&&l.push(-5),e&&l.push(e),l.push(null)),l}}var _O=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function NO(t){return t.replace(_O,FO)}function FO(t,e,n){if(e)return e;if(n.charCodeAt(0)===35){let r=n.charCodeAt(1),i=r===120||r===88;return OS(n.slice(i?2:1),i?16:10)}return hm(n)||t}var WS={}.hasOwnProperty;function VO(t,e,n){return typeof e!="string"&&(n=e,e=void 0),zO(n)(jO(LO(n).document().write(OO()(t,e,!0))))}function zO(t){let e={transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:o(Vt),autolinkProtocol:R,autolinkEmail:R,atxHeading:o(rt),blockQuote:o(lt),characterEscape:R,characterReference:R,codeFenced:o(St),codeFencedFenceInfo:a,codeFencedFenceMeta:a,codeIndented:o(St,a),codeText:o(Y,a),codeTextData:R,data:R,codeFlowValue:R,definition:o(nt),definitionDestinationString:a,definitionLabelString:a,definitionTitleString:a,emphasis:o(xt),hardBreakEscape:o(je),hardBreakTrailing:o(je),htmlFlow:o(rn,a),htmlFlowData:R,htmlText:o(rn,a),htmlTextData:R,image:o(Kt),label:a,link:o(Vt),listItem:o(rs),listItemValue:h,listOrdered:o(Ye,d),listUnordered:o(Ye),paragraph:o(is),reference:T,referenceString:a,resourceDestinationString:a,resourceTitleString:a,setextHeading:o(rt),strong:o(os),thematicBreak:o(Ke)},exit:{atxHeading:l(),atxHeadingSequence:C,autolink:l(),autolinkEmail:kt,autolinkProtocol:J,blockQuote:l(),characterEscapeValue:E,characterReferenceMarkerHexadecimal:Mt,characterReferenceMarkerNumeric:Mt,characterReferenceValue:at,characterReference:ae,codeFenced:l(b),codeFencedFence:v,codeFencedFenceInfo:p,codeFencedFenceMeta:m,codeFlowValue:E,codeIndented:l(f),codeText:l(F),codeTextData:E,data:E,definition:l(),definitionDestinationString:w,definitionLabelString:g,definitionTitleString:y,emphasis:l(),hardBreakEscape:l(N),hardBreakTrailing:l(N),htmlFlow:l(B),htmlFlowData:E,htmlText:l(U),htmlTextData:E,image:l(Q),label:z,labelText:I,lineEnding:L,link:l(K),listItem:l(),listOrdered:l(),listUnordered:l(),paragraph:l(),referenceString:bt,resourceDestinationString:x,resourceTitleString:X,resource:Z,setextHeading:l(P),setextHeadingLineSequence:M,setextHeadingText:k,strong:l(),thematicBreak:l()}};qS(e,(t||{}).mdastExtensions||[]);let n={};return r;function r(D){let _={type:"root",children:[]},H={stack:[_],tokenStack:[],config:e,enter:s,exit:u,buffer:a,resume:c,data:n},ht=[],gt=-1;for(;++gt<D.length;)if(D[gt][1].type==="listOrdered"||D[gt][1].type==="listUnordered")if(D[gt][0]==="enter")ht.push(gt);else{let on=ht.pop();gt=i(D,on,gt)}for(gt=-1;++gt<D.length;){let on=e[D[gt][0]];WS.call(on,D[gt][1].type)&&on[D[gt][1].type].call(Object.assign({sliceSerialize:D[gt][2].sliceSerialize},H),D[gt][1])}if(H.tokenStack.length>0){let on=H.tokenStack[H.tokenStack.length-1];(on[1]||s0).call(H,void 0,on[0])}for(_.position={start:Yn(D.length>0?D[0][1].start:{line:1,column:1,offset:0}),end:Yn(D.length>0?D[D.length-2][1].end:{line:1,column:1,offset:0})},gt=-1;++gt<e.transforms.length;)_=e.transforms[gt](_)||_;return _}function i(D,_,H){let ht=_-1,gt=-1,on=!1,ai,xn,po,fo;for(;++ht<=H;){let ke=D[ht];switch(ke[1].type){case"listUnordered":case"listOrdered":case"blockQuote":{ke[0]==="enter"?gt++:gt--,fo=void 0;break}case"lineEndingBlank":{ke[0]==="enter"&&(ai&&!fo&&!gt&&!po&&(po=ht),fo=void 0);break}case"linePrefix":case"listItemValue":case"listItemMarker":case"listItemPrefix":case"listItemPrefixWhitespace":break;default:fo=void 0}if(!gt&&ke[0]==="enter"&&ke[1].type==="listItemPrefix"||gt===-1&&ke[0]==="exit"&&(ke[1].type==="listUnordered"||ke[1].type==="listOrdered")){if(ai){let si=ht;for(xn=void 0;si--;){let wn=D[si];if(wn[1].type==="lineEnding"||wn[1].type==="lineEndingBlank"){if(wn[0]==="exit")continue;xn&&(D[xn][1].type="lineEndingBlank",on=!0),wn[1].type="lineEnding",xn=si}else if(!(wn[1].type==="linePrefix"||wn[1].type==="blockQuotePrefix"||wn[1].type==="blockQuotePrefixWhitespace"||wn[1].type==="blockQuoteMarker"||wn[1].type==="listItemIndent"))break}po&&(!xn||po<xn)&&(ai._spread=!0),ai.end=Object.assign({},xn?D[xn][1].start:ke[1].end),D.splice(xn||ht,0,["exit",ai,ke[2]]),ht++,H++}if(ke[1].type==="listItemPrefix"){let si={type:"listItem",_spread:!1,start:Object.assign({},ke[1].start),end:void 0};ai=si,D.splice(ht,0,["enter",si,ke[2]]),ht++,H++,po=void 0,fo=!0}}}return D[_][1]._spread=on,H}function o(D,_){return H;function H(ht){s.call(this,D(ht),ht),_&&_.call(this,ht)}}function a(){this.stack.push({type:"fragment",children:[]})}function s(D,_,H){this.stack[this.stack.length-1].children.push(D),this.stack.push(D),this.tokenStack.push([_,H||void 0]),D.position={start:Yn(_.start),end:void 0}}function l(D){return _;function _(H){D&&D.call(this,H),u.call(this,H)}}function u(D,_){let H=this.stack.pop(),ht=this.tokenStack.pop();if(ht)ht[0].type!==D.type&&(_?_.call(this,D,ht[0]):(ht[1]||s0).call(this,D,ht[0]));else throw new Error("Cannot close `"+D.type+"` ("+Xo({start:D.start,end:D.end})+"): it\u2019s not open");H.position.end=Yn(D.end)}function c(){return dm(this.stack.pop())}function d(){this.data.expectingFirstListItemValue=!0}function h(D){if(this.data.expectingFirstListItemValue){let _=this.stack[this.stack.length-2];_.start=Number.parseInt(this.sliceSerialize(D),10),this.data.expectingFirstListItemValue=void 0}}function p(){let D=this.resume(),_=this.stack[this.stack.length-1];_.lang=D}function m(){let D=this.resume(),_=this.stack[this.stack.length-1];_.meta=D}function v(){this.data.flowCodeInside||(this.buffer(),this.data.flowCodeInside=!0)}function b(){let D=this.resume(),_=this.stack[this.stack.length-1];_.value=D.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,""),this.data.flowCodeInside=void 0}function f(){let D=this.resume(),_=this.stack[this.stack.length-1];_.value=D.replace(/(\r?\n|\r)$/g,"")}function g(D){let _=this.resume(),H=this.stack[this.stack.length-1];H.label=_,H.identifier=en(this.sliceSerialize(D)).toLowerCase()}function y(){let D=this.resume(),_=this.stack[this.stack.length-1];_.title=D}function w(){let D=this.resume(),_=this.stack[this.stack.length-1];_.url=D}function C(D){let _=this.stack[this.stack.length-1];if(!_.depth){let H=this.sliceSerialize(D).length;_.depth=H}}function k(){this.data.setextHeadingSlurpLineEnding=!0}function M(D){let _=this.stack[this.stack.length-1];_.depth=this.sliceSerialize(D).codePointAt(0)===61?1:2}function P(){this.data.setextHeadingSlurpLineEnding=void 0}function R(D){let _=this.stack[this.stack.length-1].children,H=_[_.length-1];(!H||H.type!=="text")&&(H=he(),H.position={start:Yn(D.start),end:void 0},_.push(H)),this.stack.push(H)}function E(D){let _=this.stack.pop();_.value+=this.sliceSerialize(D),_.position.end=Yn(D.end)}function L(D){let _=this.stack[this.stack.length-1];if(this.data.atHardBreak){let H=_.children[_.children.length-1];H.position.end=Yn(D.end),this.data.atHardBreak=void 0;return}!this.data.setextHeadingSlurpLineEnding&&e.canContainEols.includes(_.type)&&(R.call(this,D),E.call(this,D))}function N(){this.data.atHardBreak=!0}function B(){let D=this.resume(),_=this.stack[this.stack.length-1];_.value=D}function U(){let D=this.resume(),_=this.stack[this.stack.length-1];_.value=D}function F(){let D=this.resume(),_=this.stack[this.stack.length-1];_.value=D}function K(){let D=this.stack[this.stack.length-1];if(this.data.inReference){let _=this.data.referenceType||"shortcut";D.type+="Reference",D.referenceType=_,delete D.url,delete D.title}else delete D.identifier,delete D.label;this.data.referenceType=void 0}function Q(){let D=this.stack[this.stack.length-1];if(this.data.inReference){let _=this.data.referenceType||"shortcut";D.type+="Reference",D.referenceType=_,delete D.url,delete D.title}else delete D.identifier,delete D.label;this.data.referenceType=void 0}function I(D){let _=this.sliceSerialize(D),H=this.stack[this.stack.length-2];H.label=NO(_),H.identifier=en(_).toLowerCase()}function z(){let D=this.stack[this.stack.length-1],_=this.resume(),H=this.stack[this.stack.length-1];if(this.data.inReference=!0,H.type==="link"){let ht=D.children;H.children=ht}else H.alt=_}function x(){let D=this.resume(),_=this.stack[this.stack.length-1];_.url=D}function X(){let D=this.resume(),_=this.stack[this.stack.length-1];_.title=D}function Z(){this.data.inReference=void 0}function T(){this.data.referenceType="collapsed"}function bt(D){let _=this.resume(),H=this.stack[this.stack.length-1];H.label=_,H.identifier=en(this.sliceSerialize(D)).toLowerCase(),this.data.referenceType="full"}function Mt(D){this.data.characterReferenceType=D.type}function at(D){let _=this.sliceSerialize(D),H=this.data.characterReferenceType,ht;H?(ht=OS(_,H==="characterReferenceMarkerNumeric"?10:16),this.data.characterReferenceType=void 0):ht=hm(_);let gt=this.stack[this.stack.length-1];gt.value+=ht}function ae(D){let _=this.stack.pop();_.position.end=Yn(D.end)}function J(D){E.call(this,D);let _=this.stack[this.stack.length-1];_.url=this.sliceSerialize(D)}function kt(D){E.call(this,D);let _=this.stack[this.stack.length-1];_.url="mailto:"+this.sliceSerialize(D)}function lt(){return{type:"blockquote",children:[]}}function St(){return{type:"code",lang:null,meta:null,value:""}}function Y(){return{type:"inlineCode",value:""}}function nt(){return{type:"definition",identifier:"",label:null,title:null,url:""}}function xt(){return{type:"emphasis",children:[]}}function rt(){return{type:"heading",depth:0,children:[]}}function je(){return{type:"break"}}function rn(){return{type:"html",value:""}}function Kt(){return{type:"image",title:null,url:"",alt:null}}function Vt(){return{type:"link",title:null,url:"",children:[]}}function Ye(D){return{type:"list",ordered:D.type==="listOrdered",start:null,spread:D._spread,children:[]}}function rs(D){return{type:"listItem",spread:D._spread,checked:null,children:[]}}function is(){return{type:"paragraph",children:[]}}function os(){return{type:"strong",children:[]}}function he(){return{type:"text",value:""}}function Ke(){return{type:"thematicBreak"}}}function Yn(t){return{line:t.line,column:t.column,offset:t.offset}}function qS(t,e){let n=-1;for(;++n<e.length;){let r=e[n];Array.isArray(r)?qS(t,r):BO(t,r)}}function BO(t,e){let n;for(n in e)if(WS.call(e,n))switch(n){case"canContainEols":{let r=e[n];r&&t[n].push(...r);break}case"transforms":{let r=e[n];r&&t[n].push(...r);break}case"enter":case"exit":{let r=e[n];r&&Object.assign(t[n],r);break}}}function s0(t,e){throw t?new Error("Cannot close `"+t.type+"` ("+Xo({start:t.start,end:t.end})+"): a different token (`"+e.type+"`, "+Xo({start:e.start,end:e.end})+") is open"):new Error("Cannot close document, a token (`"+e.type+"`, "+Xo({start:e.start,end:e.end})+") is still open")}function UO(t){let e=this;e.parser=n;function n(r){return VO(r,{...e.data("settings"),...t,extensions:e.data("micromarkExtensions")||[],mdastExtensions:e.data("fromMarkdownExtensions")||[]})}}function $O(t,e){let n={type:"element",tagName:"blockquote",properties:{},children:t.wrap(t.all(e),!0)};return t.patch(e,n),t.applyData(e,n)}function HO(t,e){let n={type:"element",tagName:"br",properties:{},children:[]};return t.patch(e,n),[t.applyData(e,n),{type:"text",value:`
`}]}function WO(t,e){let n=e.value?e.value+`
`:"",r={};e.lang&&(r.className=["language-"+e.lang]);let i={type:"element",tagName:"code",properties:r,children:[{type:"text",value:n}]};return e.meta&&(i.data={meta:e.meta}),t.patch(e,i),i=t.applyData(e,i),i={type:"element",tagName:"pre",properties:{},children:[i]},t.patch(e,i),i}function qO(t,e){let n={type:"element",tagName:"del",properties:{},children:t.all(e)};return t.patch(e,n),t.applyData(e,n)}function YO(t,e){let n={type:"element",tagName:"em",properties:{},children:t.all(e)};return t.patch(e,n),t.applyData(e,n)}function KO(t,e){let n=typeof t.options.clobberPrefix=="string"?t.options.clobberPrefix:"user-content-",r=String(e.identifier).toUpperCase(),i=co(r.toLowerCase()),o=t.footnoteOrder.indexOf(r),a,s=t.footnoteCounts.get(r);s===void 0?(s=0,t.footnoteOrder.push(r),a=t.footnoteOrder.length):a=o+1,s+=1,t.footnoteCounts.set(r,s);let l={type:"element",tagName:"a",properties:{href:"#"+n+"fn-"+i,id:n+"fnref-"+i+(s>1?"-"+s:""),dataFootnoteRef:!0,ariaDescribedBy:["footnote-label"]},children:[{type:"text",value:String(a)}]};t.patch(e,l);let u={type:"element",tagName:"sup",properties:{},children:[l]};return t.patch(e,u),t.applyData(e,u)}function XO(t,e){let n={type:"element",tagName:"h"+e.depth,properties:{},children:t.all(e)};return t.patch(e,n),t.applyData(e,n)}function GO(t,e){if(t.options.allowDangerousHtml){let n={type:"raw",value:e.value};return t.patch(e,n),t.applyData(e,n)}}function YS(t,e){let n=e.referenceType,r="]";if(n==="collapsed"?r+="[]":n==="full"&&(r+="["+(e.label||e.identifier)+"]"),e.type==="imageReference")return[{type:"text",value:"!["+e.alt+r}];let i=t.all(e),o=i[0];o&&o.type==="text"?o.value="["+o.value:i.unshift({type:"text",value:"["});let a=i[i.length-1];return a&&a.type==="text"?a.value+=r:i.push({type:"text",value:r}),i}function QO(t,e){let n=String(e.identifier).toUpperCase(),r=t.definitionById.get(n);if(!r)return YS(t,e);let i={src:co(r.url||""),alt:e.alt};r.title!==null&&r.title!==void 0&&(i.title=r.title);let o={type:"element",tagName:"img",properties:i,children:[]};return t.patch(e,o),t.applyData(e,o)}function JO(t,e){let n={src:co(e.url)};e.alt!==null&&e.alt!==void 0&&(n.alt=e.alt),e.title!==null&&e.title!==void 0&&(n.title=e.title);let r={type:"element",tagName:"img",properties:n,children:[]};return t.patch(e,r),t.applyData(e,r)}function ZO(t,e){let n={type:"text",value:e.value.replace(/\r?\n|\r/g," ")};t.patch(e,n);let r={type:"element",tagName:"code",properties:{},children:[n]};return t.patch(e,r),t.applyData(e,r)}function t_(t,e){let n=String(e.identifier).toUpperCase(),r=t.definitionById.get(n);if(!r)return YS(t,e);let i={href:co(r.url||"")};r.title!==null&&r.title!==void 0&&(i.title=r.title);let o={type:"element",tagName:"a",properties:i,children:t.all(e)};return t.patch(e,o),t.applyData(e,o)}function e_(t,e){let n={href:co(e.url)};e.title!==null&&e.title!==void 0&&(n.title=e.title);let r={type:"element",tagName:"a",properties:n,children:t.all(e)};return t.patch(e,r),t.applyData(e,r)}function n_(t,e,n){let r=t.all(e),i=n?r_(n):KS(e),o={},a=[];if(typeof e.checked=="boolean"){let c=r[0],d;c&&c.type==="element"&&c.tagName==="p"?d=c:(d={type:"element",tagName:"p",properties:{},children:[]},r.unshift(d)),d.children.length>0&&d.children.unshift({type:"text",value:" "}),d.children.unshift({type:"element",tagName:"input",properties:{type:"checkbox",checked:e.checked,disabled:!0},children:[]}),o.className=["task-list-item"]}let s=-1;for(;++s<r.length;){let c=r[s];(i||s!==0||c.type!=="element"||c.tagName!=="p")&&a.push({type:"text",value:`
`}),c.type==="element"&&c.tagName==="p"&&!i?a.push(...c.children):a.push(c)}let l=r[r.length-1];l&&(i||l.type!=="element"||l.tagName!=="p")&&a.push({type:"text",value:`
`});let u={type:"element",tagName:"li",properties:o,children:a};return t.patch(e,u),t.applyData(e,u)}function r_(t){let e=!1;if(t.type==="list"){e=t.spread||!1;let n=t.children,r=-1;for(;!e&&++r<n.length;)e=KS(n[r])}return e}function KS(t){return t.spread??t.children.length>1}function i_(t,e){let n={},r=t.all(e),i=-1;for(typeof e.start=="number"&&e.start!==1&&(n.start=e.start);++i<r.length;){let a=r[i];if(a.type==="element"&&a.tagName==="li"&&a.properties&&Array.isArray(a.properties.className)&&a.properties.className.includes("task-list-item")){n.className=["contains-task-list"];break}}let o={type:"element",tagName:e.ordered?"ol":"ul",properties:n,children:t.wrap(r,!0)};return t.patch(e,o),t.applyData(e,o)}function o_(t,e){let n={type:"element",tagName:"p",properties:{},children:t.all(e)};return t.patch(e,n),t.applyData(e,n)}function a_(t,e){let n={type:"root",children:t.wrap(t.all(e))};return t.patch(e,n),t.applyData(e,n)}function s_(t,e){let n={type:"element",tagName:"strong",properties:{},children:t.all(e)};return t.patch(e,n),t.applyData(e,n)}function l_(t,e){let n=t.all(e),r=n.shift(),i=[];if(r){let a={type:"element",tagName:"thead",properties:{},children:t.wrap([r],!0)};t.patch(e.children[0],a),i.push(a)}if(n.length>0){let a={type:"element",tagName:"tbody",properties:{},children:t.wrap(n,!0)},s=sm(e.children[1]),l=PS(e.children[e.children.length-1]);s&&l&&(a.position={start:s,end:l}),i.push(a)}let o={type:"element",tagName:"table",properties:{},children:t.wrap(i,!0)};return t.patch(e,o),t.applyData(e,o)}function u_(t,e,n){let r=n?n.children:void 0,i=(r?r.indexOf(e):1)===0?"th":"td",o=n&&n.type==="table"?n.align:void 0,a=o?o.length:e.children.length,s=-1,l=[];for(;++s<a;){let c=e.children[s],d={},h=o?o[s]:void 0;h&&(d.align=h);let p={type:"element",tagName:i,properties:d,children:[]};c&&(p.children=t.all(c),t.patch(c,p),p=t.applyData(c,p)),l.push(p)}let u={type:"element",tagName:"tr",properties:{},children:t.wrap(l,!0)};return t.patch(e,u),t.applyData(e,u)}function c_(t,e){let n={type:"element",tagName:"td",properties:{},children:t.all(e)};return t.patch(e,n),t.applyData(e,n)}var l0=9,u0=32;function d_(t){let e=String(t),n=/\r?\n|\r/g,r=n.exec(e),i=0,o=[];for(;r;)o.push(c0(e.slice(i,r.index),i>0,!0),r[0]),i=r.index+r[0].length,r=n.exec(e);return o.push(c0(e.slice(i),i>0,!1)),o.join("")}function c0(t,e,n){let r=0,i=t.length;if(e){let o=t.codePointAt(r);for(;o===l0||o===u0;)r++,o=t.codePointAt(r)}if(n){let o=t.codePointAt(i-1);for(;o===l0||o===u0;)i--,o=t.codePointAt(i-1)}return i>r?t.slice(r,i):""}function h_(t,e){let n={type:"text",value:d_(String(e.value))};return t.patch(e,n),t.applyData(e,n)}function p_(t,e){let n={type:"element",tagName:"hr",properties:{},children:[]};return t.patch(e,n),t.applyData(e,n)}var f_={blockquote:$O,break:HO,code:WO,delete:qO,emphasis:YO,footnoteReference:KO,heading:XO,html:GO,imageReference:QO,image:JO,inlineCode:ZO,linkReference:t_,link:e_,listItem:n_,list:i_,paragraph:o_,root:a_,strong:s_,table:l_,tableCell:c_,tableRow:u_,text:h_,thematicBreak:p_,toml:Ls,yaml:Ls,definition:Ls,footnoteDefinition:Ls};function Ls(){}var XS=-1,zu=0,Kl=1,Xl=2,fm=3,mm=4,gm=5,vm=6,GS=7,QS=8,d0=typeof self=="object"?self:globalThis,m_=(t,e)=>{let n=(i,o)=>(t.set(o,i),i),r=i=>{if(t.has(i))return t.get(i);let[o,a]=e[i];switch(o){case zu:case XS:return n(a,i);case Kl:{let s=n([],i);for(let l of a)s.push(r(l));return s}case Xl:{let s=n({},i);for(let[l,u]of a)s[r(l)]=r(u);return s}case fm:return n(new Date(a),i);case mm:{let{source:s,flags:l}=a;return n(new RegExp(s,l),i)}case gm:{let s=n(new Map,i);for(let[l,u]of a)s.set(r(l),r(u));return s}case vm:{let s=n(new Set,i);for(let l of a)s.add(r(l));return s}case GS:{let{name:s,message:l}=a;return n(new d0[s](l),i)}case QS:return n(BigInt(a),i);case"BigInt":return n(Object(BigInt(a)),i)}return n(new d0[o](a),i)};return r},h0=t=>m_(new Map,t)(0),ci="",{toString:g_}={},{keys:v_}=Object,Co=t=>{let e=typeof t;if(e!=="object"||!t)return[zu,e];let n=g_.call(t).slice(8,-1);switch(n){case"Array":return[Kl,ci];case"Object":return[Xl,ci];case"Date":return[fm,ci];case"RegExp":return[mm,ci];case"Map":return[gm,ci];case"Set":return[vm,ci]}return n.includes("Array")?[Kl,n]:n.includes("Error")?[GS,n]:[Xl,n]},js=([t,e])=>t===zu&&(e==="function"||e==="symbol"),y_=(t,e,n,r)=>{let i=(a,s)=>{let l=r.push(a)-1;return n.set(s,l),l},o=a=>{if(n.has(a))return n.get(a);let[s,l]=Co(a);switch(s){case zu:{let c=a;switch(l){case"bigint":s=QS,c=a.toString();break;case"function":case"symbol":if(t)throw new TypeError("unable to serialize "+l);c=null;break;case"undefined":return i([XS],a)}return i([s,c],a)}case Kl:{if(l)return i([l,[...a]],a);let c=[],d=i([s,c],a);for(let h of a)c.push(o(h));return d}case Xl:{if(l)switch(l){case"BigInt":return i([l,a.toString()],a);case"Boolean":case"Number":case"String":return i([l,a.valueOf()],a)}if(e&&"toJSON"in a)return o(a.toJSON());let c=[],d=i([s,c],a);for(let h of v_(a))(t||!js(Co(a[h])))&&c.push([o(h),o(a[h])]);return d}case fm:return i([s,a.toISOString()],a);case mm:{let{source:c,flags:d}=a;return i([s,{source:c,flags:d}],a)}case gm:{let c=[],d=i([s,c],a);for(let[h,p]of a)(t||!(js(Co(h))||js(Co(p))))&&c.push([o(h),o(p)]);return d}case vm:{let c=[],d=i([s,c],a);for(let h of a)(t||!js(Co(h)))&&c.push(o(h));return d}}let{message:u}=a;return i([s,{name:l,message:u}],a)};return o},p0=(t,{json:e,lossy:n}={})=>{let r=[];return y_(!(e||n),!!e,new Map,r)(t),r},Wr=typeof structuredClone=="function"?(t,e)=>e&&("json"in e||"lossy"in e)?h0(p0(t,e)):structuredClone(t):(t,e)=>h0(p0(t,e));function b_(t,e){let n=[{type:"text",value:"\u21A9"}];return e>1&&n.push({type:"element",tagName:"sup",properties:{},children:[{type:"text",value:String(e)}]}),n}function x_(t,e){return"Back to reference "+(t+1)+(e>1?"-"+e:"")}function w_(t){let e=typeof t.options.clobberPrefix=="string"?t.options.clobberPrefix:"user-content-",n=t.options.footnoteBackContent||b_,r=t.options.footnoteBackLabel||x_,i=t.options.footnoteLabel||"Footnotes",o=t.options.footnoteLabelTagName||"h2",a=t.options.footnoteLabelProperties||{className:["sr-only"]},s=[],l=-1;for(;++l<t.footnoteOrder.length;){let u=t.footnoteById.get(t.footnoteOrder[l]);if(!u)continue;let c=t.all(u),d=String(u.identifier).toUpperCase(),h=co(d.toLowerCase()),p=0,m=[],v=t.footnoteCounts.get(d);for(;v!==void 0&&++p<=v;){m.length>0&&m.push({type:"text",value:" "});let g=typeof n=="string"?n:n(l,p);typeof g=="string"&&(g={type:"text",value:g}),m.push({type:"element",tagName:"a",properties:{href:"#"+e+"fnref-"+h+(p>1?"-"+p:""),dataFootnoteBackref:"",ariaLabel:typeof r=="string"?r:r(l,p),className:["data-footnote-backref"]},children:Array.isArray(g)?g:[g]})}let b=c[c.length-1];if(b&&b.type==="element"&&b.tagName==="p"){let g=b.children[b.children.length-1];g&&g.type==="text"?g.value+=" ":b.children.push({type:"text",value:" "}),b.children.push(...m)}else c.push(...m);let f={type:"element",tagName:"li",properties:{id:e+"fn-"+h},children:t.wrap(c,!0)};t.patch(u,f),s.push(f)}if(s.length!==0)return{type:"element",tagName:"section",properties:{dataFootnotes:!0,className:["footnotes"]},children:[{type:"element",tagName:o,properties:{...Wr(a),id:"footnote-label"},children:[{type:"text",value:i}]},{type:"text",value:`
`},{type:"element",tagName:"ol",properties:{},children:t.wrap(s,!0)},{type:"text",value:`
`}]}}var Bu=function(t){if(t==null)return E_;if(typeof t=="function")return Uu(t);if(typeof t=="object")return Array.isArray(t)?k_(t):S_(t);if(typeof t=="string")return T_(t);throw new Error("Expected function, string, or object as test")};function k_(t){let e=[],n=-1;for(;++n<t.length;)e[n]=Bu(t[n]);return Uu(r);function r(...i){let o=-1;for(;++o<e.length;)if(e[o].apply(this,i))return!0;return!1}}function S_(t){let e=t;return Uu(n);function n(r){let i=r,o;for(o in t)if(i[o]!==e[o])return!1;return!0}}function T_(t){return Uu(e);function e(n){return n&&n.type===t}}function Uu(t){return e;function e(n,r,i){return!!(C_(n)&&t.call(this,n,typeof r=="number"?r:void 0,i||void 0))}}function E_(){return!0}function C_(t){return t!==null&&typeof t=="object"&&"type"in t}var JS=[],P_=!0,Vh=!1,A_="skip";function ZS(t,e,n,r){let i;typeof e=="function"&&typeof n!="function"?(r=n,n=e):i=e;let o=Bu(i),a=r?-1:1;s(t,void 0,[])();function s(l,u,c){let d=l&&typeof l=="object"?l:{};if(typeof d.type=="string"){let p=typeof d.tagName=="string"?d.tagName:typeof d.name=="string"?d.name:void 0;Object.defineProperty(h,"name",{value:"node ("+(l.type+(p?"<"+p+">":""))+")"})}return h;function h(){let p=JS,m,v,b;if((!e||o(l,u,c[c.length-1]||void 0))&&(p=M_(n(l,c)),p[0]===Vh))return p;if("children"in l&&l.children){let f=l;if(f.children&&p[0]!==A_)for(v=(r?f.children.length:-1)+a,b=c.concat(f);v>-1&&v<f.children.length;){let g=f.children[v];if(m=s(g,v,b)(),m[0]===Vh)return m;v=typeof m[1]=="number"?m[1]:v+a}}return p}}}function M_(t){return Array.isArray(t)?t:typeof t=="number"?[P_,t]:t==null?JS:[t]}function $u(t,e,n,r){let i,o,a;typeof e=="function"&&typeof n!="function"?(o=void 0,a=e,i=n):(o=e,a=n,i=r),ZS(t,o,s,i);function s(l,u){let c=u[u.length-1],d=c?c.children.indexOf(l):void 0;return a(l,d,c)}}var zh={}.hasOwnProperty,D_={};function R_(t,e){let n=e||D_,r=new Map,i=new Map,o=new Map,a={...f_,...n.handlers},s={all:u,applyData:L_,definitionById:r,footnoteById:i,footnoteCounts:o,footnoteOrder:[],handlers:a,one:l,options:n,patch:I_,wrap:O_};return $u(t,function(c){if(c.type==="definition"||c.type==="footnoteDefinition"){let d=c.type==="definition"?r:i,h=String(c.identifier).toUpperCase();d.has(h)||d.set(h,c)}}),s;function l(c,d){let h=c.type,p=s.handlers[h];if(zh.call(s.handlers,h)&&p)return p(s,c,d);if(s.options.passThrough&&s.options.passThrough.includes(h)){if("children"in c){let{children:m,...v}=c,b=Wr(v);return b.children=s.all(c),b}return Wr(c)}return(s.options.unknownHandler||j_)(s,c,d)}function u(c){let d=[];if("children"in c){let h=c.children,p=-1;for(;++p<h.length;){let m=s.one(h[p],c);if(m){if(p&&h[p-1].type==="break"&&(!Array.isArray(m)&&m.type==="text"&&(m.value=f0(m.value)),!Array.isArray(m)&&m.type==="element")){let v=m.children[0];v&&v.type==="text"&&(v.value=f0(v.value))}Array.isArray(m)?d.push(...m):d.push(m)}}}return d}}function I_(t,e){t.position&&(e.position=bj(t))}function L_(t,e){let n=e;if(t&&t.data){let r=t.data.hName,i=t.data.hChildren,o=t.data.hProperties;if(typeof r=="string")if(n.type==="element")n.tagName=r;else{let a="children"in n?n.children:[n];n={type:"element",tagName:r,properties:{},children:a}}n.type==="element"&&o&&Object.assign(n.properties,Wr(o)),"children"in n&&n.children&&i!==null&&i!==void 0&&(n.children=i)}return n}function j_(t,e){let n=e.data||{},r="value"in e&&!(zh.call(n,"hProperties")||zh.call(n,"hChildren"))?{type:"text",value:e.value}:{type:"element",tagName:"div",properties:{},children:t.all(e)};return t.patch(e,r),t.applyData(e,r)}function O_(t,e){let n=[],r=-1;for(e&&n.push({type:"text",value:`
`});++r<t.length;)r&&n.push({type:"text",value:`
`}),n.push(t[r]);return e&&t.length>0&&n.push({type:"text",value:`
`}),n}function f0(t){let e=0,n=t.charCodeAt(e);for(;n===9||n===32;)e++,n=t.charCodeAt(e);return t.slice(e)}function m0(t,e){let n=R_(t,e),r=n.one(t,void 0),i=w_(n),o=Array.isArray(r)?{type:"root",children:r}:r||{type:"root",children:[]};return i&&o.children.push({type:"text",value:`
`},i),o}function __(t,e){return t&&"run"in t?async function(n,r){let i=m0(n,{file:r,...e});await t.run(i,r)}:function(n,r){return m0(n,{file:r,...t||e})}}function g0(t){if(t)throw t}var ol=Object.prototype.hasOwnProperty,tT=Object.prototype.toString,v0=Object.defineProperty,y0=Object.getOwnPropertyDescriptor,b0=function(t){return typeof Array.isArray=="function"?Array.isArray(t):tT.call(t)==="[object Array]"},x0=function(t){if(!t||tT.call(t)!=="[object Object]")return!1;var e=ol.call(t,"constructor"),n=t.constructor&&t.constructor.prototype&&ol.call(t.constructor.prototype,"isPrototypeOf");if(t.constructor&&!e&&!n)return!1;var r;for(r in t);return typeof r>"u"||ol.call(t,r)},w0=function(t,e){v0&&e.name==="__proto__"?v0(t,e.name,{enumerable:!0,configurable:!0,value:e.newValue,writable:!0}):t[e.name]=e.newValue},k0=function(t,e){if(e==="__proto__")if(ol.call(t,e)){if(y0)return y0(t,e).value}else return;return t[e]},N_=function t(){var e,n,r,i,o,a,s=arguments[0],l=1,u=arguments.length,c=!1;for(typeof s=="boolean"&&(c=s,s=arguments[1]||{},l=2),(s==null||typeof s!="object"&&typeof s!="function")&&(s={});l<u;++l)if(e=arguments[l],e!=null)for(n in e)r=k0(s,n),i=k0(e,n),s!==i&&(c&&i&&(x0(i)||(o=b0(i)))?(o?(o=!1,a=r&&b0(r)?r:[]):a=r&&x0(r)?r:{},w0(s,{name:n,newValue:t(c,a,i)})):typeof i<"u"&&w0(s,{name:n,newValue:i}));return s},Hc=du(N_);function Bh(t){if(typeof t!="object"||t===null)return!1;let e=Object.getPrototypeOf(t);return(e===null||e===Object.prototype||Object.getPrototypeOf(e)===null)&&!(Symbol.toStringTag in t)&&!(Symbol.iterator in t)}function F_(){let t=[],e={run:n,use:r};return e;function n(...i){let o=-1,a=i.pop();if(typeof a!="function")throw new TypeError("Expected function as last argument, not "+a);s(null,...i);function s(l,...u){let c=t[++o],d=-1;if(l){a(l);return}for(;++d<i.length;)(u[d]===null||u[d]===void 0)&&(u[d]=i[d]);i=u,c?V_(c,s)(...u):a(null,...u)}}function r(i){if(typeof i!="function")throw new TypeError("Expected `middelware` to be a function, not "+i);return t.push(i),e}}function V_(t,e){let n;return r;function r(...a){let s=t.length>a.length,l;s&&a.push(i);try{l=t.apply(this,a)}catch(u){let c=u;if(s&&n)throw c;return i(c)}s||(l&&l.then&&typeof l.then=="function"?l.then(o,i):l instanceof Error?i(l):o(l))}function i(a,...s){n||(n=!0,e(a,...s))}function o(a){i(null,a)}}var ln={basename:z_,dirname:B_,extname:U_,join:$_,sep:"/"};function z_(t,e){if(e!==void 0&&typeof e!="string")throw new TypeError('"ext" argument must be a string');Za(t);let n=0,r=-1,i=t.length,o;if(e===void 0||e.length===0||e.length>t.length){for(;i--;)if(t.codePointAt(i)===47){if(o){n=i+1;break}}else r<0&&(o=!0,r=i+1);return r<0?"":t.slice(n,r)}if(e===t)return"";let a=-1,s=e.length-1;for(;i--;)if(t.codePointAt(i)===47){if(o){n=i+1;break}}else a<0&&(o=!0,a=i+1),s>-1&&(t.codePointAt(i)===e.codePointAt(s--)?s<0&&(r=i):(s=-1,r=a));return n===r?r=a:r<0&&(r=t.length),t.slice(n,r)}function B_(t){if(Za(t),t.length===0)return".";let e=-1,n=t.length,r;for(;--n;)if(t.codePointAt(n)===47){if(r){e=n;break}}else r||(r=!0);return e<0?t.codePointAt(0)===47?"/":".":e===1&&t.codePointAt(0)===47?"//":t.slice(0,e)}function U_(t){Za(t);let e=t.length,n=-1,r=0,i=-1,o=0,a;for(;e--;){let s=t.codePointAt(e);if(s===47){if(a){r=e+1;break}continue}n<0&&(a=!0,n=e+1),s===46?i<0?i=e:o!==1&&(o=1):i>-1&&(o=-1)}return i<0||n<0||o===0||o===1&&i===n-1&&i===r+1?"":t.slice(i,n)}function $_(...t){let e=-1,n;for(;++e<t.length;)Za(t[e]),t[e]&&(n=n===void 0?t[e]:n+"/"+t[e]);return n===void 0?".":H_(n)}function H_(t){Za(t);let e=t.codePointAt(0)===47,n=W_(t,!e);return n.length===0&&!e&&(n="."),n.length>0&&t.codePointAt(t.length-1)===47&&(n+="/"),e?"/"+n:n}function W_(t,e){let n="",r=0,i=-1,o=0,a=-1,s,l;for(;++a<=t.length;){if(a<t.length)s=t.codePointAt(a);else{if(s===47)break;s=47}if(s===47){if(!(i===a-1||o===1))if(i!==a-1&&o===2){if(n.length<2||r!==2||n.codePointAt(n.length-1)!==46||n.codePointAt(n.length-2)!==46){if(n.length>2){if(l=n.lastIndexOf("/"),l!==n.length-1){l<0?(n="",r=0):(n=n.slice(0,l),r=n.length-1-n.lastIndexOf("/")),i=a,o=0;continue}}else if(n.length>0){n="",r=0,i=a,o=0;continue}}e&&(n=n.length>0?n+"/..":"..",r=2)}else n.length>0?n+="/"+t.slice(i+1,a):n=t.slice(i+1,a),r=a-i-1;i=a,o=0}else s===46&&o>-1?o++:o=-1}return n}function Za(t){if(typeof t!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(t))}var q_={cwd:Y_};function Y_(){return"/"}function Uh(t){return!!(t!==null&&typeof t=="object"&&"href"in t&&t.href&&"protocol"in t&&t.protocol&&t.auth===void 0)}function K_(t){if(typeof t=="string")t=new URL(t);else if(!Uh(t)){let e=new TypeError('The "path" argument must be of type string or an instance of URL. Received `'+t+"`");throw e.code="ERR_INVALID_ARG_TYPE",e}if(t.protocol!=="file:"){let e=new TypeError("The URL must be of scheme file");throw e.code="ERR_INVALID_URL_SCHEME",e}return X_(t)}function X_(t){if(t.hostname!==""){let r=new TypeError('File URL host must be "localhost" or empty on darwin');throw r.code="ERR_INVALID_FILE_URL_HOST",r}let e=t.pathname,n=-1;for(;++n<e.length;)if(e.codePointAt(n)===37&&e.codePointAt(n+1)===50){let r=e.codePointAt(n+2);if(r===70||r===102){let i=new TypeError("File URL path must not include encoded / characters");throw i.code="ERR_INVALID_FILE_URL_PATH",i}}return decodeURIComponent(e)}var Wc=["history","path","basename","stem","extname","dirname"],Gl=class{constructor(e){let n;e?Uh(e)?n={path:e}:typeof e=="string"||G_(e)?n={value:e}:n=e:n={},this.cwd="cwd"in n?"":q_.cwd(),this.data={},this.history=[],this.messages=[],this.value,this.map,this.result,this.stored;let r=-1;for(;++r<Wc.length;){let o=Wc[r];o in n&&n[o]!==void 0&&n[o]!==null&&(this[o]=o==="history"?[...n[o]]:n[o])}let i;for(i in n)Wc.includes(i)||(this[i]=n[i])}get basename(){return typeof this.path=="string"?ln.basename(this.path):void 0}set basename(e){Yc(e,"basename"),qc(e,"basename"),this.path=ln.join(this.dirname||"",e)}get dirname(){return typeof this.path=="string"?ln.dirname(this.path):void 0}set dirname(e){S0(this.basename,"dirname"),this.path=ln.join(e||"",this.basename)}get extname(){return typeof this.path=="string"?ln.extname(this.path):void 0}set extname(e){if(qc(e,"extname"),S0(this.dirname,"extname"),e){if(e.codePointAt(0)!==46)throw new Error("`extname` must start with `.`");if(e.includes(".",1))throw new Error("`extname` cannot contain multiple dots")}this.path=ln.join(this.dirname,this.stem+(e||""))}get path(){return this.history[this.history.length-1]}set path(e){Uh(e)&&(e=K_(e)),Yc(e,"path"),this.path!==e&&this.history.push(e)}get stem(){return typeof this.path=="string"?ln.basename(this.path,this.extname):void 0}set stem(e){Yc(e,"stem"),qc(e,"stem"),this.path=ln.join(this.dirname||"",e+(this.extname||""))}fail(e,n,r){let i=this.message(e,n,r);throw i.fatal=!0,i}info(e,n,r){let i=this.message(e,n,r);return i.fatal=void 0,i}message(e,n,r){let i=new Ut(e,n,r);return this.path&&(i.name=this.path+":"+i.name,i.file=this.path),i.fatal=!1,this.messages.push(i),i}toString(e){return this.value===void 0?"":typeof this.value=="string"?this.value:new TextDecoder(e||void 0).decode(this.value)}};function qc(t,e){if(t&&t.includes(ln.sep))throw new Error("`"+e+"` cannot be a path: did not expect `"+ln.sep+"`")}function Yc(t,e){if(!t)throw new Error("`"+e+"` cannot be empty")}function S0(t,e){if(!t)throw new Error("Setting `"+e+"` requires `path` to be set too")}function G_(t){return!!(t&&typeof t=="object"&&"byteLength"in t&&"byteOffset"in t)}var Q_=function(t){let e=this.constructor.prototype,n=e[t],r=function(){return n.apply(r,arguments)};return Object.setPrototypeOf(r,e),r},J_={}.hasOwnProperty,$h=class t extends Q_{constructor(){super("copy"),this.Compiler=void 0,this.Parser=void 0,this.attachers=[],this.compiler=void 0,this.freezeIndex=-1,this.frozen=void 0,this.namespace={},this.parser=void 0,this.transformers=F_()}copy(){let e=new t,n=-1;for(;++n<this.attachers.length;){let r=this.attachers[n];e.use(...r)}return e.data(Hc(!0,{},this.namespace)),e}data(e,n){return typeof e=="string"?arguments.length===2?(Gc("data",this.frozen),this.namespace[e]=n,this):J_.call(this.namespace,e)&&this.namespace[e]||void 0:e?(Gc("data",this.frozen),this.namespace=e,this):this.namespace}freeze(){if(this.frozen)return this;let e=this;for(;++this.freezeIndex<this.attachers.length;){let[n,...r]=this.attachers[this.freezeIndex];if(r[0]===!1)continue;r[0]===!0&&(r[0]=void 0);let i=n.call(e,...r);typeof i=="function"&&this.transformers.use(i)}return this.frozen=!0,this.freezeIndex=Number.POSITIVE_INFINITY,this}parse(e){this.freeze();let n=Os(e),r=this.parser||this.Parser;return Kc("parse",r),r(String(n),n)}process(e,n){let r=this;return this.freeze(),Kc("process",this.parser||this.Parser),Xc("process",this.compiler||this.Compiler),n?i(void 0,n):new Promise(i);function i(o,a){let s=Os(e),l=r.parse(s);r.run(l,s,function(c,d,h){if(c||!d||!h)return u(c);let p=d,m=r.stringify(p,h);eN(m)?h.value=m:h.result=m,u(c,h)});function u(c,d){c||!d?a(c):o?o(d):n(void 0,d)}}}processSync(e){let n=!1,r;return this.freeze(),Kc("processSync",this.parser||this.Parser),Xc("processSync",this.compiler||this.Compiler),this.process(e,i),E0("processSync","process",n),r;function i(o,a){n=!0,g0(o),r=a}}run(e,n,r){T0(e),this.freeze();let i=this.transformers;return!r&&typeof n=="function"&&(r=n,n=void 0),r?o(void 0,r):new Promise(o);function o(a,s){let l=Os(n);i.run(e,l,u);function u(c,d,h){let p=d||e;c?s(c):a?a(p):r(void 0,p,h)}}}runSync(e,n){let r=!1,i;return this.run(e,n,o),E0("runSync","run",r),i;function o(a,s){g0(a),i=s,r=!0}}stringify(e,n){this.freeze();let r=Os(n),i=this.compiler||this.Compiler;return Xc("stringify",i),T0(e),i(e,r)}use(e,...n){let r=this.attachers,i=this.namespace;if(Gc("use",this.frozen),e!=null)if(typeof e=="function")l(e,n);else if(typeof e=="object")Array.isArray(e)?s(e):a(e);else throw new TypeError("Expected usable value, not `"+e+"`");return this;function o(u){if(typeof u=="function")l(u,[]);else if(typeof u=="object")if(Array.isArray(u)){let[c,...d]=u;l(c,d)}else a(u);else throw new TypeError("Expected usable value, not `"+u+"`")}function a(u){if(!("plugins"in u)&&!("settings"in u))throw new Error("Expected usable value but received an empty preset, which is probably a mistake: presets typically come with `plugins` and sometimes with `settings`, but this has neither");s(u.plugins),u.settings&&(i.settings=Hc(!0,i.settings,u.settings))}function s(u){let c=-1;if(u!=null)if(Array.isArray(u))for(;++c<u.length;){let d=u[c];o(d)}else throw new TypeError("Expected a list of plugins, not `"+u+"`")}function l(u,c){let d=-1,h=-1;for(;++d<r.length;)if(r[d][0]===u){h=d;break}if(h===-1)r.push([u,...c]);else if(c.length>0){let[p,...m]=c,v=r[h][1];Bh(v)&&Bh(p)&&(p=Hc(!0,v,p)),r[h]=[u,p,...m]}}}},Z_=new $h().freeze();function Kc(t,e){if(typeof e!="function")throw new TypeError("Cannot `"+t+"` without `parser`")}function Xc(t,e){if(typeof e!="function")throw new TypeError("Cannot `"+t+"` without `compiler`")}function Gc(t,e){if(e)throw new Error("Cannot call `"+t+"` on a frozen processor.\nCreate a new processor first, by calling it: use `processor()` instead of `processor`.")}function T0(t){if(!Bh(t)||typeof t.type!="string")throw new TypeError("Expected node, got `"+t+"`")}function E0(t,e,n){if(!n)throw new Error("`"+t+"` finished async. Use `"+e+"` instead")}function Os(t){return tN(t)?t:new Gl(t)}function tN(t){return!!(t&&typeof t=="object"&&"message"in t&&"messages"in t)}function eN(t){return typeof t=="string"||nN(t)}function nN(t){return!!(t&&typeof t=="object"&&"byteLength"in t&&"byteOffset"in t)}var rN="https://github.com/remarkjs/react-markdown/blob/main/changelog.md",C0=[],P0={allowDangerousHtml:!0},iN=/^(https?|ircs?|mailto|xmpp)$/i,oN=[{from:"astPlugins",id:"remove-buggy-html-in-markdown-parser"},{from:"allowDangerousHtml",id:"remove-buggy-html-in-markdown-parser"},{from:"allowNode",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"allowElement"},{from:"allowedTypes",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"allowedElements"},{from:"disallowedTypes",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"disallowedElements"},{from:"escapeHtml",id:"remove-buggy-html-in-markdown-parser"},{from:"includeElementIndex",id:"#remove-includeelementindex"},{from:"includeNodeIndex",id:"change-includenodeindex-to-includeelementindex"},{from:"linkTarget",id:"remove-linktarget"},{from:"plugins",id:"change-plugins-to-remarkplugins",to:"remarkPlugins"},{from:"rawSourcePos",id:"#remove-rawsourcepos"},{from:"renderers",id:"change-renderers-to-components",to:"components"},{from:"source",id:"change-source-to-children",to:"children"},{from:"sourcePos",id:"#remove-sourcepos"},{from:"transformImageUri",id:"#add-urltransform",to:"urlTransform"},{from:"transformLinkUri",id:"#add-urltransform",to:"urlTransform"}];function Hu(t){let e=t.allowedElements,n=t.allowElement,r=t.children||"",i=t.className,o=t.components,a=t.disallowedElements,s=t.rehypePlugins||C0,l=t.remarkPlugins||C0,u=t.remarkRehypeOptions?{...t.remarkRehypeOptions,...P0}:P0,c=t.skipHtml,d=t.unwrapDisallowed,h=t.urlTransform||aN,p=Z_().use(UO).use(l).use(__,u).use(s),m=new Gl;typeof r=="string"&&(m.value=r);for(let g of oN)Object.hasOwn(t,g.from)&&""+g.from+(g.to?"use `"+g.to+"` instead":"remove it")+rN+g.id;let v=p.parse(m),b=p.runSync(v,m);return i&&(b={type:"element",tagName:"div",properties:{className:i},children:b.type==="root"?b.children:[b]}),$u(b,f),Ej(b,{Fragment:A.Fragment,components:o,ignoreInvalidStyle:!0,jsx:A.jsx,jsxs:A.jsxs,passKeys:!0,passNode:!0});function f(g,y,w){if(g.type==="raw"&&w&&typeof y=="number")return c?w.children.splice(y,1):w.children[y]={type:"text",value:g.value},y;if(g.type==="element"){let C;for(C in Bc)if(Object.hasOwn(Bc,C)&&Object.hasOwn(g.properties,C)){let k=g.properties[C],M=Bc[C];(M===null||M.includes(g.tagName))&&(g.properties[C]=h(String(k||""),C,g))}}if(g.type==="element"){let C=e?!e.includes(g.tagName):a?a.includes(g.tagName):!1;if(!C&&n&&typeof y=="number"&&(C=!n(g,y,w)),C&&w&&typeof y=="number")return d&&g.children?w.children.splice(y,1,...g.children):w.children.splice(y,1),y}}}function aN(t){let e=t.indexOf(":"),n=t.indexOf("?"),r=t.indexOf("#"),i=t.indexOf("/");return e<0||i>-1&&e>i||n>-1&&e>n||r>-1&&e>r||iN.test(t.slice(0,e))?t:""}var eT=function(t){if(t==null)return uN;if(typeof t=="string")return lN(t);if(typeof t=="object")return sN(t);if(typeof t=="function")return ym(t);throw new Error("Expected function, string, or array as `test`")};function sN(t){let e=[],n=-1;for(;++n<t.length;)e[n]=eT(t[n]);return ym(r);function r(...i){let o=-1;for(;++o<e.length;)if(e[o].apply(this,i))return!0;return!1}}function lN(t){return ym(e);function e(n){return n.tagName===t}}function ym(t){return e;function e(n,r,i){return!!(cN(n)&&t.call(this,n,typeof r=="number"?r:void 0,i||void 0))}}function uN(t){return!!(t&&typeof t=="object"&&"type"in t&&t.type==="element"&&"tagName"in t&&typeof t.tagName=="string")}function cN(t){return t!==null&&typeof t=="object"&&"type"in t&&"tagName"in t}var dN=/^[a-zA-Z][a-zA-Z\d+\-.]*?:/,hN=/^[a-zA-Z]:\\/;function pN(t){if(typeof t!="string")throw new TypeError(`Expected a \`string\`, got \`${typeof t}\``);return hN.test(t)?!1:dN.test(t)}var fN=["http","https"],mN=["nofollow"],gN={};function bm(t){let e=t||gN,n=e.protocols||fN,r=eT(e.test);return function(i){$u(i,"element",function(o,a,s){if(o.tagName==="a"&&typeof o.properties.href=="string"&&r(o,a,s)){let l=o.properties.href;if(pN(l)?n.includes(l.slice(0,l.indexOf(":"))):l.startsWith("//")){let u=Po(e.content,o),c=u&&!Array.isArray(u)?[u]:u,d=Po(e.rel,o)||mN,h=typeof d=="string"?nj(d):d,p=Po(e.target,o),m=Po(e.properties,o);if(m&&Object.assign(o.properties,Wr(m)),h.length>0&&(o.properties.rel=[...h]),p&&(o.properties.target=p),c){let v=Po(e.contentProperties,o)||{};o.children.push({type:"element",tagName:"span",properties:Wr(v),children:Wr(c)})}}}})}}function Po(t,e){return typeof t=="function"?t(e):t}function A0(t,e){let n=String(t);if(typeof e!="string")throw new TypeError("Expected character");let r=0,i=n.indexOf(e);for(;i!==-1;)r++,i=n.indexOf(e,i+e.length);return r}function vN(t){if(typeof t!="string")throw new TypeError("Expected a string");return t.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}function yN(t,e,n){let r=Bu((n||{}).ignore||[]),i=bN(e),o=-1;for(;++o<i.length;)ZS(t,"text",a);function a(l,u){let c=-1,d;for(;++c<u.length;){let h=u[c],p=d?d.children:void 0;if(r(h,p?p.indexOf(h):void 0,d))return;d=h}if(d)return s(l,u)}function s(l,u){let c=u[u.length-1],d=i[o][0],h=i[o][1],p=0,m=c.children.indexOf(l),v=!1,b=[];d.lastIndex=0;let f=d.exec(l.value);for(;f;){let g=f.index,y={index:f.index,input:f.input,stack:[...u,l]},w=h(...f,y);if(typeof w=="string"&&(w=w.length>0?{type:"text",value:w}:void 0),w===!1?d.lastIndex=g+1:(p!==g&&b.push({type:"text",value:l.value.slice(p,g)}),Array.isArray(w)?b.push(...w):w&&b.push(w),p=g+f[0].length,v=!0),!d.global)break;f=d.exec(l.value)}return v?(p<l.value.length&&b.push({type:"text",value:l.value.slice(p)}),c.children.splice(m,1,...b)):b=[l],m+b.length}}function bN(t){let e=[];if(!Array.isArray(t))throw new TypeError("Expected find and replace tuple or list of tuples");let n=!t[0]||Array.isArray(t[0])?t:[t],r=-1;for(;++r<n.length;){let i=n[r];e.push([xN(i[0]),wN(i[1])])}return e}function xN(t){return typeof t=="string"?new RegExp(vN(t),"g"):t}function wN(t){return typeof t=="function"?t:function(){return t}}var Qc="phrasing",Jc=["autolink","link","image","label"];function kN(){return{transforms:[MN],enter:{literalAutolink:TN,literalAutolinkEmail:Zc,literalAutolinkHttp:Zc,literalAutolinkWww:Zc},exit:{literalAutolink:AN,literalAutolinkEmail:PN,literalAutolinkHttp:EN,literalAutolinkWww:CN}}}function SN(){return{unsafe:[{character:"@",before:"[+\\-.\\w]",after:"[\\-.\\w]",inConstruct:Qc,notInConstruct:Jc},{character:".",before:"[Ww]",after:"[\\-.\\w]",inConstruct:Qc,notInConstruct:Jc},{character:":",before:"[ps]",after:"\\/",inConstruct:Qc,notInConstruct:Jc}]}}function TN(t){this.enter({type:"link",title:null,url:"",children:[]},t)}function Zc(t){this.config.enter.autolinkProtocol.call(this,t)}function EN(t){this.config.exit.autolinkProtocol.call(this,t)}function CN(t){this.config.exit.data.call(this,t);let e=this.stack[this.stack.length-1];e.type,e.url="http://"+this.sliceSerialize(t)}function PN(t){this.config.exit.autolinkEmail.call(this,t)}function AN(t){this.exit(t)}function MN(t){yN(t,[[/(https?:\/\/|www(?=\.))([-.\w]+)([^ \t\r\n]*)/gi,DN],[new RegExp("(?<=^|\\s|\\p{P}|\\p{S})([-.\\w+]+)@([-\\w]+(?:\\.[-\\w]+)+)","gu"),RN]],{ignore:["link","linkReference"]})}function DN(t,e,n,r,i){let o="";if(!nT(i)||(/^w/i.test(e)&&(n=e+n,e="",o="http://"),!IN(n)))return!1;let a=LN(n+r);if(!a[0])return!1;let s={type:"link",title:null,url:o+e+a[0],children:[{type:"text",value:e+a[0]}]};return a[1]?[s,{type:"text",value:a[1]}]:s}function RN(t,e,n,r){return!nT(r,!0)||/[-\d_]$/.test(n)?!1:{type:"link",title:null,url:"mailto:"+e+"@"+n,children:[{type:"text",value:e+"@"+n}]}}function IN(t){let e=t.split(".");return!(e.length<2||e[e.length-1]&&(/_/.test(e[e.length-1])||!/[a-zA-Z\d]/.test(e[e.length-1]))||e[e.length-2]&&(/_/.test(e[e.length-2])||!/[a-zA-Z\d]/.test(e[e.length-2])))}function LN(t){let e=/[!"&'),.:;<>?\]}]+$/.exec(t);if(!e)return[t,void 0];t=t.slice(0,e.index);let n=e[0],r=n.indexOf(")"),i=A0(t,"("),o=A0(t,")");for(;r!==-1&&i>o;)t+=n.slice(0,r+1),n=n.slice(r+1),r=n.indexOf(")"),o++;return[t,n]}function nT(t,e){let n=t.input.charCodeAt(t.index-1);return(t.index===0||Zr(n)||Fu(n))&&(!e||n!==47)}rT.peek=HN;function jN(){return{enter:{gfmFootnoteDefinition:_N,gfmFootnoteDefinitionLabelString:NN,gfmFootnoteCall:zN,gfmFootnoteCallString:BN},exit:{gfmFootnoteDefinition:VN,gfmFootnoteDefinitionLabelString:FN,gfmFootnoteCall:$N,gfmFootnoteCallString:UN}}}function ON(){return{unsafe:[{character:"[",inConstruct:["phrasing","label","reference"]}],handlers:{footnoteDefinition:WN,footnoteReference:rT}}}function _N(t){this.enter({type:"footnoteDefinition",identifier:"",label:"",children:[]},t)}function NN(){this.buffer()}function FN(t){let e=this.resume(),n=this.stack[this.stack.length-1];n.type,n.label=e,n.identifier=en(this.sliceSerialize(t)).toLowerCase()}function VN(t){this.exit(t)}function zN(t){this.enter({type:"footnoteReference",identifier:"",label:""},t)}function BN(){this.buffer()}function UN(t){let e=this.resume(),n=this.stack[this.stack.length-1];n.type,n.label=e,n.identifier=en(this.sliceSerialize(t)).toLowerCase()}function $N(t){this.exit(t)}function rT(t,e,n,r){let i=n.createTracker(r),o=i.move("[^"),a=n.enter("footnoteReference"),s=n.enter("reference");return o+=i.move(n.safe(n.associationId(t),{...i.current(),before:o,after:"]"})),s(),a(),o+=i.move("]"),o}function HN(){return"["}function WN(t,e,n,r){let i=n.createTracker(r),o=i.move("[^"),a=n.enter("footnoteDefinition"),s=n.enter("label");return o+=i.move(n.safe(n.associationId(t),{...i.current(),before:o,after:"]"})),s(),o+=i.move("]:"+(t.children&&t.children.length>0?" ":"")),i.shift(4),o+=i.move(n.indentLines(n.containerFlow(t,i.current()),qN)),a(),o}function qN(t,e,n){return e===0?t:(n?"":"    ")+t}var YN=["autolink","destinationLiteral","destinationRaw","reference","titleQuote","titleApostrophe"];iT.peek=JN;function KN(){return{canContainEols:["delete"],enter:{strikethrough:GN},exit:{strikethrough:QN}}}function XN(){return{unsafe:[{character:"~",inConstruct:"phrasing",notInConstruct:YN}],handlers:{delete:iT}}}function GN(t){this.enter({type:"delete",children:[]},t)}function QN(t){this.exit(t)}function iT(t,e,n,r){let i=n.createTracker(r),o=n.enter("strikethrough"),a=i.move("~~");return a+=n.containerPhrasing(t,{...i.current(),before:a,after:"~"}),a+=i.move("~~"),o(),a}function JN(){return"~"}function ZN(t){return t.length}function tF(t,e){let n=e||{},r=(n.align||[]).concat(),i=n.stringLength||ZN,o=[],a=[],s=[],l=[],u=0,c=-1;for(;++c<t.length;){let v=[],b=[],f=-1;for(t[c].length>u&&(u=t[c].length);++f<t[c].length;){let g=eF(t[c][f]);if(n.alignDelimiters!==!1){let y=i(g);b[f]=y,(l[f]===void 0||y>l[f])&&(l[f]=y)}v.push(g)}a[c]=v,s[c]=b}let d=-1;if(typeof r=="object"&&"length"in r)for(;++d<u;)o[d]=M0(r[d]);else{let v=M0(r);for(;++d<u;)o[d]=v}d=-1;let h=[],p=[];for(;++d<u;){let v=o[d],b="",f="";v===99?(b=":",f=":"):v===108?b=":":v===114&&(f=":");let g=n.alignDelimiters===!1?1:Math.max(1,l[d]-b.length-f.length),y=b+"-".repeat(g)+f;n.alignDelimiters!==!1&&(g=b.length+g+f.length,g>l[d]&&(l[d]=g),p[d]=g),h[d]=y}a.splice(1,0,h),s.splice(1,0,p),c=-1;let m=[];for(;++c<a.length;){let v=a[c],b=s[c];d=-1;let f=[];for(;++d<u;){let g=v[d]||"",y="",w="";if(n.alignDelimiters!==!1){let C=l[d]-(b[d]||0),k=o[d];k===114?y=" ".repeat(C):k===99?C%2?(y=" ".repeat(C/2+.5),w=" ".repeat(C/2-.5)):(y=" ".repeat(C/2),w=y):w=" ".repeat(C)}n.delimiterStart!==!1&&!d&&f.push("|"),n.padding!==!1&&!(n.alignDelimiters===!1&&g==="")&&(n.delimiterStart!==!1||d)&&f.push(" "),n.alignDelimiters!==!1&&f.push(y),f.push(g),n.alignDelimiters!==!1&&f.push(w),n.padding!==!1&&f.push(" "),(n.delimiterEnd!==!1||d!==u-1)&&f.push("|")}m.push(n.delimiterEnd===!1?f.join("").replace(/ +$/,""):f.join(""))}return m.join(`
`)}function eF(t){return t==null?"":String(t)}function M0(t){let e=typeof t=="string"?t.codePointAt(0):0;return e===67||e===99?99:e===76||e===108?108:e===82||e===114?114:0}function nF(t,e,n,r){let i=n.enter("blockquote"),o=n.createTracker(r);o.move("> "),o.shift(2);let a=n.indentLines(n.containerFlow(t,o.current()),rF);return i(),a}function rF(t,e,n){return">"+(n?"":" ")+t}function iF(t,e){return D0(t,e.inConstruct,!0)&&!D0(t,e.notInConstruct,!1)}function D0(t,e,n){if(typeof e=="string"&&(e=[e]),!e||e.length===0)return n;let r=-1;for(;++r<e.length;)if(t.includes(e[r]))return!0;return!1}function R0(t,e,n,r){let i=-1;for(;++i<n.unsafe.length;)if(n.unsafe[i].character===`
`&&iF(n.stack,n.unsafe[i]))return/[ \t]/.test(r.before)?"":" ";return`\\
`}function oF(t,e){let n=String(t),r=n.indexOf(e),i=r,o=0,a=0;if(typeof e!="string")throw new TypeError("Expected substring");for(;r!==-1;)r===i?++o>a&&(a=o):o=1,i=r+e.length,r=n.indexOf(e,i);return a}function aF(t,e){return!!(e.options.fences===!1&&t.value&&!t.lang&&/[^ \r\n]/.test(t.value)&&!/^[\t ]*(?:[\r\n]|$)|(?:^|[\r\n])[\t ]*$/.test(t.value))}function sF(t){let e=t.options.fence||"`";if(e!=="`"&&e!=="~")throw new Error("Cannot serialize code with `"+e+"` for `options.fence`, expected `` ` `` or `~`");return e}function lF(t,e,n,r){let i=sF(n),o=t.value||"",a=i==="`"?"GraveAccent":"Tilde";if(aF(t,n)){let d=n.enter("codeIndented"),h=n.indentLines(o,uF);return d(),h}let s=n.createTracker(r),l=i.repeat(Math.max(oF(o,i)+1,3)),u=n.enter("codeFenced"),c=s.move(l);if(t.lang){let d=n.enter(`codeFencedLang${a}`);c+=s.move(n.safe(t.lang,{before:c,after:" ",encode:["`"],...s.current()})),d()}if(t.lang&&t.meta){let d=n.enter(`codeFencedMeta${a}`);c+=s.move(" "),c+=s.move(n.safe(t.meta,{before:c,after:`
`,encode:["`"],...s.current()})),d()}return c+=s.move(`
`),o&&(c+=s.move(o+`
`)),c+=s.move(l),u(),c}function uF(t,e,n){return(n?"":"    ")+t}function xm(t){let e=t.options.quote||'"';if(e!=='"'&&e!=="'")throw new Error("Cannot serialize title with `"+e+"` for `options.quote`, expected `\"`, or `'`");return e}function cF(t,e,n,r){let i=xm(n),o=i==='"'?"Quote":"Apostrophe",a=n.enter("definition"),s=n.enter("label"),l=n.createTracker(r),u=l.move("[");return u+=l.move(n.safe(n.associationId(t),{before:u,after:"]",...l.current()})),u+=l.move("]: "),s(),!t.url||/[\0- \u007F]/.test(t.url)?(s=n.enter("destinationLiteral"),u+=l.move("<"),u+=l.move(n.safe(t.url,{before:u,after:">",...l.current()})),u+=l.move(">")):(s=n.enter("destinationRaw"),u+=l.move(n.safe(t.url,{before:u,after:t.title?" ":`
`,...l.current()}))),s(),t.title&&(s=n.enter(`title${o}`),u+=l.move(" "+i),u+=l.move(n.safe(t.title,{before:u,after:i,...l.current()})),u+=l.move(i),s()),a(),u}function dF(t){let e=t.options.emphasis||"*";if(e!=="*"&&e!=="_")throw new Error("Cannot serialize emphasis with `"+e+"` for `options.emphasis`, expected `*`, or `_`");return e}function Oa(t){return"&#x"+t.toString(16).toUpperCase()+";"}function Ql(t,e,n){let r=Zi(t),i=Zi(e);return r===void 0?i===void 0?n==="_"?{inside:!0,outside:!0}:{inside:!1,outside:!1}:i===1?{inside:!0,outside:!0}:{inside:!1,outside:!0}:r===1?i===void 0?{inside:!1,outside:!1}:i===1?{inside:!0,outside:!0}:{inside:!1,outside:!1}:i===void 0?{inside:!1,outside:!1}:i===1?{inside:!0,outside:!1}:{inside:!1,outside:!1}}oT.peek=hF;function oT(t,e,n,r){let i=dF(n),o=n.enter("emphasis"),a=n.createTracker(r),s=a.move(i),l=a.move(n.containerPhrasing(t,{after:i,before:s,...a.current()})),u=l.charCodeAt(0),c=Ql(r.before.charCodeAt(r.before.length-1),u,i);c.inside&&(l=Oa(u)+l.slice(1));let d=l.charCodeAt(l.length-1),h=Ql(r.after.charCodeAt(0),d,i);h.inside&&(l=l.slice(0,-1)+Oa(d));let p=a.move(i);return o(),n.attentionEncodeSurroundingInfo={after:h.outside,before:c.outside},s+l+p}function hF(t,e,n){return n.options.emphasis||"*"}function pF(t,e){let n=!1;return $u(t,function(r){if("value"in r&&/\r?\n|\r/.test(r.value)||r.type==="break")return n=!0,Vh}),!!((!t.depth||t.depth<3)&&dm(t)&&(e.options.setext||n))}function fF(t,e,n,r){let i=Math.max(Math.min(6,t.depth||1),1),o=n.createTracker(r);if(pF(t,n)){let c=n.enter("headingSetext"),d=n.enter("phrasing"),h=n.containerPhrasing(t,{...o.current(),before:`
`,after:`
`});return d(),c(),h+`
`+(i===1?"=":"-").repeat(h.length-(Math.max(h.lastIndexOf("\r"),h.lastIndexOf(`
`))+1))}let a="#".repeat(i),s=n.enter("headingAtx"),l=n.enter("phrasing");o.move(a+" ");let u=n.containerPhrasing(t,{before:"# ",after:`
`,...o.current()});return/^[\t ]/.test(u)&&(u=Oa(u.charCodeAt(0))+u.slice(1)),u=u?a+" "+u:a,n.options.closeAtx&&(u+=" "+a),l(),s(),u}aT.peek=mF;function aT(t){return t.value||""}function mF(){return"<"}sT.peek=gF;function sT(t,e,n,r){let i=xm(n),o=i==='"'?"Quote":"Apostrophe",a=n.enter("image"),s=n.enter("label"),l=n.createTracker(r),u=l.move("![");return u+=l.move(n.safe(t.alt,{before:u,after:"]",...l.current()})),u+=l.move("]("),s(),!t.url&&t.title||/[\0- \u007F]/.test(t.url)?(s=n.enter("destinationLiteral"),u+=l.move("<"),u+=l.move(n.safe(t.url,{before:u,after:">",...l.current()})),u+=l.move(">")):(s=n.enter("destinationRaw"),u+=l.move(n.safe(t.url,{before:u,after:t.title?" ":")",...l.current()}))),s(),t.title&&(s=n.enter(`title${o}`),u+=l.move(" "+i),u+=l.move(n.safe(t.title,{before:u,after:i,...l.current()})),u+=l.move(i),s()),u+=l.move(")"),a(),u}function gF(){return"!"}lT.peek=vF;function lT(t,e,n,r){let i=t.referenceType,o=n.enter("imageReference"),a=n.enter("label"),s=n.createTracker(r),l=s.move("!["),u=n.safe(t.alt,{before:l,after:"]",...s.current()});l+=s.move(u+"]["),a();let c=n.stack;n.stack=[],a=n.enter("reference");let d=n.safe(n.associationId(t),{before:l,after:"]",...s.current()});return a(),n.stack=c,o(),i==="full"||!u||u!==d?l+=s.move(d+"]"):i==="shortcut"?l=l.slice(0,-1):l+=s.move("]"),l}function vF(){return"!"}uT.peek=yF;function uT(t,e,n){let r=t.value||"",i="`",o=-1;for(;new RegExp("(^|[^`])"+i+"([^`]|$)").test(r);)i+="`";for(/[^ \r\n]/.test(r)&&(/^[ \r\n]/.test(r)&&/[ \r\n]$/.test(r)||/^`|`$/.test(r))&&(r=" "+r+" ");++o<n.unsafe.length;){let a=n.unsafe[o],s=n.compilePattern(a),l;if(a.atBreak)for(;l=s.exec(r);){let u=l.index;r.charCodeAt(u)===10&&r.charCodeAt(u-1)===13&&u--,r=r.slice(0,u)+" "+r.slice(l.index+1)}}return i+r+i}function yF(){return"`"}function cT(t,e){let n=dm(t);return!!(!e.options.resourceLink&&t.url&&!t.title&&t.children&&t.children.length===1&&t.children[0].type==="text"&&(n===t.url||"mailto:"+n===t.url)&&/^[a-z][a-z+.-]+:/i.test(t.url)&&!/[\0- <>\u007F]/.test(t.url))}dT.peek=bF;function dT(t,e,n,r){let i=xm(n),o=i==='"'?"Quote":"Apostrophe",a=n.createTracker(r),s,l;if(cT(t,n)){let c=n.stack;n.stack=[],s=n.enter("autolink");let d=a.move("<");return d+=a.move(n.containerPhrasing(t,{before:d,after:">",...a.current()})),d+=a.move(">"),s(),n.stack=c,d}s=n.enter("link"),l=n.enter("label");let u=a.move("[");return u+=a.move(n.containerPhrasing(t,{before:u,after:"](",...a.current()})),u+=a.move("]("),l(),!t.url&&t.title||/[\0- \u007F]/.test(t.url)?(l=n.enter("destinationLiteral"),u+=a.move("<"),u+=a.move(n.safe(t.url,{before:u,after:">",...a.current()})),u+=a.move(">")):(l=n.enter("destinationRaw"),u+=a.move(n.safe(t.url,{before:u,after:t.title?" ":")",...a.current()}))),l(),t.title&&(l=n.enter(`title${o}`),u+=a.move(" "+i),u+=a.move(n.safe(t.title,{before:u,after:i,...a.current()})),u+=a.move(i),l()),u+=a.move(")"),s(),u}function bF(t,e,n){return cT(t,n)?"<":"["}hT.peek=xF;function hT(t,e,n,r){let i=t.referenceType,o=n.enter("linkReference"),a=n.enter("label"),s=n.createTracker(r),l=s.move("["),u=n.containerPhrasing(t,{before:l,after:"]",...s.current()});l+=s.move(u+"]["),a();let c=n.stack;n.stack=[],a=n.enter("reference");let d=n.safe(n.associationId(t),{before:l,after:"]",...s.current()});return a(),n.stack=c,o(),i==="full"||!u||u!==d?l+=s.move(d+"]"):i==="shortcut"?l=l.slice(0,-1):l+=s.move("]"),l}function xF(){return"["}function wm(t){let e=t.options.bullet||"*";if(e!=="*"&&e!=="+"&&e!=="-")throw new Error("Cannot serialize items with `"+e+"` for `options.bullet`, expected `*`, `+`, or `-`");return e}function wF(t){let e=wm(t),n=t.options.bulletOther;if(!n)return e==="*"?"-":"*";if(n!=="*"&&n!=="+"&&n!=="-")throw new Error("Cannot serialize items with `"+n+"` for `options.bulletOther`, expected `*`, `+`, or `-`");if(n===e)throw new Error("Expected `bullet` (`"+e+"`) and `bulletOther` (`"+n+"`) to be different");return n}function kF(t){let e=t.options.bulletOrdered||".";if(e!=="."&&e!==")")throw new Error("Cannot serialize items with `"+e+"` for `options.bulletOrdered`, expected `.` or `)`");return e}function pT(t){let e=t.options.rule||"*";if(e!=="*"&&e!=="-"&&e!=="_")throw new Error("Cannot serialize rules with `"+e+"` for `options.rule`, expected `*`, `-`, or `_`");return e}function SF(t,e,n,r){let i=n.enter("list"),o=n.bulletCurrent,a=t.ordered?kF(n):wm(n),s=t.ordered?a==="."?")":".":wF(n),l=e&&n.bulletLastUsed?a===n.bulletLastUsed:!1;if(!t.ordered){let c=t.children?t.children[0]:void 0;if((a==="*"||a==="-")&&c&&(!c.children||!c.children[0])&&n.stack[n.stack.length-1]==="list"&&n.stack[n.stack.length-2]==="listItem"&&n.stack[n.stack.length-3]==="list"&&n.stack[n.stack.length-4]==="listItem"&&n.indexStack[n.indexStack.length-1]===0&&n.indexStack[n.indexStack.length-2]===0&&n.indexStack[n.indexStack.length-3]===0&&(l=!0),pT(n)===a&&c){let d=-1;for(;++d<t.children.length;){let h=t.children[d];if(h&&h.type==="listItem"&&h.children&&h.children[0]&&h.children[0].type==="thematicBreak"){l=!0;break}}}}l&&(a=s),n.bulletCurrent=a;let u=n.containerFlow(t,r);return n.bulletLastUsed=a,n.bulletCurrent=o,i(),u}function TF(t){let e=t.options.listItemIndent||"one";if(e!=="tab"&&e!=="one"&&e!=="mixed")throw new Error("Cannot serialize items with `"+e+"` for `options.listItemIndent`, expected `tab`, `one`, or `mixed`");return e}function EF(t,e,n,r){let i=TF(n),o=n.bulletCurrent||wm(n);e&&e.type==="list"&&e.ordered&&(o=(typeof e.start=="number"&&e.start>-1?e.start:1)+(n.options.incrementListMarker===!1?0:e.children.indexOf(t))+o);let a=o.length+1;(i==="tab"||i==="mixed"&&(e&&e.type==="list"&&e.spread||t.spread))&&(a=Math.ceil(a/4)*4);let s=n.createTracker(r);s.move(o+" ".repeat(a-o.length)),s.shift(a);let l=n.enter("listItem"),u=n.indentLines(n.containerFlow(t,s.current()),c);return l(),u;function c(d,h,p){return h?(p?"":" ".repeat(a))+d:(p?o:o+" ".repeat(a-o.length))+d}}function CF(t,e,n,r){let i=n.enter("paragraph"),o=n.enter("phrasing"),a=n.containerPhrasing(t,r);return o(),i(),a}var PF=Bu(["break","delete","emphasis","footnote","footnoteReference","image","imageReference","inlineCode","inlineMath","link","linkReference","mdxJsxTextElement","mdxTextExpression","strong","text","textDirective"]);function AF(t,e,n,r){return(t.children.some(function(i){return PF(i)})?n.containerPhrasing:n.containerFlow).call(n,t,r)}function MF(t){let e=t.options.strong||"*";if(e!=="*"&&e!=="_")throw new Error("Cannot serialize strong with `"+e+"` for `options.strong`, expected `*`, or `_`");return e}fT.peek=DF;function fT(t,e,n,r){let i=MF(n),o=n.enter("strong"),a=n.createTracker(r),s=a.move(i+i),l=a.move(n.containerPhrasing(t,{after:i,before:s,...a.current()})),u=l.charCodeAt(0),c=Ql(r.before.charCodeAt(r.before.length-1),u,i);c.inside&&(l=Oa(u)+l.slice(1));let d=l.charCodeAt(l.length-1),h=Ql(r.after.charCodeAt(0),d,i);h.inside&&(l=l.slice(0,-1)+Oa(d));let p=a.move(i+i);return o(),n.attentionEncodeSurroundingInfo={after:h.outside,before:c.outside},s+l+p}function DF(t,e,n){return n.options.strong||"*"}function RF(t,e,n,r){return n.safe(t.value,r)}function IF(t){let e=t.options.ruleRepetition||3;if(e<3)throw new Error("Cannot serialize rules with repetition `"+e+"` for `options.ruleRepetition`, expected `3` or more");return e}function LF(t,e,n){let r=(pT(n)+(n.options.ruleSpaces?" ":"")).repeat(IF(n));return n.options.ruleSpaces?r.slice(0,-1):r}var mT={blockquote:nF,break:R0,code:lF,definition:cF,emphasis:oT,hardBreak:R0,heading:fF,html:aT,image:sT,imageReference:lT,inlineCode:uT,link:dT,linkReference:hT,list:SF,listItem:EF,paragraph:CF,root:AF,strong:fT,text:RF,thematicBreak:LF};function jF(){return{enter:{table:OF,tableData:I0,tableHeader:I0,tableRow:NF},exit:{codeText:FF,table:_F,tableData:td,tableHeader:td,tableRow:td}}}function OF(t){let e=t._align;this.enter({type:"table",align:e.map(function(n){return n==="none"?null:n}),children:[]},t),this.data.inTable=!0}function _F(t){this.exit(t),this.data.inTable=void 0}function NF(t){this.enter({type:"tableRow",children:[]},t)}function td(t){this.exit(t)}function I0(t){this.enter({type:"tableCell",children:[]},t)}function FF(t){let e=this.resume();this.data.inTable&&(e=e.replace(/\\([\\|])/g,VF));let n=this.stack[this.stack.length-1];n.type,n.value=e,this.exit(t)}function VF(t,e){return e==="|"?e:t}function zF(t){let e=t||{},n=e.tableCellPadding,r=e.tablePipeAlign,i=e.stringLength,o=n?" ":"|";return{unsafe:[{character:"\r",inConstruct:"tableCell"},{character:`
`,inConstruct:"tableCell"},{atBreak:!0,character:"|",after:"[	 :-]"},{character:"|",inConstruct:"tableCell"},{atBreak:!0,character:":",after:"-"},{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{inlineCode:h,table:a,tableCell:l,tableRow:s}};function a(p,m,v,b){return u(c(p,v,b),p.align)}function s(p,m,v,b){let f=d(p,v,b),g=u([f]);return g.slice(0,g.indexOf(`
`))}function l(p,m,v,b){let f=v.enter("tableCell"),g=v.enter("phrasing"),y=v.containerPhrasing(p,{...b,before:o,after:o});return g(),f(),y}function u(p,m){return tF(p,{align:m,alignDelimiters:r,padding:n,stringLength:i})}function c(p,m,v){let b=p.children,f=-1,g=[],y=m.enter("table");for(;++f<b.length;)g[f]=d(b[f],m,v);return y(),g}function d(p,m,v){let b=p.children,f=-1,g=[],y=m.enter("tableRow");for(;++f<b.length;)g[f]=l(b[f],p,m,v);return y(),g}function h(p,m,v){let b=mT.inlineCode(p,m,v);return v.stack.includes("tableCell")&&(b=b.replace(/\|/g,"\\$&")),b}}function BF(){return{exit:{taskListCheckValueChecked:L0,taskListCheckValueUnchecked:L0,paragraph:$F}}}function UF(){return{unsafe:[{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{listItem:HF}}}function L0(t){let e=this.stack[this.stack.length-2];e.type,e.checked=t.type==="taskListCheckValueChecked"}function $F(t){let e=this.stack[this.stack.length-2];if(e&&e.type==="listItem"&&typeof e.checked=="boolean"){let n=this.stack[this.stack.length-1];n.type;let r=n.children[0];if(r&&r.type==="text"){let i=e.children,o=-1,a;for(;++o<i.length;){let s=i[o];if(s.type==="paragraph"){a=s;break}}a===n&&(r.value=r.value.slice(1),r.value.length===0?n.children.shift():n.position&&r.position&&typeof r.position.start.offset=="number"&&(r.position.start.column++,r.position.start.offset++,n.position.start=Object.assign({},r.position.start)))}}this.exit(t)}function HF(t,e,n,r){let i=t.children[0],o=typeof t.checked=="boolean"&&i&&i.type==="paragraph",a="["+(t.checked?"x":" ")+"] ",s=n.createTracker(r);o&&s.move(a);let l=mT.listItem(t,e,n,{...r,...s.current()});return o&&(l=l.replace(/^(?:[*+-]|\d+\.)([\r\n]| {1,3})/,u)),l;function u(c){return c+a}}function WF(){return[kN(),jN(),KN(),jF(),BF()]}function qF(t){return{extensions:[SN(),ON(),XN(),zF(t),UF()]}}var YF={tokenize:ZF,partial:!0},gT={tokenize:tV,partial:!0},vT={tokenize:eV,partial:!0},yT={tokenize:nV,partial:!0},KF={tokenize:rV,partial:!0},bT={name:"wwwAutolink",tokenize:QF,previous:wT},xT={name:"protocolAutolink",tokenize:JF,previous:kT},Wn={name:"emailAutolink",tokenize:GF,previous:ST},bn={};function XF(){return{text:bn}}var Ar=48;for(;Ar<123;)bn[Ar]=Wn,Ar++,Ar===58?Ar=65:Ar===91&&(Ar=97);bn[43]=Wn;bn[45]=Wn;bn[46]=Wn;bn[95]=Wn;bn[72]=[Wn,xT];bn[104]=[Wn,xT];bn[87]=[Wn,bT];bn[119]=[Wn,bT];function GF(t,e,n){let r=this,i,o;return a;function a(d){return!Hh(d)||!ST.call(r,r.previous)||km(r.events)?n(d):(t.enter("literalAutolink"),t.enter("literalAutolinkEmail"),s(d))}function s(d){return Hh(d)?(t.consume(d),s):d===64?(t.consume(d),l):n(d)}function l(d){return d===46?t.check(KF,c,u)(d):d===45||d===95||ee(d)?(o=!0,t.consume(d),l):c(d)}function u(d){return t.consume(d),i=!0,l}function c(d){return o&&i&&le(r.previous)?(t.exit("literalAutolinkEmail"),t.exit("literalAutolink"),e(d)):n(d)}}function QF(t,e,n){let r=this;return i;function i(a){return a!==87&&a!==119||!wT.call(r,r.previous)||km(r.events)?n(a):(t.enter("literalAutolink"),t.enter("literalAutolinkWww"),t.check(YF,t.attempt(gT,t.attempt(vT,o),n),n)(a))}function o(a){return t.exit("literalAutolinkWww"),t.exit("literalAutolink"),e(a)}}function JF(t,e,n){let r=this,i="",o=!1;return a;function a(d){return(d===72||d===104)&&kT.call(r,r.previous)&&!km(r.events)?(t.enter("literalAutolink"),t.enter("literalAutolinkHttp"),i+=String.fromCodePoint(d),t.consume(d),s):n(d)}function s(d){if(le(d)&&i.length<5)return i+=String.fromCodePoint(d),t.consume(d),s;if(d===58){let h=i.toLowerCase();if(h==="http"||h==="https")return t.consume(d),l}return n(d)}function l(d){return d===47?(t.consume(d),o?u:(o=!0,l)):n(d)}function u(d){return d===null||Yl(d)||pt(d)||Zr(d)||Fu(d)?n(d):t.attempt(gT,t.attempt(vT,c),n)(d)}function c(d){return t.exit("literalAutolinkHttp"),t.exit("literalAutolink"),e(d)}}function ZF(t,e,n){let r=0;return i;function i(a){return(a===87||a===119)&&r<3?(r++,t.consume(a),i):a===46&&r===3?(t.consume(a),o):n(a)}function o(a){return a===null?n(a):e(a)}}function tV(t,e,n){let r,i,o;return a;function a(u){return u===46||u===95?t.check(yT,l,s)(u):u===null||pt(u)||Zr(u)||u!==45&&Fu(u)?l(u):(o=!0,t.consume(u),a)}function s(u){return u===95?r=!0:(i=r,r=void 0),t.consume(u),a}function l(u){return i||r||!o?n(u):e(u)}}function eV(t,e){let n=0,r=0;return i;function i(a){return a===40?(n++,t.consume(a),i):a===41&&r<n?o(a):a===33||a===34||a===38||a===39||a===41||a===42||a===44||a===46||a===58||a===59||a===60||a===63||a===93||a===95||a===126?t.check(yT,e,o)(a):a===null||pt(a)||Zr(a)?e(a):(t.consume(a),i)}function o(a){return a===41&&r++,t.consume(a),i}}function nV(t,e,n){return r;function r(s){return s===33||s===34||s===39||s===41||s===42||s===44||s===46||s===58||s===59||s===63||s===95||s===126?(t.consume(s),r):s===38?(t.consume(s),o):s===93?(t.consume(s),i):s===60||s===null||pt(s)||Zr(s)?e(s):n(s)}function i(s){return s===null||s===40||s===91||pt(s)||Zr(s)?e(s):r(s)}function o(s){return le(s)?a(s):n(s)}function a(s){return s===59?(t.consume(s),r):le(s)?(t.consume(s),a):n(s)}}function rV(t,e,n){return r;function r(o){return t.consume(o),i}function i(o){return ee(o)?n(o):e(o)}}function wT(t){return t===null||t===40||t===42||t===95||t===91||t===93||t===126||pt(t)}function kT(t){return!le(t)}function ST(t){return!(t===47||Hh(t))}function Hh(t){return t===43||t===45||t===46||t===95||ee(t)}function km(t){let e=t.length,n=!1;for(;e--;){let r=t[e][1];if((r.type==="labelLink"||r.type==="labelImage")&&!r._balanced){n=!0;break}if(r._gfmAutolinkLiteralWalkedInto){n=!1;break}}return t.length>0&&!n&&(t[t.length-1][1]._gfmAutolinkLiteralWalkedInto=!0),n}var iV={tokenize:hV,partial:!0};function oV(){return{document:{91:{name:"gfmFootnoteDefinition",tokenize:uV,continuation:{tokenize:cV},exit:dV}},text:{91:{name:"gfmFootnoteCall",tokenize:lV},93:{name:"gfmPotentialFootnoteCall",add:"after",tokenize:aV,resolveTo:sV}}}}function aV(t,e,n){let r=this,i=r.events.length,o=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]),a;for(;i--;){let l=r.events[i][1];if(l.type==="labelImage"){a=l;break}if(l.type==="gfmFootnoteCall"||l.type==="labelLink"||l.type==="label"||l.type==="image"||l.type==="link")break}return s;function s(l){if(!a||!a._balanced)return n(l);let u=en(r.sliceSerialize({start:a.end,end:r.now()}));return u.codePointAt(0)!==94||!o.includes(u.slice(1))?n(l):(t.enter("gfmFootnoteCallLabelMarker"),t.consume(l),t.exit("gfmFootnoteCallLabelMarker"),e(l))}}function sV(t,e){let n=t.length;for(;n--;)if(t[n][1].type==="labelImage"&&t[n][0]==="enter"){t[n][1];break}t[n+1][1].type="data",t[n+3][1].type="gfmFootnoteCallLabelMarker";let r={type:"gfmFootnoteCall",start:Object.assign({},t[n+3][1].start),end:Object.assign({},t[t.length-1][1].end)},i={type:"gfmFootnoteCallMarker",start:Object.assign({},t[n+3][1].end),end:Object.assign({},t[n+3][1].end)};i.end.column++,i.end.offset++,i.end._bufferIndex++;let o={type:"gfmFootnoteCallString",start:Object.assign({},i.end),end:Object.assign({},t[t.length-1][1].start)},a={type:"chunkString",contentType:"string",start:Object.assign({},o.start),end:Object.assign({},o.end)},s=[t[n+1],t[n+2],["enter",r,e],t[n+3],t[n+4],["enter",i,e],["exit",i,e],["enter",o,e],["enter",a,e],["exit",a,e],["exit",o,e],t[t.length-2],t[t.length-1],["exit",r,e]];return t.splice(n,t.length-n+1,...s),t}function lV(t,e,n){let r=this,i=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]),o=0,a;return s;function s(d){return t.enter("gfmFootnoteCall"),t.enter("gfmFootnoteCallLabelMarker"),t.consume(d),t.exit("gfmFootnoteCallLabelMarker"),l}function l(d){return d!==94?n(d):(t.enter("gfmFootnoteCallMarker"),t.consume(d),t.exit("gfmFootnoteCallMarker"),t.enter("gfmFootnoteCallString"),t.enter("chunkString").contentType="string",u)}function u(d){if(o>999||d===93&&!a||d===null||d===91||pt(d))return n(d);if(d===93){t.exit("chunkString");let h=t.exit("gfmFootnoteCallString");return i.includes(en(r.sliceSerialize(h)))?(t.enter("gfmFootnoteCallLabelMarker"),t.consume(d),t.exit("gfmFootnoteCallLabelMarker"),t.exit("gfmFootnoteCall"),e):n(d)}return pt(d)||(a=!0),o++,t.consume(d),d===92?c:u}function c(d){return d===91||d===92||d===93?(t.consume(d),o++,u):u(d)}}function uV(t,e,n){let r=this,i=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]),o,a=0,s;return l;function l(m){return t.enter("gfmFootnoteDefinition")._container=!0,t.enter("gfmFootnoteDefinitionLabel"),t.enter("gfmFootnoteDefinitionLabelMarker"),t.consume(m),t.exit("gfmFootnoteDefinitionLabelMarker"),u}function u(m){return m===94?(t.enter("gfmFootnoteDefinitionMarker"),t.consume(m),t.exit("gfmFootnoteDefinitionMarker"),t.enter("gfmFootnoteDefinitionLabelString"),t.enter("chunkString").contentType="string",c):n(m)}function c(m){if(a>999||m===93&&!s||m===null||m===91||pt(m))return n(m);if(m===93){t.exit("chunkString");let v=t.exit("gfmFootnoteDefinitionLabelString");return o=en(r.sliceSerialize(v)),t.enter("gfmFootnoteDefinitionLabelMarker"),t.consume(m),t.exit("gfmFootnoteDefinitionLabelMarker"),t.exit("gfmFootnoteDefinitionLabel"),h}return pt(m)||(s=!0),a++,t.consume(m),m===92?d:c}function d(m){return m===91||m===92||m===93?(t.consume(m),a++,c):c(m)}function h(m){return m===58?(t.enter("definitionMarker"),t.consume(m),t.exit("definitionMarker"),i.includes(o)||i.push(o),it(t,p,"gfmFootnoteDefinitionWhitespace")):n(m)}function p(m){return e(m)}}function cV(t,e,n){return t.check(Ja,e,t.attempt(iV,e,n))}function dV(t){t.exit("gfmFootnoteDefinition")}function hV(t,e,n){let r=this;return it(t,i,"gfmFootnoteDefinitionIndent",5);function i(o){let a=r.events[r.events.length-1];return a&&a[1].type==="gfmFootnoteDefinitionIndent"&&a[2].sliceSerialize(a[1],!0).length===4?e(o):n(o)}}function pV(t){let e=(t||{}).singleTilde,n={name:"strikethrough",tokenize:i,resolveAll:r};return e==null&&(e=!0),{text:{126:n},insideSpan:{null:[n]},attentionMarkers:{null:[126]}};function r(o,a){let s=-1;for(;++s<o.length;)if(o[s][0]==="enter"&&o[s][1].type==="strikethroughSequenceTemporary"&&o[s][1]._close){let l=s;for(;l--;)if(o[l][0]==="exit"&&o[l][1].type==="strikethroughSequenceTemporary"&&o[l][1]._open&&o[s][1].end.offset-o[s][1].start.offset===o[l][1].end.offset-o[l][1].start.offset){o[s][1].type="strikethroughSequence",o[l][1].type="strikethroughSequence";let u={type:"strikethrough",start:Object.assign({},o[l][1].start),end:Object.assign({},o[s][1].end)},c={type:"strikethroughText",start:Object.assign({},o[l][1].end),end:Object.assign({},o[s][1].start)},d=[["enter",u,a],["enter",o[l][1],a],["exit",o[l][1],a],["enter",c,a]],h=a.parser.constructs.insideSpan.null;h&&He(d,d.length,0,Vu(h,o.slice(l+1,s),a)),He(d,d.length,0,[["exit",c,a],["enter",o[s][1],a],["exit",o[s][1],a],["exit",u,a]]),He(o,l-1,s-l+3,d),s=l+d.length-2;break}}for(s=-1;++s<o.length;)o[s][1].type==="strikethroughSequenceTemporary"&&(o[s][1].type="data");return o}function i(o,a,s){let l=this.previous,u=this.events,c=0;return d;function d(p){return l===126&&u[u.length-1][1].type!=="characterEscape"?s(p):(o.enter("strikethroughSequenceTemporary"),h(p))}function h(p){let m=Zi(l);if(p===126)return c>1?s(p):(o.consume(p),c++,h);if(c<2&&!e)return s(p);let v=o.exit("strikethroughSequenceTemporary"),b=Zi(p);return v._open=!b||b===2&&!!m,v._close=!m||m===2&&!!b,a(p)}}}var Wh=class{constructor(){this.map=[]}add(e,n,r){fV(this,e,n,r)}consume(e){if(this.map.sort(function(o,a){return o[0]-a[0]}),this.map.length===0)return;let n=this.map.length,r=[];for(;n>0;)n-=1,r.push(e.slice(this.map[n][0]+this.map[n][1]),this.map[n][2]),e.length=this.map[n][0];r.push([...e]),e.length=0;let i=r.pop();for(;i;)e.push(...i),i=r.pop();this.map.length=0}};function fV(t,e,n,r){let i=0;if(!(n===0&&r.length===0)){for(;i<t.map.length;){if(t.map[i][0]===e){t.map[i][1]+=n,t.map[i][2].push(...r);return}i+=1}t.map.push([e,n,r])}}function mV(t,e){let n=!1,r=[];for(;e<t.length;){let i=t[e];if(n){if(i[0]==="enter")i[1].type==="tableContent"&&r.push(t[e+1][1].type==="tableDelimiterMarker"?"left":"none");else if(i[1].type==="tableContent"){if(t[e-1][1].type==="tableDelimiterMarker"){let o=r.length-1;r[o]=r[o]==="left"?"center":"right"}}else if(i[1].type==="tableDelimiterRow")break}else i[0]==="enter"&&i[1].type==="tableDelimiterRow"&&(n=!0);e+=1}return r}function gV(){return{flow:{null:{name:"table",tokenize:vV,resolveAll:yV}}}}function vV(t,e,n){let r=this,i=0,o=0,a;return s;function s(E){let L=r.events.length-1;for(;L>-1;){let U=r.events[L][1].type;if(U==="lineEnding"||U==="linePrefix")L--;else break}let N=L>-1?r.events[L][1].type:null,B=N==="tableHead"||N==="tableRow"?k:l;return B===k&&r.parser.lazy[r.now().line]?n(E):B(E)}function l(E){return t.enter("tableHead"),t.enter("tableRow"),u(E)}function u(E){return E===124||(a=!0,o+=1),c(E)}function c(E){return E===null?n(E):$(E)?o>1?(o=0,r.interrupt=!0,t.exit("tableRow"),t.enter("lineEnding"),t.consume(E),t.exit("lineEnding"),p):n(E):tt(E)?it(t,c,"whitespace")(E):(o+=1,a&&(a=!1,i+=1),E===124?(t.enter("tableCellDivider"),t.consume(E),t.exit("tableCellDivider"),a=!0,c):(t.enter("data"),d(E)))}function d(E){return E===null||E===124||pt(E)?(t.exit("data"),c(E)):(t.consume(E),E===92?h:d)}function h(E){return E===92||E===124?(t.consume(E),d):d(E)}function p(E){return r.interrupt=!1,r.parser.lazy[r.now().line]?n(E):(t.enter("tableDelimiterRow"),a=!1,tt(E)?it(t,m,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(E):m(E))}function m(E){return E===45||E===58?b(E):E===124?(a=!0,t.enter("tableCellDivider"),t.consume(E),t.exit("tableCellDivider"),v):C(E)}function v(E){return tt(E)?it(t,b,"whitespace")(E):b(E)}function b(E){return E===58?(o+=1,a=!0,t.enter("tableDelimiterMarker"),t.consume(E),t.exit("tableDelimiterMarker"),f):E===45?(o+=1,f(E)):E===null||$(E)?w(E):C(E)}function f(E){return E===45?(t.enter("tableDelimiterFiller"),g(E)):C(E)}function g(E){return E===45?(t.consume(E),g):E===58?(a=!0,t.exit("tableDelimiterFiller"),t.enter("tableDelimiterMarker"),t.consume(E),t.exit("tableDelimiterMarker"),y):(t.exit("tableDelimiterFiller"),y(E))}function y(E){return tt(E)?it(t,w,"whitespace")(E):w(E)}function w(E){return E===124?m(E):E===null||$(E)?!a||i!==o?C(E):(t.exit("tableDelimiterRow"),t.exit("tableHead"),e(E)):C(E)}function C(E){return n(E)}function k(E){return t.enter("tableRow"),M(E)}function M(E){return E===124?(t.enter("tableCellDivider"),t.consume(E),t.exit("tableCellDivider"),M):E===null||$(E)?(t.exit("tableRow"),e(E)):tt(E)?it(t,M,"whitespace")(E):(t.enter("data"),P(E))}function P(E){return E===null||E===124||pt(E)?(t.exit("data"),M(E)):(t.consume(E),E===92?R:P)}function R(E){return E===92||E===124?(t.consume(E),P):P(E)}}function yV(t,e){let n=-1,r=!0,i=0,o=[0,0,0,0],a=[0,0,0,0],s=!1,l=0,u,c,d,h=new Wh;for(;++n<t.length;){let p=t[n],m=p[1];p[0]==="enter"?m.type==="tableHead"?(s=!1,l!==0&&(j0(h,e,l,u,c),c=void 0,l=0),u={type:"table",start:Object.assign({},m.start),end:Object.assign({},m.end)},h.add(n,0,[["enter",u,e]])):m.type==="tableRow"||m.type==="tableDelimiterRow"?(r=!0,d=void 0,o=[0,0,0,0],a=[0,n+1,0,0],s&&(s=!1,c={type:"tableBody",start:Object.assign({},m.start),end:Object.assign({},m.end)},h.add(n,0,[["enter",c,e]])),i=m.type==="tableDelimiterRow"?2:c?3:1):i&&(m.type==="data"||m.type==="tableDelimiterMarker"||m.type==="tableDelimiterFiller")?(r=!1,a[2]===0&&(o[1]!==0&&(a[0]=a[1],d=_s(h,e,o,i,void 0,d),o=[0,0,0,0]),a[2]=n)):m.type==="tableCellDivider"&&(r?r=!1:(o[1]!==0&&(a[0]=a[1],d=_s(h,e,o,i,void 0,d)),o=a,a=[o[1],n,0,0])):m.type==="tableHead"?(s=!0,l=n):m.type==="tableRow"||m.type==="tableDelimiterRow"?(l=n,o[1]!==0?(a[0]=a[1],d=_s(h,e,o,i,n,d)):a[1]!==0&&(d=_s(h,e,a,i,n,d)),i=0):i&&(m.type==="data"||m.type==="tableDelimiterMarker"||m.type==="tableDelimiterFiller")&&(a[3]=n)}for(l!==0&&j0(h,e,l,u,c),h.consume(e.events),n=-1;++n<e.events.length;){let p=e.events[n];p[0]==="enter"&&p[1].type==="table"&&(p[1]._align=mV(e.events,n))}return t}function _s(t,e,n,r,i,o){let a=r===1?"tableHeader":r===2?"tableDelimiter":"tableData",s="tableContent";n[0]!==0&&(o.end=Object.assign({},di(e.events,n[0])),t.add(n[0],0,[["exit",o,e]]));let l=di(e.events,n[1]);if(o={type:a,start:Object.assign({},l),end:Object.assign({},l)},t.add(n[1],0,[["enter",o,e]]),n[2]!==0){let u=di(e.events,n[2]),c=di(e.events,n[3]),d={type:s,start:Object.assign({},u),end:Object.assign({},c)};if(t.add(n[2],0,[["enter",d,e]]),r!==2){let h=e.events[n[2]],p=e.events[n[3]];if(h[1].end=Object.assign({},p[1].end),h[1].type="chunkText",h[1].contentType="text",n[3]>n[2]+1){let m=n[2]+1,v=n[3]-n[2]-1;t.add(m,v,[])}}t.add(n[3]+1,0,[["exit",d,e]])}return i!==void 0&&(o.end=Object.assign({},di(e.events,i)),t.add(i,0,[["exit",o,e]]),o=void 0),o}function j0(t,e,n,r,i){let o=[],a=di(e.events,n);i&&(i.end=Object.assign({},a),o.push(["exit",i,e])),r.end=Object.assign({},a),o.push(["exit",r,e]),t.add(n+1,0,o)}function di(t,e){let n=t[e],r=n[0]==="enter"?"start":"end";return n[1][r]}var bV={name:"tasklistCheck",tokenize:wV};function xV(){return{text:{91:bV}}}function wV(t,e,n){let r=this;return i;function i(l){return r.previous!==null||!r._gfmTasklistFirstContentOfListItem?n(l):(t.enter("taskListCheck"),t.enter("taskListCheckMarker"),t.consume(l),t.exit("taskListCheckMarker"),o)}function o(l){return pt(l)?(t.enter("taskListCheckValueUnchecked"),t.consume(l),t.exit("taskListCheckValueUnchecked"),a):l===88||l===120?(t.enter("taskListCheckValueChecked"),t.consume(l),t.exit("taskListCheckValueChecked"),a):n(l)}function a(l){return l===93?(t.enter("taskListCheckMarker"),t.consume(l),t.exit("taskListCheckMarker"),t.exit("taskListCheck"),s):n(l)}function s(l){return $(l)?e(l):tt(l)?t.check({tokenize:kV},e,n)(l):n(l)}}function kV(t,e,n){return it(t,r,"whitespace");function r(i){return i===null?n(i):e(i)}}function SV(t){return jS([XF(),oV(),pV(t),gV(),xV()])}var TV={};function Wu(t){let e=this,n=t||TV,r=e.data(),i=r.micromarkExtensions||(r.micromarkExtensions=[]),o=r.fromMarkdownExtensions||(r.fromMarkdownExtensions=[]),a=r.toMarkdownExtensions||(r.toMarkdownExtensions=[]);i.push(SV(n)),o.push(WF()),a.push(qF(n))}function EV(t){if(typeof Proxy>"u")return t;let e=new Map,n=(...r)=>t(...r);return new Proxy(n,{get:(r,i)=>i==="create"?t:(e.has(i)||e.set(i,t(i)),e.get(i))})}function qu(t){return t!==null&&typeof t=="object"&&typeof t.start=="function"}var qh=t=>Array.isArray(t);function TT(t,e){if(!Array.isArray(e))return!1;let n=e.length;if(n!==t.length)return!1;for(let r=0;r<n;r++)if(e[r]!==t[r])return!1;return!0}function _a(t){return typeof t=="string"||Array.isArray(t)}function O0(t){let e=[{},{}];return t?.values.forEach((n,r)=>{e[0][r]=n.get(),e[1][r]=n.getVelocity()}),e}function Sm(t,e,n,r){if(typeof e=="function"){let[i,o]=O0(r);e=e(n!==void 0?n:t.custom,i,o)}if(typeof e=="string"&&(e=t.variants&&t.variants[e]),typeof e=="function"){let[i,o]=O0(r);e=e(n!==void 0?n:t.custom,i,o)}return e}function Yu(t,e,n){let r=t.getProps();return Sm(r,e,n!==void 0?n:r.custom,t)}var Tm=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],Em=["initial",...Tm],ts=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],oi=new Set(ts),On=t=>t*1e3,_n=t=>t/1e3,CV={type:"spring",stiffness:500,damping:25,restSpeed:10},PV=t=>({type:"spring",stiffness:550,damping:t===0?2*Math.sqrt(550):30,restSpeed:10}),AV={type:"keyframes",duration:.8},MV={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},DV=(t,{keyframes:e})=>e.length>2?AV:oi.has(t)?t.startsWith("scale")?PV(e[1]):CV:MV;function Cm(t,e){return t?t[e]||t.default||t:void 0}var RV={skipAnimations:!1,useManualTiming:!1},IV=t=>t!==null;function Ku(t,{repeat:e,repeatType:n="loop"},r){let i=t.filter(IV),o=e&&n!=="loop"&&e%2===1?0:i.length-1;return!o||r===void 0?i[o]:r}var ie=t=>t;function LV(t){let e=new Set,n=new Set,r=!1,i=!1,o=new WeakSet,a={delta:0,timestamp:0,isProcessing:!1};function s(u){o.has(u)&&(l.schedule(u),t()),u(a)}let l={schedule:(u,c=!1,d=!1)=>{let h=d&&r?e:n;return c&&o.add(u),h.has(u)||h.add(u),u},cancel:u=>{n.delete(u),o.delete(u)},process:u=>{if(a=u,r){i=!0;return}r=!0,[e,n]=[n,e],n.clear(),e.forEach(s),r=!1,i&&(i=!1,l.process(u))}};return l}var Ns=["read","resolveKeyframes","update","preRender","render","postRender"],jV=40;function ET(t,e){let n=!1,r=!0,i={delta:0,timestamp:0,isProcessing:!1},o=()=>n=!0,a=Ns.reduce((v,b)=>(v[b]=LV(o),v),{}),{read:s,resolveKeyframes:l,update:u,preRender:c,render:d,postRender:h}=a,p=()=>{let v=performance.now();n=!1,i.delta=r?1e3/60:Math.max(Math.min(v-i.timestamp,jV),1),i.timestamp=v,i.isProcessing=!0,s.process(i),l.process(i),u.process(i),c.process(i),d.process(i),h.process(i),i.isProcessing=!1,n&&e&&(r=!1,t(p))},m=()=>{n=!0,r=!0,i.isProcessing||t(p)};return{schedule:Ns.reduce((v,b)=>{let f=a[b];return v[b]=(g,y=!1,w=!1)=>(n||m(),f.schedule(g,y,w)),v},{}),cancel:v=>{for(let b=0;b<Ns.length;b++)a[Ns[b]].cancel(v)},state:i,steps:a}}var{schedule:dt,cancel:yr,state:Wt,steps:ed}=ET(typeof requestAnimationFrame<"u"?requestAnimationFrame:ie,!0),CT=(t,e,n)=>(((1-3*n+3*e)*t+(3*n-6*e))*t+3*e)*t,OV=1e-7,_V=12;function NV(t,e,n,r,i){let o,a,s=0;do a=e+(n-e)/2,o=CT(a,r,i)-t,o>0?n=a:e=a;while(Math.abs(o)>OV&&++s<_V);return a}function es(t,e,n,r){if(t===e&&n===r)return ie;let i=o=>NV(o,0,1,t,n);return o=>o===0||o===1?o:CT(i(o),e,r)}var PT=t=>e=>e<=.5?t(2*e)/2:(2-t(2*(1-e)))/2,AT=t=>e=>1-t(1-e),MT=es(.33,1.53,.69,.99),Pm=AT(MT),DT=PT(Pm),RT=t=>(t*=2)<1?.5*Pm(t):.5*(2-Math.pow(2,-10*(t-1))),Am=t=>1-Math.sin(Math.acos(t)),IT=AT(Am),LT=PT(Am),jT=t=>/^0[^.\s]+$/u.test(t);function FV(t){return typeof t=="number"?t===0:t!==null?t==="none"||t==="0"||jT(t):!0}var Yh=ie,OT=t=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(t),_T=t=>e=>typeof e=="string"&&e.startsWith(t),NT=_T("--"),VV=_T("var(--"),Mm=t=>VV(t)?zV.test(t.split("/*")[0].trim()):!1,zV=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu,BV=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function UV(t){let e=BV.exec(t);if(!e)return[,];let[,n,r,i]=e;return[`--${n??r}`,i]}function FT(t,e,n=1){let[r,i]=UV(t);if(!r)return;let o=window.getComputedStyle(e).getPropertyValue(r);if(o){let a=o.trim();return OT(a)?parseFloat(a):a}return Mm(i)?FT(i,e,n+1):i}var br=(t,e,n)=>n>e?e:n<t?t:n,ho={test:t=>typeof t=="number",parse:parseFloat,transform:t=>t},Na={...ho,transform:t=>br(0,1,t)},Fs={...ho,default:1},ns=t=>({test:e=>typeof e=="string"&&e.endsWith(t)&&e.split(" ").length===1,parse:parseFloat,transform:e=>`${e}${t}`}),Xn=ns("deg"),mn=ns("%"),q=ns("px"),$V=ns("vh"),HV=ns("vw"),_0={...mn,parse:t=>mn.parse(t)/100,transform:t=>mn.transform(t*100)},WV=new Set(["width","height","top","left","right","bottom","x","y","translateX","translateY"]),N0=t=>t===ho||t===q,F0=(t,e)=>parseFloat(t.split(", ")[e]),V0=(t,e)=>(n,{transform:r})=>{if(r==="none"||!r)return 0;let i=r.match(/^matrix3d\((.+)\)$/u);if(i)return F0(i[1],e);{let o=r.match(/^matrix\((.+)\)$/u);return o?F0(o[1],t):0}},qV=new Set(["x","y","z"]),YV=ts.filter(t=>!qV.has(t));function KV(t){let e=[];return YV.forEach(n=>{let r=t.getValue(n);r!==void 0&&(e.push([n,r.get()]),r.set(n.startsWith("scale")?1:0))}),e}var to={width:({x:t},{paddingLeft:e="0",paddingRight:n="0"})=>t.max-t.min-parseFloat(e)-parseFloat(n),height:({y:t},{paddingTop:e="0",paddingBottom:n="0"})=>t.max-t.min-parseFloat(e)-parseFloat(n),top:(t,{top:e})=>parseFloat(e),left:(t,{left:e})=>parseFloat(e),bottom:({y:t},{top:e})=>parseFloat(e)+(t.max-t.min),right:({x:t},{left:e})=>parseFloat(e)+(t.max-t.min),x:V0(4,13),y:V0(5,14)};to.translateX=to.x;to.translateY=to.y;var VT=t=>e=>e.test(t),XV={test:t=>t==="auto",parse:t=>t},zT=[ho,q,mn,Xn,HV,$V,XV],z0=t=>zT.find(VT(t)),qr=new Set,Kh=!1,Xh=!1;function BT(){if(Xh){let t=Array.from(qr).filter(r=>r.needsMeasurement),e=new Set(t.map(r=>r.element)),n=new Map;e.forEach(r=>{let i=KV(r);i.length&&(n.set(r,i),r.render())}),t.forEach(r=>r.measureInitialState()),e.forEach(r=>{r.render();let i=n.get(r);i&&i.forEach(([o,a])=>{var s;(s=r.getValue(o))===null||s===void 0||s.set(a)})}),t.forEach(r=>r.measureEndState()),t.forEach(r=>{r.suspendedScrollY!==void 0&&window.scrollTo(0,r.suspendedScrollY)})}Xh=!1,Kh=!1,qr.forEach(t=>t.complete()),qr.clear()}function UT(){qr.forEach(t=>{t.readKeyframes(),t.needsMeasurement&&(Xh=!0)})}function GV(){UT(),BT()}var Fa=class{constructor(e,n,r,i,o,a=!1){this.isComplete=!1,this.isAsync=!1,this.needsMeasurement=!1,this.isScheduled=!1,this.unresolvedKeyframes=[...e],this.onComplete=n,this.name=r,this.motionValue=i,this.element=o,this.isAsync=a}scheduleResolve(){this.isScheduled=!0,this.isAsync?(qr.add(this),Kh||(Kh=!0,dt.read(UT),dt.resolveKeyframes(BT))):(this.readKeyframes(),this.complete())}readKeyframes(){let{unresolvedKeyframes:e,name:n,element:r,motionValue:i}=this;for(let o=0;o<e.length;o++)if(e[o]===null)if(o===0){let a=i?.get(),s=e[e.length-1];if(a!==void 0)e[0]=a;else if(r&&n){let l=r.readValue(n,s);l!=null&&(e[0]=l)}e[0]===void 0&&(e[0]=s),i&&a===void 0&&i.set(e[0])}else e[o]=e[o-1]}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(){this.isComplete=!0,this.onComplete(this.unresolvedKeyframes,this.finalKeyframe),qr.delete(this)}cancel(){this.isComplete||(this.isScheduled=!1,qr.delete(this))}resume(){this.isComplete||this.scheduleResolve()}},Qo=t=>Math.round(t*1e5)/1e5,Dm=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function QV(t){return t==null}var JV=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,Rm=(t,e)=>n=>!!(typeof n=="string"&&JV.test(n)&&n.startsWith(t)||e&&!QV(n)&&Object.prototype.hasOwnProperty.call(n,e)),$T=(t,e,n)=>r=>{if(typeof r!="string")return r;let[i,o,a,s]=r.match(Dm);return{[t]:parseFloat(i),[e]:parseFloat(o),[n]:parseFloat(a),alpha:s!==void 0?parseFloat(s):1}},ZV=t=>br(0,255,t),nd={...ho,transform:t=>Math.round(ZV(t))},Br={test:Rm("rgb","red"),parse:$T("red","green","blue"),transform:({red:t,green:e,blue:n,alpha:r=1})=>"rgba("+nd.transform(t)+", "+nd.transform(e)+", "+nd.transform(n)+", "+Qo(Na.transform(r))+")"};function t5(t){let e="",n="",r="",i="";return t.length>5?(e=t.substring(1,3),n=t.substring(3,5),r=t.substring(5,7),i=t.substring(7,9)):(e=t.substring(1,2),n=t.substring(2,3),r=t.substring(3,4),i=t.substring(4,5),e+=e,n+=n,r+=r,i+=i),{red:parseInt(e,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:i?parseInt(i,16)/255:1}}var Gh={test:Rm("#"),parse:t5,transform:Br.transform},Mi={test:Rm("hsl","hue"),parse:$T("hue","saturation","lightness"),transform:({hue:t,saturation:e,lightness:n,alpha:r=1})=>"hsla("+Math.round(t)+", "+mn.transform(Qo(e))+", "+mn.transform(Qo(n))+", "+Qo(Na.transform(r))+")"},Jt={test:t=>Br.test(t)||Gh.test(t)||Mi.test(t),parse:t=>Br.test(t)?Br.parse(t):Mi.test(t)?Mi.parse(t):Gh.parse(t),transform:t=>typeof t=="string"?t:t.hasOwnProperty("red")?Br.transform(t):Mi.transform(t)},e5=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function n5(t){var e,n;return isNaN(t)&&typeof t=="string"&&(((e=t.match(Dm))===null||e===void 0?void 0:e.length)||0)+(((n=t.match(e5))===null||n===void 0?void 0:n.length)||0)>0}var HT="number",WT="color",r5="var",i5="var(",B0="${}",o5=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function Va(t){let e=t.toString(),n=[],r={color:[],number:[],var:[]},i=[],o=0,a=e.replace(o5,s=>(Jt.test(s)?(r.color.push(o),i.push(WT),n.push(Jt.parse(s))):s.startsWith(i5)?(r.var.push(o),i.push(r5),n.push(s)):(r.number.push(o),i.push(HT),n.push(parseFloat(s))),++o,B0)).split(B0);return{values:n,split:a,indexes:r,types:i}}function qT(t){return Va(t).values}function YT(t){let{split:e,types:n}=Va(t),r=e.length;return i=>{let o="";for(let a=0;a<r;a++)if(o+=e[a],i[a]!==void 0){let s=n[a];s===HT?o+=Qo(i[a]):s===WT?o+=Jt.transform(i[a]):o+=i[a]}return o}}var a5=t=>typeof t=="number"?0:t;function s5(t){let e=qT(t);return YT(t)(e.map(a5))}var xr={test:n5,parse:qT,createTransformer:YT,getAnimatableNone:s5},l5=new Set(["brightness","contrast","saturate","opacity"]);function u5(t){let[e,n]=t.slice(0,-1).split("(");if(e==="drop-shadow")return t;let[r]=n.match(Dm)||[];if(!r)return t;let i=n.replace(r,""),o=l5.has(e)?1:0;return r!==n&&(o*=100),e+"("+o+i+")"}var c5=/\b([a-z-]*)\(.*?\)/gu,Qh={...xr,getAnimatableNone:t=>{let e=t.match(c5);return e?e.map(u5).join(" "):t}},d5={borderWidth:q,borderTopWidth:q,borderRightWidth:q,borderBottomWidth:q,borderLeftWidth:q,borderRadius:q,radius:q,borderTopLeftRadius:q,borderTopRightRadius:q,borderBottomRightRadius:q,borderBottomLeftRadius:q,width:q,maxWidth:q,height:q,maxHeight:q,top:q,right:q,bottom:q,left:q,padding:q,paddingTop:q,paddingRight:q,paddingBottom:q,paddingLeft:q,margin:q,marginTop:q,marginRight:q,marginBottom:q,marginLeft:q,backgroundPositionX:q,backgroundPositionY:q},h5={rotate:Xn,rotateX:Xn,rotateY:Xn,rotateZ:Xn,scale:Fs,scaleX:Fs,scaleY:Fs,scaleZ:Fs,skew:Xn,skewX:Xn,skewY:Xn,distance:q,translateX:q,translateY:q,translateZ:q,x:q,y:q,z:q,perspective:q,transformPerspective:q,opacity:Na,originX:_0,originY:_0,originZ:q},U0={...ho,transform:Math.round},Im={...d5,...h5,zIndex:U0,size:q,fillOpacity:Na,strokeOpacity:Na,numOctaves:U0},p5={...Im,color:Jt,backgroundColor:Jt,outlineColor:Jt,fill:Jt,stroke:Jt,borderColor:Jt,borderTopColor:Jt,borderRightColor:Jt,borderBottomColor:Jt,borderLeftColor:Jt,filter:Qh,WebkitFilter:Qh},Lm=t=>p5[t];function KT(t,e){let n=Lm(t);return n!==Qh&&(n=xr),n.getAnimatableNone?n.getAnimatableNone(e):void 0}var f5=new Set(["auto","none","0"]);function m5(t,e,n){let r=0,i;for(;r<t.length&&!i;){let o=t[r];typeof o=="string"&&!f5.has(o)&&Va(o).values.length&&(i=t[r]),r++}if(i&&n)for(let o of e)t[o]=KT(n,i)}var Jl=class extends Fa{constructor(e,n,r,i,o){super(e,n,r,i,o,!0)}readKeyframes(){let{unresolvedKeyframes:e,element:n,name:r}=this;if(!n||!n.current)return;super.readKeyframes();for(let l=0;l<e.length;l++){let u=e[l];if(typeof u=="string"&&(u=u.trim(),Mm(u))){let c=FT(u,n.current);c!==void 0&&(e[l]=c),l===e.length-1&&(this.finalKeyframe=u)}}if(this.resolveNoneKeyframes(),!WV.has(r)||e.length!==2)return;let[i,o]=e,a=z0(i),s=z0(o);if(a!==s)if(N0(a)&&N0(s))for(let l=0;l<e.length;l++){let u=e[l];typeof u=="string"&&(e[l]=parseFloat(u))}else this.needsMeasurement=!0}resolveNoneKeyframes(){let{unresolvedKeyframes:e,name:n}=this,r=[];for(let i=0;i<e.length;i++)FV(e[i])&&r.push(i);r.length&&m5(e,r,n)}measureInitialState(){let{element:e,unresolvedKeyframes:n,name:r}=this;if(!e||!e.current)return;r==="height"&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=to[r](e.measureViewportBox(),window.getComputedStyle(e.current)),n[0]=this.measuredOrigin;let i=n[n.length-1];i!==void 0&&e.getValue(r,i).jump(i,!1)}measureEndState(){var e;let{element:n,name:r,unresolvedKeyframes:i}=this;if(!n||!n.current)return;let o=n.getValue(r);o&&o.jump(this.measuredOrigin,!1);let a=i.length-1,s=i[a];i[a]=to[r](n.measureViewportBox(),window.getComputedStyle(n.current)),s!==null&&this.finalKeyframe===void 0&&(this.finalKeyframe=s),!((e=this.removedTransforms)===null||e===void 0)&&e.length&&this.removedTransforms.forEach(([l,u])=>{n.getValue(l).set(u)}),this.resolveNoneKeyframes()}};function jm(t){return typeof t=="function"}var al;function g5(){al=void 0}var gn={now:()=>(al===void 0&&gn.set(Wt.isProcessing||RV.useManualTiming?Wt.timestamp:performance.now()),al),set:t=>{al=t,queueMicrotask(g5)}},$0=(t,e)=>e==="zIndex"?!1:!!(typeof t=="number"||Array.isArray(t)||typeof t=="string"&&(xr.test(t)||t==="0")&&!t.startsWith("url("));function v5(t){let e=t[0];if(t.length===1)return!0;for(let n=0;n<t.length;n++)if(t[n]!==e)return!0}function y5(t,e,n,r){let i=t[0];if(i===null)return!1;if(e==="display"||e==="visibility")return!0;let o=t[t.length-1],a=$0(i,e),s=$0(o,e);return!a||!s?!1:v5(t)||(n==="spring"||jm(n))&&r}var b5=40,Zl=class{constructor({autoplay:e=!0,delay:n=0,type:r="keyframes",repeat:i=0,repeatDelay:o=0,repeatType:a="loop",...s}){this.isStopped=!1,this.hasAttemptedResolve=!1,this.createdAt=gn.now(),this.options={autoplay:e,delay:n,type:r,repeat:i,repeatDelay:o,repeatType:a,...s},this.updateFinishedPromise()}calcStartTime(){return this.resolvedAt?this.resolvedAt-this.createdAt>b5?this.resolvedAt:this.createdAt:this.createdAt}get resolved(){return!this._resolved&&!this.hasAttemptedResolve&&GV(),this._resolved}onKeyframesResolved(e,n){this.resolvedAt=gn.now(),this.hasAttemptedResolve=!0;let{name:r,type:i,velocity:o,delay:a,onComplete:s,onUpdate:l,isGenerator:u}=this.options;if(!u&&!y5(e,r,i,o))if(a)this.options.duration=0;else{l?.(Ku(e,this.options,n)),s?.(),this.resolveFinishedPromise();return}let c=this.initPlayback(e,n);c!==!1&&(this._resolved={keyframes:e,finalKeyframe:n,...c},this.onPostResolved())}onPostResolved(){}then(e,n){return this.currentFinishedPromise.then(e,n)}flatten(){this.options.type="keyframes",this.options.ease="linear"}updateFinishedPromise(){this.currentFinishedPromise=new Promise(e=>{this.resolveFinishedPromise=e})}};function XT(t,e){return e?t*(1e3/e):0}var x5=5;function GT(t,e,n){let r=Math.max(e-x5,0);return XT(n-t(r),e-r)}var rd=.001,w5=.01,k5=10,S5=.05,T5=1;function E5({duration:t=800,bounce:e=.25,velocity:n=0,mass:r=1}){let i,o,a=1-e;a=br(S5,T5,a),t=br(w5,k5,_n(t)),a<1?(i=u=>{let c=u*a,d=c*t,h=c-n,p=Jh(u,a),m=Math.exp(-d);return rd-h/p*m},o=u=>{let c=u*a*t,d=c*n+n,h=Math.pow(a,2)*Math.pow(u,2)*t,p=Math.exp(-c),m=Jh(Math.pow(u,2),a);return(-i(u)+rd>0?-1:1)*((d-h)*p)/m}):(i=u=>{let c=Math.exp(-u*t),d=(u-n)*t+1;return-rd+c*d},o=u=>{let c=Math.exp(-u*t),d=(n-u)*(t*t);return c*d});let s=5/t,l=P5(i,o,s);if(t=On(t),isNaN(l))return{stiffness:100,damping:10,duration:t};{let u=Math.pow(l,2)*r;return{stiffness:u,damping:a*2*Math.sqrt(r*u),duration:t}}}var C5=12;function P5(t,e,n){let r=n;for(let i=1;i<C5;i++)r=r-t(r)/e(r);return r}function Jh(t,e){return t*Math.sqrt(1-e*e)}var A5=["duration","bounce"],M5=["stiffness","damping","mass"];function H0(t,e){return e.some(n=>t[n]!==void 0)}function D5(t){let e={velocity:0,stiffness:100,damping:10,mass:1,isResolvedFromDuration:!1,...t};if(!H0(t,M5)&&H0(t,A5)){let n=E5(t);e={...e,...n,mass:1},e.isResolvedFromDuration=!0}return e}function QT({keyframes:t,restDelta:e,restSpeed:n,...r}){let i=t[0],o=t[t.length-1],a={done:!1,value:i},{stiffness:s,damping:l,mass:u,duration:c,velocity:d,isResolvedFromDuration:h}=D5({...r,velocity:-_n(r.velocity||0)}),p=d||0,m=l/(2*Math.sqrt(s*u)),v=o-i,b=_n(Math.sqrt(s/u)),f=Math.abs(v)<5;n||(n=f?.01:2),e||(e=f?.005:.5);let g;if(m<1){let y=Jh(b,m);g=w=>{let C=Math.exp(-m*b*w);return o-C*((p+m*b*v)/y*Math.sin(y*w)+v*Math.cos(y*w))}}else if(m===1)g=y=>o-Math.exp(-b*y)*(v+(p+b*v)*y);else{let y=b*Math.sqrt(m*m-1);g=w=>{let C=Math.exp(-m*b*w),k=Math.min(y*w,300);return o-C*((p+m*b*v)*Math.sinh(k)+y*v*Math.cosh(k))/y}}return{calculatedDuration:h&&c||null,next:y=>{let w=g(y);if(h)a.done=y>=c;else{let C=0;m<1&&(C=y===0?On(p):GT(g,y,w));let k=Math.abs(C)<=n,M=Math.abs(o-w)<=e;a.done=k&&M}return a.value=a.done?o:w,a}}}function W0({keyframes:t,velocity:e=0,power:n=.8,timeConstant:r=325,bounceDamping:i=10,bounceStiffness:o=500,modifyTarget:a,min:s,max:l,restDelta:u=.5,restSpeed:c}){let d=t[0],h={done:!1,value:d},p=P=>s!==void 0&&P<s||l!==void 0&&P>l,m=P=>s===void 0?l:l===void 0||Math.abs(s-P)<Math.abs(l-P)?s:l,v=n*e,b=d+v,f=a===void 0?b:a(b);f!==b&&(v=f-d);let g=P=>-v*Math.exp(-P/r),y=P=>f+g(P),w=P=>{let R=g(P),E=y(P);h.done=Math.abs(R)<=u,h.value=h.done?f:E},C,k,M=P=>{p(h.value)&&(C=P,k=QT({keyframes:[h.value,m(h.value)],velocity:GT(y,P,h.value),damping:i,stiffness:o,restDelta:u,restSpeed:c}))};return M(0),{calculatedDuration:null,next:P=>{let R=!1;return!k&&C===void 0&&(R=!0,w(P),M(P)),C!==void 0&&P>=C?k.next(P-C):(!R&&w(P),h)}}}var R5=es(.42,0,1,1),I5=es(0,0,.58,1),JT=es(.42,0,.58,1),L5=t=>Array.isArray(t)&&typeof t[0]!="number",Om=t=>Array.isArray(t)&&typeof t[0]=="number",q0={linear:ie,easeIn:R5,easeInOut:JT,easeOut:I5,circIn:Am,circInOut:LT,circOut:IT,backIn:Pm,backInOut:DT,backOut:MT,anticipate:RT},Y0=t=>{if(Om(t)){Yh(t.length===4);let[e,n,r,i]=t;return es(e,n,r,i)}else if(typeof t=="string")return Yh(q0[t]!==void 0),q0[t];return t},j5=(t,e)=>n=>e(t(n)),Nn=(...t)=>t.reduce(j5),eo=(t,e,n)=>{let r=e-t;return r===0?1:(n-t)/r},Ct=(t,e,n)=>t+(e-t)*n;function id(t,e,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?t+(e-t)*6*n:n<1/2?e:n<2/3?t+(e-t)*(2/3-n)*6:t}function O5({hue:t,saturation:e,lightness:n,alpha:r}){t/=360,e/=100,n/=100;let i=0,o=0,a=0;if(!e)i=o=a=n;else{let s=n<.5?n*(1+e):n+e-n*e,l=2*n-s;i=id(l,s,t+1/3),o=id(l,s,t),a=id(l,s,t-1/3)}return{red:Math.round(i*255),green:Math.round(o*255),blue:Math.round(a*255),alpha:r}}function tu(t,e){return n=>n>0?e:t}var od=(t,e,n)=>{let r=t*t,i=n*(e*e-r)+r;return i<0?0:Math.sqrt(i)},_5=[Gh,Br,Mi],N5=t=>_5.find(e=>e.test(t));function K0(t){let e=N5(t);if(!e)return!1;let n=e.parse(t);return e===Mi&&(n=O5(n)),n}var X0=(t,e)=>{let n=K0(t),r=K0(e);if(!n||!r)return tu(t,e);let i={...n};return o=>(i.red=od(n.red,r.red,o),i.green=od(n.green,r.green,o),i.blue=od(n.blue,r.blue,o),i.alpha=Ct(n.alpha,r.alpha,o),Br.transform(i))},Zh=new Set(["none","hidden"]);function F5(t,e){return Zh.has(t)?n=>n<=0?t:e:n=>n>=1?e:t}function V5(t,e){return n=>Ct(t,e,n)}function _m(t){return typeof t=="number"?V5:typeof t=="string"?Mm(t)?tu:Jt.test(t)?X0:U5:Array.isArray(t)?ZT:typeof t=="object"?Jt.test(t)?X0:z5:tu}function ZT(t,e){let n=[...t],r=n.length,i=t.map((o,a)=>_m(o)(o,e[a]));return o=>{for(let a=0;a<r;a++)n[a]=i[a](o);return n}}function z5(t,e){let n={...t,...e},r={};for(let i in n)t[i]!==void 0&&e[i]!==void 0&&(r[i]=_m(t[i])(t[i],e[i]));return i=>{for(let o in r)n[o]=r[o](i);return n}}function B5(t,e){var n;let r=[],i={color:0,var:0,number:0};for(let o=0;o<e.values.length;o++){let a=e.types[o],s=t.indexes[a][i[a]],l=(n=t.values[s])!==null&&n!==void 0?n:0;r[o]=l,i[a]++}return r}var U5=(t,e)=>{let n=xr.createTransformer(e),r=Va(t),i=Va(e);return r.indexes.var.length===i.indexes.var.length&&r.indexes.color.length===i.indexes.color.length&&r.indexes.number.length>=i.indexes.number.length?Zh.has(t)&&!i.values.length||Zh.has(e)&&!r.values.length?F5(t,e):Nn(ZT(B5(r,i),i.values),n):tu(t,e)};function tE(t,e,n){return typeof t=="number"&&typeof e=="number"&&typeof n=="number"?Ct(t,e,n):_m(t)(t,e)}function $5(t,e,n){let r=[],i=n||tE,o=t.length-1;for(let a=0;a<o;a++){let s=i(t[a],t[a+1]);if(e){let l=Array.isArray(e)?e[a]||ie:e;s=Nn(l,s)}r.push(s)}return r}function H5(t,e,{clamp:n=!0,ease:r,mixer:i}={}){let o=t.length;if(Yh(o===e.length),o===1)return()=>e[0];if(o===2&&t[0]===t[1])return()=>e[1];t[0]>t[o-1]&&(t=[...t].reverse(),e=[...e].reverse());let a=$5(e,r,i),s=a.length,l=u=>{let c=0;if(s>1)for(;c<t.length-2&&!(u<t[c+1]);c++);let d=eo(t[c],t[c+1],u);return a[c](d)};return n?u=>l(br(t[0],t[o-1],u)):l}function W5(t,e){let n=t[t.length-1];for(let r=1;r<=e;r++){let i=eo(0,e,r);t.push(Ct(n,1,i))}}function q5(t){let e=[0];return W5(e,t.length-1),e}function Y5(t,e){return t.map(n=>n*e)}function K5(t,e){return t.map(()=>e||JT).splice(0,t.length-1)}function eu({duration:t=300,keyframes:e,times:n,ease:r="easeInOut"}){let i=L5(r)?r.map(Y0):Y0(r),o={done:!1,value:e[0]},a=Y5(n&&n.length===e.length?n:q5(e),t),s=H5(a,e,{ease:Array.isArray(i)?i:K5(e,i)});return{calculatedDuration:t,next:l=>(o.value=s(l),o.done=l>=t,o)}}var G0=2e4;function X5(t){let e=0,n=50,r=t.next(e);for(;!r.done&&e<G0;)e+=n,r=t.next(e);return e>=G0?1/0:e}var G5=t=>{let e=({timestamp:n})=>t(n);return{start:()=>dt.update(e,!0),stop:()=>yr(e),now:()=>Wt.isProcessing?Wt.timestamp:gn.now()}},Q5={decay:W0,inertia:W0,tween:eu,keyframes:eu,spring:QT},J5=t=>t/100,za=class extends Zl{constructor(e){super(e),this.holdTime=null,this.cancelTime=null,this.currentTime=0,this.playbackSpeed=1,this.pendingPlayState="running",this.startTime=null,this.state="idle",this.stop=()=>{if(this.resolver.cancel(),this.isStopped=!0,this.state==="idle")return;this.teardown();let{onStop:l}=this.options;l&&l()};let{name:n,motionValue:r,element:i,keyframes:o}=this.options,a=i?.KeyframeResolver||Fa,s=(l,u)=>this.onKeyframesResolved(l,u);this.resolver=new a(o,s,n,r,i),this.resolver.scheduleResolve()}flatten(){super.flatten(),this._resolved&&Object.assign(this._resolved,this.initPlayback(this._resolved.keyframes))}initPlayback(e){let{type:n="keyframes",repeat:r=0,repeatDelay:i=0,repeatType:o,velocity:a=0}=this.options,s=jm(n)?n:Q5[n]||eu,l,u;s!==eu&&typeof e[0]!="number"&&(l=Nn(J5,tE(e[0],e[1])),e=[0,100]);let c=s({...this.options,keyframes:e});o==="mirror"&&(u=s({...this.options,keyframes:[...e].reverse(),velocity:-a})),c.calculatedDuration===null&&(c.calculatedDuration=X5(c));let{calculatedDuration:d}=c,h=d+i,p=h*(r+1)-i;return{generator:c,mirroredGenerator:u,mapPercentToKeyframes:l,calculatedDuration:d,resolvedDuration:h,totalDuration:p}}onPostResolved(){let{autoplay:e=!0}=this.options;this.play(),this.pendingPlayState==="paused"||!e?this.pause():this.state=this.pendingPlayState}tick(e,n=!1){let{resolved:r}=this;if(!r){let{keyframes:P}=this.options;return{done:!0,value:P[P.length-1]}}let{finalKeyframe:i,generator:o,mirroredGenerator:a,mapPercentToKeyframes:s,keyframes:l,calculatedDuration:u,totalDuration:c,resolvedDuration:d}=r;if(this.startTime===null)return o.next(0);let{delay:h,repeat:p,repeatType:m,repeatDelay:v,onUpdate:b}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,e):this.speed<0&&(this.startTime=Math.min(e-c/this.speed,this.startTime)),n?this.currentTime=e:this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=Math.round(e-this.startTime)*this.speed;let f=this.currentTime-h*(this.speed>=0?1:-1),g=this.speed>=0?f<0:f>c;this.currentTime=Math.max(f,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=c);let y=this.currentTime,w=o;if(p){let P=Math.min(this.currentTime,c)/d,R=Math.floor(P),E=P%1;!E&&P>=1&&(E=1),E===1&&R--,R=Math.min(R,p+1),R%2&&(m==="reverse"?(E=1-E,v&&(E-=v/d)):m==="mirror"&&(w=a)),y=br(0,1,E)*d}let C=g?{done:!1,value:l[0]}:w.next(y);s&&(C.value=s(C.value));let{done:k}=C;!g&&u!==null&&(k=this.speed>=0?this.currentTime>=c:this.currentTime<=0);let M=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&k);return M&&i!==void 0&&(C.value=Ku(l,this.options,i)),b&&b(C.value),M&&this.finish(),C}get duration(){let{resolved:e}=this;return e?_n(e.calculatedDuration):0}get time(){return _n(this.currentTime)}set time(e){e=On(e),this.currentTime=e,this.holdTime!==null||this.speed===0?this.holdTime=e:this.driver&&(this.startTime=this.driver.now()-e/this.speed)}get speed(){return this.playbackSpeed}set speed(e){let n=this.playbackSpeed!==e;this.playbackSpeed=e,n&&(this.time=_n(this.currentTime))}play(){if(this.resolver.isScheduled||this.resolver.resume(),!this._resolved){this.pendingPlayState="running";return}if(this.isStopped)return;let{driver:e=G5,onPlay:n,startTime:r}=this.options;this.driver||(this.driver=e(o=>this.tick(o))),n&&n();let i=this.driver.now();this.holdTime!==null?this.startTime=i-this.holdTime:this.startTime?this.state==="finished"&&(this.startTime=i):this.startTime=r??this.calcStartTime(),this.state==="finished"&&this.updateFinishedPromise(),this.cancelTime=this.startTime,this.holdTime=null,this.state="running",this.driver.start()}pause(){var e;if(!this._resolved){this.pendingPlayState="paused";return}this.state="paused",this.holdTime=(e=this.currentTime)!==null&&e!==void 0?e:0}complete(){this.state!=="running"&&this.play(),this.pendingPlayState=this.state="finished",this.holdTime=null}finish(){this.teardown(),this.state="finished";let{onComplete:e}=this.options;e&&e()}cancel(){this.cancelTime!==null&&this.tick(this.cancelTime),this.teardown(),this.updateFinishedPromise()}teardown(){this.state="idle",this.stopDriver(),this.resolveFinishedPromise(),this.updateFinishedPromise(),this.startTime=this.cancelTime=null,this.resolver.cancel()}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(e){return this.startTime=0,this.tick(e,!0)}},Z5=new Set(["opacity","clipPath","filter","transform"]),tz=10,ez=(t,e)=>{let n="",r=Math.max(Math.round(e/tz),2);for(let i=0;i<r;i++)n+=t(eo(0,r-1,i))+", ";return`linear(${n.substring(0,n.length-2)})`};function Nm(t){let e;return()=>(e===void 0&&(e=t()),e)}var nz={linearEasing:void 0};function rz(t,e){let n=Nm(t);return()=>{var r;return(r=nz[e])!==null&&r!==void 0?r:n()}}var nu=rz(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing");function eE(t){return!!(typeof t=="function"&&nu()||!t||typeof t=="string"&&(t in tp||nu())||Om(t)||Array.isArray(t)&&t.every(eE))}var Oo=([t,e,n,r])=>`cubic-bezier(${t}, ${e}, ${n}, ${r})`,tp={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:Oo([0,.65,.55,1]),circOut:Oo([.55,0,1,.45]),backIn:Oo([.31,.01,.66,-.59]),backOut:Oo([.33,1.53,.69,.99])};function nE(t,e){if(t)return typeof t=="function"&&nu()?ez(t,e):Om(t)?Oo(t):Array.isArray(t)?t.map(n=>nE(n,e)||tp.easeOut):tp[t]}function iz(t,e,n,{delay:r=0,duration:i=300,repeat:o=0,repeatType:a="loop",ease:s="easeInOut",times:l}={}){let u={[e]:n};l&&(u.offset=l);let c=nE(s,i);return Array.isArray(c)&&(u.easing=c),t.animate(u,{delay:r,duration:i,easing:Array.isArray(c)?"linear":c,fill:"both",iterations:o+1,direction:a==="reverse"?"alternate":"normal"})}function Q0(t,e){t.timeline=e,t.onfinish=null}var oz=Nm(()=>Object.hasOwnProperty.call(Element.prototype,"animate")),ru=10,az=2e4;function sz(t){return jm(t.type)||t.type==="spring"||!eE(t.ease)}function lz(t,e){let n=new za({...e,keyframes:t,repeat:0,delay:0,isGenerator:!0}),r={done:!1,value:t[0]},i=[],o=0;for(;!r.done&&o<az;)r=n.sample(o),i.push(r.value),o+=ru;return{times:void 0,keyframes:i,duration:o-ru,ease:"linear"}}var rE={anticipate:RT,backInOut:DT,circInOut:LT};function uz(t){return t in rE}var iu=class extends Zl{constructor(e){super(e);let{name:n,motionValue:r,element:i,keyframes:o}=this.options;this.resolver=new Jl(o,(a,s)=>this.onKeyframesResolved(a,s),n,r,i),this.resolver.scheduleResolve()}initPlayback(e,n){var r;let{duration:i=300,times:o,ease:a,type:s,motionValue:l,name:u,startTime:c}=this.options;if(!(!((r=l.owner)===null||r===void 0)&&r.current))return!1;if(typeof a=="string"&&nu()&&uz(a)&&(a=rE[a]),sz(this.options)){let{onComplete:h,onUpdate:p,motionValue:m,element:v,...b}=this.options,f=lz(e,b);e=f.keyframes,e.length===1&&(e[1]=e[0]),i=f.duration,o=f.times,a=f.ease,s="keyframes"}let d=iz(l.owner.current,u,e,{...this.options,duration:i,times:o,ease:a});return d.startTime=c??this.calcStartTime(),this.pendingTimeline?(Q0(d,this.pendingTimeline),this.pendingTimeline=void 0):d.onfinish=()=>{let{onComplete:h}=this.options;l.set(Ku(e,this.options,n)),h&&h(),this.cancel(),this.resolveFinishedPromise()},{animation:d,duration:i,times:o,type:s,ease:a,keyframes:e}}get duration(){let{resolved:e}=this;if(!e)return 0;let{duration:n}=e;return _n(n)}get time(){let{resolved:e}=this;if(!e)return 0;let{animation:n}=e;return _n(n.currentTime||0)}set time(e){let{resolved:n}=this;if(!n)return;let{animation:r}=n;r.currentTime=On(e)}get speed(){let{resolved:e}=this;if(!e)return 1;let{animation:n}=e;return n.playbackRate}set speed(e){let{resolved:n}=this;if(!n)return;let{animation:r}=n;r.playbackRate=e}get state(){let{resolved:e}=this;if(!e)return"idle";let{animation:n}=e;return n.playState}get startTime(){let{resolved:e}=this;if(!e)return null;let{animation:n}=e;return n.startTime}attachTimeline(e){if(!this._resolved)this.pendingTimeline=e;else{let{resolved:n}=this;if(!n)return ie;let{animation:r}=n;Q0(r,e)}return ie}play(){if(this.isStopped)return;let{resolved:e}=this;if(!e)return;let{animation:n}=e;n.playState==="finished"&&this.updateFinishedPromise(),n.play()}pause(){let{resolved:e}=this;if(!e)return;let{animation:n}=e;n.pause()}stop(){if(this.resolver.cancel(),this.isStopped=!0,this.state==="idle")return;this.resolveFinishedPromise(),this.updateFinishedPromise();let{resolved:e}=this;if(!e)return;let{animation:n,keyframes:r,duration:i,type:o,ease:a,times:s}=e;if(n.playState==="idle"||n.playState==="finished")return;if(this.time){let{motionValue:u,onUpdate:c,onComplete:d,element:h,...p}=this.options,m=new za({...p,keyframes:r,duration:i,type:o,ease:a,times:s,isGenerator:!0}),v=On(this.time);u.setWithVelocity(m.sample(v-ru).value,m.sample(v).value,ru)}let{onStop:l}=this.options;l&&l(),this.cancel()}complete(){let{resolved:e}=this;e&&e.animation.finish()}cancel(){let{resolved:e}=this;e&&e.animation.cancel()}static supports(e){let{motionValue:n,name:r,repeatDelay:i,repeatType:o,damping:a,type:s}=e;return oz()&&r&&Z5.has(r)&&n&&n.owner&&n.owner.current instanceof HTMLElement&&!n.owner.getProps().onUpdate&&!i&&o!=="mirror"&&a!==0&&s!=="inertia"}},cz=Nm(()=>window.ScrollTimeline!==void 0),ep=class{constructor(e){this.stop=()=>this.runAll("stop"),this.animations=e.filter(Boolean)}then(e,n){return Promise.all(this.animations).then(e).catch(n)}getAll(e){return this.animations[0][e]}setAll(e,n){for(let r=0;r<this.animations.length;r++)this.animations[r][e]=n}attachTimeline(e,n){let r=this.animations.map(i=>cz()&&i.attachTimeline?i.attachTimeline(e):n(i));return()=>{r.forEach((i,o)=>{i&&i(),this.animations[o].stop()})}}get time(){return this.getAll("time")}set time(e){this.setAll("time",e)}get speed(){return this.getAll("speed")}set speed(e){this.setAll("speed",e)}get startTime(){return this.getAll("startTime")}get duration(){let e=0;for(let n=0;n<this.animations.length;n++)e=Math.max(e,this.animations[n].duration);return e}runAll(e){this.animations.forEach(n=>n[e]())}flatten(){this.runAll("flatten")}play(){this.runAll("play")}pause(){this.runAll("pause")}cancel(){this.runAll("cancel")}complete(){this.runAll("complete")}};function dz({when:t,delay:e,delayChildren:n,staggerChildren:r,staggerDirection:i,repeat:o,repeatType:a,repeatDelay:s,from:l,elapsed:u,...c}){return!!Object.keys(c).length}var Fm=(t,e,n,r={},i,o)=>a=>{let s=Cm(r,t)||{},l=s.delay||r.delay||0,{elapsed:u=0}=r;u=u-On(l);let c={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:e.getVelocity(),...s,delay:-u,onUpdate:h=>{e.set(h),s.onUpdate&&s.onUpdate(h)},onComplete:()=>{a(),s.onComplete&&s.onComplete()},name:t,motionValue:e,element:o?void 0:i};dz(s)||(c={...c,...DV(t,c)}),c.duration&&(c.duration=On(c.duration)),c.repeatDelay&&(c.repeatDelay=On(c.repeatDelay)),c.from!==void 0&&(c.keyframes[0]=c.from);let d=!1;if((c.type===!1||c.duration===0&&!c.repeatDelay)&&(c.duration=0,c.delay===0&&(d=!0)),d&&!o&&e.get()!==void 0){let h=Ku(c.keyframes,s);if(h!==void 0)return dt.update(()=>{c.onUpdate(h),c.onComplete()}),new ep([])}return!o&&iu.supports(c)?new iu(c):new za(c)},hz=t=>!!(t&&typeof t=="object"&&t.mix&&t.toValue),pz=t=>qh(t)?t[t.length-1]||0:t;function Vm(t,e){t.indexOf(e)===-1&&t.push(e)}function zm(t,e){let n=t.indexOf(e);n>-1&&t.splice(n,1)}var Ba=class{constructor(){this.subscriptions=[]}add(e){return Vm(this.subscriptions,e),()=>zm(this.subscriptions,e)}notify(e,n,r){let i=this.subscriptions.length;if(i)if(i===1)this.subscriptions[0](e,n,r);else for(let o=0;o<i;o++){let a=this.subscriptions[o];a&&a(e,n,r)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}},J0=30,fz=t=>!isNaN(parseFloat(t)),np=class{constructor(e,n={}){this.version="11.11.17",this.canTrackVelocity=null,this.events={},this.updateAndNotify=(r,i=!0)=>{let o=gn.now();this.updatedAt!==o&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(r),this.current!==this.prev&&this.events.change&&this.events.change.notify(this.current),i&&this.events.renderRequest&&this.events.renderRequest.notify(this.current)},this.hasAnimated=!1,this.setCurrent(e),this.owner=n.owner}setCurrent(e){this.current=e,this.updatedAt=gn.now(),this.canTrackVelocity===null&&e!==void 0&&(this.canTrackVelocity=fz(this.current))}setPrevFrameValue(e=this.current){this.prevFrameValue=e,this.prevUpdatedAt=this.updatedAt}onChange(e){return this.on("change",e)}on(e,n){this.events[e]||(this.events[e]=new Ba);let r=this.events[e].add(n);return e==="change"?()=>{r(),dt.read(()=>{this.events.change.getSize()||this.stop()})}:r}clearListeners(){for(let e in this.events)this.events[e].clear()}attach(e,n){this.passiveEffect=e,this.stopPassiveEffect=n}set(e,n=!0){!n||!this.passiveEffect?this.updateAndNotify(e,n):this.passiveEffect(e,this.updateAndNotify)}setWithVelocity(e,n,r){this.set(n),this.prev=void 0,this.prevFrameValue=e,this.prevUpdatedAt=this.updatedAt-r}jump(e,n=!0){this.updateAndNotify(e),this.prev=e,this.prevUpdatedAt=this.prevFrameValue=void 0,n&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}get(){return this.current}getPrevious(){return this.prev}getVelocity(){let e=gn.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||e-this.updatedAt>J0)return 0;let n=Math.min(this.updatedAt-this.prevUpdatedAt,J0);return XT(parseFloat(this.current)-parseFloat(this.prevFrameValue),n)}start(e){return this.stop(),new Promise(n=>{this.hasAnimated=!0,this.animation=e(n),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}};function Ua(t,e){return new np(t,e)}function mz(t,e,n){t.hasValue(e)?t.getValue(e).set(n):t.addValue(e,Ua(n))}function gz(t,e){let n=Yu(t,e),{transitionEnd:r={},transition:i={},...o}=n||{};o={...o,...r};for(let a in o){let s=pz(o[a]);mz(t,a,s)}}var Bm=t=>t.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase(),vz="framerAppearId",iE="data-"+Bm(vz);function oE(t){return t.props[iE]}var ne=t=>!!(t&&t.getVelocity);function yz(t){return!!(ne(t)&&t.add)}function rp(t,e){let n=t.getValue("willChange");if(yz(n))return n.add(e)}function bz({protectedKeys:t,needsAnimating:e},n){let r=t.hasOwnProperty(n)&&e[n]!==!0;return e[n]=!1,r}function aE(t,e,{delay:n=0,transitionOverride:r,type:i}={}){var o;let{transition:a=t.getDefaultTransition(),transitionEnd:s,...l}=e;r&&(a=r);let u=[],c=i&&t.animationState&&t.animationState.getState()[i];for(let d in l){let h=t.getValue(d,(o=t.latestValues[d])!==null&&o!==void 0?o:null),p=l[d];if(p===void 0||c&&bz(c,d))continue;let m={delay:n,...Cm(a||{},d)},v=!1;if(window.MotionHandoffAnimation){let f=oE(t);if(f){let g=window.MotionHandoffAnimation(f,d,dt);g!==null&&(m.startTime=g,v=!0)}}rp(t,d),h.start(Fm(d,h,p,t.shouldReduceMotion&&oi.has(d)?{type:!1}:m,t,v));let b=h.animation;b&&u.push(b)}return s&&Promise.all(u).then(()=>{dt.update(()=>{s&&gz(t,s)})}),u}function ip(t,e,n={}){var r;let i=Yu(t,e,n.type==="exit"?(r=t.presenceContext)===null||r===void 0?void 0:r.custom:void 0),{transition:o=t.getDefaultTransition()||{}}=i||{};n.transitionOverride&&(o=n.transitionOverride);let a=i?()=>Promise.all(aE(t,i,n)):()=>Promise.resolve(),s=t.variantChildren&&t.variantChildren.size?(u=0)=>{let{delayChildren:c=0,staggerChildren:d,staggerDirection:h}=o;return xz(t,e,c+u,d,h,n)}:()=>Promise.resolve(),{when:l}=o;if(l){let[u,c]=l==="beforeChildren"?[a,s]:[s,a];return u().then(()=>c())}else return Promise.all([a(),s(n.delay)])}function xz(t,e,n=0,r=0,i=1,o){let a=[],s=(t.variantChildren.size-1)*r,l=i===1?(u=0)=>u*r:(u=0)=>s-u*r;return Array.from(t.variantChildren).sort(wz).forEach((u,c)=>{u.notify("AnimationStart",e),a.push(ip(u,e,{...o,delay:n+l(c)}).then(()=>u.notify("AnimationComplete",e)))}),Promise.all(a)}function wz(t,e){return t.sortNodePosition(e)}function kz(t,e,n={}){t.notify("AnimationStart",e);let r;if(Array.isArray(e)){let i=e.map(o=>ip(t,o,n));r=Promise.all(i)}else if(typeof e=="string")r=ip(t,e,n);else{let i=typeof e=="function"?Yu(t,e,n.custom):e;r=Promise.all(aE(t,i,n))}return r.then(()=>{t.notify("AnimationComplete",e)})}var Sz=Em.length;function sE(t){if(!t)return;if(!t.isControllingVariants){let n=t.parent?sE(t.parent)||{}:{};return t.props.initial!==void 0&&(n.initial=t.props.initial),n}let e={};for(let n=0;n<Sz;n++){let r=Em[n],i=t.props[r];(_a(i)||i===!1)&&(e[r]=i)}return e}var Tz=[...Tm].reverse(),Ez=Tm.length;function Cz(t){return e=>Promise.all(e.map(({animation:n,options:r})=>kz(t,n,r)))}function Pz(t){let e=Cz(t),n=Z0(),r=!0,i=l=>(u,c)=>{var d;let h=Yu(t,c,l==="exit"?(d=t.presenceContext)===null||d===void 0?void 0:d.custom:void 0);if(h){let{transition:p,transitionEnd:m,...v}=h;u={...u,...v,...m}}return u};function o(l){e=l(t)}function a(l){let{props:u}=t,c=sE(t.parent)||{},d=[],h=new Set,p={},m=1/0;for(let b=0;b<Ez;b++){let f=Tz[b],g=n[f],y=u[f]!==void 0?u[f]:c[f],w=_a(y),C=f===l?g.isActive:null;C===!1&&(m=b);let k=y===c[f]&&y!==u[f]&&w;if(k&&r&&t.manuallyAnimateOnMount&&(k=!1),g.protectedKeys={...p},!g.isActive&&C===null||!y&&!g.prevProp||qu(y)||typeof y=="boolean")continue;let M=Az(g.prevProp,y),P=M||f===l&&g.isActive&&!k&&w||b>m&&w,R=!1,E=Array.isArray(y)?y:[y],L=E.reduce(i(f),{});C===!1&&(L={});let{prevResolvedValues:N={}}=g,B={...N,...L},U=F=>{P=!0,h.has(F)&&(R=!0,h.delete(F)),g.needsAnimating[F]=!0;let K=t.getValue(F);K&&(K.liveStyle=!1)};for(let F in B){let K=L[F],Q=N[F];if(p.hasOwnProperty(F))continue;let I=!1;qh(K)&&qh(Q)?I=!TT(K,Q):I=K!==Q,I?K!=null?U(F):h.add(F):K!==void 0&&h.has(F)?U(F):g.protectedKeys[F]=!0}g.prevProp=y,g.prevResolvedValues=L,g.isActive&&(p={...p,...L}),r&&t.blockInitialAnimation&&(P=!1),P&&(!(k&&M)||R)&&d.push(...E.map(F=>({animation:F,options:{type:f}})))}if(h.size){let b={};h.forEach(f=>{let g=t.getBaseTarget(f),y=t.getValue(f);y&&(y.liveStyle=!0),b[f]=g??null}),d.push({animation:b})}let v=!!d.length;return r&&(u.initial===!1||u.initial===u.animate)&&!t.manuallyAnimateOnMount&&(v=!1),r=!1,v?e(d):Promise.resolve()}function s(l,u){var c;if(n[l].isActive===u)return Promise.resolve();(c=t.variantChildren)===null||c===void 0||c.forEach(h=>{var p;return(p=h.animationState)===null||p===void 0?void 0:p.setActive(l,u)}),n[l].isActive=u;let d=a(l);for(let h in n)n[h].protectedKeys={};return d}return{animateChanges:a,setActive:s,setAnimateFunction:o,getState:()=>n,reset:()=>{n=Z0(),r=!0}}}function Az(t,e){return typeof e=="string"?e!==t:Array.isArray(e)?!TT(e,t):!1}function Mr(t=!1){return{isActive:t,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function Z0(){return{animate:Mr(!0),whileInView:Mr(),whileHover:Mr(),whileTap:Mr(),whileDrag:Mr(),whileFocus:Mr(),exit:Mr()}}var vn=class{constructor(e){this.isMounted=!1,this.node=e}update(){}},op=class extends vn{constructor(e){super(e),e.animationState||(e.animationState=Pz(e))}updateAnimationControlsSubscription(){let{animate:e}=this.node.getProps();qu(e)&&(this.unmountControls=e.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){let{animate:e}=this.node.getProps(),{animate:n}=this.node.prevProps||{};e!==n&&this.updateAnimationControlsSubscription()}unmount(){var e;this.node.animationState.reset(),(e=this.unmountControls)===null||e===void 0||e.call(this)}},Mz=0,ap=class extends vn{constructor(){super(...arguments),this.id=Mz++}update(){if(!this.node.presenceContext)return;let{isPresent:e,onExitComplete:n}=this.node.presenceContext,{isPresent:r}=this.node.prevPresenceContext||{};if(!this.node.animationState||e===r)return;let i=this.node.animationState.setActive("exit",!e);n&&!e&&i.then(()=>n(this.id))}mount(){let{register:e}=this.node.presenceContext||{};e&&(this.unmount=e(this.id))}unmount(){}},Dz={animation:{Feature:op},exit:{Feature:ap}},lE=t=>t.pointerType==="mouse"?typeof t.button!="number"||t.button<=0:t.isPrimary!==!1;function Xu(t,e="page"){return{point:{x:t[`${e}X`],y:t[`${e}Y`]}}}var Rz=t=>e=>lE(e)&&t(e,Xu(e));function Mn(t,e,n,r={passive:!0}){return t.addEventListener(e,n,r),()=>t.removeEventListener(e,n)}function Fn(t,e,n,r){return Mn(t,e,Rz(n),r)}var t1=(t,e)=>Math.abs(t-e);function Iz(t,e){let n=t1(t.x,e.x),r=t1(t.y,e.y);return Math.sqrt(n**2+r**2)}var ou=class{constructor(e,n,{transformPagePoint:r,contextWindow:i,dragSnapToOrigin:o=!1}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;let d=sd(this.lastMoveEventInfo,this.history),h=this.startEvent!==null,p=Iz(d.offset,{x:0,y:0})>=3;if(!h&&!p)return;let{point:m}=d,{timestamp:v}=Wt;this.history.push({...m,timestamp:v});let{onStart:b,onMove:f}=this.handlers;h||(b&&b(this.lastMoveEvent,d),this.startEvent=this.lastMoveEvent),f&&f(this.lastMoveEvent,d)},this.handlePointerMove=(d,h)=>{this.lastMoveEvent=d,this.lastMoveEventInfo=ad(h,this.transformPagePoint),dt.update(this.updatePoint,!0)},this.handlePointerUp=(d,h)=>{this.end();let{onEnd:p,onSessionEnd:m,resumeAnimation:v}=this.handlers;if(this.dragSnapToOrigin&&v&&v(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;let b=sd(d.type==="pointercancel"?this.lastMoveEventInfo:ad(h,this.transformPagePoint),this.history);this.startEvent&&p&&p(d,b),m&&m(d,b)},!lE(e))return;this.dragSnapToOrigin=o,this.handlers=n,this.transformPagePoint=r,this.contextWindow=i||window;let a=Xu(e),s=ad(a,this.transformPagePoint),{point:l}=s,{timestamp:u}=Wt;this.history=[{...l,timestamp:u}];let{onSessionStart:c}=n;c&&c(e,sd(s,this.history)),this.removeListeners=Nn(Fn(this.contextWindow,"pointermove",this.handlePointerMove),Fn(this.contextWindow,"pointerup",this.handlePointerUp),Fn(this.contextWindow,"pointercancel",this.handlePointerUp))}updateHandlers(e){this.handlers=e}end(){this.removeListeners&&this.removeListeners(),yr(this.updatePoint)}};function ad(t,e){return e?{point:e(t.point)}:t}function e1(t,e){return{x:t.x-e.x,y:t.y-e.y}}function sd({point:t},e){return{point:t,delta:e1(t,uE(e)),offset:e1(t,Lz(e)),velocity:jz(e,.1)}}function Lz(t){return t[0]}function uE(t){return t[t.length-1]}function jz(t,e){if(t.length<2)return{x:0,y:0};let n=t.length-1,r=null,i=uE(t);for(;n>=0&&(r=t[n],!(i.timestamp-r.timestamp>On(e)));)n--;if(!r)return{x:0,y:0};let o=_n(i.timestamp-r.timestamp);if(o===0)return{x:0,y:0};let a={x:(i.x-r.x)/o,y:(i.y-r.y)/o};return a.x===1/0&&(a.x=0),a.y===1/0&&(a.y=0),a}function cE(t){let e=null;return()=>{let n=()=>{e=null};return e===null?(e=t,n):!1}}var n1=cE("dragHorizontal"),r1=cE("dragVertical");function dE(t){let e=!1;if(t==="y")e=r1();else if(t==="x")e=n1();else{let n=n1(),r=r1();n&&r?e=()=>{n(),r()}:(n&&n(),r&&r())}return e}function hE(){let t=dE(!0);return t?(t(),!1):!0}function Di(t){return t&&typeof t=="object"&&Object.prototype.hasOwnProperty.call(t,"current")}var pE=1e-4,Oz=1-pE,_z=1+pE,fE=.01,Nz=0-fE,Fz=0+fE;function De(t){return t.max-t.min}function Vz(t,e,n){return Math.abs(t-e)<=n}function i1(t,e,n,r=.5){t.origin=r,t.originPoint=Ct(e.min,e.max,t.origin),t.scale=De(n)/De(e),t.translate=Ct(n.min,n.max,t.origin)-t.originPoint,(t.scale>=Oz&&t.scale<=_z||isNaN(t.scale))&&(t.scale=1),(t.translate>=Nz&&t.translate<=Fz||isNaN(t.translate))&&(t.translate=0)}function Jo(t,e,n,r){i1(t.x,e.x,n.x,r?r.originX:void 0),i1(t.y,e.y,n.y,r?r.originY:void 0)}function o1(t,e,n){t.min=n.min+e.min,t.max=t.min+De(e)}function zz(t,e,n){o1(t.x,e.x,n.x),o1(t.y,e.y,n.y)}function a1(t,e,n){t.min=e.min-n.min,t.max=t.min+De(e)}function Zo(t,e,n){a1(t.x,e.x,n.x),a1(t.y,e.y,n.y)}function Bz(t,{min:e,max:n},r){return e!==void 0&&t<e?t=r?Ct(e,t,r.min):Math.max(t,e):n!==void 0&&t>n&&(t=r?Ct(n,t,r.max):Math.min(t,n)),t}function s1(t,e,n){return{min:e!==void 0?t.min+e:void 0,max:n!==void 0?t.max+n-(t.max-t.min):void 0}}function Uz(t,{top:e,left:n,bottom:r,right:i}){return{x:s1(t.x,n,i),y:s1(t.y,e,r)}}function l1(t,e){let n=e.min-t.min,r=e.max-t.max;return e.max-e.min<t.max-t.min&&([n,r]=[r,n]),{min:n,max:r}}function $z(t,e){return{x:l1(t.x,e.x),y:l1(t.y,e.y)}}function Hz(t,e){let n=.5,r=De(t),i=De(e);return i>r?n=eo(e.min,e.max-r,t.min):r>i&&(n=eo(t.min,t.max-i,e.min)),br(0,1,n)}function Wz(t,e){let n={};return e.min!==void 0&&(n.min=e.min-t.min),e.max!==void 0&&(n.max=e.max-t.min),n}var sp=.35;function qz(t=sp){return t===!1?t=0:t===!0&&(t=sp),{x:u1(t,"left","right"),y:u1(t,"top","bottom")}}function u1(t,e,n){return{min:c1(t,e),max:c1(t,n)}}function c1(t,e){return typeof t=="number"?t:t[e]||0}var d1=()=>({translate:0,scale:1,origin:0,originPoint:0}),Ri=()=>({x:d1(),y:d1()}),h1=()=>({min:0,max:0}),It=()=>({x:h1(),y:h1()});function Fe(t){return[t("x"),t("y")]}function mE({top:t,left:e,right:n,bottom:r}){return{x:{min:e,max:n},y:{min:t,max:r}}}function Yz({x:t,y:e}){return{top:e.min,right:t.max,bottom:e.max,left:t.min}}function Kz(t,e){if(!e)return t;let n=e({x:t.left,y:t.top}),r=e({x:t.right,y:t.bottom});return{top:n.y,left:n.x,bottom:r.y,right:r.x}}function ld(t){return t===void 0||t===1}function lp({scale:t,scaleX:e,scaleY:n}){return!ld(t)||!ld(e)||!ld(n)}function jr(t){return lp(t)||gE(t)||t.z||t.rotate||t.rotateX||t.rotateY||t.skewX||t.skewY}function gE(t){return p1(t.x)||p1(t.y)}function p1(t){return t&&t!=="0%"}function au(t,e,n){let r=t-n,i=e*r;return n+i}function f1(t,e,n,r,i){return i!==void 0&&(t=au(t,i,r)),au(t,n,r)+e}function up(t,e=0,n=1,r,i){t.min=f1(t.min,e,n,r,i),t.max=f1(t.max,e,n,r,i)}function vE(t,{x:e,y:n}){up(t.x,e.translate,e.scale,e.originPoint),up(t.y,n.translate,n.scale,n.originPoint)}var m1=.999999999999,g1=1.0000000000001;function Xz(t,e,n,r=!1){let i=n.length;if(!i)return;e.x=e.y=1;let o,a;for(let s=0;s<i;s++){o=n[s],a=o.projectionDelta;let{visualElement:l}=o.options;l&&l.props.style&&l.props.style.display==="contents"||(r&&o.options.layoutScroll&&o.scroll&&o!==o.root&&Li(t,{x:-o.scroll.offset.x,y:-o.scroll.offset.y}),a&&(e.x*=a.x.scale,e.y*=a.y.scale,vE(t,a)),r&&jr(o.latestValues)&&Li(t,o.latestValues))}e.x<g1&&e.x>m1&&(e.x=1),e.y<g1&&e.y>m1&&(e.y=1)}function Ii(t,e){t.min=t.min+e,t.max=t.max+e}function v1(t,e,n,r,i=.5){let o=Ct(t.min,t.max,i);up(t,e,n,o,r)}function Li(t,e){v1(t.x,e.x,e.scaleX,e.scale,e.originX),v1(t.y,e.y,e.scaleY,e.scale,e.originY)}function yE(t,e){return mE(Kz(t.getBoundingClientRect(),e))}function Gz(t,e,n){let r=yE(t,n),{scroll:i}=e;return i&&(Ii(r.x,i.offset.x),Ii(r.y,i.offset.y)),r}var bE=({current:t})=>t?t.ownerDocument.defaultView:null,Qz=new WeakMap,cp=class{constructor(e){this.openGlobalLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=It(),this.visualElement=e}start(e,{snapToCursor:n=!1}={}){let{presenceContext:r}=this.visualElement;if(r&&r.isPresent===!1)return;let i=c=>{let{dragSnapToOrigin:d}=this.getProps();d?this.pauseAnimation():this.stopAnimation(),n&&this.snapToCursor(Xu(c,"page").point)},o=(c,d)=>{let{drag:h,dragPropagation:p,onDragStart:m}=this.getProps();if(h&&!p&&(this.openGlobalLock&&this.openGlobalLock(),this.openGlobalLock=dE(h),!this.openGlobalLock))return;this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),Fe(b=>{let f=this.getAxisMotionValue(b).get()||0;if(mn.test(f)){let{projection:g}=this.visualElement;if(g&&g.layout){let y=g.layout.layoutBox[b];y&&(f=De(y)*(parseFloat(f)/100))}}this.originPoint[b]=f}),m&&dt.postRender(()=>m(c,d)),rp(this.visualElement,"transform");let{animationState:v}=this.visualElement;v&&v.setActive("whileDrag",!0)},a=(c,d)=>{let{dragPropagation:h,dragDirectionLock:p,onDirectionLock:m,onDrag:v}=this.getProps();if(!h&&!this.openGlobalLock)return;let{offset:b}=d;if(p&&this.currentDirection===null){this.currentDirection=Jz(b),this.currentDirection!==null&&m&&m(this.currentDirection);return}this.updateAxis("x",d.point,b),this.updateAxis("y",d.point,b),this.visualElement.render(),v&&v(c,d)},s=(c,d)=>this.stop(c,d),l=()=>Fe(c=>{var d;return this.getAnimationState(c)==="paused"&&((d=this.getAxisMotionValue(c).animation)===null||d===void 0?void 0:d.play())}),{dragSnapToOrigin:u}=this.getProps();this.panSession=new ou(e,{onSessionStart:i,onStart:o,onMove:a,onSessionEnd:s,resumeAnimation:l},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:u,contextWindow:bE(this.visualElement)})}stop(e,n){let r=this.isDragging;if(this.cancel(),!r)return;let{velocity:i}=n;this.startAnimation(i);let{onDragEnd:o}=this.getProps();o&&dt.postRender(()=>o(e,n))}cancel(){this.isDragging=!1;let{projection:e,animationState:n}=this.visualElement;e&&(e.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;let{dragPropagation:r}=this.getProps();!r&&this.openGlobalLock&&(this.openGlobalLock(),this.openGlobalLock=null),n&&n.setActive("whileDrag",!1)}updateAxis(e,n,r){let{drag:i}=this.getProps();if(!r||!Vs(e,i,this.currentDirection))return;let o=this.getAxisMotionValue(e),a=this.originPoint[e]+r[e];this.constraints&&this.constraints[e]&&(a=Bz(a,this.constraints[e],this.elastic[e])),o.set(a)}resolveConstraints(){var e;let{dragConstraints:n,dragElastic:r}=this.getProps(),i=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):(e=this.visualElement.projection)===null||e===void 0?void 0:e.layout,o=this.constraints;n&&Di(n)?this.constraints||(this.constraints=this.resolveRefConstraints()):n&&i?this.constraints=Uz(i.layoutBox,n):this.constraints=!1,this.elastic=qz(r),o!==this.constraints&&i&&this.constraints&&!this.hasMutatedConstraints&&Fe(a=>{this.constraints!==!1&&this.getAxisMotionValue(a)&&(this.constraints[a]=Wz(i.layoutBox[a],this.constraints[a]))})}resolveRefConstraints(){let{dragConstraints:e,onMeasureDragConstraints:n}=this.getProps();if(!e||!Di(e))return!1;let r=e.current,{projection:i}=this.visualElement;if(!i||!i.layout)return!1;let o=Gz(r,i.root,this.visualElement.getTransformPagePoint()),a=$z(i.layout.layoutBox,o);if(n){let s=n(Yz(a));this.hasMutatedConstraints=!!s,s&&(a=mE(s))}return a}startAnimation(e){let{drag:n,dragMomentum:r,dragElastic:i,dragTransition:o,dragSnapToOrigin:a,onDragTransitionEnd:s}=this.getProps(),l=this.constraints||{},u=Fe(c=>{if(!Vs(c,n,this.currentDirection))return;let d=l&&l[c]||{};a&&(d={min:0,max:0});let h=i?200:1e6,p=i?40:1e7,m={type:"inertia",velocity:r?e[c]:0,bounceStiffness:h,bounceDamping:p,timeConstant:750,restDelta:1,restSpeed:10,...o,...d};return this.startAxisValueAnimation(c,m)});return Promise.all(u).then(s)}startAxisValueAnimation(e,n){let r=this.getAxisMotionValue(e);return rp(this.visualElement,e),r.start(Fm(e,r,0,n,this.visualElement,!1))}stopAnimation(){Fe(e=>this.getAxisMotionValue(e).stop())}pauseAnimation(){Fe(e=>{var n;return(n=this.getAxisMotionValue(e).animation)===null||n===void 0?void 0:n.pause()})}getAnimationState(e){var n;return(n=this.getAxisMotionValue(e).animation)===null||n===void 0?void 0:n.state}getAxisMotionValue(e){let n=`_drag${e.toUpperCase()}`,r=this.visualElement.getProps();return r[n]||this.visualElement.getValue(e,(r.initial?r.initial[e]:void 0)||0)}snapToCursor(e){Fe(n=>{let{drag:r}=this.getProps();if(!Vs(n,r,this.currentDirection))return;let{projection:i}=this.visualElement,o=this.getAxisMotionValue(n);if(i&&i.layout){let{min:a,max:s}=i.layout.layoutBox[n];o.set(e[n]-Ct(a,s,.5))}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;let{drag:e,dragConstraints:n}=this.getProps(),{projection:r}=this.visualElement;if(!Di(n)||!r||!this.constraints)return;this.stopAnimation();let i={x:0,y:0};Fe(a=>{let s=this.getAxisMotionValue(a);if(s&&this.constraints!==!1){let l=s.get();i[a]=Hz({min:l,max:l},this.constraints[a])}});let{transformTemplate:o}=this.visualElement.getProps();this.visualElement.current.style.transform=o?o({},""):"none",r.root&&r.root.updateScroll(),r.updateLayout(),this.resolveConstraints(),Fe(a=>{if(!Vs(a,e,null))return;let s=this.getAxisMotionValue(a),{min:l,max:u}=this.constraints[a];s.set(Ct(l,u,i[a]))})}addListeners(){if(!this.visualElement.current)return;Qz.set(this.visualElement,this);let e=this.visualElement.current,n=Fn(e,"pointerdown",l=>{let{drag:u,dragListener:c=!0}=this.getProps();u&&c&&this.start(l)}),r=()=>{let{dragConstraints:l}=this.getProps();Di(l)&&l.current&&(this.constraints=this.resolveRefConstraints())},{projection:i}=this.visualElement,o=i.addEventListener("measure",r);i&&!i.layout&&(i.root&&i.root.updateScroll(),i.updateLayout()),dt.read(r);let a=Mn(window,"resize",()=>this.scalePositionWithinConstraints()),s=i.addEventListener("didUpdate",({delta:l,hasLayoutChanged:u})=>{this.isDragging&&u&&(Fe(c=>{let d=this.getAxisMotionValue(c);d&&(this.originPoint[c]+=l[c].translate,d.set(d.get()+l[c].translate))}),this.visualElement.render())});return()=>{a(),n(),o(),s&&s()}}getProps(){let e=this.visualElement.getProps(),{drag:n=!1,dragDirectionLock:r=!1,dragPropagation:i=!1,dragConstraints:o=!1,dragElastic:a=sp,dragMomentum:s=!0}=e;return{...e,drag:n,dragDirectionLock:r,dragPropagation:i,dragConstraints:o,dragElastic:a,dragMomentum:s}}};function Vs(t,e,n){return(e===!0||e===t)&&(n===null||n===t)}function Jz(t,e=10){let n=null;return Math.abs(t.y)>e?n="y":Math.abs(t.x)>e&&(n="x"),n}var dp=class extends vn{constructor(e){super(e),this.removeGroupControls=ie,this.removeListeners=ie,this.controls=new cp(e)}mount(){let{dragControls:e}=this.node.getProps();e&&(this.removeGroupControls=e.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||ie}unmount(){this.removeGroupControls(),this.removeListeners()}},y1=t=>(e,n)=>{t&&dt.postRender(()=>t(e,n))},hp=class extends vn{constructor(){super(...arguments),this.removePointerDownListener=ie}onPointerDown(e){this.session=new ou(e,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:bE(this.node)})}createPanHandlers(){let{onPanSessionStart:e,onPanStart:n,onPan:r,onPanEnd:i}=this.node.getProps();return{onSessionStart:y1(e),onStart:y1(n),onMove:r,onEnd:(o,a)=>{delete this.session,i&&dt.postRender(()=>i(o,a))}}}mount(){this.removePointerDownListener=Fn(this.node.current,"pointerdown",e=>this.onPointerDown(e))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}},Um=S.createContext(null);function Zz(){let t=S.useContext(Um);if(t===null)return[!0,null];let{isPresent:e,onExitComplete:n,register:r}=t,i=S.useId();S.useEffect(()=>r(i),[]);let o=S.useCallback(()=>n&&n(i),[i,n]);return!e&&n?[!1,o]:[!0]}var xE=S.createContext({}),wE=S.createContext({}),sl={hasAnimatedSinceResize:!0,hasEverUpdated:!1};function b1(t,e){return e.max===e.min?0:t/(e.max-e.min)*100}var Ao={correct:(t,e)=>{if(!e.target)return t;if(typeof t=="string")if(q.test(t))t=parseFloat(t);else return t;let n=b1(t,e.target.x),r=b1(t,e.target.y);return`${n}% ${r}%`}},t6={correct:(t,{treeScale:e,projectionDelta:n})=>{let r=t,i=xr.parse(t);if(i.length>5)return r;let o=xr.createTransformer(t),a=typeof i[0]!="number"?1:0,s=n.x.scale*e.x,l=n.y.scale*e.y;i[0+a]/=s,i[1+a]/=l;let u=Ct(s,l,.5);return typeof i[2+a]=="number"&&(i[2+a]/=u),typeof i[3+a]=="number"&&(i[3+a]/=u),o(i)}},su={};function e6(t){Object.assign(su,t)}var{schedule:$m,cancel:XB}=ET(queueMicrotask,!1),pp=class extends S.Component{componentDidMount(){let{visualElement:e,layoutGroup:n,switchLayoutGroup:r,layoutId:i}=this.props,{projection:o}=e;e6(n6),o&&(n.group&&n.group.add(o),r&&r.register&&i&&r.register(o),o.root.didUpdate(),o.addEventListener("animationComplete",()=>{this.safeToRemove()}),o.setOptions({...o.options,onExitComplete:()=>this.safeToRemove()})),sl.hasEverUpdated=!0}getSnapshotBeforeUpdate(e){let{layoutDependency:n,visualElement:r,drag:i,isPresent:o}=this.props,a=r.projection;return a&&(a.isPresent=o,i||e.layoutDependency!==n||n===void 0?a.willUpdate():this.safeToRemove(),e.isPresent!==o&&(o?a.promote():a.relegate()||dt.postRender(()=>{let s=a.getStack();(!s||!s.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){let{projection:e}=this.props.visualElement;e&&(e.root.didUpdate(),$m.postRender(()=>{!e.currentAnimation&&e.isLead()&&this.safeToRemove()}))}componentWillUnmount(){let{visualElement:e,layoutGroup:n,switchLayoutGroup:r}=this.props,{projection:i}=e;i&&(i.scheduleCheckAfterUnmount(),n&&n.group&&n.group.remove(i),r&&r.deregister&&r.deregister(i))}safeToRemove(){let{safeToRemove:e}=this.props;e&&e()}render(){return null}};function kE(t){let[e,n]=Zz(),r=S.useContext(xE);return A.jsx(pp,{...t,layoutGroup:r,switchLayoutGroup:S.useContext(wE),isPresent:e,safeToRemove:n})}var n6={borderRadius:{...Ao,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:Ao,borderTopRightRadius:Ao,borderBottomLeftRadius:Ao,borderBottomRightRadius:Ao,boxShadow:t6},SE=["TopLeft","TopRight","BottomLeft","BottomRight"],r6=SE.length,x1=t=>typeof t=="string"?parseFloat(t):t,w1=t=>typeof t=="number"||q.test(t);function i6(t,e,n,r,i,o){i?(t.opacity=Ct(0,n.opacity!==void 0?n.opacity:1,o6(r)),t.opacityExit=Ct(e.opacity!==void 0?e.opacity:1,0,a6(r))):o&&(t.opacity=Ct(e.opacity!==void 0?e.opacity:1,n.opacity!==void 0?n.opacity:1,r));for(let a=0;a<r6;a++){let s=`border${SE[a]}Radius`,l=k1(e,s),u=k1(n,s);l===void 0&&u===void 0||(l||(l=0),u||(u=0),l===0||u===0||w1(l)===w1(u)?(t[s]=Math.max(Ct(x1(l),x1(u),r),0),(mn.test(u)||mn.test(l))&&(t[s]+="%")):t[s]=u)}(e.rotate||n.rotate)&&(t.rotate=Ct(e.rotate||0,n.rotate||0,r))}function k1(t,e){return t[e]!==void 0?t[e]:t.borderRadius}var o6=TE(0,.5,IT),a6=TE(.5,.95,ie);function TE(t,e,n){return r=>r<t?0:r>e?1:n(eo(t,e,r))}function S1(t,e){t.min=e.min,t.max=e.max}function _e(t,e){S1(t.x,e.x),S1(t.y,e.y)}function T1(t,e){t.translate=e.translate,t.scale=e.scale,t.originPoint=e.originPoint,t.origin=e.origin}function E1(t,e,n,r,i){return t-=e,t=au(t,1/n,r),i!==void 0&&(t=au(t,1/i,r)),t}function s6(t,e=0,n=1,r=.5,i,o=t,a=t){if(mn.test(e)&&(e=parseFloat(e),e=Ct(a.min,a.max,e/100)-a.min),typeof e!="number")return;let s=Ct(o.min,o.max,r);t===o&&(s-=e),t.min=E1(t.min,e,n,s,i),t.max=E1(t.max,e,n,s,i)}function C1(t,e,[n,r,i],o,a){s6(t,e[n],e[r],e[i],e.scale,o,a)}var l6=["x","scaleX","originX"],u6=["y","scaleY","originY"];function P1(t,e,n,r){C1(t.x,e,l6,n?n.x:void 0,r?r.x:void 0),C1(t.y,e,u6,n?n.y:void 0,r?r.y:void 0)}function A1(t){return t.translate===0&&t.scale===1}function EE(t){return A1(t.x)&&A1(t.y)}function M1(t,e){return t.min===e.min&&t.max===e.max}function c6(t,e){return M1(t.x,e.x)&&M1(t.y,e.y)}function D1(t,e){return Math.round(t.min)===Math.round(e.min)&&Math.round(t.max)===Math.round(e.max)}function CE(t,e){return D1(t.x,e.x)&&D1(t.y,e.y)}function R1(t){return De(t.x)/De(t.y)}function I1(t,e){return t.translate===e.translate&&t.scale===e.scale&&t.originPoint===e.originPoint}var fp=class{constructor(){this.members=[]}add(e){Vm(this.members,e),e.scheduleRender()}remove(e){if(zm(this.members,e),e===this.prevLead&&(this.prevLead=void 0),e===this.lead){let n=this.members[this.members.length-1];n&&this.promote(n)}}relegate(e){let n=this.members.findIndex(i=>e===i);if(n===0)return!1;let r;for(let i=n;i>=0;i--){let o=this.members[i];if(o.isPresent!==!1){r=o;break}}return r?(this.promote(r),!0):!1}promote(e,n){let r=this.lead;if(e!==r&&(this.prevLead=r,this.lead=e,e.show(),r)){r.instance&&r.scheduleRender(),e.scheduleRender(),e.resumeFrom=r,n&&(e.resumeFrom.preserveOpacity=!0),r.snapshot&&(e.snapshot=r.snapshot,e.snapshot.latestValues=r.animationValues||r.latestValues),e.root&&e.root.isUpdating&&(e.isLayoutDirty=!0);let{crossfade:i}=e.options;i===!1&&r.hide()}}exitAnimationComplete(){this.members.forEach(e=>{let{options:n,resumingFrom:r}=e;n.onExitComplete&&n.onExitComplete(),r&&r.options.onExitComplete&&r.options.onExitComplete()})}scheduleRender(){this.members.forEach(e=>{e.instance&&e.scheduleRender(!1)})}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}};function d6(t,e,n){let r="",i=t.x.translate/e.x,o=t.y.translate/e.y,a=n?.z||0;if((i||o||a)&&(r=`translate3d(${i}px, ${o}px, ${a}px) `),(e.x!==1||e.y!==1)&&(r+=`scale(${1/e.x}, ${1/e.y}) `),n){let{transformPerspective:u,rotate:c,rotateX:d,rotateY:h,skewX:p,skewY:m}=n;u&&(r=`perspective(${u}px) ${r}`),c&&(r+=`rotate(${c}deg) `),d&&(r+=`rotateX(${d}deg) `),h&&(r+=`rotateY(${h}deg) `),p&&(r+=`skewX(${p}deg) `),m&&(r+=`skewY(${m}deg) `)}let s=t.x.scale*e.x,l=t.y.scale*e.y;return(s!==1||l!==1)&&(r+=`scale(${s}, ${l})`),r||"none"}var h6=(t,e)=>t.depth-e.depth,mp=class{constructor(){this.children=[],this.isDirty=!1}add(e){Vm(this.children,e),this.isDirty=!0}remove(e){zm(this.children,e),this.isDirty=!0}forEach(e){this.isDirty&&this.children.sort(h6),this.isDirty=!1,this.children.forEach(e)}};function ll(t){let e=ne(t)?t.get():t;return hz(e)?e.toValue():e}function p6(t,e){let n=gn.now(),r=({timestamp:i})=>{let o=i-n;o>=e&&(yr(r),t(o-e))};return dt.read(r,!0),()=>yr(r)}function f6(t){return t instanceof SVGElement&&t.tagName!=="svg"}function m6(t,e,n){let r=ne(t)?t:Ua(t);return r.start(Fm("",r,e,n)),r.animation}var Or={type:"projectionFrame",totalNodes:0,resolvedTargetDeltas:0,recalculatedProjection:0},_o=typeof window<"u"&&window.MotionDebug!==void 0,ud=["","X","Y","Z"],g6={visibility:"hidden"},L1=1e3,v6=0;function cd(t,e,n,r){let{latestValues:i}=e;i[t]&&(n[t]=i[t],e.setStaticValue(t,0),r&&(r[t]=0))}function PE(t){if(t.hasCheckedOptimisedAppear=!0,t.root===t)return;let{visualElement:e}=t.options;if(!e)return;let n=oE(e);if(window.MotionHasOptimisedAnimation(n,"transform")){let{layout:i,layoutId:o}=t.options;window.MotionCancelOptimisedAnimation(n,"transform",dt,!(i||o))}let{parent:r}=t;r&&!r.hasCheckedOptimisedAppear&&PE(r)}function AE({attachResizeListener:t,defaultParent:e,measureScroll:n,checkIsScrollRoot:r,resetTransform:i}){return class{constructor(o={},a=e?.()){this.id=v6++,this.animationId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,_o&&(Or.totalNodes=Or.resolvedTargetDeltas=Or.recalculatedProjection=0),this.nodes.forEach(x6),this.nodes.forEach(E6),this.nodes.forEach(C6),this.nodes.forEach(w6),_o&&window.MotionDebug.record(Or)},this.resolvedRelativeTargetAt=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=o,this.root=a?a.root||a:this,this.path=a?[...a.path,a]:[],this.parent=a,this.depth=a?a.depth+1:0;for(let s=0;s<this.path.length;s++)this.path[s].shouldResetTransform=!0;this.root===this&&(this.nodes=new mp)}addEventListener(o,a){return this.eventHandlers.has(o)||this.eventHandlers.set(o,new Ba),this.eventHandlers.get(o).add(a)}notifyListeners(o,...a){let s=this.eventHandlers.get(o);s&&s.notify(...a)}hasListeners(o){return this.eventHandlers.has(o)}mount(o,a=this.root.hasTreeAnimated){if(this.instance)return;this.isSVG=f6(o),this.instance=o;let{layoutId:s,layout:l,visualElement:u}=this.options;if(u&&!u.current&&u.mount(o),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),a&&(l||s)&&(this.isLayoutDirty=!0),t){let c,d=()=>this.root.updateBlockedByResize=!1;t(o,()=>{this.root.updateBlockedByResize=!0,c&&c(),c=p6(d,250),sl.hasAnimatedSinceResize&&(sl.hasAnimatedSinceResize=!1,this.nodes.forEach(O1))})}s&&this.root.registerSharedNode(s,this),this.options.animate!==!1&&u&&(s||l)&&this.addEventListener("didUpdate",({delta:c,hasLayoutChanged:d,hasRelativeTargetChanged:h,layout:p})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}let m=this.options.transition||u.getDefaultTransition()||R6,{onLayoutAnimationStart:v,onLayoutAnimationComplete:b}=u.getProps(),f=!this.targetLayout||!CE(this.targetLayout,p)||h,g=!d&&h;if(this.options.layoutRoot||this.resumeFrom&&this.resumeFrom.instance||g||d&&(f||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0),this.setAnimationOrigin(c,g);let y={...Cm(m,"layout"),onPlay:v,onComplete:b};(u.shouldReduceMotion||this.options.layoutRoot)&&(y.delay=0,y.type=!1),this.startAnimation(y)}else d||O1(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=p})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);let o=this.getStack();o&&o.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,yr(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(P6),this.animationId++)}getTransformTemplate(){let{visualElement:o}=this.options;return o&&o.getProps().transformTemplate}willUpdate(o=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&PE(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let u=0;u<this.path.length;u++){let c=this.path[u];c.shouldResetTransform=!0,c.updateScroll("snapshot"),c.options.layoutRoot&&c.willUpdate(!1)}let{layoutId:a,layout:s}=this.options;if(a===void 0&&!s)return;let l=this.getTransformTemplate();this.prevTransformTemplateValue=l?l(this.latestValues,""):void 0,this.updateSnapshot(),o&&this.notifyListeners("willUpdate")}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){this.unblockUpdate(),this.clearAllSnapshots(),this.nodes.forEach(j1);return}this.isUpdating||this.nodes.forEach(S6),this.isUpdating=!1,this.nodes.forEach(T6),this.nodes.forEach(y6),this.nodes.forEach(b6),this.clearAllSnapshots();let o=gn.now();Wt.delta=br(0,1e3/60,o-Wt.timestamp),Wt.timestamp=o,Wt.isProcessing=!0,ed.update.process(Wt),ed.preRender.process(Wt),ed.render.process(Wt),Wt.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,$m.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(k6),this.sharedNodes.forEach(A6)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,dt.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){dt.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure())}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let s=0;s<this.path.length;s++)this.path[s].updateScroll();let o=this.layout;this.layout=this.measure(!1),this.layoutCorrected=It(),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);let{visualElement:a}=this.options;a&&a.notify("LayoutMeasure",this.layout.layoutBox,o?o.layoutBox:void 0)}updateScroll(o="measure"){let a=!!(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===o&&(a=!1),a){let s=r(this.instance);this.scroll={animationId:this.root.animationId,phase:o,isRoot:s,offset:n(this.instance),wasRoot:this.scroll?this.scroll.isRoot:s}}}resetTransform(){if(!i)return;let o=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,a=this.projectionDelta&&!EE(this.projectionDelta),s=this.getTransformTemplate(),l=s?s(this.latestValues,""):void 0,u=l!==this.prevTransformTemplateValue;o&&(a||jr(this.latestValues)||u)&&(i(this.instance,l),this.shouldResetTransform=!1,this.scheduleRender())}measure(o=!0){let a=this.measurePageBox(),s=this.removeElementScroll(a);return o&&(s=this.removeTransform(s)),I6(s),{animationId:this.root.animationId,measuredBox:a,layoutBox:s,latestValues:{},source:this.id}}measurePageBox(){var o;let{visualElement:a}=this.options;if(!a)return It();let s=a.measureViewportBox();if(!(!((o=this.scroll)===null||o===void 0)&&o.wasRoot||this.path.some(L6))){let{scroll:l}=this.root;l&&(Ii(s.x,l.offset.x),Ii(s.y,l.offset.y))}return s}removeElementScroll(o){var a;let s=It();if(_e(s,o),!((a=this.scroll)===null||a===void 0)&&a.wasRoot)return s;for(let l=0;l<this.path.length;l++){let u=this.path[l],{scroll:c,options:d}=u;u!==this.root&&c&&d.layoutScroll&&(c.wasRoot&&_e(s,o),Ii(s.x,c.offset.x),Ii(s.y,c.offset.y))}return s}applyTransform(o,a=!1){let s=It();_e(s,o);for(let l=0;l<this.path.length;l++){let u=this.path[l];!a&&u.options.layoutScroll&&u.scroll&&u!==u.root&&Li(s,{x:-u.scroll.offset.x,y:-u.scroll.offset.y}),jr(u.latestValues)&&Li(s,u.latestValues)}return jr(this.latestValues)&&Li(s,this.latestValues),s}removeTransform(o){let a=It();_e(a,o);for(let s=0;s<this.path.length;s++){let l=this.path[s];if(!l.instance||!jr(l.latestValues))continue;lp(l.latestValues)&&l.updateSnapshot();let u=It(),c=l.measurePageBox();_e(u,c),P1(a,l.latestValues,l.snapshot?l.snapshot.layoutBox:void 0,u)}return jr(this.latestValues)&&P1(a,this.latestValues),a}setTargetDelta(o){this.targetDelta=o,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(o){this.options={...this.options,...o,crossfade:o.crossfade!==void 0?o.crossfade:!0}}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==Wt.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(o=!1){var a;let s=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=s.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=s.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=s.isSharedProjectionDirty);let l=!!this.resumingFrom||this!==s;if(!(o||l&&this.isSharedProjectionDirty||this.isProjectionDirty||!((a=this.parent)===null||a===void 0)&&a.isProjectionDirty||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;let{layout:u,layoutId:c}=this.options;if(!(!this.layout||!(u||c))){if(this.resolvedRelativeTargetAt=Wt.timestamp,!this.targetDelta&&!this.relativeTarget){let d=this.getClosestProjectingParent();d&&d.layout&&this.animationProgress!==1?(this.relativeParent=d,this.forceRelativeParentToResolveTarget(),this.relativeTarget=It(),this.relativeTargetOrigin=It(),Zo(this.relativeTargetOrigin,this.layout.layoutBox,d.layout.layoutBox),_e(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}if(!(!this.relativeTarget&&!this.targetDelta)){if(this.target||(this.target=It(),this.targetWithTransforms=It()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),zz(this.target,this.relativeTarget,this.relativeParent.target)):this.targetDelta?(this.resumingFrom?this.target=this.applyTransform(this.layout.layoutBox):_e(this.target,this.layout.layoutBox),vE(this.target,this.targetDelta)):_e(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget){this.attemptToResolveRelativeTarget=!1;let d=this.getClosestProjectingParent();d&&!!d.resumingFrom==!!this.resumingFrom&&!d.options.layoutScroll&&d.target&&this.animationProgress!==1?(this.relativeParent=d,this.forceRelativeParentToResolveTarget(),this.relativeTarget=It(),this.relativeTargetOrigin=It(),Zo(this.relativeTargetOrigin,this.target,d.target),_e(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}_o&&Or.resolvedTargetDeltas++}}}getClosestProjectingParent(){if(!(!this.parent||lp(this.parent.latestValues)||gE(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}calcProjection(){var o;let a=this.getLead(),s=!!this.resumingFrom||this!==a,l=!0;if((this.isProjectionDirty||!((o=this.parent)===null||o===void 0)&&o.isProjectionDirty)&&(l=!1),s&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(l=!1),this.resolvedRelativeTargetAt===Wt.timestamp&&(l=!1),l)return;let{layout:u,layoutId:c}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(u||c))return;_e(this.layoutCorrected,this.layout.layoutBox);let d=this.treeScale.x,h=this.treeScale.y;Xz(this.layoutCorrected,this.treeScale,this.path,s),a.layout&&!a.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(a.target=a.layout.layoutBox,a.targetWithTransforms=It());let{target:p}=a;if(!p){this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender());return}!this.projectionDelta||!this.prevProjectionDelta?this.createProjectionDeltas():(T1(this.prevProjectionDelta.x,this.projectionDelta.x),T1(this.prevProjectionDelta.y,this.projectionDelta.y)),Jo(this.projectionDelta,this.layoutCorrected,p,this.latestValues),(this.treeScale.x!==d||this.treeScale.y!==h||!I1(this.projectionDelta.x,this.prevProjectionDelta.x)||!I1(this.projectionDelta.y,this.prevProjectionDelta.y))&&(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",p)),_o&&Or.recalculatedProjection++}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(o=!0){var a;if((a=this.options.visualElement)===null||a===void 0||a.scheduleRender(),o){let s=this.getStack();s&&s.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=Ri(),this.projectionDelta=Ri(),this.projectionDeltaWithTransform=Ri()}setAnimationOrigin(o,a=!1){let s=this.snapshot,l=s?s.latestValues:{},u={...this.latestValues},c=Ri();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!a;let d=It(),h=s?s.source:void 0,p=this.layout?this.layout.source:void 0,m=h!==p,v=this.getStack(),b=!v||v.members.length<=1,f=!!(m&&!b&&this.options.crossfade===!0&&!this.path.some(D6));this.animationProgress=0;let g;this.mixTargetDelta=y=>{let w=y/1e3;_1(c.x,o.x,w),_1(c.y,o.y,w),this.setTargetDelta(c),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(Zo(d,this.layout.layoutBox,this.relativeParent.layout.layoutBox),M6(this.relativeTarget,this.relativeTargetOrigin,d,w),g&&c6(this.relativeTarget,g)&&(this.isProjectionDirty=!1),g||(g=It()),_e(g,this.relativeTarget)),m&&(this.animationValues=u,i6(u,l,this.latestValues,w,f,b)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=w},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(o){this.notifyListeners("animationStart"),this.currentAnimation&&this.currentAnimation.stop(),this.resumingFrom&&this.resumingFrom.currentAnimation&&this.resumingFrom.currentAnimation.stop(),this.pendingAnimation&&(yr(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=dt.update(()=>{sl.hasAnimatedSinceResize=!0,this.currentAnimation=m6(0,L1,{...o,onUpdate:a=>{this.mixTargetDelta(a),o.onUpdate&&o.onUpdate(a)},onComplete:()=>{o.onComplete&&o.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);let o=this.getStack();o&&o.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(L1),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){let o=this.getLead(),{targetWithTransforms:a,target:s,layout:l,latestValues:u}=o;if(!(!a||!s||!l)){if(this!==o&&this.layout&&l&&ME(this.options.animationType,this.layout.layoutBox,l.layoutBox)){s=this.target||It();let c=De(this.layout.layoutBox.x);s.x.min=o.target.x.min,s.x.max=s.x.min+c;let d=De(this.layout.layoutBox.y);s.y.min=o.target.y.min,s.y.max=s.y.min+d}_e(a,s),Li(a,u),Jo(this.projectionDeltaWithTransform,this.layoutCorrected,a,u)}}registerSharedNode(o,a){this.sharedNodes.has(o)||this.sharedNodes.set(o,new fp),this.sharedNodes.get(o).add(a);let s=a.options.initialPromotionConfig;a.promote({transition:s?s.transition:void 0,preserveFollowOpacity:s&&s.shouldPreserveFollowOpacity?s.shouldPreserveFollowOpacity(a):void 0})}isLead(){let o=this.getStack();return o?o.lead===this:!0}getLead(){var o;let{layoutId:a}=this.options;return a?((o=this.getStack())===null||o===void 0?void 0:o.lead)||this:this}getPrevLead(){var o;let{layoutId:a}=this.options;return a?(o=this.getStack())===null||o===void 0?void 0:o.prevLead:void 0}getStack(){let{layoutId:o}=this.options;if(o)return this.root.sharedNodes.get(o)}promote({needsReset:o,transition:a,preserveFollowOpacity:s}={}){let l=this.getStack();l&&l.promote(this,s),o&&(this.projectionDelta=void 0,this.needsReset=!0),a&&this.setOptions({transition:a})}relegate(){let o=this.getStack();return o?o.relegate(this):!1}resetSkewAndRotation(){let{visualElement:o}=this.options;if(!o)return;let a=!1,{latestValues:s}=o;if((s.z||s.rotate||s.rotateX||s.rotateY||s.rotateZ||s.skewX||s.skewY)&&(a=!0),!a)return;let l={};s.z&&cd("z",o,l,this.animationValues);for(let u=0;u<ud.length;u++)cd(`rotate${ud[u]}`,o,l,this.animationValues),cd(`skew${ud[u]}`,o,l,this.animationValues);o.render();for(let u in l)o.setStaticValue(u,l[u]),this.animationValues&&(this.animationValues[u]=l[u]);o.scheduleRender()}getProjectionStyles(o){var a,s;if(!this.instance||this.isSVG)return;if(!this.isVisible)return g6;let l={visibility:""},u=this.getTransformTemplate();if(this.needsReset)return this.needsReset=!1,l.opacity="",l.pointerEvents=ll(o?.pointerEvents)||"",l.transform=u?u(this.latestValues,""):"none",l;let c=this.getLead();if(!this.projectionDelta||!this.layout||!c.target){let m={};return this.options.layoutId&&(m.opacity=this.latestValues.opacity!==void 0?this.latestValues.opacity:1,m.pointerEvents=ll(o?.pointerEvents)||""),this.hasProjected&&!jr(this.latestValues)&&(m.transform=u?u({},""):"none",this.hasProjected=!1),m}let d=c.animationValues||c.latestValues;this.applyTransformsToTarget(),l.transform=d6(this.projectionDeltaWithTransform,this.treeScale,d),u&&(l.transform=u(d,l.transform));let{x:h,y:p}=this.projectionDelta;l.transformOrigin=`${h.origin*100}% ${p.origin*100}% 0`,c.animationValues?l.opacity=c===this?(s=(a=d.opacity)!==null&&a!==void 0?a:this.latestValues.opacity)!==null&&s!==void 0?s:1:this.preserveOpacity?this.latestValues.opacity:d.opacityExit:l.opacity=c===this?d.opacity!==void 0?d.opacity:"":d.opacityExit!==void 0?d.opacityExit:0;for(let m in su){if(d[m]===void 0)continue;let{correct:v,applyTo:b}=su[m],f=l.transform==="none"?d[m]:v(d[m],c);if(b){let g=b.length;for(let y=0;y<g;y++)l[b[y]]=f}else l[m]=f}return this.options.layoutId&&(l.pointerEvents=c===this?ll(o?.pointerEvents)||"":"none"),l}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(o=>{var a;return(a=o.currentAnimation)===null||a===void 0?void 0:a.stop()}),this.root.nodes.forEach(j1),this.root.sharedNodes.clear()}}}function y6(t){t.updateLayout()}function b6(t){var e;let n=((e=t.resumeFrom)===null||e===void 0?void 0:e.snapshot)||t.snapshot;if(t.isLead()&&t.layout&&n&&t.hasListeners("didUpdate")){let{layoutBox:r,measuredBox:i}=t.layout,{animationType:o}=t.options,a=n.source!==t.layout.source;o==="size"?Fe(d=>{let h=a?n.measuredBox[d]:n.layoutBox[d],p=De(h);h.min=r[d].min,h.max=h.min+p}):ME(o,n.layoutBox,r)&&Fe(d=>{let h=a?n.measuredBox[d]:n.layoutBox[d],p=De(r[d]);h.max=h.min+p,t.relativeTarget&&!t.currentAnimation&&(t.isProjectionDirty=!0,t.relativeTarget[d].max=t.relativeTarget[d].min+p)});let s=Ri();Jo(s,r,n.layoutBox);let l=Ri();a?Jo(l,t.applyTransform(i,!0),n.measuredBox):Jo(l,r,n.layoutBox);let u=!EE(s),c=!1;if(!t.resumeFrom){let d=t.getClosestProjectingParent();if(d&&!d.resumeFrom){let{snapshot:h,layout:p}=d;if(h&&p){let m=It();Zo(m,n.layoutBox,h.layoutBox);let v=It();Zo(v,r,p.layoutBox),CE(m,v)||(c=!0),d.options.layoutRoot&&(t.relativeTarget=v,t.relativeTargetOrigin=m,t.relativeParent=d)}}}t.notifyListeners("didUpdate",{layout:r,snapshot:n,delta:l,layoutDelta:s,hasLayoutChanged:u,hasRelativeTargetChanged:c})}else if(t.isLead()){let{onExitComplete:r}=t.options;r&&r()}t.options.transition=void 0}function x6(t){_o&&Or.totalNodes++,t.parent&&(t.isProjecting()||(t.isProjectionDirty=t.parent.isProjectionDirty),t.isSharedProjectionDirty||(t.isSharedProjectionDirty=!!(t.isProjectionDirty||t.parent.isProjectionDirty||t.parent.isSharedProjectionDirty)),t.isTransformDirty||(t.isTransformDirty=t.parent.isTransformDirty))}function w6(t){t.isProjectionDirty=t.isSharedProjectionDirty=t.isTransformDirty=!1}function k6(t){t.clearSnapshot()}function j1(t){t.clearMeasurements()}function S6(t){t.isLayoutDirty=!1}function T6(t){let{visualElement:e}=t.options;e&&e.getProps().onBeforeLayoutMeasure&&e.notify("BeforeLayoutMeasure"),t.resetTransform()}function O1(t){t.finishAnimation(),t.targetDelta=t.relativeTarget=t.target=void 0,t.isProjectionDirty=!0}function E6(t){t.resolveTargetDelta()}function C6(t){t.calcProjection()}function P6(t){t.resetSkewAndRotation()}function A6(t){t.removeLeadSnapshot()}function _1(t,e,n){t.translate=Ct(e.translate,0,n),t.scale=Ct(e.scale,1,n),t.origin=e.origin,t.originPoint=e.originPoint}function N1(t,e,n,r){t.min=Ct(e.min,n.min,r),t.max=Ct(e.max,n.max,r)}function M6(t,e,n,r){N1(t.x,e.x,n.x,r),N1(t.y,e.y,n.y,r)}function D6(t){return t.animationValues&&t.animationValues.opacityExit!==void 0}var R6={duration:.45,ease:[.4,0,.1,1]},F1=t=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(t),V1=F1("applewebkit/")&&!F1("chrome/")?Math.round:ie;function z1(t){t.min=V1(t.min),t.max=V1(t.max)}function I6(t){z1(t.x),z1(t.y)}function ME(t,e,n){return t==="position"||t==="preserve-aspect"&&!Vz(R1(e),R1(n),.2)}function L6(t){var e;return t!==t.root&&((e=t.scroll)===null||e===void 0?void 0:e.wasRoot)}var j6=AE({attachResizeListener:(t,e)=>Mn(t,"resize",e),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),dd={current:void 0},DE=AE({measureScroll:t=>({x:t.scrollLeft,y:t.scrollTop}),defaultParent:()=>{if(!dd.current){let t=new j6({});t.mount(window),t.setOptions({layoutScroll:!0}),dd.current=t}return dd.current},resetTransform:(t,e)=>{t.style.transform=e!==void 0?e:"none"},checkIsScrollRoot:t=>window.getComputedStyle(t).position==="fixed"}),O6={pan:{Feature:hp},drag:{Feature:dp,ProjectionNode:DE,MeasureLayout:kE}};function B1(t,e){let n=e?"pointerenter":"pointerleave",r=e?"onHoverStart":"onHoverEnd",i=(o,a)=>{if(o.pointerType==="touch"||hE())return;let s=t.getProps();t.animationState&&s.whileHover&&t.animationState.setActive("whileHover",e);let l=s[r];l&&dt.postRender(()=>l(o,a))};return Fn(t.current,n,i,{passive:!t.getProps()[r]})}var gp=class extends vn{mount(){this.unmount=Nn(B1(this.node,!0),B1(this.node,!1))}unmount(){}},vp=class extends vn{constructor(){super(...arguments),this.isActive=!1}onFocus(){let e=!1;try{e=this.node.current.matches(":focus-visible")}catch{e=!0}!e||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){!this.isActive||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=Nn(Mn(this.node.current,"focus",()=>this.onFocus()),Mn(this.node.current,"blur",()=>this.onBlur()))}unmount(){}},RE=(t,e)=>e?t===e?!0:RE(t,e.parentElement):!1;function hd(t,e){if(!e)return;let n=new PointerEvent("pointer"+t);e(n,Xu(n))}var yp=class extends vn{constructor(){super(...arguments),this.removeStartListeners=ie,this.removeEndListeners=ie,this.removeAccessibleListeners=ie,this.startPointerPress=(e,n)=>{if(this.isPressing)return;this.removeEndListeners();let r=this.node.getProps(),i=Fn(window,"pointerup",(a,s)=>{if(!this.checkPressEnd())return;let{onTap:l,onTapCancel:u,globalTapTarget:c}=this.node.getProps(),d=!c&&!RE(this.node.current,a.target)?u:l;d&&dt.update(()=>d(a,s))},{passive:!(r.onTap||r.onPointerUp)}),o=Fn(window,"pointercancel",(a,s)=>this.cancelPress(a,s),{passive:!(r.onTapCancel||r.onPointerCancel)});this.removeEndListeners=Nn(i,o),this.startPress(e,n)},this.startAccessiblePress=()=>{let e=o=>{if(o.key!=="Enter"||this.isPressing)return;let a=s=>{s.key!=="Enter"||!this.checkPressEnd()||hd("up",(l,u)=>{let{onTap:c}=this.node.getProps();c&&dt.postRender(()=>c(l,u))})};this.removeEndListeners(),this.removeEndListeners=Mn(this.node.current,"keyup",a),hd("down",(s,l)=>{this.startPress(s,l)})},n=Mn(this.node.current,"keydown",e),r=()=>{this.isPressing&&hd("cancel",(o,a)=>this.cancelPress(o,a))},i=Mn(this.node.current,"blur",r);this.removeAccessibleListeners=Nn(n,i)}}startPress(e,n){this.isPressing=!0;let{onTapStart:r,whileTap:i}=this.node.getProps();i&&this.node.animationState&&this.node.animationState.setActive("whileTap",!0),r&&dt.postRender(()=>r(e,n))}checkPressEnd(){return this.removeEndListeners(),this.isPressing=!1,this.node.getProps().whileTap&&this.node.animationState&&this.node.animationState.setActive("whileTap",!1),!hE()}cancelPress(e,n){if(!this.checkPressEnd())return;let{onTapCancel:r}=this.node.getProps();r&&dt.postRender(()=>r(e,n))}mount(){let e=this.node.getProps(),n=Fn(e.globalTapTarget?window:this.node.current,"pointerdown",this.startPointerPress,{passive:!(e.onTapStart||e.onPointerStart)}),r=Mn(this.node.current,"focus",this.startAccessiblePress);this.removeStartListeners=Nn(n,r)}unmount(){this.removeStartListeners(),this.removeEndListeners(),this.removeAccessibleListeners()}},bp=new WeakMap,pd=new WeakMap,_6=t=>{let e=bp.get(t.target);e&&e(t)},N6=t=>{t.forEach(_6)};function F6({root:t,...e}){let n=t||document;pd.has(n)||pd.set(n,{});let r=pd.get(n),i=JSON.stringify(e);return r[i]||(r[i]=new IntersectionObserver(N6,{root:t,...e})),r[i]}function V6(t,e,n){let r=F6(e);return bp.set(t,n),r.observe(t),()=>{bp.delete(t),r.unobserve(t)}}var z6={some:0,all:1},xp=class extends vn{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();let{viewport:e={}}=this.node.getProps(),{root:n,margin:r,amount:i="some",once:o}=e,a={root:n?n.current:void 0,rootMargin:r,threshold:typeof i=="number"?i:z6[i]},s=l=>{let{isIntersecting:u}=l;if(this.isInView===u||(this.isInView=u,o&&!u&&this.hasEnteredView))return;u&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",u);let{onViewportEnter:c,onViewportLeave:d}=this.node.getProps(),h=u?c:d;h&&h(l)};return V6(this.node.current,a,s)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;let{props:e,prevProps:n}=this.node;["amount","margin","root"].some(B6(e,n))&&this.startObserver()}unmount(){}};function B6({viewport:t={}},{viewport:e={}}={}){return n=>t[n]!==e[n]}var U6={inView:{Feature:xp},tap:{Feature:yp},focus:{Feature:vp},hover:{Feature:gp}},$6={layout:{ProjectionNode:DE,MeasureLayout:kE}},IE=S.createContext({transformPagePoint:t=>t,isStatic:!1,reducedMotion:"never"}),Gu=S.createContext({}),Hm=typeof window<"u",H6=Hm?S.useLayoutEffect:S.useEffect,LE=S.createContext({strict:!1});function W6(t,e,n,r,i){var o,a;let{visualElement:s}=S.useContext(Gu),l=S.useContext(LE),u=S.useContext(Um),c=S.useContext(IE).reducedMotion,d=S.useRef();r=r||l.renderer,!d.current&&r&&(d.current=r(t,{visualState:e,parent:s,props:n,presenceContext:u,blockInitialAnimation:u?u.initial===!1:!1,reducedMotionConfig:c}));let h=d.current,p=S.useContext(wE);h&&!h.projection&&i&&(h.type==="html"||h.type==="svg")&&q6(d.current,n,i,p);let m=S.useRef(!1);S.useInsertionEffect(()=>{h&&m.current&&h.update(n,u)});let v=n[iE],b=S.useRef(!!v&&!(!((o=window.MotionHandoffIsComplete)===null||o===void 0)&&o.call(window,v))&&((a=window.MotionHasOptimisedAnimation)===null||a===void 0?void 0:a.call(window,v)));return H6(()=>{h&&(m.current=!0,window.MotionIsMounted=!0,h.updateFeatures(),$m.render(h.render),b.current&&h.animationState&&h.animationState.animateChanges())}),S.useEffect(()=>{h&&(!b.current&&h.animationState&&h.animationState.animateChanges(),b.current&&(queueMicrotask(()=>{var f;(f=window.MotionHandoffMarkAsComplete)===null||f===void 0||f.call(window,v)}),b.current=!1))}),h}function q6(t,e,n,r){let{layoutId:i,layout:o,drag:a,dragConstraints:s,layoutScroll:l,layoutRoot:u}=e;t.projection=new n(t.latestValues,e["data-framer-portal-id"]?void 0:jE(t.parent)),t.projection.setOptions({layoutId:i,layout:o,alwaysMeasureLayout:!!a||s&&Di(s),visualElement:t,animationType:typeof o=="string"?o:"both",initialPromotionConfig:r,layoutScroll:l,layoutRoot:u})}function jE(t){if(t)return t.options.allowProjection!==!1?t.projection:jE(t.parent)}function Y6(t,e,n){return S.useCallback(r=>{r&&t.mount&&t.mount(r),e&&(r?e.mount(r):e.unmount()),n&&(typeof n=="function"?n(r):Di(n)&&(n.current=r))},[e])}function Qu(t){return qu(t.animate)||Em.some(e=>_a(t[e]))}function OE(t){return!!(Qu(t)||t.variants)}function K6(t,e){if(Qu(t)){let{initial:n,animate:r}=t;return{initial:n===!1||_a(n)?n:void 0,animate:_a(r)?r:void 0}}return t.inherit!==!1?e:{}}function X6(t){let{initial:e,animate:n}=K6(t,S.useContext(Gu));return S.useMemo(()=>({initial:e,animate:n}),[U1(e),U1(n)])}function U1(t){return Array.isArray(t)?t.join(" "):t}var $1={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]},no={};for(let t in $1)no[t]={isEnabled:e=>$1[t].some(n=>!!e[n])};function G6(t){for(let e in t)no[e]={...no[e],...t[e]}}var Q6=Symbol.for("motionComponentSymbol");function J6({preloadedFeatures:t,createVisualElement:e,useRender:n,useVisualState:r,Component:i}){t&&G6(t);function o(s,l){let u,c={...S.useContext(IE),...s,layoutId:Z6(s)},{isStatic:d}=c,h=X6(s),p=r(s,d);if(!d&&Hm){tB();let m=eB(c);u=m.MeasureLayout,h.visualElement=W6(i,p,c,e,m.ProjectionNode)}return A.jsxs(Gu.Provider,{value:h,children:[u&&h.visualElement?A.jsx(u,{visualElement:h.visualElement,...c}):null,n(i,s,Y6(p,h.visualElement,l),p,d,h.visualElement)]})}let a=S.forwardRef(o);return a[Q6]=i,a}function Z6({layoutId:t}){let e=S.useContext(xE).id;return e&&t!==void 0?e+"-"+t:t}function tB(t,e){S.useContext(LE).strict}function eB(t){let{drag:e,layout:n}=no;if(!e&&!n)return{};let r={...e,...n};return{MeasureLayout:e!=null&&e.isEnabled(t)||n!=null&&n.isEnabled(t)?r.MeasureLayout:void 0,ProjectionNode:r.ProjectionNode}}var nB=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function Wm(t){return typeof t!="string"||t.includes("-")?!1:!!(nB.indexOf(t)>-1||/[A-Z]/u.test(t))}function _E(t,{style:e,vars:n},r,i){Object.assign(t.style,e,i&&i.getProjectionStyles(r));for(let o in n)t.style.setProperty(o,n[o])}var NE=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]);function FE(t,e,n,r){_E(t,e,void 0,r);for(let i in e.attrs)t.setAttribute(NE.has(i)?i:Bm(i),e.attrs[i])}function VE(t,{layout:e,layoutId:n}){return oi.has(t)||t.startsWith("origin")||(e||n!==void 0)&&(!!su[t]||t==="opacity")}function qm(t,e,n){var r;let{style:i}=t,o={};for(let a in i)(ne(i[a])||e.style&&ne(e.style[a])||VE(a,t)||((r=n?.getValue(a))===null||r===void 0?void 0:r.liveStyle)!==void 0)&&(o[a]=i[a]);return o}function zE(t,e,n){let r=qm(t,e,n);for(let i in t)if(ne(t[i])||ne(e[i])){let o=ts.indexOf(i)!==-1?"attr"+i.charAt(0).toUpperCase()+i.substring(1):i;r[o]=t[i]}return r}function rB(t){let e=S.useRef(null);return e.current===null&&(e.current=t()),e.current}function iB({scrapeMotionValuesFromProps:t,createRenderState:e,onMount:n},r,i,o){let a={latestValues:oB(r,i,o,t),renderState:e()};return n&&(a.mount=s=>n(r,s,a)),a}var BE=t=>(e,n)=>{let r=S.useContext(Gu),i=S.useContext(Um),o=()=>iB(t,e,r,i);return n?o():rB(o)};function oB(t,e,n,r){let i={},o=r(t,{});for(let h in o)i[h]=ll(o[h]);let{initial:a,animate:s}=t,l=Qu(t),u=OE(t);e&&u&&!l&&t.inherit!==!1&&(a===void 0&&(a=e.initial),s===void 0&&(s=e.animate));let c=n?n.initial===!1:!1;c=c||a===!1;let d=c?s:a;if(d&&typeof d!="boolean"&&!qu(d)){let h=Array.isArray(d)?d:[d];for(let p=0;p<h.length;p++){let m=Sm(t,h[p]);if(m){let{transitionEnd:v,transition:b,...f}=m;for(let g in f){let y=f[g];if(Array.isArray(y)){let w=c?y.length-1:0;y=y[w]}y!==null&&(i[g]=y)}for(let g in v)i[g]=v[g]}}}return i}var Ym=()=>({style:{},transform:{},transformOrigin:{},vars:{}}),UE=()=>({...Ym(),attrs:{}}),$E=(t,e)=>e&&typeof t=="number"?e.transform(t):t,aB={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},sB=ts.length;function lB(t,e,n){let r="",i=!0;for(let o=0;o<sB;o++){let a=ts[o],s=t[a];if(s===void 0)continue;let l=!0;if(typeof s=="number"?l=s===(a.startsWith("scale")?1:0):l=parseFloat(s)===0,!l||n){let u=$E(s,Im[a]);if(!l){i=!1;let c=aB[a]||a;r+=`${c}(${u}) `}n&&(e[a]=u)}}return r=r.trim(),n?r=n(e,i?"":r):i&&(r="none"),r}function Km(t,e,n){let{style:r,vars:i,transformOrigin:o}=t,a=!1,s=!1;for(let l in e){let u=e[l];if(oi.has(l)){a=!0;continue}else if(NT(l)){i[l]=u;continue}else{let c=$E(u,Im[l]);l.startsWith("origin")?(s=!0,o[l]=c):r[l]=c}}if(e.transform||(a||n?r.transform=lB(e,t.transform,n):r.transform&&(r.transform="none")),s){let{originX:l="50%",originY:u="50%",originZ:c=0}=o;r.transformOrigin=`${l} ${u} ${c}`}}function H1(t,e,n){return typeof t=="string"?t:q.transform(e+n*t)}function uB(t,e,n){let r=H1(e,t.x,t.width),i=H1(n,t.y,t.height);return`${r} ${i}`}var cB={offset:"stroke-dashoffset",array:"stroke-dasharray"},dB={offset:"strokeDashoffset",array:"strokeDasharray"};function hB(t,e,n=1,r=0,i=!0){t.pathLength=1;let o=i?cB:dB;t[o.offset]=q.transform(-r);let a=q.transform(e),s=q.transform(n);t[o.array]=`${a} ${s}`}function Xm(t,{attrX:e,attrY:n,attrScale:r,originX:i,originY:o,pathLength:a,pathSpacing:s=1,pathOffset:l=0,...u},c,d){if(Km(t,u,d),c){t.style.viewBox&&(t.attrs.viewBox=t.style.viewBox);return}t.attrs=t.style,t.style={};let{attrs:h,style:p,dimensions:m}=t;h.transform&&(m&&(p.transform=h.transform),delete h.transform),m&&(i!==void 0||o!==void 0||p.transform)&&(p.transformOrigin=uB(m,i!==void 0?i:.5,o!==void 0?o:.5)),e!==void 0&&(h.x=e),n!==void 0&&(h.y=n),r!==void 0&&(h.scale=r),a!==void 0&&hB(h,a,s,l,!1)}var Gm=t=>typeof t=="string"&&t.toLowerCase()==="svg",pB={useVisualState:BE({scrapeMotionValuesFromProps:zE,createRenderState:UE,onMount:(t,e,{renderState:n,latestValues:r})=>{dt.read(()=>{try{n.dimensions=typeof e.getBBox=="function"?e.getBBox():e.getBoundingClientRect()}catch{n.dimensions={x:0,y:0,width:0,height:0}}}),dt.render(()=>{Xm(n,r,Gm(e.tagName),t.transformTemplate),FE(e,n)})}})},fB={useVisualState:BE({scrapeMotionValuesFromProps:qm,createRenderState:Ym})};function HE(t,e,n){for(let r in e)!ne(e[r])&&!VE(r,n)&&(t[r]=e[r])}function mB({transformTemplate:t},e){return S.useMemo(()=>{let n=Ym();return Km(n,e,t),Object.assign({},n.vars,n.style)},[e])}function gB(t,e){let n=t.style||{},r={};return HE(r,n,t),Object.assign(r,mB(t,e)),r}function vB(t,e){let n={},r=gB(t,e);return t.drag&&t.dragListener!==!1&&(n.draggable=!1,r.userSelect=r.WebkitUserSelect=r.WebkitTouchCallout="none",r.touchAction=t.drag===!0?"none":`pan-${t.drag==="x"?"y":"x"}`),t.tabIndex===void 0&&(t.onTap||t.onTapStart||t.whileTap)&&(n.tabIndex=0),n.style=r,n}var yB=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function lu(t){return t.startsWith("while")||t.startsWith("drag")&&t!=="draggable"||t.startsWith("layout")||t.startsWith("onTap")||t.startsWith("onPan")||t.startsWith("onLayout")||yB.has(t)}var WE=t=>!lu(t);function bB(t){t&&(WE=e=>e.startsWith("on")?!lu(e):t(e))}try{bB(Qm("@emotion/is-prop-valid").default)}catch{}function xB(t,e,n){let r={};for(let i in t)i==="values"&&typeof t.values=="object"||(WE(i)||n===!0&&lu(i)||!e&&!lu(i)||t.draggable&&i.startsWith("onDrag"))&&(r[i]=t[i]);return r}function wB(t,e,n,r){let i=S.useMemo(()=>{let o=UE();return Xm(o,e,Gm(r),t.transformTemplate),{...o.attrs,style:{...o.style}}},[e]);if(t.style){let o={};HE(o,t.style,t),i.style={...o,...i.style}}return i}function kB(t=!1){return(e,n,r,{latestValues:i},o)=>{let a=(Wm(e)?wB:vB)(n,i,o,e),s=xB(n,typeof e=="string",t),l=e!==S.Fragment?{...s,...a,ref:r}:{},{children:u}=n,c=S.useMemo(()=>ne(u)?u.get():u,[u]);return S.createElement(e,{...l,children:c})}}function SB(t,e){return function(n,{forwardMotionProps:r}={forwardMotionProps:!1}){let i={...Wm(n)?pB:fB,preloadedFeatures:t,useRender:kB(r),createVisualElement:e,Component:n};return J6(i)}}var wp={current:null},qE={current:!1};function TB(){if(qE.current=!0,!!Hm)if(window.matchMedia){let t=window.matchMedia("(prefers-reduced-motion)"),e=()=>wp.current=t.matches;t.addListener(e),e()}else wp.current=!1}function EB(t,e,n){for(let r in e){let i=e[r],o=n[r];if(ne(i))t.addValue(r,i);else if(ne(o))t.addValue(r,Ua(i,{owner:t}));else if(o!==i)if(t.hasValue(r)){let a=t.getValue(r);a.liveStyle===!0?a.jump(i):a.hasAnimated||a.set(i)}else{let a=t.getStaticValue(r);t.addValue(r,Ua(a!==void 0?a:i,{owner:t}))}}for(let r in n)e[r]===void 0&&t.removeValue(r);return e}var W1=new WeakMap,CB=[...zT,Jt,xr],PB=t=>CB.find(VT(t)),q1=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"],kp=class{scrapeMotionValuesFromProps(e,n,r){return{}}constructor({parent:e,props:n,presenceContext:r,reducedMotionConfig:i,blockInitialAnimation:o,visualState:a},s={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=Fa,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{let h=gn.now();this.renderScheduledAt<h&&(this.renderScheduledAt=h,dt.render(this.render,!1,!0))};let{latestValues:l,renderState:u}=a;this.latestValues=l,this.baseTarget={...l},this.initialValues=n.initial?{...l}:{},this.renderState=u,this.parent=e,this.props=n,this.presenceContext=r,this.depth=e?e.depth+1:0,this.reducedMotionConfig=i,this.options=s,this.blockInitialAnimation=!!o,this.isControllingVariants=Qu(n),this.isVariantNode=OE(n),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(e&&e.current);let{willChange:c,...d}=this.scrapeMotionValuesFromProps(n,{},this);for(let h in d){let p=d[h];l[h]!==void 0&&ne(p)&&p.set(l[h],!1)}}mount(e){this.current=e,W1.set(e,this),this.projection&&!this.projection.instance&&this.projection.mount(e),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((n,r)=>this.bindToMotionValue(r,n)),qE.current||TB(),this.shouldReduceMotion=this.reducedMotionConfig==="never"?!1:this.reducedMotionConfig==="always"?!0:wp.current,this.parent&&this.parent.children.add(this),this.update(this.props,this.presenceContext)}unmount(){W1.delete(this.current),this.projection&&this.projection.unmount(),yr(this.notifyUpdate),yr(this.render),this.valueSubscriptions.forEach(e=>e()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent&&this.parent.children.delete(this);for(let e in this.events)this.events[e].clear();for(let e in this.features){let n=this.features[e];n&&(n.unmount(),n.isMounted=!1)}this.current=null}bindToMotionValue(e,n){this.valueSubscriptions.has(e)&&this.valueSubscriptions.get(e)();let r=oi.has(e),i=n.on("change",s=>{this.latestValues[e]=s,this.props.onUpdate&&dt.preRender(this.notifyUpdate),r&&this.projection&&(this.projection.isTransformDirty=!0)}),o=n.on("renderRequest",this.scheduleRender),a;window.MotionCheckAppearSync&&(a=window.MotionCheckAppearSync(this,e,n)),this.valueSubscriptions.set(e,()=>{i(),o(),a&&a(),n.owner&&n.stop()})}sortNodePosition(e){return!this.current||!this.sortInstanceNodePosition||this.type!==e.type?0:this.sortInstanceNodePosition(this.current,e.current)}updateFeatures(){let e="animation";for(e in no){let n=no[e];if(!n)continue;let{isEnabled:r,Feature:i}=n;if(!this.features[e]&&i&&r(this.props)&&(this.features[e]=new i(this)),this.features[e]){let o=this.features[e];o.isMounted?o.update():(o.mount(),o.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):It()}getStaticValue(e){return this.latestValues[e]}setStaticValue(e,n){this.latestValues[e]=n}update(e,n){(e.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=e,this.prevPresenceContext=this.presenceContext,this.presenceContext=n;for(let r=0;r<q1.length;r++){let i=q1[r];this.propEventSubscriptions[i]&&(this.propEventSubscriptions[i](),delete this.propEventSubscriptions[i]);let o="on"+i,a=e[o];a&&(this.propEventSubscriptions[i]=this.on(i,a))}this.prevMotionValues=EB(this,this.scrapeMotionValuesFromProps(e,this.prevProps,this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(e){return this.props.variants?this.props.variants[e]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}addVariantChild(e){let n=this.getClosestVariantNode();if(n)return n.variantChildren&&n.variantChildren.add(e),()=>n.variantChildren.delete(e)}addValue(e,n){let r=this.values.get(e);n!==r&&(r&&this.removeValue(e),this.bindToMotionValue(e,n),this.values.set(e,n),this.latestValues[e]=n.get())}removeValue(e){this.values.delete(e);let n=this.valueSubscriptions.get(e);n&&(n(),this.valueSubscriptions.delete(e)),delete this.latestValues[e],this.removeValueFromRenderState(e,this.renderState)}hasValue(e){return this.values.has(e)}getValue(e,n){if(this.props.values&&this.props.values[e])return this.props.values[e];let r=this.values.get(e);return r===void 0&&n!==void 0&&(r=Ua(n===null?void 0:n,{owner:this}),this.addValue(e,r)),r}readValue(e,n){var r;let i=this.latestValues[e]!==void 0||!this.current?this.latestValues[e]:(r=this.getBaseTargetFromProps(this.props,e))!==null&&r!==void 0?r:this.readValueFromInstance(this.current,e,this.options);return i!=null&&(typeof i=="string"&&(OT(i)||jT(i))?i=parseFloat(i):!PB(i)&&xr.test(n)&&(i=KT(e,n)),this.setBaseTarget(e,ne(i)?i.get():i)),ne(i)?i.get():i}setBaseTarget(e,n){this.baseTarget[e]=n}getBaseTarget(e){var n;let{initial:r}=this.props,i;if(typeof r=="string"||typeof r=="object"){let a=Sm(this.props,r,(n=this.presenceContext)===null||n===void 0?void 0:n.custom);a&&(i=a[e])}if(r&&i!==void 0)return i;let o=this.getBaseTargetFromProps(this.props,e);return o!==void 0&&!ne(o)?o:this.initialValues[e]!==void 0&&i===void 0?void 0:this.baseTarget[e]}on(e,n){return this.events[e]||(this.events[e]=new Ba),this.events[e].add(n)}notify(e,...n){this.events[e]&&this.events[e].notify(...n)}},uu=class extends kp{constructor(){super(...arguments),this.KeyframeResolver=Jl}sortInstanceNodePosition(e,n){return e.compareDocumentPosition(n)&2?1:-1}getBaseTargetFromProps(e,n){return e.style?e.style[n]:void 0}removeValueFromRenderState(e,{vars:n,style:r}){delete n[e],delete r[e]}};function AB(t){return window.getComputedStyle(t)}var Sp=class extends uu{constructor(){super(...arguments),this.type="html",this.renderInstance=_E}readValueFromInstance(e,n){if(oi.has(n)){let r=Lm(n);return r&&r.default||0}else{let r=AB(e),i=(NT(n)?r.getPropertyValue(n):r[n])||0;return typeof i=="string"?i.trim():i}}measureInstanceViewportBox(e,{transformPagePoint:n}){return yE(e,n)}build(e,n,r){Km(e,n,r.transformTemplate)}scrapeMotionValuesFromProps(e,n,r){return qm(e,n,r)}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);let{children:e}=this.props;ne(e)&&(this.childSubscription=e.on("change",n=>{this.current&&(this.current.textContent=`${n}`)}))}},Tp=class extends uu{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=It}getBaseTargetFromProps(e,n){return e[n]}readValueFromInstance(e,n){if(oi.has(n)){let r=Lm(n);return r&&r.default||0}return n=NE.has(n)?n:Bm(n),e.getAttribute(n)}scrapeMotionValuesFromProps(e,n,r){return zE(e,n,r)}build(e,n,r){Xm(e,n,this.isSVGTag,r.transformTemplate)}renderInstance(e,n,r,i){FE(e,n,r,i)}mount(e){this.isSVGTag=Gm(e.tagName),super.mount(e)}},MB=(t,e)=>Wm(t)?new Tp(e):new Sp(e,{allowProjection:t!==S.Fragment}),DB=SB({...Dz,...U6,...O6,...$6},MB),cu=EV(DB);function RB({message:t,isLoading:e}){let{content:n}=t;return A.jsx(cu.div,{className:"leoai-message-container user",children:A.jsx("div",{className:"leoai-message-bubble",children:A.jsx(Hu,{remarkPlugins:[Wu,[bm,{target:"_blank"}]],children:n})})})}function IB(){let{links:t,name:e}=we();return A.jsxs("div",{className:"leoai-message-container ai",children:[A.jsx("img",{alt:e,src:t?.icon,className:"leoai-assistant-icon"}),A.jsx("div",{className:"leoai-message-bubble",children:A.jsxs("div",{className:"leoai-typing-dots",children:[A.jsx("span",{}),A.jsx("span",{}),A.jsx("span",{})]})})]})}function LB({message:t}){let{links:e,name:n}=we(),{content:r}=t;return A.jsxs(cu.div,{animate:{y:0,opacity:1},initial:{y:5,opacity:0},className:"leoai-message-container ai",children:[A.jsx("img",{alt:n,src:e?.icon,className:"leoai-assistant-icon"}),t.content&&A.jsx("div",{className:"leoai-message-bubble",children:A.jsx(Hu,{remarkPlugins:[Wu,[bm,{target:"_blank"}]],children:r})})]},t.id)}function Ep(t,e){return e instanceof RegExp?e.test(t):t.includes(e)}function jB(t,e){var n,r;return(n=e.exclude)!=null&&n.some(i=>Ep(t,i))?!1:(r=e.match)!=null&&r.length?e.match.some(i=>Ep(t,i)):!0}function OB(t,e){var n;if(!e.length)return!1;let r=0,i=e.length-1;for(let o=i;o>=0;o--){let a=e[o];if(((n=t.pageType.urlPatterns)==null?void 0:n.some(s=>Ep(a,s)))??!0){if(r++,r>=t.count)return!0}else if(t.resetOnMismatch)break}return!1}function _B(){let{setMessages:t,handleNewEvent:e}=yn(),[n,r]=Nt("leoaiv3.6-visited-pages",[]),[i,o]=S.useState(!1),[a,s]=S.useState(!0),l=S.useCallback(()=>{let u=window.location.pathname;if(!(a||document.readyState!=="complete")){if(n.length===0||n[n.length-1]!==u){let c={id:crypto.randomUUID(),role:"system",content:JSON.stringify({event:"page_visit",title:document.title,path:u,isProduct:!1}),data:{type:"page_visit",path:u,title:document.title,isProduct:!1,timestamp:new Date().toISOString()}};t(d=>[...d,c]),r(d=>[...d,u]),e({type:"PAGE_VISIT",metadata:{url:window.location.href}})}o(!0)}},[t,e,n,a]);return S.useEffect(()=>{let u=()=>{document.readyState==="complete"&&setTimeout(()=>{s(!1),l()},1e3)};u(),window.addEventListener("load",u);let c,d=()=>{clearTimeout(c),c=setTimeout(()=>{l()},100)},h=new MutationObserver(d);return h.observe(document.documentElement,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["href"]}),()=>{h.disconnect(),clearTimeout(c),window.removeEventListener("load",u)}},[l]),{isTrackingDone:i}}async function fd(t){try{let e=await fetch("https://api.leoai.hu/sessions/messages/store",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(t)});if(!e.ok)throw new Error(`HTTP error! status: ${e.status}`);return await e.json()}catch(e){throw console.error("Error posting message:",e),e}}function NB(t){let{opened:e}=Le(),[n]=Nt("leoaiv3.6-visited-pages",[]),{messages:r,setMessages:i,append:o,setSeen:a,session:s}=yn(),{isTrackingDone:l}=_B(),{setQuickReplies:u}=Cf(),c=S.useRef(null);S.useEffect(()=>{if(!t||!l||!s)return;var d=null;if(r.filter(v=>v.data&&typeof v.data=="object"&&"type"in v.data&&v.data.type==="automated").length>=t.globalMaxRetries)return;let h=window.location.pathname,p=t.messages.filter(v=>!r.some(b=>b.id===v.id)).sort((v,b)=>v.priority-b.priority);for(let v of p){let{trigger:b}=v;if(jB(h,b)&&b.isProduct===void 0&&!(b.sequence&&!OB(b.sequence,n))){d=v;break}}let m=async v=>{if(v.message.type==="static")i(b=>[...b,{id:v.id,content:v.message.content,role:"assistant",data:{type:"automated",timestamp:new Date().toISOString()}}]),u(v.message.quickReplies??[]),fd({content:v.message.content,role:"assistant",sessionId:s?.id});else if(v.message.type==="dynamic")try{let b=await o({id:v.id,content:`instruction: ${v.message.customPrompt}
                    example: ${v.message.fallback.content}`,role:"system",data:{type:"automated_message_instruction",timestamp:new Date().toISOString()}});fd({content:b,role:"assistant",sessionId:s?.id})}catch(b){console.error(b),i(f=>[...f,{id:v.id,content:v.message.fallback.content,role:"assistant",data:{type:"automated",timestamp:new Date().toISOString()}}]),fd({content:v.message.fallback.content,role:"assistant",sessionId:s?.id}),u(v.message.fallback.quickReplies??[])}a(!1)};if(d){if(!r.some(v=>v.role==="assistant")){m(d);return}c.current&&clearTimeout(c.current),c.current=setTimeout(()=>{e||m(d)},d.trigger.delay*1e3)}return()=>{c.current&&clearTimeout(c.current)}},[t,n,r,i,l,s])}function FB(){let{chatbotId:t,automatedMessageStrategy:e}=we(),{setScrollAnchorPosition:n,scrollAnchorPosition:r,scrollAnchor:i,messages:o,isLoading:a}=yn();S.useEffect(()=>{if(o&&o.length>0&&!a){let l=o.length-1;l!==r&&n(l)}},[o,n,t,a]),S.useEffect(()=>{i.current&&i.current.scrollIntoView({behavior:"smooth",block:"start"})},[r,i]);let s=S.useMemo(()=>o?.map((l,u)=>{let c=l.role==="user",d=o.length-1===u;return c?A.jsx(RB,{message:l,isLoading:a&&d},l.id):l.role==="assistant"&&l.content?A.jsx(LB,{message:l},l.id):null}),[o,a]);return NB(e),A.jsxs("div",{className:"leoai-messages-container",children:[s,a&&o.length>0&&o[o.length-1].role==="user"&&A.jsx(IB,{})]})}function VB({setShouldAutoScroll:t}){let{input:e,inputRef:n,handleInputChange:r,handleSubmit:i,shouldFocusInput:o,setShouldFocusInput:a}=yn(),{texts:s}=we();S.useEffect(()=>{n.current&&o&&(n.current.focus(),a(!1))},[o,n,a]),S.useEffect(()=>{let u=c=>{var d;document.activeElement!==n.current&&c.key.length===1&&!c.ctrlKey&&!c.altKey&&!c.metaKey&&((d=n.current)==null||d.focus())};return document.addEventListener("keydown",u),()=>document.removeEventListener("keydown",u)},[]);let l=u=>{u.key==="Enter"&&!u.shiftKey&&(u.preventDefault(),i(u))};return A.jsxs("form",{className:"leoai-chat-form",onSubmit:u=>{if(u.preventDefault(),!e){Ef.error("\xCDrja be k\xE9rd\xE9s\xE9t el\u0151sz\xF6r!");return}i(u)},children:[A.jsx(mS.div,{layout:!0,transition:{duration:.1},className:"grow-wrap","data-replicated-value":e,children:A.jsx("textarea",{ref:n,value:e,onChange:r,onKeyDown:l,onFocus:()=>t(!0),placeholder:s?.views.chat.input_placeholder||"K\xE9rdezzen b\xE1rmit...",className:"leoai-chat-textarea"})}),A.jsx("button",{type:"submit",className:"leoai-chat-submit-button",children:A.jsx(R3,{size:24,strokeWidth:2})})]})}function zB(){let{quickReplies:t}=Cf(),{append:e,handleNewEvent:n,isLoading:r}=yn();return t&&t.length>0&&!r?A.jsx("div",{className:"leoai-chat-buttons-container",children:t.map((i,o)=>A.jsx("button",{className:"leoai-quick-button chat",onClick:()=>{e({role:"user",content:i,data:{quickReply:{id:o+1,from:"chat"}}})},children:i},o))}):null}function BB(t){let e=S.useRef(null),n=S.useRef(null),{messages:r,shouldAutoScroll:i=!0,opened:o=!0}=t;return S.useEffect(()=>{let a=e.current,s=n.current;!a||!s||!i||!o||a.scrollHeight-a.scrollTop<=a.clientHeight+100&&s.scrollIntoView({behavior:"smooth",block:"end"})},[r,i,o]),[e,n]}function UB(){let t=S.useRef(null),{messages:e,shouldAutoScroll:n,setShouldAutoScroll:r}=yn(),{opened:i}=Le(),[o,a]=BB({messages:e,shouldAutoScroll:n,opened:i??!1}),s=l=>{let u=l.currentTarget,c=u.scrollHeight-u.scrollTop<=u.clientHeight+100;n!==c&&r(c)};return A.jsxs("div",{ref:t,className:"leoai-chat-view leoai-view-container",children:[A.jsx(F3,{}),A.jsxs("div",{className:"leoai-chat-view-main-container",ref:o,onScroll:s,children:[A.jsx(FB,{}),A.jsx(zB,{}),A.jsx("div",{ref:a,className:"shrink-0 min-w-[24px] min-h-[24px]"})]}),A.jsx(Nu,{children:A.jsx(VB,{setShouldAutoScroll:r})})]})}function $B(){let{selectedArticle:t}=cw(),{texts:e}=we(),{setView:n}=Le(),[r,i]=S.useState(!0);if(t)return S.useEffect(()=>{let o=setTimeout(()=>{i(!1)},600);return()=>clearTimeout(o)},[]),A.jsxs(A.Fragment,{children:[r&&A.jsx(vS,{}),A.jsxs("div",{className:"leoai-article-view leoai-view-container",children:[A.jsx(om,{children:A.jsxs("span",{className:"leoai-article-header-title",children:[t.title.length>35?t.title.split(" ").reduce((o,a)=>o.length+a.length+1<=30?o+(o.length?" ":"")+a:o,"")+"...":t.title," "]})}),A.jsxs("div",{className:"leoai-article-wrapper",children:[A.jsxs("div",{className:"updated-at",children:[A.jsx(A3,{size:16,strokeWidth:2}),t.updatedAt?`${new Date(t.updatedAt).toLocaleDateString("hu-HU",{year:"numeric",month:"long",day:"numeric"})}`:"Ismeretlen d\xE1tum"]}),t.thumbnail&&A.jsx("img",{className:"leoai-article-thumbnail",src:t.thumbnail,alt:t.title}),A.jsx("h1",{className:"leoai-article-title",children:t.title}),A.jsx("p",{className:"leoai-article-description",children:t.description}),A.jsx(Hu,{className:"leoai-article",remarkPlugins:[Wu,[bm,{target:"_blank"}]],children:t.content})]}),A.jsx(Nu,{children:A.jsxs("button",{className:"leoai-article-footer-button",onClick:()=>n("chat"),children:[e.common.open_chat_view_button_text,A.jsx(im,{size:24,strokeWidth:2})]})})]})]})}var Y1=30;function HB(){var t;let{opened:e,setOpened:n,setView:r}=Le(),{texts:i,links:o,automatedMessageStrategy:a}=we(),[s,l]=Nt("leoaiv3.6-show-popup",!1),{isLoading:u,quickReplies:c}=Cf(),{messages:d,seen:h,append:p}=yn(),m=S.useRef(null),v=S.useRef(new Audio("https://console.minio.vsites.dev/api/v1/buckets/leoai/objects/download?preview=true&prefix=popup-notification.mp3&version_id=null")),b=S.useRef(!1);return S.useEffect(()=>{let f=()=>{b.current||v.current.play().then(()=>{v.current.pause(),v.current.currentTime=0,b.current=!0}).catch(()=>{})};return document.addEventListener("click",f,{once:!0}),()=>document.removeEventListener("click",f)},[]),S.useEffect(()=>{var f,g;m.current&&clearTimeout(m.current);let y=d[d.length-1];if(y?.role==="assistant"&&!h)if(d.filter(w=>w.role==="assistant").length===1){let w=(((g=(f=a?.messages.find(C=>C.id===y.id))==null?void 0:f.trigger)==null?void 0:g.delay)??12)*1e3;m.current||(m.current=setTimeout(()=>{l(!0),b.current&&!e&&v.current.play(),m.current=setTimeout(()=>{l(!1),m.current=null},Y1*1e3)},w))}else m.current||(l(!0),m.current=setTimeout(()=>{l(!1),m.current=null},Y1*1e3));else l(!1);return()=>{m.current&&(clearTimeout(m.current),m.current=null)}},[d,h]),A.jsxs(cu.div,{className:`leoai-popup-container ${s&&!e&&!u?"show":""}`,initial:{opacity:0,y:20},animate:{opacity:s?1:0,y:s?0:20},exit:{opacity:0,y:20},transition:{duration:.3},children:[A.jsxs(cu.div,{className:"leoai-popup-controls",initial:{opacity:0,y:-10},animate:{opacity:s?1:0,y:s?0:-10},transition:{duration:.2},children:[A.jsxs("button",{className:"leoai-popup-open",onClick:()=>{n(!0)},children:[A.jsx(im,{size:13,strokeWidth:2}),"Chat megnyit\xE1sa"]}),A.jsx("button",{className:"leoai-popup-close",onClick:()=>{l(!1)},children:A.jsx(ql,{size:16,strokeWidth:2})})]}),A.jsxs("div",{className:"leoai-popup-message-container",children:[A.jsx("img",{alt:"chatbot icon",src:o?.icon,className:"leoai-popup-message-icon",onClick:()=>{n(!0),r("chat")},width:32}),A.jsxs("div",{className:"leoai-popup-message",onClick:()=>{n(!0),r("chat")},children:[A.jsx("span",{className:"from",children:i?.common.popup.from}),A.jsx(Hu,{remarkPlugins:[Wu],children:((t=d.filter(f=>f.role==="assistant").slice(-1)[0])==null?void 0:t.content)||""})]})]}),c&&c.length>0&&A.jsx("div",{className:"leoai-popup-buttons-container",children:c.map((f,g)=>A.jsx("button",{className:"leoai-quick-button popup",onClick:()=>{n(!0),r("chat"),p({role:"user",content:f,data:{quickReply:{id:g+1,from:"popup"}}})},children:f},g))})]})}function WB(){let{view:t}=Le(),{chatbotId:e,name:n,enabled:r}=we();if(!r)return null;let i=()=>t==="home"?A.jsx(N3,{}):t==="chat"?A.jsx(UB,{}):t==="article"?A.jsx($B,{}):A.jsx("h1",{children:"404"});return A.jsxs("div",{className:"leoai-container",children:[A.jsx(S3,{children:A.jsx(i,{})}),n&&A.jsx(HB,{}),e&&n&&A.jsx(I3,{})]})}var YE=document.createElement("div");YE.id="leoai-wrapper";document.body.appendChild(YE);var qB=md.createRoot(document.getElementById("leoai-wrapper"));qB.render(A.jsx(R2,{children:A.jsx(WB,{})}));})();
/**
* @license React
* react.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
/**
* @license React
* react-jsx-runtime.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
/**
* @license React
* scheduler.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
/**
* @license React
* react-dom.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
/**
* @license React
* use-sync-external-store-shim.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
/**
* @license lucide-react v0.456.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/
