PageSourceSearch

https://totalhorsechannel.com/assets/index-DwhlwOyx.js

js totalhorsechannel.com collected 2026-10-02 19:41:41 UTC 1,459,887 bytes, 654 lines download raw bytes

vendor: 5,297 bytes, lines 1-10
1const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/ArticleRichTextEditor-Cfo8kN2k.js","assets/query-DYVpeFO3.js","assets/radix-ui-BrXWnT8S.js","assets/react-vendor-DYU0Rr6N.js","assets/CookieBanner-ChUegC1S.js"])))=>i.map(i=>d[i]);
2var p4=Object.defineProperty;var e0=t=>{throw TypeError(t)};var f4=(t,a,r)=>a in t?p4(t,a,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[a]=r;var ma=(t,a,r)=>f4(t,typeof a!="symbol"?a+"":a,r),t0=(t,a,r)=>a.has(t)||e0("Cannot "+r);var Ba=(t,a,r)=>(t0(t,a,"read from private field"),r?r.call(t):a.get(t)),Po=(t,a,r)=>a.has(t)?e0("Cannot add the same private member more than once"):a instanceof WeakSet?a.add(t):a.set(t,r),yn=(t,a,r,o)=>(t0(t,a,"write to private field"),o?o.call(t,r):a.set(t,r),r);import{a as x4,j as e,r as g,Q as g4,b as b4}from"./query-DYVpeFO3.js";import{r as y4}from"./react-vendor-DYU0Rr6N.js";import{r as v4,S as j4}from"./radix-ui-BrXWnT8S.js";(function(){const a=document.createElement("link").relList;if(a&&a.supports&&a.supports("modulepreload"))return;for(const l of document.querySelectorAll('link[rel="modulepreload"]'))o(l);new MutationObserver(l=>{for(const d of l)if(d.type==="childList")for(const u of d.addedNodes)u.tagName==="LINK"&&u.rel==="modulepreload"&&o(u)}).observe(document,{childList:!0,subtree:!0});function r(l){const d={};return l.integrity&&(d.integrity=l.integrity),l.referrerPolicy&&(d.referrerPolicy=l.referrerPolicy),l.crossOrigin==="use-credentials"?d.credentials="include":l.crossOrigin==="anonymous"?d.credentials="omit":d.credentials="same-origin",d}function o(l){if(l.ep)return;l.ep=!0;const d=r(l);fetch(l.href,d)}})();var Zp={exports:{}},rc={},Jp={exports:{}},Xp={};/**
3 * @license React
4 * scheduler.production.js
5 *
6 * Copyright (c) Meta Platforms, Inc. and affiliates.
7 *
8 * This source code is licensed under the MIT license found in the
9 * LICENSE file in the root directory of this source tree.
10 */var s0;function w4(){return s0||(s0=1,(function(t){function a(k,K){var L=k.length;k.push(K);e:for(;0<L;){var se=L-1>>>1,X=k[se];if(0<l(X,K))k[se]=K,k[L]=X,L=se;else break e}}function r(k){return k.length===0?null:k[0]}function o(k){if(k.length===0)return null;var K=k[0],L=k.pop();if(L!==K){k[0]=L;e:for(var se=0,X=k.length,le=X>>>1;se<le;){var ge=2*(se+1)-1,Se=k[ge],Me=ge+1,st=k[Me];if(0>l(Se,L))Me<X&&0>l(st,Se)?(k[se]=st,k[Me]=L,se=Me):(k[se]=Se,k[ge]=L,se=ge);else if(Me<X&&0>l(st,L))k[se]=st,k[Me]=L,se=Me;else break e}}return K}function l(k,K){var L=k.sortIndex-K.sortIndex;return L!==0?L:k.id-K.id}if(t.unstable_now=void 0,typeof performance=="object"&&typeof performance.now=="function"){var d=performance;t.unstable_now=function(){return d.now()}}else{var u=Date,m=u.now();t.unstable_now=function(){return u.now()-m}}var p=[],x=[],b=1,y=null,v=3,w=!1,C=!1,A=!1,S=!1,z=typeof setTimeout=="function"?setTimeout:null,T=typeof clearTimeout=="function"?clearTimeout:null,M=typeof setImmediate<"u"?setImmediate:null;function P(k){for(var K=r(x);K!==null;){if(K.callback===null)o(x);else if(K.startTime<=k)o(x),K.sortIndex=K.expirationTime,a(p,K);else break;K=r(x)}}function E(k){if(A=!1,P(k),!C)if(r(p)!==null)C=!0,U||(U=!0,$());else{var K=r(x);K!==null&&I(E,K.startTime-k)}}var U=!1,q=-1,H=5,J=-1;function B(){return S?!0:!(t.unstable_now()-J<H)}function Y(){if(S=!1,U){var k=t.unstable_now();J=k;var K=!0;try{e:{C=!1,A&&(A=!1,T(q),q=-1),w=!0;var L=v;try{t:{for(P(k),y=r(p);y!==null&&!(y.expirationTime>k&&B());){var se=y.callback;if(typeof se=="function"){y.callback=null,v=y.priorityLevel;var X=se(y.expirationTime<=k);if(k=t.unstable_now(),typeof X=="function"){y.callback=X,P(k),K=!0;break t}y===r(p)&&o(p),P(k)}else o(p);y=r(p)}if(y!==null)K=!0;else{var le=r(x);le!==null&&I(E,le.startTime-k),K=!1}}break e}finally{y=null,v=L,w=!1}K=void 0}}finally{K?$():U=!1}}}var $;if(typeof M=="function")$=function(){M(Y)};else if(typeof MessageChannel<"u"){var D=new MessageChannel,W=D.port2;D.port1.onmessage=Y,$=function(){W.postMessage(null)}}else $=function(){z(Y,0)};function I(k,K){q=z(function(){k(t.unstable_now())},K)}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(k){k.callback=null},t.unstable_forceFrameRate=function(k){0>k||125<k?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):H=0<k?Math.floor(1e3/k):5},t.unstable_getCurrentPriorityLevel=function(){return v},t.unstable_next=function(k){switch(v){case 1:case 2:case 3:var K=3;break;default:K=v}var L=v;v=K;try{return k()}finally{v=L}},t.unstable_requestPaint=function(){S=!0},t.unstable_runWithPriority=function(k,K){switch(k){case 1:case 2:case 3:case 4:case 5:break;default:k=3}var L=v;v=k;try{return K()}finally{v=L}},t.unstable_scheduleCallback=function(k,K,L){var se=t.unstable_now();switch(typeof L=="object"&&L!==null?(L=L.delay,L=typeof L=="number"&&0<L?se+L:se):L=se,k){case 1:var X=-1;break;case 2:X=250;break;case 5:X=1073741823;break;case 4:X=1e4;break;default:X=5e3}return X=L+X,k={id:b++,callback:K,priorityLevel:k,startTime:L,expirationTime:X,sortIndex:-1},L>se?(k.sortIndex=L,a(x,k),r(p)===null&&k===r(x)&&(A?(T(q),q=-1):A=!0,I(E,L-se))):(k.sortIndex=X,a(p,k),
vendor: 4,166 bytes, lines 10-18
10C||w||(C=!0,U||(U=!0,$()))),k},t.unstable_shouldYield=B,t.unstable_wrapCallback=function(k){var K=v;return function(){var L=v;v=K;try{return k.apply(this,arguments)}finally{v=L}}}})(Xp)),Xp}var a0;function N4(){return a0||(a0=1,Jp.exports=w4()),Jp.exports}/**
11 * @license React
12 * react-dom-client.production.js
13 *
14 * Copyright (c) Meta Platforms, Inc. and affiliates.
15 *
16 * This source code is licensed under the MIT license found in the
17 * LICENSE file in the root directory of this source tree.
18 */var n0;function S4(){if(n0)return rc;n0=1;var t=N4(),a=x4(),r=y4();function o(s){var n="https://react.dev/errors/"+s;if(1<arguments.length){n+="?args[]="+encodeURIComponent(arguments[1]);for(var i=2;i<arguments.length;i++)n+="&args[]="+encodeURIComponent(arguments[i])}return"Minified React error #"+s+"; visit "+n+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function l(s){return!(!s||s.nodeType!==1&&s.nodeType!==9&&s.nodeType!==11)}function d(s){var n=s,i=s;if(s.alternate)for(;n.return;)n=n.return;else{s=n;do n=s,(n.flags&4098)!==0&&(i=n.return),s=n.return;while(s)}return n.tag===3?i:null}function u(s){if(s.tag===13){var n=s.memoizedState;if(n===null&&(s=s.alternate,s!==null&&(n=s.memoizedState)),n!==null)return n.dehydrated}return null}function m(s){if(s.tag===31){var n=s.memoizedState;if(n===null&&(s=s.alternate,s!==null&&(n=s.memoizedState)),n!==null)return n.dehydrated}return null}function p(s){if(d(s)!==s)throw Error(o(188))}function x(s){var n=s.alternate;if(!n){if(n=d(s),n===null)throw Error(o(188));return n!==s?null:s}for(var i=s,c=n;;){var h=i.return;if(h===null)break;var f=h.alternate;if(f===null){if(c=h.return,c!==null){i=c;continue}break}if(h.child===f.child){for(f=h.child;f;){if(f===i)return p(h),s;if(f===c)return p(h),n;f=f.sibling}throw Error(o(188))}if(i.return!==c.return)i=h,c=f;else{for(var j=!1,R=h.child;R;){if(R===i){j=!0,i=h,c=f;break}if(R===c){j=!0,c=h,i=f;break}R=R.sibling}if(!j){for(R=f.child;R;){if(R===i){j=!0,i=f,c=h;break}if(R===c){j=!0,c=f,i=h;break}R=R.sibling}if(!j)throw Error(o(189))}}if(i.alternate!==c)throw Error(o(190))}if(i.tag!==3)throw Error(o(188));return i.stateNode.current===i?s:n}function b(s){var n=s.tag;if(n===5||n===26||n===27||n===6)return s;for(s=s.child;s!==null;){if(n=b(s),n!==null)return n;s=s.sibling}return null}var y=Object.assign,v=Symbol.for("react.element"),w=Symbol.for("react.transitional.element"),C=Symbol.for("react.portal"),A=Symbol.for("react.fragment"),S=Symbol.for("react.strict_mode"),z=Symbol.for("react.profiler"),T=Symbol.for("react.consumer"),M=Symbol.for("react.context"),P=Symbol.for("react.forward_ref"),E=Symbol.for("react.suspense"),U=Symbol.for("react.suspense_list"),q=Symbol.for("react.memo"),H=Symbol.for("react.lazy"),J=Symbol.for("react.activity"),B=Symbol.for("react.memo_cache_sentinel"),Y=Symbol.iterator;function $(s){return s===null||typeof s!="object"?null:(s=Y&&s[Y]||s["@@iterator"],typeof s=="function"?s:null)}var D=Symbol.for("react.client.reference");function W(s){if(s==null)return null;if(typeof s=="function")return s.$$typeof===D?null:s.displayName||s.name||null;if(typeof s=="string")return s;switch(s){case A:return"Fragment";case z:return"Profiler";case S:return"StrictMode";case E:return"Suspense";case U:return"SuspenseList";case J:return"Activity"}if(typeof s=="object")switch(s.$$typeof){case C:return"Portal";case M:return s.displayName||"Context";case T:return(s._context.displayName||"Context")+".Consumer";case P:var n=s.render;return s=s.displayName,s||(s=n.displayName||n.name||"",s=s!==""?"ForwardRef("+s+")":"ForwardRef"),s;case q:return n=s.displayName||null,n!==null?n:W(s.type)||"Memo";case H:n=s._payload,s=s._init;try{return W(s(n))}catch{}}return null}var I=Array.isArray,k=a.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,K=r.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,L={pending:!1,data:null,method:null,action:null},se=[],X=-1;function le(s){return{current:s}}function ge(s){0>X||(s.current=se[X],se[X]=null,X--)}function Se(s,n){X++,se[X]=s.current,s.current=n}var Me=le(null),st=le(null),We=le(null),Ye=le(null);
vendor: 11,884 bytes, lines 18-25
18function te(s,n){switch(Se(We,n),Se(st,s),Se(Me,null),n.nodeType){case 9:case 11:s=(s=n.documentElement)&&(s=s.namespaceURI)?Nv(s):0;break;default:if(s=n.tagName,n=n.namespaceURI)n=Nv(n),s=Sv(n,s);else switch(s){case"svg":s=1;break;case"math":s=2;break;default:s=0}}ge(Me),Se(Me,s)}function me(){ge(Me),ge(st),ge(We)}function Le(s){s.memoizedState!==null&&Se(Ye,s);var n=Me.current,i=Sv(n,s.type);n!==i&&(Se(st,s),Se(Me,i))}function Ie(s){st.current===s&&(ge(Me),ge(st)),Ye.current===s&&(ge(Ye),tc._currentValue=L)}var ve,ze;function Ue(s){if(ve===void 0)try{throw Error()}catch(i){var n=i.stack.trim().match(/\n( *(at )?)/);ve=n&&n[1]||"",ze=-1<i.stack.indexOf(`
19    at`)?" (<anonymous>)":-1<i.stack.indexOf("@")?"@unknown:0:0":""}return`
20`+ve+s+ze}var ct=!1;function Ot(s,n){if(!s||ct)return"";ct=!0;var i=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var c={DetermineComponentFrameRoot:function(){try{if(n){var pe=function(){throw Error()};if(Object.defineProperty(pe.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(pe,[])}catch(oe){var ie=oe}Reflect.construct(s,[],pe)}else{try{pe.call()}catch(oe){ie=oe}s.call(pe.prototype)}}else{try{throw Error()}catch(oe){ie=oe}(pe=s())&&typeof pe.catch=="function"&&pe.catch(function(){})}}catch(oe){if(oe&&ie&&typeof oe.stack=="string")return[oe.stack,ie.stack]}return[null,null]}};c.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var h=Object.getOwnPropertyDescriptor(c.DetermineComponentFrameRoot,"name");h&&h.configurable&&Object.defineProperty(c.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var f=c.DetermineComponentFrameRoot(),j=f[0],R=f[1];if(j&&R){var F=j.split(`
21`),ne=R.split(`
22`);for(h=c=0;c<F.length&&!F[c].includes("DetermineComponentFrameRoot");)c++;for(;h<ne.length&&!ne[h].includes("DetermineComponentFrameRoot");)h++;if(c===F.length||h===ne.length)for(c=F.length-1,h=ne.length-1;1<=c&&0<=h&&F[c]!==ne[h];)h--;for(;1<=c&&0<=h;c--,h--)if(F[c]!==ne[h]){if(c!==1||h!==1)do if(c--,h--,0>h||F[c]!==ne[h]){var ce=`
23`+F[c].replace(" at new "," at ");return s.displayName&&ce.includes("<anonymous>")&&(ce=ce.replace("<anonymous>",s.displayName)),ce}while(1<=c&&0<=h);break}}}finally{ct=!1,Error.prepareStackTrace=i}return(i=s?s.displayName||s.name:"")?Ue(i):""}function Et(s,n){switch(s.tag){case 26:case 27:case 5:return Ue(s.type);case 16:return Ue("Lazy");case 13:return s.child!==n&&n!==null?Ue("Suspense Fallback"):Ue("Suspense");case 19:return Ue("SuspenseList");case 0:case 15:return Ot(s.type,!1);case 11:return Ot(s.type.render,!1);case 1:return Ot(s.type,!0);case 31:return Ue("Activity");default:return""}}function Zt(s){try{var n="",i=null;do n+=Et(s,i),i=s,s=s.return;while(s);return n}catch(c){return`
24Error generating stack: `+c.message+`
25`+c.stack}}var as=Object.prototype.hasOwnProperty,Jt=t.unstable_scheduleCallback,vs=t.unstable_cancelCallback,js=t.unstable_shouldYield,Ws=t.unstable_requestPaint,Mt=t.unstable_now,jt=t.unstable_getCurrentPriorityLevel,ps=t.unstable_ImmediatePriority,Wt=t.unstable_UserBlockingPriority,ws=t.unstable_NormalPriority,os=t.unstable_LowPriority,qt=t.unstable_IdlePriority,je=t.log,gt=t.unstable_setDisableYieldValue,et=null,Xe=null;function Ae(s){if(typeof je=="function"&&gt(s),Xe&&typeof Xe.setStrictMode=="function")try{Xe.setStrictMode(et,s)}catch{}}var De=Math.clz32?Math.clz32:ls,ft=Math.log,Yt=Math.LN2;function ls(s){return s>>>=0,s===0?32:31-(ft(s)/Yt|0)|0}var qs=256,ue=262144,be=4194304;function _t(s){var n=s&42;if(n!==0)return n;switch(s&-s){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:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return s&261888;case 262144:case 524288:case 1048576:case 2097152:return s&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return s&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return s}}function ns(s,n,i){var c=s.pendingLanes;if(c===0)return 0;var h=0,f=s.suspendedLanes,j=s.pingedLanes;s=s.warmLanes;var R=c&134217727;return R!==0?(c=R&~f,c!==0?h=_t(c):(j&=R,j!==0?h=_t(j):i||(i=R&~s,i!==0&&(h=_t(i))))):(R=c&~f,R!==0?h=_t(R):j!==0?h=_t(j):i||(i=c&~s,i!==0&&(h=_t(i)))),h===0?0:n!==0&&n!==h&&(n&f)===0&&(f=h&-h,i=n&-n,f>=i||f===32&&(i&4194048)!==0)?n:h}function Ct(s,n){return(s.pendingLanes&~(s.suspendedLanes&~s.pingedLanes)&n)===0}function Ut(s,n){switch(s){case 1:case 2:case 4:case 8:case 64:return n+250;case 16:case 32: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 n+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function Qs(){var s=be;return be<<=1,(be&62914560)===0&&(be=4194304),s}function Is(s){for(var n=[],i=0;31>i;i++)n.push(s);return n}function ba(s,n){s.pendingLanes|=n,n!==268435456&&(s.suspendedLanes=0,s.pingedLanes=0,s.warmLanes=0)}function Tr(s,n,i,c,h,f){var j=s.pendingLanes;s.pendingLanes=i,s.suspendedLanes=0,s.pingedLanes=0,s.warmLanes=0,s.expiredLanes&=i,s.entangledLanes&=i,s.errorRecoveryDisabledLanes&=i,s.shellSuspendCounter=0;var R=s.entanglements,F=s.expirationTimes,ne=s.hiddenUpdates;for(i=j&~i;0<i;){var ce=31-De(i),pe=1<<ce;R[ce]=0,F[ce]=-1;var ie=ne[ce];if(ie!==null)for(ne[ce]=null,ce=0;ce<ie.length;ce++){var oe=ie[ce];oe!==null&&(oe.lane&=-536870913)}i&=~pe}c!==0&&wi(s,c,0),f!==0&&h===0&&s.tag!==0&&(s.suspendedLanes|=f&~(j&~n))}function wi(s,n,i){s.pendingLanes|=n,s.suspendedLanes&=~n;var c=31-De(n);s.entangledLanes|=n,s.entanglements[c]=s.entanglements[c]|1073741824|i&261930}function Jn(s,n){var i=s.entangledLanes|=n;for(s=s.entanglements;i;){var c=31-De(i),h=1<<c;h&n|s[c]&n&&(s[c]|=n),i&=~h}}function V(s,n){var i=n&-n;return i=(i&42)!==0?1:G(i),(i&(s.suspendedLanes|n))!==0?0:i}function G(s){switch(s){case 2:s=1;break;case 8:s=4;break;case 32:s=16;break;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:s=128;break;case 268435456:s=134217728;break;default:s=0}return s}function ee(s){return s&=-s,2<s?8<s?(s&134217727)!==0?32:268435456:8:2}function fe(){var s=K.p;return s!==0?s:(s=window.event,s===void 0?32:qv(s.type))}function xe(s,n){var i=K.p;try{return K.p=s,n()}finally{K.p=i}}var Re=Math.random().toString(36).slice(2),Ee="__reactFiber$"+Re,He="__reactProps$"+Re,ke="__reactContainer$"+Re,$e="__reactEvents$"+Re,Ze="__reactListeners$"+Re,qe="__reactHandles$"+Re,Qe="__reactResources$"+Re,wt="__reactMarker$"+Re;function kt(s){delete s[Ee],delete s[He],delete s[$e],delete s[Ze],delete s[qe]}function Gt(s){var n=s[Ee];if(n)return n;for(var i=s.parentNode;i;){if(n=i[ke]||i[Ee]){if(i=n.alternate,n.child!==null||i!==null&&i.child!==null)for(s=zv(s);s!==null;){if(i=s[Ee])return i;s=zv(s)}return n}s=i,i=s.parentNode}return null}function nt(s){if(s=s[Ee]||s[ke]){var n=s.tag;if(n===5||n===6||n===13||n===31||n===26||n===27||n===3)return s}return null}function ea(s){var n=s.tag;if(n===5||n===26||n===27||n===6)return s.stateNode;throw Error(o(33))}function Tt(s){var n=s[Qe];return n||(n=s[Qe]={hoistableStyles:new Map,hoistableScripts:new Map}),n}function bt(s){s[wt]=!0}var ca=new Set,ya={};function da(s,n){fs(s,n),fs(s+"Capture",n)}function fs(s,n){for(ya[s]=n,s=0;s<n.length;s++)ca.add(n[s])}var un=RegExp("^[: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]*$"),Ra={},Wa={};function mn(s){return as.call(Wa,s)?!0:as.call(Ra,s)?!1:un.test(s)?Wa[s]=!0:(Ra[s]=!0,!1)}function hn(s,n,i){if(mn(n))if(i===null)s.removeAttribute(n);else{switch(typeof i){case"undefined":case"function":case"symbol":s.removeAttribute(n);return;case"boolean":var c=n.toLowerCase().slice(0,5);if(c!=="data-"&&c!=="aria-"){s.removeAttribute(n);return}}s.setAttribute(n,""+i)}}function _a(s,n,i){if(i===null)s.removeAttribute(n);else{switch(typeof i){case"undefined":case"function":case"symbol":case"boolean":s.removeAttribute(n);return}s.setAttribute(n,""+i)}}function at(s,n,i,c){if(c===null)s.removeAttribute(i);else{switch(typeof c){case"undefined":case"function":case"symbol":case"boolean":s.removeAttribute(i);return}s.setAttributeNS(n,i,""+c)}}function Ht(s){switch(typeof s){case"bigint":case"boolean":case"number":case"string":case"undefined":return s;case"object":return s;default:return""}}function zt(s){var n=s.type;return(s=s.nodeName)&&s.toLowerCase()==="input"&&(n==="checkbox"||n==="radio")}function pn(s,n,i){var c=Object.getOwnPropertyDescriptor(s.constructor.prototype,n);if(!s.hasOwnProperty(n)&&typeof c<"u"&&typeof c.get=="function"&&typeof c.set=="function"){var h=c.get,f=c.set;return Object.defineProperty(s,n,{configurable:!0,get:function(){return h.call(this)},set:function(j){i=""+j,f.call(this,j)}}),Object.defineProperty(s,n,{enumerable:c.enumerable}),{getValue:function(){return i},setValue:function(j){i=""+j},stopTracking:function(){s._valueTracker=null,delete s[n]}}}}function fn(s){if(!s._valueTracker){var n=zt(s)?"checked":"value";s._valueTracker=pn(s,n,""+s[n])}}function Bt(s){if(!s)return!1;var n=s._valueTracker;if(!n)return!0;var i=n.getValue(),c="";return s&&(c=zt(s)?s.checked?"true":"false":s.value),s=c,s!==i?(n.setValue(s),!0):!1}function ua(s){if(s=s||(typeof document<"u"?document:void 0),typeof s>"u")return null;try{return s.activeElement||s.body}catch{return s.body}}var oo=/[\n"\\]/g;function ta(s){return s.replace(oo,function(n){return"\\"+n.charCodeAt(0).toString(16)+" "})}function Ni(s,n,i,c,h,f,j,R){s.name="",j!=null&&typeof j!="function"&&typeof j!="symbol"&&typeof j!="boolean"?s.type=j:s.removeAttribute("type"),n!=null?j==="number"?(n===0&&s.value===""||s.value!=n)&&(s.value=""+Ht(n)):s.value!==""+Ht(n)&&(s.value=""+Ht(n)):j!=="submit"&&j!=="reset"||s.removeAttribute("value"),n!=null?fl(s,j,Ht(n)):i!=null?fl(s,j,Ht(i)):c!=null&&s.removeAttribute("value"),h==null&&f!=null&&(s.defaultChecked=!!f),h!=null&&(s.checked=h&&typeof h!="function"&&typeof h!="symbol"),R!=null&&typeof R!="function"&&typeof R!="symbol"&&typeof R!="boolean"?s.name=""+Ht(R):s.removeAttribute("name")}function ad(s,n,i,c,h,f,j,R){if(f!=null&&typeof f!="function"&&typeof f!="symbol"&&typeof f!="boolean"&&(s.type=f),n!=null||i!=null){if(!(f!=="submit"&&f!=="reset"||n!=null)){fn(s);return}i=i!=null?""+Ht(i):"",n=n!=null?""+Ht(n):i,R||n===s.value||(s.value=n),s.defaultValue=n}c=c??h,c=typeof c!="function"&&typeof c!="symbol"&&!!c,s.checked=R?s.checked:!!c,s.defaultChecked=!!c,j!=null&&typeof j!="function"&&typeof j!="symbol"&&typeof j!="boolean"&&(s.name=j),fn(s)}function fl(s,n,i){n==="number"&&ua(s.ownerDocument)===s||s.defaultValue===""+i||(s.defaultValue=""+i)}function Ar(s,n,i,c){if(s=s.options,n){n={};for(var h=0;h<i.length;h++)n["$"+i[h]]=!0;for(i=0;i<s.length;i++)h=n.hasOwnProperty("$"+s[i].value),s[i].selected!==h&&(s[i].selected=h),h&&c&&(s[i].defaultSelected=!0)}else{for(i=""+Ht(i),n=null,h=0;h<s.length;h++){if(s[h].value===i){s[h].selected=!0,c&&(s[h].defaultSelected=!0);return}n!==null||s[h].disabled||(n=s[h])}n!==null&&(n.selected=!0)}}function nd(s,n,i){if(n!=null&&(n=""+Ht(n),n!==s.value&&(s.value=n),i==null)){s.defaultValue!==n&&(s.defaultValue=n);return}
vendor: 4,449 bytes, line 25
25s.defaultValue=i!=null?""+Ht(i):""}function xl(s,n,i,c){if(n==null){if(c!=null){if(i!=null)throw Error(o(92));if(I(c)){if(1<c.length)throw Error(o(93));c=c[0]}i=c}i==null&&(i=""),n=i}i=Ht(n),s.defaultValue=i,c=s.textContent,c===i&&c!==""&&c!==null&&(s.value=c),fn(s)}function Er(s,n){if(n){var i=s.firstChild;if(i&&i===s.lastChild&&i.nodeType===3){i.nodeValue=n;return}}s.textContent=n}var Zm=new Set("animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp".split(" "));function gl(s,n,i){var c=n.indexOf("--")===0;i==null||typeof i=="boolean"||i===""?c?s.setProperty(n,""):n==="float"?s.cssFloat="":s[n]="":c?s.setProperty(n,i):typeof i!="number"||i===0||Zm.has(n)?n==="float"?s.cssFloat=i:s[n]=(""+i).trim():s[n]=i+"px"}function lo(s,n,i){if(n!=null&&typeof n!="object")throw Error(o(62));if(s=s.style,i!=null){for(var c in i)!i.hasOwnProperty(c)||n!=null&&n.hasOwnProperty(c)||(c.indexOf("--")===0?s.setProperty(c,""):c==="float"?s.cssFloat="":s[c]="");for(var h in n)c=n[h],n.hasOwnProperty(h)&&i[h]!==c&&gl(s,h,c)}else for(var f in n)n.hasOwnProperty(f)&&gl(s,f,n[f])}function bl(s){if(s.indexOf("-")===-1)return!1;switch(s){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 rd=new Map([["acceptCharset","accept-charset"],["htmlFor","for"],["httpEquiv","http-equiv"],["crossOrigin","crossorigin"],["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRendering","color-rendering"],["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"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["imageRendering","image-rendering"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["paintOrder","paint-order"],["panose-1","panose-1"],["pointerEvents","pointer-events"],["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"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["transformOrigin","transform-origin"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode
25-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"],["xmlnsXlink","xmlns:xlink"],["xHeight","x-height"]]),id=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function Si(s){return id.test(""+s)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":s}function re(){}var Ne=null;function Pe(s){return s=s.target||s.srcElement||window,s.correspondingUseElement&&(s=s.correspondingUseElement),s.nodeType===3?s.parentNode:s}var rt=null,ks=null;function ja(s){var n=nt(s);if(n&&(s=n.stateNode)){var i=s[He]||null;e:switch(s=n.stateNode,n.type){case"input":if(Ni(s,i.value,i.defaultValue,i.defaultValue,i.checked,i.defaultChecked,i.type,i.name),n=i.name,i.type==="radio"&&n!=null){for(i=s;i.parentNode;)i=i.parentNode;for(i=i.querySelectorAll('input[name="'+ta(""+n)+'"][type="radio"]'),n=0;n<i.length;n++){var c=i[n];if(c!==s&&c.form===s.form){var h=c[He]||null;if(!h)throw Error(o(90));Ni(c,h.value,h.defaultValue,h.defaultValue,h.checked,h.defaultChecked,h.type,h.name)}}for(n=0;n<i.length;n++)c=i[n],c.form===s.form&&Bt(c)}break e;case"textarea":nd(s,i.value,i.defaultValue);break e;case"select":n=i.value,n!=null&&Ar(s,!!i.multiple,n,!1)}}}var cs=!1;function Ys(s,n,i){if(cs)return s(n,i);cs=!0;try{var c=s(n);return c}finally{if(cs=!1,(rt!==null||ks!==null)&&(qd(),rt&&(n=rt,s=ks,ks=rt=null,ja(n),s)))for(n=0;n<s.length;n++)ja(s[n])}}function Ts(s,n){var i=s.stateNode;if(i===null)return null;var c=i[He]||null;if(c===null)return null;i=c[n];e:switch(n){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(c=!c.disabled)||(s=s.type,c=!(s==="button"||s==="input"||s==="select"||s==="textarea")),s=!c;break e;default:s=!1}if(s)return null;if(i&&typeof i!="function")throw Error(o(231,n,typeof i));return i}var La=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),yl=!1;if(La)try{var Hn={};Object.defineProperty(Hn,"passive",{get:function(){yl=!0}}),window.addEventListener("test",Hn,Hn),window.removeEventListener("test",Hn,Hn)}catch{yl=!1}var Hr=null,Jm=null,od=null;function Sg(){if(od)return od;var s,n=Jm,i=n.length,c,h="value"in Hr?Hr.value:Hr.textContent,f=h.length;for(s=0;s<i&&n[s]===h[s];s++);var j=i-s;for(c=1;c<=j&&n[i-c]===h[f-c];c++);return od=h.slice(s,1<c?1-c:void 0)}function ld(s){var n=s.keyCode;return"charCode"in s?(s=s.charCode,s===0&&n===13&&(s=13)):s=n,s===10&&(s=13),32<=s||s===13?s:0}function cd(){return!0}function Cg(){return!1}function wa(s){function n(i,c,h,f,j){this._reactName=i,this._targetInst=h,this.type=c,this.nativeEvent=f,this.target=j,this.currentTarget=null;for(var R in s)s.hasOwnProperty(R)&&(i=s[R],this[R]=i?i(f):f[R]);return this.isDefaultPrevented=(f.defaultPrevented!=null?f.defaultPrevented:f.returnValue===!1)?cd:Cg,this.isPropagationStopped=Cg,this}return y(n.prototype,{preventDefault:function(){this.defaultPrevented=!0;var i=this.nativeEvent;i&&(i.preventDefault?i.preventDefault():typeof i.returnValue!="unknown"&&(i.returnValue=!1),this.isDefaultPrevented=cd)},stopPropagation:function(){var i=this.nativeEvent;i&&(i.stopPropagation?i.stopPropagation():typeof i.cancelBubble!="unknown"&&(i.cancelBubble=!0),this.isPropagationStopped=cd)},persist:function(){},isPersistent:cd}),n}var Ci={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(s){return s.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},dd=wa(Ci),vl=y({},Ci,{view:0,detail:0}),mN=wa(vl),Xm,Qm,jl,ud=y({},vl,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:th,button:0,buttons:0,relatedTarget:function(s){return s.relatedTarget===void 0?s.fromElement===s.srcElement?s.toElement:s.fromElement:s.relatedTarget},movementX:function(s){return"movementX"in s?s.movementX:(s!==jl&&(jl&&s.type==="mousemove"?(Xm=s.screenX-jl.screenX,Qm=s.screenY-jl.screenY):Qm=Xm=0,jl=s),Xm)},movementY:function(s){return"movementY"in s?s.movementY:Qm}}),kg=wa(ud),hN=y({},ud,{dataTransfer:0}),pN=wa(hN),fN=y({},vl,{relatedTarget:0}),eh=wa(fN),xN=y({},Ci,{animationName:0,elapsedTime:0,pseudoElement:0}),gN=wa(xN),bN=y({},Ci,{clipboardData:function(s){return"clipboardData"in s?s.clipboardData:window.clipboardData}}),yN=wa(bN),vN=y({},Ci,{data:0}),Tg=wa(vN),jN={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},wN={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"},NN={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function SN(s){var n=this.nativeEvent;return n.getModifierState?n.getModifierState(s):(s=NN[s])?!!n[s]:!1}function th(){return SN}var CN=y({},vl,{key:function(s){if(s.key){var n=jN[s.key]||s.key;if(n!=="Unidentified")return n}
vendor: 5,186 bytes, line 25
25return s.type==="keypress"?(s=ld(s),s===13?"Enter":String.fromCharCode(s)):s.type==="keydown"||s.type==="keyup"?wN[s.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:th,charCode:function(s){return s.type==="keypress"?ld(s):0},keyCode:function(s){return s.type==="keydown"||s.type==="keyup"?s.keyCode:0},which:function(s){return s.type==="keypress"?ld(s):s.type==="keydown"||s.type==="keyup"?s.keyCode:0}}),kN=wa(CN),TN=y({},ud,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Ag=wa(TN),AN=y({},vl,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:th}),EN=wa(AN),HN=y({},Ci,{propertyName:0,elapsedTime:0,pseudoElement:0}),zN=wa(HN),RN=y({},ud,{deltaX:function(s){return"deltaX"in s?s.deltaX:"wheelDeltaX"in s?-s.wheelDeltaX:0},deltaY:function(s){return"deltaY"in s?s.deltaY:"wheelDeltaY"in s?-s.wheelDeltaY:"wheelDelta"in s?-s.wheelDelta:0},deltaZ:0,deltaMode:0}),_N=wa(RN),LN=y({},Ci,{newState:0,oldState:0}),DN=wa(LN),ON=[9,13,27,32],sh=La&&"CompositionEvent"in window,wl=null;La&&"documentMode"in document&&(wl=document.documentMode);var MN=La&&"TextEvent"in window&&!wl,Eg=La&&(!sh||wl&&8<wl&&11>=wl),Hg=" ",zg=!1;function Rg(s,n){switch(s){case"keyup":return ON.indexOf(n.keyCode)!==-1;case"keydown":return n.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function _g(s){return s=s.detail,typeof s=="object"&&"data"in s?s.data:null}var co=!1;function UN(s,n){switch(s){case"compositionend":return _g(n);case"keypress":return n.which!==32?null:(zg=!0,Hg);case"textInput":return s=n.data,s===Hg&&zg?null:s;default:return null}}function PN(s,n){if(co)return s==="compositionend"||!sh&&Rg(s,n)?(s=Sg(),od=Jm=Hr=null,co=!1,s):null;switch(s){case"paste":return null;case"keypress":if(!(n.ctrlKey||n.altKey||n.metaKey)||n.ctrlKey&&n.altKey){if(n.char&&1<n.char.length)return n.char;if(n.which)return String.fromCharCode(n.which)}return null;case"compositionend":return Eg&&n.locale!=="ko"?null:n.data;default:return null}}var KN={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 Lg(s){var n=s&&s.nodeName&&s.nodeName.toLowerCase();return n==="input"?!!KN[s.type]:n==="textarea"}function Dg(s,n,i,c){rt?ks?ks.push(c):ks=[c]:rt=c,n=eu(n,"onChange"),0<n.length&&(i=new dd("onChange","change",null,i,c),s.push({event:i,listeners:n}))}var Nl=null,Sl=null;function IN(s){gv(s,0)}function md(s){var n=ea(s);if(Bt(n))return s}function Og(s,n){if(s==="change")return n}var Mg=!1;if(La){var ah;if(La){var nh="oninput"in document;if(!nh){var Ug=document.createElement("div");Ug.setAttribute("oninput","return;"),nh=typeof Ug.oninput=="function"}ah=nh}else ah=!1;Mg=ah&&(!document.documentMode||9<document.documentMode)}function Pg(){Nl&&(Nl.detachEvent("onpropertychange",Kg),Sl=Nl=null)}function Kg(s){if(s.propertyName==="value"&&md(Sl)){var n=[];Dg(n,Sl,s,Pe(s)),Ys(IN,n)}}function BN(s,n,i){s==="focusin"?(Pg(),Nl=n,Sl=i,Nl.attachEvent("onpropertychange",Kg)):s==="focusout"&&Pg()}function $N(s){if(s==="selectionchange"||s==="keyup"||s==="keydown")return md(Sl)}function VN(s,n){if(s==="click")return md(n)}function FN(s,n){if(s==="input"||s==="change")return md(n)}function WN(s,n){return s===n&&(s!==0||1/s===1/n)||s!==s&&n!==n}var Da=typeof Object.is=="function"?Object.is:WN;function Cl(s,n){if(Da(s,n))return!0;if(typeof s!="object"||s===null||typeof n!="object"||n===null)return!1;var i=Object.keys(s),c=Object.keys(n);if(i.length!==c.length)return!1;for(c=0;c<i.length;c++){var h=i[c];if(!as.call(n,h)||!Da(s[h],n[h]))return!1}return!0}function Ig(s){for(;s&&s.firstChild;)s=s.firstChild;return s}function Bg(s,n){var i=Ig(s);s=0;for(var c;i;){if(i.nodeType===3){if(c=s+i.textContent.length,s<=n&&c>=n)return{node:i,offset:n-s};s=c}e:{for(;i;){if(i.nextSibling){i=i.nextSibling;break e}i=i.parentNode}i=void 0}i=Ig(i)}}function $g(s,n){return s&&n?s===n?!0:s&&s.nodeType===3?!1:n&&n.nodeType===3?$g(s,n.parentNode):"contains"in s?s.contains(n):s.compareDocumentPosition?!!(s.compareDocumentPosition(n)&16):!1:!1}function Vg(s){s=s!=null&&s.ownerDocument!=null&&s.ownerDocument.defaultView!=null?s.ownerDocument.defaultView:window;for(var n=ua(s.document);n instanceof s.HTMLIFrameElement;){try{var i=typeof n.contentWindow.location.href=="string"}catch{i=!1}if(i)s=n.contentWindow;else break;n=ua(s.document)}return n}function rh(s){var n=s&&s.nodeName&&s.nodeName.toLowerCase();return n&&(n==="input"&&(s.type==="text"||s.type==="search"||s.type==="tel"||s.type==="url"||s.type==="password")||n==="textarea"||s.contentEditable==="true")}var qN=La&&"documentMode"in document&&11>=document.documentMode,uo=null,ih=null,kl=null,oh=!1;function Fg(s,n,i){var c=i.window===i?i.document:i.nodeType===9?i:i.ownerDocument;oh||uo==null||uo!==ua(c)||(c=uo,"selectionStart"in c&&rh(c)?c={start:c.selectionStart,end:c.selectionEnd}:(c=(c.ownerDocument&&c.ownerDocument.defaultView||window).getSelection(),c={anchorNode:c.anchorNode,anchorOffset:c.anchorOffset,focu
vendor: 19,179 bytes, line 25
25sNode:c.focusNode,focusOffset:c.focusOffset}),kl&&Cl(kl,c)||(kl=c,c=eu(ih,"onSelect"),0<c.length&&(n=new dd("onSelect","select",null,n,i),s.push({event:n,listeners:c}),n.target=uo)))}function ki(s,n){var i={};return i[s.toLowerCase()]=n.toLowerCase(),i["Webkit"+s]="webkit"+n,i["Moz"+s]="moz"+n,i}var mo={animationend:ki("Animation","AnimationEnd"),animationiteration:ki("Animation","AnimationIteration"),animationstart:ki("Animation","AnimationStart"),transitionrun:ki("Transition","TransitionRun"),transitionstart:ki("Transition","TransitionStart"),transitioncancel:ki("Transition","TransitionCancel"),transitionend:ki("Transition","TransitionEnd")},lh={},Wg={};La&&(Wg=document.createElement("div").style,"AnimationEvent"in window||(delete mo.animationend.animation,delete mo.animationiteration.animation,delete mo.animationstart.animation),"TransitionEvent"in window||delete mo.transitionend.transition);function Ti(s){if(lh[s])return lh[s];if(!mo[s])return s;var n=mo[s],i;for(i in n)if(n.hasOwnProperty(i)&&i in Wg)return lh[s]=n[i];return s}var qg=Ti("animationend"),Yg=Ti("animationiteration"),Gg=Ti("animationstart"),YN=Ti("transitionrun"),GN=Ti("transitionstart"),ZN=Ti("transitioncancel"),Zg=Ti("transitionend"),Jg=new Map,ch="abort auxClick beforeToggle 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(" ");ch.push("scrollEnd");function xn(s,n){Jg.set(s,n),da(n,[s])}var hd=typeof reportError=="function"?reportError:function(s){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var n=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof s=="object"&&s!==null&&typeof s.message=="string"?String(s.message):String(s),error:s});if(!window.dispatchEvent(n))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",s);return}console.error(s)},qa=[],ho=0,dh=0;function pd(){for(var s=ho,n=dh=ho=0;n<s;){var i=qa[n];qa[n++]=null;var c=qa[n];qa[n++]=null;var h=qa[n];qa[n++]=null;var f=qa[n];if(qa[n++]=null,c!==null&&h!==null){var j=c.pending;j===null?h.next=h:(h.next=j.next,j.next=h),c.pending=h}f!==0&&Xg(i,h,f)}}function fd(s,n,i,c){qa[ho++]=s,qa[ho++]=n,qa[ho++]=i,qa[ho++]=c,dh|=c,s.lanes|=c,s=s.alternate,s!==null&&(s.lanes|=c)}function uh(s,n,i,c){return fd(s,n,i,c),xd(s)}function Ai(s,n){return fd(s,null,null,n),xd(s)}function Xg(s,n,i){s.lanes|=i;var c=s.alternate;c!==null&&(c.lanes|=i);for(var h=!1,f=s.return;f!==null;)f.childLanes|=i,c=f.alternate,c!==null&&(c.childLanes|=i),f.tag===22&&(s=f.stateNode,s===null||s._visibility&1||(h=!0)),s=f,f=f.return;return s.tag===3?(f=s.stateNode,h&&n!==null&&(h=31-De(i),s=f.hiddenUpdates,c=s[h],c===null?s[h]=[n]:c.push(n),n.lane=i|536870912),f):null}function xd(s){if(50<Yl)throw Yl=0,vp=null,Error(o(185));for(var n=s.return;n!==null;)s=n,n=s.return;return s.tag===3?s.stateNode:null}var po={};function JN(s,n,i,c){this.tag=s,this.key=i,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=n,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=c,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Oa(s,n,i,c){return new JN(s,n,i,c)}function mh(s){return s=s.prototype,!(!s||!s.isReactComponent)}function Xn(s,n){var i=s.alternate;return i===null?(i=Oa(s.tag,n,s.key,s.mode),i.elementType=s.elementType,i.type=s.type,i.stateNode=s.stateNode,i.alternate=s,s.alternate=i):(i.pendingProps=n,i.type=s.type,i.flags=0,i.subtreeFlags=0,i.deletions=null),i.flags=s.flags&65011712,i.childLanes=s.childLanes,i.lanes=s.lanes,i.child=s.child,i.memoizedProps=s.memoizedProps,i.memoizedState=s.memoizedState,i.updateQueue=s.updateQueue,n=s.dependencies,i.dependencies=n===null?null:{lanes:n.lanes,firstContext:n.firstContext},i.sibling=s.sibling,i.index=s.index,i.ref=s.ref,i.refCleanup=s.refCleanup,i}function Qg(s,n){s.flags&=65011714;var i=s.alternate;return i===null?(s.childLanes=0,s.lanes=n,s.child=null,s.subtreeFlags=0,s.memoizedProps=null,s.memoizedState=null,s.updateQueue=null,s.dependencies=null,s.stateNode=null):(s.childLanes=i.childLanes,s.lanes=i.lanes,s.child=i.child,s.subtreeFlags=0,s.deletions=null,s.memoizedProps=i.memoizedProps,s.memoizedState=i.memoizedState,s.updateQueue=i.updateQueue,s.type=i.type,n=i.dependencies,s.dependencies=n===null?null:{lanes:n.lanes,firstContext:n.firstContext}),s}function gd(s,n,i,c,h,f){var j=0;if(c=s,typeof s=="function")mh(s)&&(j=1);else if(typeof s=="string")j=s4(s,i,Me.current)?26:s==="html"||s==="head"||s==="body"?27:5;else e:switch(s){case J:return s=Oa(31,i,n,h),s.elementType=J,s.lanes=f,s;case A:return Ei(i.children,h,f,n);case S:j=8,h|=24;break;case z:return s=Oa(12,i,n,h|2),s.elementType=z,s.lanes=f,s;case E:return s=Oa(13,i,n,h),s.elementType=E,s.lanes=f,s;case U:return s=Oa(19,i,n,h),s.elementType=U,s.lanes=f,s;default:if(typeof s=="object"&&s!==null)switch(s.$$typeof){case M:j=10;break e;case T:j=9;break e;case P:j=11;break e;case q:j=14;break e;case H:j=16,c=null;break e}j=29,i=Error(o(130,s===null?"null":typeof s,"")),c=null}return n=Oa(j,i,n,h),n.elementType=s,n.type=c,n.lanes=f,n}function Ei(s,n,i,c){return s=Oa(7,s,c,n),s.lanes=i,s}function hh(s,n,i){return s=Oa(6,s,null,n),s.lanes=i,s}function eb(s){var n=Oa(18,null,null,0);return n.stateNode=s,n}function ph(s,n,i){return n=Oa(4,s.children!==null?s.children:[],s.key,n),n.lanes=i,n.stateNode={containerInfo:s.containerInfo,pendingChildren:null,implementation:s.implementation},n}var tb=new WeakMap;function Ya(s,n){if(typeof s=="object"&&s!==null){var i=tb.get(s);return i!==void 0?i:(n={value:s,source:n,stack:Zt(n)},tb.set(s,n),n)}return{value:s,source:n,stack:Zt(n)}}var fo=[],xo=0,bd=null,Tl=0,Ga=[],Za=0,zr=null,zn=1,Rn="";function Qn(s,n){fo[xo++]=Tl,fo[xo++]=bd,bd=s,Tl=n}function sb(s,n,i){Ga[Za++]=zn,Ga[Za++]=Rn,Ga[Za++]=zr,zr=s;var c=zn;s=Rn;var h=32-De(c)-1;c&=~(1<<h),i+=1;var f=32-De(n)+h;if(30<f){var j=h-h%5;f=(c&(1<<j)-1).toString(32),c>>=j,h-=j,zn=1<<32-De(n)+h|i<<h|c,Rn=f+s}else zn=1<<f|i<<h|c,Rn=s}function fh(s){s.return!==null&&(Qn(s,1),sb(s,1,0))}function xh(s){for(;s===bd;)bd=fo[--xo],fo[xo]=null,Tl=fo[--xo],fo[xo]=null;for(;s===zr;)zr=Ga[--Za],Ga[Za]=null,Rn=Ga[--Za],Ga[Za]=null,zn=Ga[--Za],Ga[Za]=null}function ab(s,n){Ga[Za++]=zn,Ga[Za++]=Rn,Ga[Za++]=zr,zn=n.id,Rn=n.overflow,zr=s}var sa=null,ds=null,At=!1,Rr=null,Ja=!1,gh=Error(o(519));function _r(s){var n=Error(o(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?"text":"HTML",""));throw Al(Ya(n,s)),gh}function nb(s){var n=s.stateNode,i=s.type,c=s.memoizedProps;switch(n[Ee]=s,n[He]=c,i){case"dialog":vt("cancel",n),vt("close",n);break;case"iframe":case"object":case"embed":vt("load",n);break;case"video":case"audio":for(i=0;i<Zl.length;i++)vt(Zl[i],n);break;case"source":vt("error",n);break;case"img":case"image":case"link":vt("error",n),vt("load",n);break;case"details":vt("toggle",n);break;case"input":vt("invalid",n),ad(n,c.value,c.defaultValue,c.checked,c.defaultChecked,c.type,c.name,!0);break;case"select":vt("invalid",n);break;case"textarea":vt("invalid",n),xl(n,c.value,c.defaultValue,c.children)}i=c.children,typeof i!="string"&&typeof i!="number"&&typeof i!="bigint"||n.textContent===""+i||c.suppressHydrationWarning===!0||jv(n.textContent,i)?(c.popover!=null&&(vt("beforetoggle",n),vt("toggle",n)),c.onScroll!=null&&vt("scroll",n),c.onScrollEnd!=null&&vt("scrollend",n),c.onClick!=null&&(n.onclick=re),n=!0):n=!1,n||_r(s,!0)}function rb(s){for(sa=s.return;sa;)switch(sa.tag){case 5:case 31:case 13:Ja=!1;return;case 27:case 3:Ja=!0;return;default:sa=sa.return}}function go(s){if(s!==sa)return!1;if(!At)return rb(s),At=!0,!1;var n=s.tag,i;if((i=n!==3&&n!==27)&&((i=n===5)&&(i=s.type,i=!(i!=="form"&&i!=="button")||Dp(s.type,s.memoizedProps)),i=!i),i&&ds&&_r(s),rb(s),n===13){if(s=s.memoizedState,s=s!==null?s.dehydrated:null,!s)throw Error(o(317));ds=Hv(s)}else if(n===31){if(s=s.memoizedState,s=s!==null?s.dehydrated:null,!s)throw Error(o(317));ds=Hv(s)}else n===27?(n=ds,qr(s.type)?(s=Kp,Kp=null,ds=s):ds=n):ds=sa?Qa(s.stateNode.nextSibling):null;return!0}function Hi(){ds=sa=null,At=!1}function bh(){var s=Rr;return s!==null&&(ka===null?ka=s:ka.push.apply(ka,s),Rr=null),s}function Al(s){Rr===null?Rr=[s]:Rr.push(s)}var yh=le(null),zi=null,er=null;function Lr(s,n,i){Se(yh,n._currentValue),n._currentValue=i}function tr(s){s._currentValue=yh.current,ge(yh)}function vh(s,n,i){for(;s!==null;){var c=s.alternate;if((s.childLanes&n)!==n?(s.childLanes|=n,c!==null&&(c.childLanes|=n)):c!==null&&(c.childLanes&n)!==n&&(c.childLanes|=n),s===i)break;s=s.return}}function jh(s,n,i,c){var h=s.child;for(h!==null&&(h.return=s);h!==null;){var f=h.dependencies;if(f!==null){var j=h.child;f=f.firstContext;e:for(;f!==null;){var R=f;f=h;for(var F=0;F<n.length;F++)if(R.context===n[F]){f.lanes|=i,R=f.alternate,R!==null&&(R.lanes|=i),vh(f.return,i,s),c||(j=null);break e}f=R.next}}else if(h.tag===18){if(j=h.return,j===null)throw Error(o(341));j.lanes|=i,f=j.alternate,f!==null&&(f.lanes|=i),vh(j,i,s),j=null}else j=h.child;if(j!==null)j.return=h;else for(j=h;j!==null;){if(j===s){j=null;break}if(h=j.sibling,h!==null){h.return=j.return,j=h;break}j=j.return}h=j}}function bo(s,n,i,c){s=null;for(var h=n,f=!1;h!==null;){if(!f){if((h.flags&524288)!==0)f=!0;else if((h.flags&262144)!==0)break}if(h.tag===10){var j=h.alternate;if(j===null)throw Error(o(387));if(j=j.memoizedProps,j!==null){var R=h.type;Da(h.pendingProps.value,j.value)||(s!==null?s.push(R):s=[R])}}else if(h===Ye.current){if(j=h.alternate,j===null)throw Error(o(387));j.memoizedState.memoizedState!==h.memoizedState.memoizedState&&(s!==null?s.push(tc):s=[tc])}h=h.return}s!==null&&jh(n,s,i,c),n.flags|=262144}function yd(s){for(s=s.firstContext;s!==null;){if(!Da(s.context._currentValue,s.memoizedValue))return!0;s=s.next}return!1}function Ri(s){zi=s,er=null,s=s.dependencies,s!==null&&(s.firstContext=null)}function aa(s){return ib(zi,s)}function vd(s,n){return zi===null&&Ri(s),ib(s,n)}function ib(s,n){var i=n._currentValue;if(n={context:n,memoizedValue:i,next:null},er===null){if(s===null)throw Error(o(308));er=n,s.dependencies={lanes:0,firstContext:n},s.flags|=524288}else er=er.next=n;return i}var XN=typeof AbortController<"u"?AbortController:function(){var s=[],n=this.signal={aborted:!1,addEventListener:function(i,c){s.push(c)}};this.abort=function(){n.aborted=!0,s.forEach(function(i){return i()})}},QN=t.unstable_scheduleCallback,eS=t.unstable_NormalPriority,Rs={$$typeof:M,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function wh(){return{controller:new XN,data:new Map,refCount:0}}function El(s){s.refCount--,s.refCount===0&&QN(eS,function(){s.controller.abort()})}var Hl=null,Nh=0,yo=0,vo=null;function tS(s,n){if(Hl===null){var i=Hl=[];Nh=0,yo=kp(),vo={status:"pending",value:void 0,then:function(c){i.push(c)}}}return Nh++,n.then(ob,ob),n}function ob(){if(--Nh===0&&Hl!==null){vo!==null&&(vo.status="fulfilled");var s=Hl;Hl=null,yo=0,vo=null;for(var n=0;n<s.length;n++)(0,s[n])()}}function sS(s,n){var i=[],c={status:"pending",value:null,reason:null,then:function(h){i.push(h)}};return s.then(function(){c.status="fulfilled",c.value=n;for(var h=0;h<i.length;h++)(0,i[h])(n)},function(h){for(c.status="rejected",c.reason=h,h=0;h<i.length;h++)(0,i[h])(void 0)}),c}var lb=k.S;k.S=function(s,n){Fy=Mt(),typeof n=="object"&&n!==null&&typeof n.then=="function"&&tS(s,n),lb!==null&&lb(s,n)};var _i=le(null);function Sh(){var s=_i.current;return s!==null?s:rs.pooledCache}function jd(s,n){n===null?Se(_i,_i.current):Se(_i,n.pool)}function cb(){var s=Sh();return s===null?null:{parent:Rs._currentValue,pool:s}}var jo=Error(o(460)),Ch=Error(o(474)),wd=Error(o(542)),Nd={then:function(){}};function db(s){return s=s.status,s==="fulfilled"||s==="rejected"}function ub(s,n,i){switch(i=s[i],i===void 0?s.push(n):i!==n&&(n.then(re,re),n=i),n.status){case"fulfilled":return n.value;case"rejected":throw s=n.reason,hb(s),s;default:if(typeof n.status=="string")n.then(re,re);else{if(s=rs,s!==null&&100<s.shellSuspendCounter)throw Error(o(482));s=n,s.status="pending",s.then(function(c){if(n.status==="pending"){var h=n;h.status="fulfilled",h.value=c}},function(c){if(n.status==="pending"){var h=n;h.status="rejected",h.reason=c}})}switch(n.status){case"fulfilled":return n.value;case"rejected":throw s=n.reason,hb(s),s}throw Di=n,jo}}function Li(s){try{var n=s._init;return n(s._payload)}catch(i){throw i!==null&&typeof i=="object"&&typeof i.then=="function"?(Di=i,jo):i}}var Di=null;function mb(){if(Di===null)throw Error(o(459));var s=Di;return Di=null,s}function hb(s){if(s===jo||s===wd)throw Error(o(483))}var wo=null,zl=0;function Sd(s){var n=zl;return zl+=1,wo===null&&(wo=[]),ub(wo,s,n)}function Rl(s,n){n=n.props.ref,s.ref=n!==void 0?n:null}function Cd(s,n){throw n.$$typeof===v?Error(o(525)):(s=Object.prototype.toString.call(n),Error(o(31,s==="[object Object]"?"object with keys {"+Object.keys(n).join(", ")+"}":s)))}function pb(s){function n(Q,Z){if(s){var ae=Q.deletions;ae===null?(Q.deletions=[Z],Q.flags|=16):ae.push(Z)}}function i(Q,Z){if(!s)return null;for(;Z!==null;)n(Q,Z),Z=Z.sibling;return null}function c(Q){for(var Z=new Map;Q!==null;)Q.key!==null?Z.set(Q.key,Q):Z.set(Q.index,Q),Q=Q.sibling;return Z}function h(Q,Z){return Q=Xn(Q,Z),Q.index=0,Q.sibling=null,Q}function f(Q,Z,ae){return Q.index=ae,s?(ae=Q.alternate,ae!==null?(ae=ae.index,ae<Z?(Q.flags|=67108866,Z):ae):(Q.flags|=67108866,Z)):(Q.flags|=1048576,Z)}function j(Q){return s&&Q.alternate===null&&(Q.flags|=67108866),Q}function R(Q,Z,ae,he){return Z===null||Z.tag!==6?(Z=hh(ae,Q.mode,he),Z.return=Q,Z):(Z=h(Z,ae),Z.return=Q,Z)}function F(Q,Z,ae,he){var Ge=ae.type;return Ge===A?ce(Q,Z,ae.props.children,he,ae.key):Z!==null&&(Z.elementType===Ge||typeof Ge=="object"&&Ge!==null&&Ge.$$typeof===H&&Li(Ge)===Z.type)?(Z=h(Z,ae.props),Rl(Z,ae),Z.return=Q,Z):(Z=gd(ae.type,ae.key,ae.props,null,Q.mode,he),Rl(Z,ae),Z.return=Q,Z)}function ne(Q,Z,ae,he){return Z===null||Z.tag!==4||Z.stateNode.containerInfo!==ae.containerInfo||Z.stateNode.implementation!==ae.implementation?(Z=ph(ae,Q.mode,he),Z.return=Q,Z):(Z=h(Z,ae.children||[]),Z.return=Q,Z)}function ce(Q,Z,ae,he,Ge){return Z===null||Z.tag!==7?(Z=Ei(ae,Q.mode,he,Ge),Z.return=Q,Z):(Z=h(Z,ae),Z.return=Q,Z)}function pe(Q,Z,ae){if(typeof Z=="string"&&Z!==""||typeof Z=="number"||typeof Z=="bigint")return Z=hh(""+Z,Q.mode,ae),Z.return=Q,Z;if(typeof Z=="object"&&Z!==null){switch(Z.$$typeof){case w:return ae=gd(Z.type,Z.key,Z.props,null,Q.mode,ae),Rl(ae,Z),ae.return=Q,ae;case C:return Z=ph(Z,Q.mode,ae),Z.return=Q,Z;case H:return Z=Li(Z),pe(Q,Z,ae)}if(I(Z)||$(Z))return Z=Ei(Z,Q.mode,ae,null),Z.return=Q,Z;if(typeof Z.then=="function")return pe(Q,Sd(Z),ae);if(Z.$$typeof===M)return pe(Q,vd(Q,Z),ae);Cd(Q,Z)}return null}function ie(Q,Z,ae,he){var Ge=Z!==null?Z.key:null;if(typeof ae=="string"&&ae!==""||typeof ae=="number"||typeof ae=="bigint")return Ge!==null?null:R(Q,Z,""+ae,he);if(typeof ae=="object"&&ae!==null){switch(ae.$$typeof){case w:return ae.key===Ge?F(Q,Z,ae,he):null;case C:return ae.key===Ge?ne(Q,Z,ae,he):null;case H:return ae=Li(ae),ie(Q,Z,ae,he)}if(I(ae)||$(ae))return Ge!==null?null:ce(Q,Z,ae,he,null);if(typeof ae.then=="function")return ie(Q,Z,Sd(ae),he);if(ae.$$typeof===M)return ie(Q,Z,vd(Q,ae),he);Cd(Q,ae)}return null}function oe(Q,Z,ae,he,Ge){if(typeof he=="string"&&he!==""||typeof he=="number"||typeof he=="bigint")return Q=Q.get(ae)||null,R(Z,Q,""+he,Ge);if(typeof he=="object"&&he!==null){switch(he.$$typeof){case w:return Q=Q.get(he.key===null?ae:he.key)||null,F(Z,Q,he,Ge);case C:return Q=Q.get(he.key===null?ae:he.key)||null,ne(Z,Q,he,Ge);case H:return he=Li(he),oe(Q,Z,ae,he,Ge)}if(I(he)||$(he))return Q=Q.get(ae)||null,ce(Z,Q,he,Ge,null);if(typeof he.then=="function")return oe(Q,Z,ae,Sd(he),Ge);if(he.$$typeof===M)return oe(Q,Z,ae,vd(Z,he),Ge);Cd(Z,he)}return null}function Oe(Q,Z,ae,he){for(var Ge=null,Pt=null,Be=Z,mt=Z=0,St=null;Be!==null&&mt<ae.length;mt++){Be.index>mt?(St=Be,Be=null):St=Be.sibling;var Kt=ie(Q,Be,ae[mt],he);if(Kt===null){Be===null&&(Be=St);break}s&&Be&&Kt.alternate===null&&n(Q,Be),Z=f(Kt,Z,mt),Pt===null?Ge=Kt:Pt.sibling=Kt,Pt=Kt,Be=St}if(mt===ae.length)return i(Q,Be),At&&Qn(Q,mt),Ge;if(Be===null){for(;mt<ae.length;mt++)Be=pe(Q,ae[mt],he),Be!==null&&(Z=f(Be,Z,mt),Pt===null?Ge=Be:Pt.sibling=Be,Pt=Be);return At&&Qn(Q,mt),Ge}for(Be=c(Be);mt<ae.length;mt++)St=oe(Be,Q,mt,ae[mt],he),St!==null&&(s&&St.alternate!==null&&Be.delete(St.key===null?mt:St.key),Z=f(St,Z,mt),Pt===null?Ge=St:Pt.sibling=St,Pt=St);return s&&Be.forEach(function(Xr){return n(Q,Xr)}),At&&Qn(Q,mt),Ge}function Je(Q,Z,ae,he){if(ae==null)throw Error(o(151));for(var Ge=null,Pt=null,Be=Z,mt=Z=0,St=null,Kt=ae.next();Be!==null&&!Kt.done;mt++,Kt=ae.next()){Be.index>mt?(St=Be,Be=null):St=Be.sibling;var Xr=ie(Q,Be,Kt.value,he);if(Xr===null){Be===null&&(Be=St);break}s&&Be&&Xr.alternate===null&&n(Q,Be),Z=f(Xr,Z,mt),Pt===null?Ge=Xr:Pt.sibling=Xr,Pt=Xr,Be=St}if(Kt.done)return i(Q,Be),At&&Qn(Q,mt),Ge;if(Be===null){for(;!Kt.done;mt++,Kt=ae.next())Kt=pe(Q,Kt.value,he),Kt!==null&&(Z=f(Kt,Z,mt),Pt===null?Ge=Kt:Pt.sibling=Kt,Pt=Kt);return At&&Qn(Q,mt),Ge}for(Be=c(Be);!Kt.done;mt++,Kt=ae.next())Kt=oe(Be,Q,mt,Kt.value,he),Kt!==null&&(s&&Kt.alternate!==null&&Be.delete(Kt.key===null?mt:Kt.key),Z=f(Kt,Z,mt),Pt===null?Ge=Kt:Pt.sibling=Kt,Pt=Kt);return s&&Be.forEach(function(h4){return n(Q,h4)}),At&&Qn(Q,mt),Ge}function ss(Q,Z,ae,he){if(typeof ae=="object"&&ae!==null&&ae.type===A&&ae.key===null&&(ae=ae.props.children),typeof ae=="object"&&ae!==null){switch(ae.$$typeof){case w:e:{for(var Ge=ae.key;Z!==null;){if(Z.key===Ge){if(Ge=ae.type,Ge===A){if(Z.tag===7){i(Q,Z.sibling),he=h(Z,ae.props.children),he.return=Q,Q=he;break e}}else if(Z.elementType===Ge||typeof Ge=="object"&&Ge!==null&&Ge.$$typeof===H&&Li(Ge)===Z.type){i(Q,Z.sibling),he=h(Z,ae.props),Rl(he,ae),he.return=Q,Q=he;break e}i(Q,Z);break}else n(Q,Z);Z=Z.sibling}ae.type===A?(he=Ei(ae.props.children,Q.mode,he,ae.key),he.return=Q,Q=he):(he=gd(ae.type,ae.key,ae.props,null,Q.mode,he),Rl(he,ae),he.return=Q,Q=he)}return j(Q);case C:e:{for(Ge=ae.key;Z!==null;){if(Z.key===Ge)if(Z.tag===4&&Z.stateNode.containerInfo===ae.containerInfo&&Z.stateNode.implementation===ae.implementation){i(Q,Z.sibling),he=h(Z,ae.children||[]),he.return=Q,Q=he;break e}else{i(Q,Z);break}else n(Q,Z);Z=Z.sibling}he=ph(ae,Q.mode,he),he.return=Q,Q=he}return j(Q);case H:return ae=Li(ae),ss(Q,Z,ae,he)}if(I(ae))return Oe(Q,Z,ae,he);if($(ae)){if(Ge=$(ae),typeof Ge!="function")throw Error(o(150));return ae=Ge.call(ae),Je(Q,Z,ae,he)}if(typeof ae.then=="function")return ss(Q,Z,Sd(ae),he);
vendor: 5,155 bytes, line 25
25if(ae.$$typeof===M)return ss(Q,Z,vd(Q,ae),he);Cd(Q,ae)}return typeof ae=="string"&&ae!==""||typeof ae=="number"||typeof ae=="bigint"?(ae=""+ae,Z!==null&&Z.tag===6?(i(Q,Z.sibling),he=h(Z,ae),he.return=Q,Q=he):(i(Q,Z),he=hh(ae,Q.mode,he),he.return=Q,Q=he),j(Q)):i(Q,Z)}return function(Q,Z,ae,he){try{zl=0;var Ge=ss(Q,Z,ae,he);return wo=null,Ge}catch(Be){if(Be===jo||Be===wd)throw Be;var Pt=Oa(29,Be,null,Q.mode);return Pt.lanes=he,Pt.return=Q,Pt}finally{}}}var Oi=pb(!0),fb=pb(!1),Dr=!1;function kh(s){s.updateQueue={baseState:s.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Th(s,n){s=s.updateQueue,n.updateQueue===s&&(n.updateQueue={baseState:s.baseState,firstBaseUpdate:s.firstBaseUpdate,lastBaseUpdate:s.lastBaseUpdate,shared:s.shared,callbacks:null})}function Or(s){return{lane:s,tag:0,payload:null,callback:null,next:null}}function Mr(s,n,i){var c=s.updateQueue;if(c===null)return null;if(c=c.shared,($t&2)!==0){var h=c.pending;return h===null?n.next=n:(n.next=h.next,h.next=n),c.pending=n,n=xd(s),Xg(s,null,i),n}return fd(s,c,n,i),xd(s)}function _l(s,n,i){if(n=n.updateQueue,n!==null&&(n=n.shared,(i&4194048)!==0)){var c=n.lanes;c&=s.pendingLanes,i|=c,n.lanes=i,Jn(s,i)}}function Ah(s,n){var i=s.updateQueue,c=s.alternate;if(c!==null&&(c=c.updateQueue,i===c)){var h=null,f=null;if(i=i.firstBaseUpdate,i!==null){do{var j={lane:i.lane,tag:i.tag,payload:i.payload,callback:null,next:null};f===null?h=f=j:f=f.next=j,i=i.next}while(i!==null);f===null?h=f=n:f=f.next=n}else h=f=n;i={baseState:c.baseState,firstBaseUpdate:h,lastBaseUpdate:f,shared:c.shared,callbacks:c.callbacks},s.updateQueue=i;return}s=i.lastBaseUpdate,s===null?i.firstBaseUpdate=n:s.next=n,i.lastBaseUpdate=n}var Eh=!1;function Ll(){if(Eh){var s=vo;if(s!==null)throw s}}function Dl(s,n,i,c){Eh=!1;var h=s.updateQueue;Dr=!1;var f=h.firstBaseUpdate,j=h.lastBaseUpdate,R=h.shared.pending;if(R!==null){h.shared.pending=null;var F=R,ne=F.next;F.next=null,j===null?f=ne:j.next=ne,j=F;var ce=s.alternate;ce!==null&&(ce=ce.updateQueue,R=ce.lastBaseUpdate,R!==j&&(R===null?ce.firstBaseUpdate=ne:R.next=ne,ce.lastBaseUpdate=F))}if(f!==null){var pe=h.baseState;j=0,ce=ne=F=null,R=f;do{var ie=R.lane&-536870913,oe=ie!==R.lane;if(oe?(Nt&ie)===ie:(c&ie)===ie){ie!==0&&ie===yo&&(Eh=!0),ce!==null&&(ce=ce.next={lane:0,tag:R.tag,payload:R.payload,callback:null,next:null});e:{var Oe=s,Je=R;ie=n;var ss=i;switch(Je.tag){case 1:if(Oe=Je.payload,typeof Oe=="function"){pe=Oe.call(ss,pe,ie);break e}pe=Oe;break e;case 3:Oe.flags=Oe.flags&-65537|128;case 0:if(Oe=Je.payload,ie=typeof Oe=="function"?Oe.call(ss,pe,ie):Oe,ie==null)break e;pe=y({},pe,ie);break e;case 2:Dr=!0}}ie=R.callback,ie!==null&&(s.flags|=64,oe&&(s.flags|=8192),oe=h.callbacks,oe===null?h.callbacks=[ie]:oe.push(ie))}else oe={lane:ie,tag:R.tag,payload:R.payload,callback:R.callback,next:null},ce===null?(ne=ce=oe,F=pe):ce=ce.next=oe,j|=ie;if(R=R.next,R===null){if(R=h.shared.pending,R===null)break;oe=R,R=oe.next,oe.next=null,h.lastBaseUpdate=oe,h.shared.pending=null}}while(!0);ce===null&&(F=pe),h.baseState=F,h.firstBaseUpdate=ne,h.lastBaseUpdate=ce,f===null&&(h.shared.lanes=0),Br|=j,s.lanes=j,s.memoizedState=pe}}function xb(s,n){if(typeof s!="function")throw Error(o(191,s));s.call(n)}function gb(s,n){var i=s.callbacks;if(i!==null)for(s.callbacks=null,s=0;s<i.length;s++)xb(i[s],n)}var No=le(null),kd=le(0);function bb(s,n){s=dr,Se(kd,s),Se(No,n),dr=s|n.baseLanes}function Hh(){Se(kd,dr),Se(No,No.current)}function zh(){dr=kd.current,ge(No),ge(kd)}var Ma=le(null),Xa=null;function Ur(s){var n=s.alternate;Se(As,As.current&1),Se(Ma,s),Xa===null&&(n===null||No.current!==null||n.memoizedState!==null)&&(Xa=s)}function Rh(s){Se(As,As.current),Se(Ma,s),Xa===null&&(Xa=s)}function yb(s){s.tag===22?(Se(As,As.current),Se(Ma,s),Xa===null&&(Xa=s)):Pr()}function Pr(){Se(As,As.current),Se(Ma,Ma.current)}function Ua(s){ge(Ma),Xa===s&&(Xa=null),ge(As)}var As=le(0);function Td(s){for(var n=s;n!==null;){if(n.tag===13){var i=n.memoizedState;if(i!==null&&(i=i.dehydrated,i===null||Up(i)||Pp(i)))return n}else if(n.tag===19&&(n.memoizedProps.revealOrder==="forwards"||n.memoizedProps.revealOrder==="backwards"||n.memoizedProps.revealOrder==="unstable_legacy-backwards"||n.memoizedProps.revealOrder==="together")){if((n.flags&128)!==0)return n}else if(n.child!==null){n.child.return=n,n=n.child;continue}if(n===s)break;for(;n.sibling===null;){if(n.return===null||n.return===s)return null;n=n.return}n.sibling.return=n.return,n=n.sibling}return null}var sr=0,ut=null,es=null,_s=null,Ad=!1,So=!1,Mi=!1,Ed=0,Ol=0,Co=null,aS=0;function Ns(){throw Error(o(321))}function _h(s,n){if(n===null)return!1;for(var i=0;i<n.length&&i<s.length;i++)if(!Da(s[i],n[i]))return!1;return!0}function Lh(s,n,i,c,h,f){return sr=f,ut=n,n.memoizedState=null,n.updateQueue=null,n.lanes=0,k.H=s===null||s.memoizedState===null?sy:Gh,Mi=!1,f=i(c,h),Mi=!1,So&&(f=jb(n,i,c,h)),vb(s),f}function vb(s){k.H=Pl;var n=es!==null&&es.next!==null;if(sr=0,_s=es=ut=null,Ad=!1,Ol=0,Co=null,n)throw Error(o(300));s===null||Ls||(s=s.dependencies,s!==null&&yd(s)&&(Ls=!0))}function jb(s,n,i,c){ut=s;var h=0;
vendor: 20,629 bytes, line 25
25do{if(So&&(Co=null),Ol=0,So=!1,25<=h)throw Error(o(301));if(h+=1,_s=es=null,s.updateQueue!=null){var f=s.updateQueue;f.lastEffect=null,f.events=null,f.stores=null,f.memoCache!=null&&(f.memoCache.index=0)}k.H=ay,f=n(i,c)}while(So);return f}function nS(){var s=k.H,n=s.useState()[0];return n=typeof n.then=="function"?Ml(n):n,s=s.useState()[0],(es!==null?es.memoizedState:null)!==s&&(ut.flags|=1024),n}function Dh(){var s=Ed!==0;return Ed=0,s}function Oh(s,n,i){n.updateQueue=s.updateQueue,n.flags&=-2053,s.lanes&=~i}function Mh(s){if(Ad){for(s=s.memoizedState;s!==null;){var n=s.queue;n!==null&&(n.pending=null),s=s.next}Ad=!1}sr=0,_s=es=ut=null,So=!1,Ol=Ed=0,Co=null}function va(){var s={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return _s===null?ut.memoizedState=_s=s:_s=_s.next=s,_s}function Es(){if(es===null){var s=ut.alternate;s=s!==null?s.memoizedState:null}else s=es.next;var n=_s===null?ut.memoizedState:_s.next;if(n!==null)_s=n,es=s;else{if(s===null)throw ut.alternate===null?Error(o(467)):Error(o(310));es=s,s={memoizedState:es.memoizedState,baseState:es.baseState,baseQueue:es.baseQueue,queue:es.queue,next:null},_s===null?ut.memoizedState=_s=s:_s=_s.next=s}return _s}function Hd(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function Ml(s){var n=Ol;return Ol+=1,Co===null&&(Co=[]),s=ub(Co,s,n),n=ut,(_s===null?n.memoizedState:_s.next)===null&&(n=n.alternate,k.H=n===null||n.memoizedState===null?sy:Gh),s}function zd(s){if(s!==null&&typeof s=="object"){if(typeof s.then=="function")return Ml(s);if(s.$$typeof===M)return aa(s)}throw Error(o(438,String(s)))}function Uh(s){var n=null,i=ut.updateQueue;if(i!==null&&(n=i.memoCache),n==null){var c=ut.alternate;c!==null&&(c=c.updateQueue,c!==null&&(c=c.memoCache,c!=null&&(n={data:c.data.map(function(h){return h.slice()}),index:0})))}if(n==null&&(n={data:[],index:0}),i===null&&(i=Hd(),ut.updateQueue=i),i.memoCache=n,i=n.data[n.index],i===void 0)for(i=n.data[n.index]=Array(s),c=0;c<s;c++)i[c]=B;return n.index++,i}function ar(s,n){return typeof n=="function"?n(s):n}function Rd(s){var n=Es();return Ph(n,es,s)}function Ph(s,n,i){var c=s.queue;if(c===null)throw Error(o(311));c.lastRenderedReducer=i;var h=s.baseQueue,f=c.pending;if(f!==null){if(h!==null){var j=h.next;h.next=f.next,f.next=j}n.baseQueue=h=f,c.pending=null}if(f=s.baseState,h===null)s.memoizedState=f;else{n=h.next;var R=j=null,F=null,ne=n,ce=!1;do{var pe=ne.lane&-536870913;if(pe!==ne.lane?(Nt&pe)===pe:(sr&pe)===pe){var ie=ne.revertLane;if(ie===0)F!==null&&(F=F.next={lane:0,revertLane:0,gesture:null,action:ne.action,hasEagerState:ne.hasEagerState,eagerState:ne.eagerState,next:null}),pe===yo&&(ce=!0);else if((sr&ie)===ie){ne=ne.next,ie===yo&&(ce=!0);continue}else pe={lane:0,revertLane:ne.revertLane,gesture:null,action:ne.action,hasEagerState:ne.hasEagerState,eagerState:ne.eagerState,next:null},F===null?(R=F=pe,j=f):F=F.next=pe,ut.lanes|=ie,Br|=ie;pe=ne.action,Mi&&i(f,pe),f=ne.hasEagerState?ne.eagerState:i(f,pe)}else ie={lane:pe,revertLane:ne.revertLane,gesture:ne.gesture,action:ne.action,hasEagerState:ne.hasEagerState,eagerState:ne.eagerState,next:null},F===null?(R=F=ie,j=f):F=F.next=ie,ut.lanes|=pe,Br|=pe;ne=ne.next}while(ne!==null&&ne!==n);if(F===null?j=f:F.next=R,!Da(f,s.memoizedState)&&(Ls=!0,ce&&(i=vo,i!==null)))throw i;s.memoizedState=f,s.baseState=j,s.baseQueue=F,c.lastRenderedState=f}return h===null&&(c.lanes=0),[s.memoizedState,c.dispatch]}function Kh(s){var n=Es(),i=n.queue;if(i===null)throw Error(o(311));i.lastRenderedReducer=s;var c=i.dispatch,h=i.pending,f=n.memoizedState;if(h!==null){i.pending=null;var j=h=h.next;do f=s(f,j.action),j=j.next;while(j!==h);Da(f,n.memoizedState)||(Ls=!0),n.memoizedState=f,n.baseQueue===null&&(n.baseState=f),i.lastRenderedState=f}return[f,c]}function wb(s,n,i){var c=ut,h=Es(),f=At;if(f){if(i===void 0)throw Error(o(407));i=i()}else i=n();var j=!Da((es||h).memoizedState,i);if(j&&(h.memoizedState=i,Ls=!0),h=h.queue,$h(Cb.bind(null,c,h,s),[s]),h.getSnapshot!==n||j||_s!==null&&_s.memoizedState.tag&1){if(c.flags|=2048,ko(9,{destroy:void 0},Sb.bind(null,c,h,i,n),null),rs===null)throw Error(o(349));f||(sr&127)!==0||Nb(c,n,i)}return i}function Nb(s,n,i){s.flags|=16384,s={getSnapshot:n,value:i},n=ut.updateQueue,n===null?(n=Hd(),ut.updateQueue=n,n.stores=[s]):(i=n.stores,i===null?n.stores=[s]:i.push(s))}function Sb(s,n,i,c){n.value=i,n.getSnapshot=c,kb(n)&&Tb(s)}function Cb(s,n,i){return i(function(){kb(n)&&Tb(s)})}function kb(s){var n=s.getSnapshot;s=s.value;try{var i=n();return!Da(s,i)}catch{return!0}}function Tb(s){var n=Ai(s,2);n!==null&&Ta(n,s,2)}function Ih(s){var n=va();if(typeof s=="function"){var i=s;if(s=i(),Mi){Ae(!0);try{i()}finally{Ae(!1)}}}return n.memoizedState=n.baseState=s,n.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:ar,lastRenderedState:s},n}function Ab(s,n,i,c){return s.baseState=i,Ph(s,es,typeof c=="function"?c:ar)}function rS(s,n,i,c,h){if(Dd(s))throw Error(o(485));if(s=n.action,s!==null){var f={payload:h,action:s,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(j){f.listeners.push(j)}};k.T!==null?i(!0):f.isTransition=!1,c(f),i=n.pending,i===null?(f.next=n.pending=f,Eb(n,f)):(f.next=i.next,n.pending=i.next=f)}}function Eb(s,n){var i=n.action,c=n.payload,h=s.state;if(n.isTransition){var f=k.T,j={};k.T=j;try{var R=i(h,c),F=k.S;F!==null&&F(j,R),Hb(s,n,R)}catch(ne){Bh(s,n,ne)}finally{f!==null&&j.types!==null&&(f.types=j.types),k.T=f}}else try{f=i(h,c),Hb(s,n,f)}catch(ne){Bh(s,n,ne)}}function Hb(s,n,i){i!==null&&typeof i=="object"&&typeof i.then=="function"?i.then(function(c){zb(s,n,c)},function(c){return Bh(s,n,c)}):zb(s,n,i)}function zb(s,n,i){n.status="fulfilled",n.value=i,Rb(n),s.state=i,n=s.pending,n!==null&&(i=n.next,i===n?s.pending=null:(i=i.next,n.next=i,Eb(s,i)))}function Bh(s,n,i){var c=s.pending;if(s.pending=null,c!==null){c=c.next;do n.status="rejected",n.reason=i,Rb(n),n=n.next;while(n!==c)}s.action=null}function Rb(s){s=s.listeners;for(var n=0;n<s.length;n++)(0,s[n])()}function _b(s,n){return n}function Lb(s,n){if(At){var i=rs.formState;if(i!==null){e:{var c=ut;if(At){if(ds){t:{for(var h=ds,f=Ja;h.nodeType!==8;){if(!f){h=null;break t}if(h=Qa(h.nextSibling),h===null){h=null;break t}}f=h.data,h=f==="F!"||f==="F"?h:null}if(h){ds=Qa(h.nextSibling),c=h.data==="F!";break e}}_r(c)}c=!1}c&&(n=i[0])}}return i=va(),i.memoizedState=i.baseState=n,c={pending:null,lanes:0,dispatch:null,lastRenderedReducer:_b,lastRenderedState:n},i.queue=c,i=Qb.bind(null,ut,c),c.dispatch=i,c=Ih(!1),f=Yh.bind(null,ut,!1,c.queue),c=va(),h={state:n,dispatch:null,action:s,pending:null},c.queue=h,i=rS.bind(null,ut,h,f,i),h.dispatch=i,c.memoizedState=s,[n,i,!1]}function Db(s){var n=Es();return Ob(n,es,s)}function Ob(s,n,i){if(n=Ph(s,n,_b)[0],s=Rd(ar)[0],typeof n=="object"&&n!==null&&typeof n.then=="function")try{var c=Ml(n)}catch(j){throw j===jo?wd:j}else c=n;n=Es();var h=n.queue,f=h.dispatch;return i!==n.memoizedState&&(ut.flags|=2048,ko(9,{destroy:void 0},iS.bind(null,h,i),null)),[c,f,s]}function iS(s,n){s.action=n}function Mb(s){var n=Es(),i=es;if(i!==null)return Ob(n,i,s);Es(),n=n.memoizedState,i=Es();var c=i.queue.dispatch;return i.memoizedState=s,[n,c,!1]}function ko(s,n,i,c){return s={tag:s,create:i,deps:c,inst:n,next:null},n=ut.updateQueue,n===null&&(n=Hd(),ut.updateQueue=n),i=n.lastEffect,i===null?n.lastEffect=s.next=s:(c=i.next,i.next=s,s.next=c,n.lastEffect=s),s}function Ub(){return Es().memoizedState}function _d(s,n,i,c){var h=va();ut.flags|=s,h.memoizedState=ko(1|n,{destroy:void 0},i,c===void 0?null:c)}function Ld(s,n,i,c){var h=Es();c=c===void 0?null:c;var f=h.memoizedState.inst;es!==null&&c!==null&&_h(c,es.memoizedState.deps)?h.memoizedState=ko(n,f,i,c):(ut.flags|=s,h.memoizedState=ko(1|n,f,i,c))}function Pb(s,n){_d(8390656,8,s,n)}function $h(s,n){Ld(2048,8,s,n)}function oS(s){ut.flags|=4;var n=ut.updateQueue;if(n===null)n=Hd(),ut.updateQueue=n,n.events=[s];else{var i=n.events;i===null?n.events=[s]:i.push(s)}}function Kb(s){var n=Es().memoizedState;return oS({ref:n,nextImpl:s}),function(){if(($t&2)!==0)throw Error(o(440));return n.impl.apply(void 0,arguments)}}function Ib(s,n){return Ld(4,2,s,n)}function Bb(s,n){return Ld(4,4,s,n)}function $b(s,n){if(typeof n=="function"){s=s();var i=n(s);return function(){typeof i=="function"?i():n(null)}}if(n!=null)return s=s(),n.current=s,function(){n.current=null}}function Vb(s,n,i){i=i!=null?i.concat([s]):null,Ld(4,4,$b.bind(null,n,s),i)}function Vh(){}function Fb(s,n){var i=Es();n=n===void 0?null:n;var c=i.memoizedState;return n!==null&&_h(n,c[1])?c[0]:(i.memoizedState=[s,n],s)}function Wb(s,n){var i=Es();n=n===void 0?null:n;var c=i.memoizedState;if(n!==null&&_h(n,c[1]))return c[0];if(c=s(),Mi){Ae(!0);try{s()}finally{Ae(!1)}}return i.memoizedState=[c,n],c}function Fh(s,n,i){return i===void 0||(sr&1073741824)!==0&&(Nt&261930)===0?s.memoizedState=n:(s.memoizedState=i,s=qy(),ut.lanes|=s,Br|=s,i)}function qb(s,n,i,c){return Da(i,n)?i:No.current!==null?(s=Fh(s,i,c),Da(s,n)||(Ls=!0),s):(sr&42)===0||(sr&1073741824)!==0&&(Nt&261930)===0?(Ls=!0,s.memoizedState=i):(s=qy(),ut.lanes|=s,Br|=s,n)}function Yb(s,n,i,c,h){var f=K.p;K.p=f!==0&&8>f?f:8;var j=k.T,R={};k.T=R,Yh(s,!1,n,i);try{var F=h(),ne=k.S;if(ne!==null&&ne(R,F),F!==null&&typeof F=="object"&&typeof F.then=="function"){var ce=sS(F,c);Ul(s,n,ce,Ia(s))}else Ul(s,n,c,Ia(s))}catch(pe){Ul(s,n,{then:function(){},status:"rejected",reason:pe},Ia())}finally{K.p=f,j!==null&&R.types!==null&&(j.types=R.types),k.T=j}}function lS(){}function Wh(s,n,i,c){if(s.tag!==5)throw Error(o(476));var h=Gb(s).queue;Yb(s,h,n,L,i===null?lS:function(){return Zb(s),i(c)})}function Gb(s){var n=s.memoizedState;if(n!==null)return n;n={memoizedState:L,baseState:L,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:ar,lastRenderedState:L},next:null};var i={};return n.next={memoizedState:i,baseState:i,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:ar,lastRenderedState:i},next:null},s.memoizedState=n,s=s.alternate,s!==null&&(s.memoizedState=n),n}function Zb(s){var n=Gb(s);n.next===null&&(n=s.alternate.memoizedState),Ul(s,n.next.queue,{},Ia())}function qh(){return aa(tc)}function Jb(){return Es().memoizedState}function Xb(){return Es().memoizedState}function cS(s){for(var n=s.return;n!==null;){switch(n.tag){case 24:case 3:var i=Ia();s=Or(i);var c=Mr(n,s,i);c!==null&&(Ta(c,n,i),_l(c,n,i)),n={cache:wh()},s.payload=n;return}n=n.return}}function dS(s,n,i){var c=Ia();i={lane:c,revertLane:0,gesture:null,action:i,hasEagerState:!1,eagerState:null,next:null},Dd(s)?ey(n,i):(i=uh(s,n,i,c),i!==null&&(Ta(i,s,c),ty(i,n,c)))}function Qb(s,n,i){var c=Ia();Ul(s,n,i,c)}function Ul(s,n,i,c){var h={lane:c,revertLane:0,gesture:null,action:i,hasEagerState:!1,eagerState:null,next:null};if(Dd(s))ey(n,h);else{var f=s.alternate;if(s.lanes===0&&(f===null||f.lanes===0)&&(f=n.lastRenderedReducer,f!==null))try{var j=n.lastRenderedState,R=f(j,i);if(h.hasEagerState=!0,h.eagerState=R,Da(R,j))return fd(s,n,h,0),rs===null&&pd(),!1}catch{}finally{}if(i=uh(s,n,h,c),i!==null)return Ta(i,s,c),ty(i,n,c),!0}return!1}function Yh(s,n,i,c){if(c={lane:2,revertLane:kp(),gesture:null,action:c,hasEagerState:!1,eagerState:null,next:null},Dd(s)){if(n)throw Error(o(479))}else n=uh(s,i,c,2),n!==null&&Ta(n,s,2)}function Dd(s){var n=s.alternate;return s===ut||n!==null&&n===ut}function ey(s,n){So=Ad=!0;var i=s.pending;i===null?n.next=n:(n.next=i.next,i.next=n),s.pending=n}function ty(s,n,i){if((i&4194048)!==0){var c=n.lanes;c&=s.pendingLanes,i|=c,n.lanes=i,Jn(s,i)}}var Pl={readContext:aa,use:zd,useCallback:Ns,useContext:Ns,useEffect:Ns,useImperativeHandle:Ns,useLayoutEffect:Ns,useInsertionEffect:Ns,useMemo:Ns,useReducer:Ns,useRef:Ns,useState:Ns,useDebugValue:Ns,useDeferredValue:Ns,useTransition:Ns,useSyncExternalStore:Ns,useId:Ns,useHostTransitionStatus:Ns,useFormState:Ns,useActionState:Ns,useOptimistic:Ns,useMemoCache:Ns,useCacheRefresh:Ns};Pl.useEffectEvent=Ns;var sy={readContext:aa,use:zd,useCallback:function(s,n){return va().memoizedState=[s,n===void 0?null:n],s},useContext:aa,useEffect:Pb,useImperativeHandle:function(s,n,i){i=i!=null?i.concat([s]):null,_d(4194308,4,$b.bind(null,n,s),i)},useLayoutEffect:function(s,n){return _d(4194308,4,s,n)},useInsertionEffect:function(s,n){_d(4,2,s,n)},useMemo:function(s,n){var i=va();n=n===void 0?null:n;var c=s();if(Mi){Ae(!0);try{s()}finally{Ae(!1)}}return i.memoizedState=[c,n],c},useReducer:function(s,n,i){var c=va();if(i!==void 0){var h=i(n);if(Mi){Ae(!0);try{i(n)}finally{Ae(!1)}}}else h=n;return c.memoizedState=c.baseState=h,s={pending:null,lanes:0,dispatch:null,lastRenderedReducer:s,lastRenderedState:h},c.queue=s,s=s.dispatch=dS.bind(null,ut,s),[c.memoizedState,s]},useRef:function(s){var n=va();return s={current:s},n.memoizedState=s},useState:function(s){s=Ih(s);var n=s.queue,i=Qb.bind(null,ut,n);return n.dispatch=i,[s.memoizedState,i]},useDebugValue:Vh,useDeferredValue:function(s,n){var i=va();return Fh(i,s,n)},useTransition:function(){var s=Ih(!1);return s=Yb.bind(null,ut,s.queue,!0,!1),va().memoizedState=s,[!1,s]},useSyncExternalStore:function(s,n,i){var c=ut,h=va();if(At){if(i===void 0)throw Error(o(407));i=i()}else{if(i=n(),rs===null)throw Error(o(349));(Nt&127)!==0||Nb(c,n,i)}h.memoizedState=i;var f={value:i,getSnapshot:n};return h.queue=f,Pb(Cb.bind(null,c,f,s),[s]),c.flags|=2048,ko(9,{destroy:void 0},Sb.bind(null,c,f,i,n),null),i},useId:function(){var s=va(),n=rs.identifierPrefix;if(At){var i=Rn,c=zn;i=(c&~(1<<32-De(c)-1)).toString(32)+i,n="_"+n+"R_"+i,i=Ed++,0<i&&(n+="H"+i.toString(32)),n+="_"}else i=aS++,n="_"+n+"r_"+i.toString(32)+"_";return s.memoizedState=n},useHostTransitionStatus:qh,useFormState:Lb,useActionState:Lb,useOptimistic:function(s){var n=va();n.memoizedState=n.baseState=s;var i={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return n.queue=i,n=Yh.bind(null,ut,!0,i),i.dispatch=n,[s,n]},useMemoCache:Uh,useCacheRefresh:function(){return va().memoizedState=cS.bind(null,ut)},useEffectEvent:function(s){var n=va(),i={impl:s};return n.memoizedState=i,function(){if(($t&2)!==0)throw Error(o(440));return i.impl.apply(void 0,arguments)}}},Gh={readContext:aa,use:zd,useCallback:Fb,useContext:aa,useEffect:$h,useImperativeHandle:Vb,useInsertionEffect:Ib,useLayoutEffect:Bb,useMemo:Wb,useReducer:Rd,useRef:Ub,useState:function(){return Rd(ar)},useDebugValue:Vh,useDeferredValue:function(s,n){var i=Es();return qb(i,es.memoizedState,s,n)},useTransition:function(){var s=Rd(ar)[0],n=Es().memoizedState;return[typeof s=="boolean"?s:Ml(s),n]},useSyncExternalStore:wb,useId:Jb,useHostTransitionStatus:qh,useFormState:Db,useActionState:Db,useOptimistic:function(s,n){var i=Es();return Ab(i,es,s,n)},useMemoCache:Uh,useCacheRefresh:Xb};Gh.useEffectEvent=Kb;var ay={readContext:aa,use:zd,useCallback:Fb,useContext:aa,useEffect:$h,useImperativeHandle:Vb,useInsertionEffect:Ib,useLayoutEffect:Bb,useMemo:Wb,useReducer:Kh,useRef:Ub,useState:function(){return Kh(ar)},useDebugValue:Vh,useDeferredValue:function(s,n){var i=Es();return es===null?Fh(i,s,n):qb(i,es.memoizedState,s,n)},useTransition:function(){var s=Kh(ar)[0],n=Es().memoizedState;return[typeof s=="boolean"?s:Ml(s),n]},useSyncExternalStore:wb,useId:Jb,useHostTransitionStatus:qh,useFormState:Mb,useActionState:Mb,useOptimistic:function(s,n){var i=Es();return es!==null?Ab(i,es,s,n):(i.baseState=s,[s,i.queue.dispatch])},useMemoCache:Uh,useCacheRefresh:Xb};ay.useEffectEvent=Kb;function Zh(s,n,i,c){n=s.memoizedState,i=i(c,n),i=i==null?n:y({},n,i),s.memoizedState=i,s.lanes===0&&(s.updateQueue.baseState=i)}var Jh={enqueueSetState:function(s,n,i){s=s._reactInternals;var c=Ia(),h=Or(c);h.payload=n,i!=null&&(h.callback=i),n=Mr(s,h,c),n!==null&&(Ta(n,s,c),_l(n,s,c))},enqueueReplaceState:function(s,n,i){s=s._reactInternals;var c=Ia(),h=Or(c);h.tag=1,h.payload=n,i!=null&&(h.callback=i),n=Mr(s,h,c),n!==null&&(Ta(n,s,c),_l(n,s,c))},enqueueForceUpdate:function(s,n){s=s._reactInternals;var i=Ia(),c=Or(i);c.tag=2,n!=null&&(c.callback=n),n=Mr(s,c,i),n!==null&&(Ta(n,s,i),_l(n,s,i))}};function ny(s,n,i,c,h,f,j){return s=s.stateNode,typeof s.shouldComponentUpdate=="function"?s.shouldComponentUpdate(c,f,j):n.prototype&&n.prototype.isPureReactComponent?!Cl(i,c)||!Cl(h,f):!0}function ry(s,n,i,c){s=n.state,typeof n.componentWillReceiveProps=="function"&&n.componentWillReceiveProps(i,c),typeof n.UNSAFE_componentWillReceiveProps=="function"&&n.UNSAFE_componentWillReceiveProps(i,c),n.state!==s&&Jh.enqueueReplaceState(n,n.state,null)}function Ui(s,n){var i=n;if("ref"in n){i={};for(var c in n)c!=="ref"&&(i[c]=n[c])}if(s=s.defaultProps){i===n&&(i=y({},i));for(var h in s)i[h]===void 0&&(i[h]=s[h])}return i}function iy(s){hd(s)}function oy(s){console.error(s)}function ly(s){hd(s)}function Od(s,n){try{var i=s.onUncaughtError;i(n.value,{componentStack:n.stack})}catch(c){setTimeout(function(){throw c})}}function cy(s,n,i){try{var c=s.onCaughtError;c(i.value,{componentStack:i.stack,errorBoundary:n.tag===1?n.stateNode:null})}catch(h){setTimeout(function(){throw h})}}function Xh(s,n,i){return i=Or(i),i.tag=3,i.payload={element:null},i.callback=function(){Od(s,n)},i}function dy(s){return s=Or(s),s.tag=3,s}function uy(s,n,i,c){var h=i.type.getDerivedStateFromError;if(typeof h=="function"){var f=c.value;s.payload=function(){return h(f)},s.callback=function(){cy(n,i,c)}}var j=i.stateNode;j!==null&&typeof j.componentDidCatch=="function"&&(s.callback=function(){cy(n,i,c),typeof h!="function"&&($r===null?$r=new Set([this]):$r.add(this));var R=c.stack;this.componentDidCatch(c.value,{componentStack:R!==null?R:""})})}function uS(s,n,i,c,h){if(i.flags|=32768,c!==null&&typeof c=="object"&&typeof c.then=="function"){if(n=i.alternate,n!==null&&bo(n,i,h,!0),i=Ma.current,i!==null){switch(i.tag){case 31:case 13:return Xa===null?Yd():i.alternate===null&&Ss===0&&(Ss=3),i.flags&=-257,i.flags|=65536,i.lanes=h,c===Nd?i.flags|=16384:(n=i.updateQueue,n===null?i.updateQueue=new Set([c]):n.add(c),Np(s,c,h)),!1;case 22:return i.flags|=65536,c===Nd?i.flags|=16384:(n=i.updateQueue,n===null?(n={transitions:null,markerInstances:null,retryQueue:new Set([c])},i.updateQueue=n):(i=n.retryQueue,i===null?n.retryQueue=new Set([c]):i.add(c)),Np(s,c,h)),!1}throw Error(o(435,i.tag))}return Np(s,c,h),Yd(),!1}if(At)return n=Ma.current,n!==null?((n.flags&65536)===0&&(n.flags|=256),n.flags|=65536,n.lanes=h,c!==gh&&(s=Error(o(422),{cause:c}),Al(Ya(s,i)))):(c!==gh&&(n=Error(o(423),{cause:c}),Al(Ya(n,i))),s=s.current.alternate,s.flags|=65536,h&=-h,s.lanes|=h,c=Ya(c,i),h=Xh(s.stateNode,c,h),Ah(s,h),Ss!==4&&(Ss=2)),!1;var f=Error(o(520),{cause:c});if(f=Ya(f,i),ql===null?ql=[f]:ql.push(f),Ss!==4&&(Ss=2),n===null)return!0;c=Ya(c,i),i=n;do{switch(i.tag){case 3:return i.flags|=65536,s=h&-h,i.lanes|=s,s=Xh(i.stateNode,c,s),Ah(i,s),!1;case 1:if(n=i.type,f=i.stateNode,(i.flags&128)===0&&(typeof n.getDerivedStateFromError=="function"||f!==null&&typeof f.componentDidCatch=="function"&&($r===null||!$r.has(f))))return i.flags|=65536,h&=-h,i.lanes|=h,h=dy(h),uy(h,s,i,c),Ah(i,h),!1}i=i.return}while(i!==null);return!1}var Qh=Error(o(461)),Ls=!1;function na(s,n,i,c){n.child=s===null?fb(n,null,i,c):Oi(n,s.child,i,c)}function my(s,n,i,c,h){i=i.render;var f=n.ref;if("ref"in c){var j={};for(var R in c)R!=="ref"&&(j[R]=c[R])}else j=c;return Ri(n),c=Lh(s,n,i,j,f,h),R=Dh(),s!==null&&!Ls?(Oh(s,n,h),nr(s,n,h)):(At&&R&&fh(n),n.flags|=1,na(s,n,c,h),n.child)}function hy(s,n,i,c,h){if(s===null){var f=i.type;return typeof f=="function"&&!mh(f)&&f.defaultProps===void 0&&i.compare===null?(n.tag=15,n.type=f,py(s,n,f,c,h)):(s=gd(i.type,null,c,n,n.mode,h),s.ref=n.ref,s.return=n,n.child=s)}if(f=s.child,!op(s,h)){var j=f.memoizedProps;if(i=i.compare,i=i!==null?i:Cl,i(j,c)&&s.ref===n.ref)return nr(s,n,h)}return n.flags|=1,s=Xn(f,c),s.ref=n.ref,s.return=n,n.child=s}function py(s,n,i,c,h){if(s!==null){var f=s.memoizedProps;if(Cl(f,c)&&s.ref===n.ref)if(Ls=!1,n.pendingProps=c=f,op(s,h))(s.flags&131072)!==0&&(Ls=!0);else return n.lanes=s.lanes,nr(s,n,h)}return ep(s,n,i,c,h)}function fy(s,n,i,c){var h=c.children,f=s!==null?s.memoizedState:null;if(s===null&&n.stateNode===null&&(n.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),c.mode==="hidden"){if((n.flags&128)!==0){if(f=f!==null?f.baseLanes|i:i,s!==null){for(c=n.child=s.child,h=0;c!==null;)h=h|c.lanes|c.childLanes,c=c.sibling;c=h&~f}else c=0,n.child=null;return xy(s,n,f,i,c)}if((i&536870912)!==0)n.memoizedState={baseLanes:0,cachePool:null},s!==null&&jd(n,f!==null?f.cachePool:null),f!==null?bb(n,f):Hh(),yb(n);else return c=n.lanes=536870912,xy(s,n,f!==null?f.baseLanes|i:i,i,c)}
vendor: 18,259 bytes, line 25
25else f!==null?(jd(n,f.cachePool),bb(n,f),Pr(),n.memoizedState=null):(s!==null&&jd(n,null),Hh(),Pr());return na(s,n,h,i),n.child}function Kl(s,n){return s!==null&&s.tag===22||n.stateNode!==null||(n.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),n.sibling}function xy(s,n,i,c,h){var f=Sh();return f=f===null?null:{parent:Rs._currentValue,pool:f},n.memoizedState={baseLanes:i,cachePool:f},s!==null&&jd(n,null),Hh(),yb(n),s!==null&&bo(s,n,c,!0),n.childLanes=h,null}function Md(s,n){return n=Pd({mode:n.mode,children:n.children},s.mode),n.ref=s.ref,s.child=n,n.return=s,n}function gy(s,n,i){return Oi(n,s.child,null,i),s=Md(n,n.pendingProps),s.flags|=2,Ua(n),n.memoizedState=null,s}function mS(s,n,i){var c=n.pendingProps,h=(n.flags&128)!==0;if(n.flags&=-129,s===null){if(At){if(c.mode==="hidden")return s=Md(n,c),n.lanes=536870912,Kl(null,s);if(Rh(n),(s=ds)?(s=Ev(s,Ja),s=s!==null&&s.data==="&"?s:null,s!==null&&(n.memoizedState={dehydrated:s,treeContext:zr!==null?{id:zn,overflow:Rn}:null,retryLane:536870912,hydrationErrors:null},i=eb(s),i.return=n,n.child=i,sa=n,ds=null)):s=null,s===null)throw _r(n);return n.lanes=536870912,null}return Md(n,c)}var f=s.memoizedState;if(f!==null){var j=f.dehydrated;if(Rh(n),h)if(n.flags&256)n.flags&=-257,n=gy(s,n,i);else if(n.memoizedState!==null)n.child=s.child,n.flags|=128,n=null;else throw Error(o(558));else if(Ls||bo(s,n,i,!1),h=(i&s.childLanes)!==0,Ls||h){if(c=rs,c!==null&&(j=V(c,i),j!==0&&j!==f.retryLane))throw f.retryLane=j,Ai(s,j),Ta(c,s,j),Qh;Yd(),n=gy(s,n,i)}else s=f.treeContext,ds=Qa(j.nextSibling),sa=n,At=!0,Rr=null,Ja=!1,s!==null&&ab(n,s),n=Md(n,c),n.flags|=4096;return n}return s=Xn(s.child,{mode:c.mode,children:c.children}),s.ref=n.ref,n.child=s,s.return=n,s}function Ud(s,n){var i=n.ref;if(i===null)s!==null&&s.ref!==null&&(n.flags|=4194816);else{if(typeof i!="function"&&typeof i!="object")throw Error(o(284));(s===null||s.ref!==i)&&(n.flags|=4194816)}}function ep(s,n,i,c,h){return Ri(n),i=Lh(s,n,i,c,void 0,h),c=Dh(),s!==null&&!Ls?(Oh(s,n,h),nr(s,n,h)):(At&&c&&fh(n),n.flags|=1,na(s,n,i,h),n.child)}function by(s,n,i,c,h,f){return Ri(n),n.updateQueue=null,i=jb(n,c,i,h),vb(s),c=Dh(),s!==null&&!Ls?(Oh(s,n,f),nr(s,n,f)):(At&&c&&fh(n),n.flags|=1,na(s,n,i,f),n.child)}function yy(s,n,i,c,h){if(Ri(n),n.stateNode===null){var f=po,j=i.contextType;typeof j=="object"&&j!==null&&(f=aa(j)),f=new i(c,f),n.memoizedState=f.state!==null&&f.state!==void 0?f.state:null,f.updater=Jh,n.stateNode=f,f._reactInternals=n,f=n.stateNode,f.props=c,f.state=n.memoizedState,f.refs={},kh(n),j=i.contextType,f.context=typeof j=="object"&&j!==null?aa(j):po,f.state=n.memoizedState,j=i.getDerivedStateFromProps,typeof j=="function"&&(Zh(n,i,j,c),f.state=n.memoizedState),typeof i.getDerivedStateFromProps=="function"||typeof f.getSnapshotBeforeUpdate=="function"||typeof f.UNSAFE_componentWillMount!="function"&&typeof f.componentWillMount!="function"||(j=f.state,typeof f.componentWillMount=="function"&&f.componentWillMount(),typeof f.UNSAFE_componentWillMount=="function"&&f.UNSAFE_componentWillMount(),j!==f.state&&Jh.enqueueReplaceState(f,f.state,null),Dl(n,c,f,h),Ll(),f.state=n.memoizedState),typeof f.componentDidMount=="function"&&(n.flags|=4194308),c=!0}else if(s===null){f=n.stateNode;var R=n.memoizedProps,F=Ui(i,R);f.props=F;var ne=f.context,ce=i.contextType;j=po,typeof ce=="object"&&ce!==null&&(j=aa(ce));var pe=i.getDerivedStateFromProps;ce=typeof pe=="function"||typeof f.getSnapshotBeforeUpdate=="function",R=n.pendingProps!==R,ce||typeof f.UNSAFE_componentWillReceiveProps!="function"&&typeof f.componentWillReceiveProps!="function"||(R||ne!==j)&&ry(n,f,c,j),Dr=!1;var ie=n.memoizedState;f.state=ie,Dl(n,c,f,h),Ll(),ne=n.memoizedState,R||ie!==ne||Dr?(typeof pe=="function"&&(Zh(n,i,pe,c),ne=n.memoizedState),(F=Dr||ny(n,i,F,c,ie,ne,j))?(ce||typeof f.UNSAFE_componentWillMount!="function"&&typeof f.componentWillMount!="function"||(typeof f.componentWillMount=="function"&&f.componentWillMount(),typeof f.UNSAFE_componentWillMount=="function"&&f.UNSAFE_componentWillMount()),typeof f.componentDidMount=="function"&&(n.flags|=4194308)):(typeof f.componentDidMount=="function"&&(n.flags|=4194308),n.memoizedProps=c,n.memoizedState=ne),f.props=c,f.state=ne,f.context=j,c=F):(typeof f.componentDidMount=="function"&&(n.flags|=4194308),c=!1)}else{f=n.stateNode,Th(s,n),j=n.memoizedProps,ce=Ui(i,j),f.props=ce,pe=n.pendingProps,ie=f.context,ne=i.contextType,F=po,typeof ne=="object"&&ne!==null&&(F=aa(ne)),R=i.getDerivedStateFromProps,(ne=typeof R=="function"||typeof f.getSnapshotBeforeUpdate=="function")||typeof f.UNSAFE_componentWillReceiveProps!="function"&&typeof f.componentWillReceiveProps!="function"||(j!==pe||ie!==F)&&ry(n,f,c,F),Dr=!1,ie=n.memoizedState,f.state=ie,Dl(n,c,f,h),Ll();var oe=n.memoizedState;j!==pe||ie!==oe||Dr||s!==null&&s.dependencies!==null&&yd(s.dependencies)?(typeof R=="function"&&(Zh(n,i,R,c),oe=n.memoizedState),(ce=Dr||ny(n,i,ce,c,ie,oe,F)||s!==null&&s.dependencies!==null&&yd(s.dependencies))?(ne||typeof f.UNSAFE_componentWillUpdate!="function"&&typeof f.componentWillUpdate!="function"||(typeof f.componentWillUpdate=="function"&&f.componentWillUpdate(c,oe,F),typeof f.UNSAFE_componentWillUpdate=="function"&&f.UNSAFE_componentWillUpdate(c,oe,F)),typeof f.componentDidUpdate=="function"&&(n.flags|=4),typeof f.getSnapshotBeforeUpdate=="function"&&(n.flags|=1024)):(typeof f.componentDidUpdate!="function"||j===s.memoizedProps&&ie===s.memoizedState||(n.flags|=4),typeof f.getSnapshotBeforeUpdate!="function"||j===s.memoizedProps&&ie===s.memoizedState||(n.flags|=1024),n.memoizedProps=c,n.memoizedState=oe),f.props=c,f.state=oe,f.context=F,c=ce):(typeof f.componentDidUpdate!="function"||j===s.memoizedProps&&ie===s.memoizedState||(n.flags|=4),typeof f.getSnapshotBeforeUpdate!="function"||j===s.memoizedProps&&ie===s.memoizedState||(n.flags|=1024),c=!1)}return f=c,Ud(s,n),c=(n.flags&128)!==0,f||c?(f=n.stateNode,i=c&&typeof i.getDerivedStateFromError!="function"?null:f.render(),n.flags|=1,s!==null&&c?(n.child=Oi(n,s.child,null,h),n.child=Oi(n,null,i,h)):na(s,n,i,h),n.memoizedState=f.state,s=n.child):s=nr(s,n,h),s}function vy(s,n,i,c){return Hi(),n.flags|=256,na(s,n,i,c),n.child}var tp={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function sp(s){return{baseLanes:s,cachePool:cb()}}function ap(s,n,i){return s=s!==null?s.childLanes&~i:0,n&&(s|=Ka),s}function jy(s,n,i){var c=n.pendingProps,h=!1,f=(n.flags&128)!==0,j;if((j=f)||(j=s!==null&&s.memoizedState===null?!1:(As.current&2)!==0),j&&(h=!0,n.flags&=-129),j=(n.flags&32)!==0,n.flags&=-33,s===null){if(At){if(h?Ur(n):Pr(),(s=ds)?(s=Ev(s,Ja),s=s!==null&&s.data!=="&"?s:null,s!==null&&(n.memoizedState={dehydrated:s,treeContext:zr!==null?{id:zn,overflow:Rn}:null,retryLane:536870912,hydrationErrors:null},i=eb(s),i.return=n,n.child=i,sa=n,ds=null)):s=null,s===null)throw _r(n);return Pp(s)?n.lanes=32:n.lanes=536870912,null}var R=c.children;return c=c.fallback,h?(Pr(),h=n.mode,R=Pd({mode:"hidden",children:R},h),c=Ei(c,h,i,null),R.return=n,c.return=n,R.sibling=c,n.child=R,c=n.child,c.memoizedState=sp(i),c.childLanes=ap(s,j,i),n.memoizedState=tp,Kl(null,c)):(Ur(n),np(n,R))}var F=s.memoizedState;if(F!==null&&(R=F.dehydrated,R!==null)){if(f)n.flags&256?(Ur(n),n.flags&=-257,n=rp(s,n,i)):n.memoizedState!==null?(Pr(),n.child=s.child,n.flags|=128,n=null):(Pr(),R=c.fallback,h=n.mode,c=Pd({mode:"visible",children:c.children},h),R=Ei(R,h,i,null),R.flags|=2,c.return=n,R.return=n,c.sibling=R,n.child=c,Oi(n,s.child,null,i),c=n.child,c.memoizedState=sp(i),c.childLanes=ap(s,j,i),n.memoizedState=tp,n=Kl(null,c));else if(Ur(n),Pp(R)){if(j=R.nextSibling&&R.nextSibling.dataset,j)var ne=j.dgst;j=ne,c=Error(o(419)),c.stack="",c.digest=j,Al({value:c,source:null,stack:null}),n=rp(s,n,i)}else if(Ls||bo(s,n,i,!1),j=(i&s.childLanes)!==0,Ls||j){if(j=rs,j!==null&&(c=V(j,i),c!==0&&c!==F.retryLane))throw F.retryLane=c,Ai(s,c),Ta(j,s,c),Qh;Up(R)||Yd(),n=rp(s,n,i)}else Up(R)?(n.flags|=192,n.child=s.child,n=null):(s=F.treeContext,ds=Qa(R.nextSibling),sa=n,At=!0,Rr=null,Ja=!1,s!==null&&ab(n,s),n=np(n,c.children),n.flags|=4096);return n}return h?(Pr(),R=c.fallback,h=n.mode,F=s.child,ne=F.sibling,c=Xn(F,{mode:"hidden",children:c.children}),c.subtreeFlags=F.subtreeFlags&65011712,ne!==null?R=Xn(ne,R):(R=Ei(R,h,i,null),R.flags|=2),R.return=n,c.return=n,c.sibling=R,n.child=c,Kl(null,c),c=n.child,R=s.child.memoizedState,R===null?R=sp(i):(h=R.cachePool,h!==null?(F=Rs._currentValue,h=h.parent!==F?{parent:F,pool:F}:h):h=cb(),R={baseLanes:R.baseLanes|i,cachePool:h}),c.memoizedState=R,c.childLanes=ap(s,j,i),n.memoizedState=tp,Kl(s.child,c)):(Ur(n),i=s.child,s=i.sibling,i=Xn(i,{mode:"visible",children:c.children}),i.return=n,i.sibling=null,s!==null&&(j=n.deletions,j===null?(n.deletions=[s],n.flags|=16):j.push(s)),n.child=i,n.memoizedState=null,i)}function np(s,n){return n=Pd({mode:"visible",children:n},s.mode),n.return=s,s.child=n}function Pd(s,n){return s=Oa(22,s,null,n),s.lanes=0,s}function rp(s,n,i){return Oi(n,s.child,null,i),s=np(n,n.pendingProps.children),s.flags|=2,n.memoizedState=null,s}function wy(s,n,i){s.lanes|=n;var c=s.alternate;c!==null&&(c.lanes|=n),vh(s.return,n,i)}function ip(s,n,i,c,h,f){var j=s.memoizedState;j===null?s.memoizedState={isBackwards:n,rendering:null,renderingStartTime:0,last:c,tail:i,tailMode:h,treeForkCount:f}:(j.isBackwards=n,j.rendering=null,j.renderingStartTime=0,j.last=c,j.tail=i,j.tailMode=h,j.treeForkCount=f)}function Ny(s,n,i){var c=n.pendingProps,h=c.revealOrder,f=c.tail;c=c.children;var j=As.current,R=(j&2)!==0;if(R?(j=j&1|2,n.flags|=128):j&=1,Se(As,j),na(s,n,c,i),c=At?Tl:0,!R&&s!==null&&(s.flags&128)!==0)e:for(s=n.child;s!==null;){if(s.tag===13)s.memoizedState!==null&&wy(s,i,n);else if(s.tag===19)wy(s,i,n);else if(s.child!==null){s.child.return=s,s=s.child;continue}if(s===n)break e;for(;s.sibling===null;){if(s.return===null||s.return===n)break e;s=s.return}s.sibling.return=s.return,s=s.sibling}switch(h){case"forwards":for(i=n.child,h=null;i!==null;)s=i.alternate,s!==null&&Td(s)===null&&(h=i),i=i.sibling;i=h,i===null?(h=n.child,n.child=null):(h=i.sibling,i.sibling=null),ip(n,!1,h,i,f,c);break;case"backwards":case"unstable_legacy-backwards":for(i=null,h=n.child,n.child=null;h!==null;){if(s=h.alternate,s!==null&&Td(s)===null){n.child=h;break}s=h.sibling,h.sibling=i,i=h,h=s}ip(n,!0,i,null,f,c);break;case"together":ip(n,!1,null,null,void 0,c);break;default:n.memoizedState=null}return n.child}function nr(s,n,i){if(s!==null&&(n.dependencies=s.dependencies),Br|=n.lanes,(i&n.childLanes)===0)if(s!==null){if(bo(s,n,i,!1),(i&n.childLanes)===0)return null}else return null;if(s!==null&&n.child!==s.child)throw Error(o(153));if(n.child!==null){for(s=n.child,i=Xn(s,s.pendingProps),n.child=i,i.return=n;s.sibling!==null;)s=s.sibling,i=i.sibling=Xn(s,s.pendingProps),i.return=n;i.sibling=null}return n.child}function op(s,n){return(s.lanes&n)!==0?!0:(s=s.dependencies,!!(s!==null&&yd(s)))}function hS(s,n,i){switch(n.tag){case 3:te(n,n.stateNode.containerInfo),Lr(n,Rs,s.memoizedState.cache),Hi();break;case 27:case 5:Le(n);break;case 4:te(n,n.stateNode.containerInfo);break;case 10:Lr(n,n.type,n.memoizedProps.value);break;case 31:if(n.memoizedState!==null)return n.flags|=128,Rh(n),null;break;case 13:var c=n.memoizedState;if(c!==null)return c.dehydrated!==null?(Ur(n),n.flags|=128,null):(i&n.child.childLanes)!==0?jy(s,n,i):(Ur(n),s=nr(s,n,i),s!==null?s.sibling:null);Ur(n);break;case 19:var h=(s.flags&128)!==0;if(c=(i&n.childLanes)!==0,c||(bo(s,n,i,!1),c=(i&n.childLanes)!==0),h){if(c)return Ny(s,n,i);n.flags|=128}if(h=n.memoizedState,h!==null&&(h.rendering=null,h.tail=null,h.lastEffect=null),Se(As,As.current),c)break;return null;case 22:return n.lanes=0,fy(s,n,i,n.pendingProps);case 24:Lr(n,Rs,s.memoizedState.cache)}return nr(s,n,i)}function Sy(s,n,i){if(s!==null)if(s.memoizedProps!==n.pendingProps)Ls=!0;else{if(!op(s,i)&&(n.flags&128)===0)return Ls=!1,hS(s,n,i);Ls=(s.flags&131072)!==0}else Ls=!1,At&&(n.flags&1048576)!==0&&sb(n,Tl,n.index);switch(n.lanes=0,n.tag){case 16:e:{var c=n.pendingProps;if(s=Li(n.elementType),n.type=s,typeof s=="function")mh(s)?(c=Ui(s,c),n.tag=1,n=yy(null,n,s,c,i)):(n.tag=0,n=ep(null,n,s,c,i));else{if(s!=null){var h=s.$$typeof;if(h===P){n.tag=11,n=my(null,n,s,c,i);break e}else if(h===q){n.tag=14,n=hy(null,n,s,c,i);break e}}throw n=W(s)||s,Error(o(306,n,""))}}return n;case 0:return ep(s,n,n.type,n.pendingProps,i);case 1:return c=n.type,h=Ui(c,n.pendingProps),yy(s,n,c,h,i);case 3:e:{if(te(n,n.stateNode.containerInfo),s===null)throw Error(o(387));c=n.pendingProps;var f=n.memoizedState;h=f.element,Th(s,n),Dl(n,c,null,i);var j=n.memoizedState;if(c=j.cache,Lr(n,Rs,c),c!==f.cache&&jh(n,[Rs],i,!0),Ll(),c=j.element,f.isDehydrated)if(f={element:c,isDehydrated:!1,cache:j.cache},n.updateQueue.baseState=f,n.memoizedState=f,n.flags&256){n=vy(s,n,c,i);break e}else if(c!==h){h=Ya(Error(o(424)),n),Al(h),n=vy(s,n,c,i);break e}else{switch(s=n.stateNode.containerInfo,s.nodeType){case 9:s=s.body;break;default:s=s.nodeName==="HTML"?s.ownerDocument.body:s}for(ds=Qa(s.firstChild),sa=n,At=!0,Rr=null,Ja=!0,i=fb(n,null,c,i),n.child=i;i;)i.flags=i.flags&-3|4096,i=i.sibling}else{if(Hi(),c===h){n=nr(s,n,i);break e}na(s,n,c,i)}n=n.child}return n;case 26:return Ud(s,n),s===null?(i=Dv(n.type,null,n.pendingProps,null))?n.memoizedState=i:At||(i=n.type,s=n.pendingProps,c=tu(We.current).createElement(i),c[Ee]=n,c[He]=s,ra(c,i,s),bt(c),n.stateNode=c):n.memoizedState=Dv(n.type,s.memoizedProps,n.pendingProps,s.memoizedState),null;case 27:return Le(n),s===null&&At&&(c=n.stateNode=Rv(n.type,n.pendingProps,We.current),sa=n,Ja=!0,h=ds,qr(n.type)?(Kp=h,ds=Qa(c.firstChild)):ds=h),na(s,n,n.pendingProps.children,i),Ud(s,n),s===null&&(n.flags|=4194304),n.child;case 5:return s===null&&At&&((h=c=ds)&&(c=$S(c,n.type,n.pendingProps,Ja),c!==null?(n.stateNode=c,sa=n,ds=Qa(c.firstChild),Ja=!1,h=!0):h=!1),h||_r(n)),Le(n),h=n.type,f=n.pendingProps,j=s!==null?s.memoizedProps:null,c=f.children,Dp(h,f)?c=null:j!==null&&Dp(h,j)&&(n.flags|=32),n.memoizedState!==null&&(h=Lh(s,n,nS,null,null,i),tc._currentValue=h),Ud(s,n),na(s,n,c,i),n.child;case 6:return s===null&&At&&((s=i=ds)&&(i=VS(i,n.pendingProps,Ja),i!==null?(n.stateNode=i,sa=n,ds=null,s=!0):s=!1),s||_r(n)),null;case 13:return jy(s,n,i);case 4:return te(n,n.stateNode.containerInfo),c=n.pendingProps,s===null?n.child=Oi(n,null,c,i):na(s,n,c,i),n.child;case 11:return my(s,n,n.type,n.pendingProps,i);case 7:return na(s,n,n.pendingProps,i),n.child;case 8:return na(s,n,n.pendingProps.children,i),n.child;case 12:return na(s,n,n.pendingProps.children,i),n.child;case 10:return c=n.pendingProps,Lr(n,n.type,c.value),na(s,n,c.children,i),n.child;case 9:return h=n.type._context,c=n.pendingProps.children,Ri(n),h=aa(h),c=c(h),n.flags|=1,na(s,n,c,i),n.child;case 14:return hy(s,n,n.type,n.pendingProps,i);case 15:return py(s,n,n.type,n.pendingProps,i);case 19:return Ny(s,n,i);case 31:return mS(s,n,i);case 22:return fy(s,n,i,n.pendingProps);case 24:return Ri(n),c=aa(Rs),s===null?(h=Sh(),h===null&&(h=rs,f=wh(),h.pooledCache=f,f.refCount++,f!==null&&(h.pooledCacheLanes|=i),h=f),n.memoizedState={parent:c,cache:h},kh(n),Lr(n,Rs,h)):((s.lanes&i)!==0&&(Th(s,n),Dl(n,null,null,i),Ll()),h=s.memoizedState,f=n.memoizedState,h.parent!==c?(h={parent:c,cache:c},n.memoizedState=h,n.lanes===0&&(n.memoizedState=n.updateQueue.baseState=h),Lr(n,Rs,c)):(c=f.cache,Lr(n,Rs,c),c!==h.cache&&jh(n,[Rs],i,!0))),na(s,n,n.pendingProps.children,i),n.child;case 29:throw n.pendingProps}throw Error(o(156,n.tag))}function rr(s){s.flags|=4}function lp(s,n,i,c,h){if((n=(s.mode&32)!==0)&&(n=!1),n){if(s.flags|=16777216,(h&335544128)===h)if(s.stateNode.complete)s.flags|=8192;else if(Jy())s.flags|=8192;else throw Di=Nd,Ch}else s.flags&=-16777217}function Cy(s,n){if(n.type!=="stylesheet"||(n.state.loading&4)!==0)s.flags&=-16777217;else if(s.flags|=16777216,!Kv(n))if(Jy())s.flags|=8192;else throw Di=Nd,Ch}function Kd(s,n){n!==null&&(s.flags|=4),s.flags&16384&&(n=s.tag!==22?Qs():536870912,s.lanes|=n,Ho|=n)}function Il(s,n){if(!At)switch(s.tailMode){case"hidden":n=s.tail;for(var i=null;n!==null;)n.alternate!==null&&(i=n),n=n.sibling;i===null?s.tail=null:i.sibling=null;break;case"collapsed":i=s.tail;for(var c=null;i!==null;)i.alternate!==null&&(c=i),i=i.sibling;c===null?n||s.tail===null?s.tail=null:s.tail.sibling=null:c.sibling=null}}function us(s){var n=s.alternate!==null&&s.alternate.child===s.child,i=0,c=0;if(n)for(var h=s.child;h!==null;)i|=h.lanes|h.childLanes,c|=h.subtreeFlags&65011712,c|=h.flags&65011712,h.return=s,h=h.sibling;else for(h=s.child;h!==null;)i|=h.lanes|h.childLanes,c|=h.subtreeFlags,c|=h.flags,h.return=s,h=h.sibling;return s.subtreeFlags|=c,s.childLanes=i,n}function pS(s,n,i){var c=n.pendingProps;switch(xh(n),n.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return us(n),null;case 1:return us(n),null;case 3:return i=n.stateNode,c=null,s!==null&&(c=s.memoizedState.cache),n.memoizedState.cache!==c&&(n.flags|=2048),tr(Rs),me(),i.pendingContext&&(i.context=i.pendingContext,i.pendingContext=null),(s===null||s.child===null)&&(go(n)?rr(n):s===null||s.memoizedState.isDehydrated&&(n.flags&256)===0||(n.flags|=1024,bh())),us(n),null;case 26:var h=n.type,f=n.memoizedState;return s===null?(rr(n),f!==null?(us(n),Cy(n,f)):(us(n),lp(n,h,null,c,i))):f?f!==s.memoizedState?(rr(n),us(n),Cy(n,f)):(us(n),n.flags&=-16777217):(s=s.memoizedProps,s!==c&&rr(n),us(n),lp(n,h,s,c,i)),null;case 27:if(Ie(n),i=We.current,h=n.type,s!==null&&n.stateNode!=null)s.memoizedProps!==c&&rr(n);else{if(!c){if(n.stateNode===null)throw Error(o(166));return us(n),null}s=Me.current,go(n)?nb(n):(s=Rv(h,c,i),n.stateNode=s,rr(n))}return us(n),null;case 5:if(Ie(n),h=n.type,s!==null&&n.stateNode!=null)s.memoizedProps!==c&&rr(n);else{if(!c){if(n.stateNode===null)throw Error(o(166));return us(n),null}if(f=Me.current,go(n))nb(n);else{var j=tu(We.current);switch(f){case 1:f=j.createElementNS("http://www.w3.org/2000/svg",h);break;case 2:f=j.createElementNS("http://www.w3.org/1998/Math/MathML",h);break;default:switch(h){case"svg":f=j.createElementNS("http://www.w3.org/2000/svg",h);break;case"math":f=j.createElementNS("http://www.w3.org/1998/Math/MathML",h);break;case"script":f=j.createElement("div"),f.innerHTML="<script><\/script>
25",f=f.removeChild(f.firstChild);break;case"select":f=typeof c.is=="string"?j.createElement("select",{is:c.is}):j.createElement("select"),c.multiple?f.multiple=!0:c.size&&(f.size=c.size);break;default:f=typeof c.is=="string"?j.createElement(h,{is:c.is}):j.createElement(h)}}f[Ee]=n,f[He]=c;e:for(j=n.child;j!==null;){if(j.tag===5||j.tag===6)f.appendChild(j.stateNode);else if(j.tag!==4&&j.tag!==27&&j.child!==null){j.child.return=j,j=j.child;continue}if(j===n)break e;for(;j.sibling===null;){if(j.return===null||j.return===n)break e;j=j.return}j.sibling.return=j.return,j=j.sibling}n.stateNode=f;e:switch(ra(f,h,c),h){case"button":case"input":case"select":case"textarea":c=!!c.autoFocus;break e;case"img":c=!0;break e;default:c=!1}c&&rr(n)}}return us(n),lp(n,n.type,s===null?null:s.memoizedProps,n.pendingProps,i),null;case 6:if(s&&n.stateNode!=null)s.memoizedProps!==c&&rr(n);else{if(typeof c!="string"&&n.stateNode===null)throw Error(o(166));if(s=We.current,go(n)){if(s=n.stateNode,i=n.memoizedProps,c=null,h=sa,h!==null)switch(h.tag){case 27:case 5:c=h.memoizedProps}s[Ee]=n,s=!!(s.nodeValue===i||c!==null&&c.suppressHydrationWarning===!0||jv(s.nodeValue,i)),s||_r(n,!0)}else s=tu(s).createTextNode(c),s[Ee]=n,n.stateNode=s}return us(n),null;case 31:if(i=n.memoizedState,s===null||s.memoizedState!==null){if(c=go(n),i!==null){if(s===null){if(!c)throw Error(o(318));if(s=n.memoizedState,s=s!==null?s.dehydrated:null,!s)throw Error(o(557));s[Ee]=n}else Hi(),(n.flags&128)===0&&(n.memoizedState=null),n.flags|=4;us(n),s=!1}else i=bh(),s!==null&&s.memoizedState!==null&&(s.memoizedState.hydrationErrors=i),s=!0;if(!s)return n.flags&256?(Ua(n),n):(Ua(n),null);if((n.flags&128)!==0)throw Error(o(558))}return us(n),null;case 13:if(c=n.memoizedState,s===null||s.memoizedState!==null&&s.memoizedState.dehydrated!==null){if(h=go(n),c!==null&&c.dehydrated!==null){if(s===null){if(!h)throw Error(o(318));if(h=n.memoizedState,h=h!==null?h.dehydrated:null,!h)throw Error(o(317));h[Ee]=n}else Hi(),(n.flags&128)===0&&(n.memoizedState=null),n.flags|=4;us(n),h=!1}else h=bh(),s!==null&&s.memoizedState!==null&&(s.memoizedState.hydrationErrors=h),h=!0;if(!h)return n.flags&256?(Ua(n),n):(Ua(n),null)}return Ua(n),(n.flags&128)!==0?(n.lanes=i,n):(i=c!==null,s=s!==null&&s.memoizedState!==null,i&&(c=n.child,h=null,c.alternate!==null&&c.alternate.memoizedState!==null&&c.alternate.memoizedState.cachePool!==null&&(h=c.alternate.memoizedState.cachePool.pool),f=null,c.memoizedState!==null&&c.memoizedState.cachePool!==null&&(f=c.memoizedState.cachePool.pool),f!==h&&(c.flags|=2048)),i!==s&&i&&(n.child.flags|=8192),Kd(n,n.updateQueue),us(n),null);case 4:return me(),s===null&&Hp(n.stateNode.containerInfo),us(n),null;case 10:return tr(n.type),us(n),null;case 19:if(ge(As),c=n.memoizedState,c===null)return us(n),null;if(h=(n.flags&128)!==0,f=c.rendering,f===null)if(h)Il(c,!1);else{if(Ss!==0||s!==null&&(s.flags&128)!==0)for(s=n.child;s!==null;){if(f=Td(s),f!==null){for(n.flags|=128,Il(c,!1),s=f.updateQueue,n.updateQueue=s,Kd(n,s),n.subtreeFlags=0,s=i,i=n.child;i!==null;)Qg(i,s),i=i.sibling;return Se(As,As.current&1|2),At&&Qn(n,c.treeForkCount),n.child}s=s.sibling}c.tail!==null&&Mt()>Fd&&(n.flags|=128,h=!0,Il(c,!1),n.lanes=4194304)}else{if(!h)if(s=Td(f),s!==null){if(n.flags|=128,h=!0,s=s.updateQueue,n.updateQueue=s,Kd(n,s),Il(c,!0),c.tail===null&&c.tailMode==="hidden"&&!f.alternate&&!At)return us(n),null}else 2*Mt()-c.renderingStartTime>Fd&&i!==536870912&&(n.flags|=128,h=!0,Il(c,!1),n.lanes=4194304);c.isBackwards?(f.sibling=n.child,n.child=f):(s=c.last,s!==null?s.sibling=f:n.child=f,c.last=f)}return c.tail!==null?(s=c.tail,c.rendering=s,c.tail=s.sibling,c.renderingStartTime=Mt(),s.sibling=null,i=As.current,Se(As,h?i&1|2:i&1),At&&Qn(n,c.treeForkCount),s):(us(n),null);case 22:case 23:return Ua(n),zh(),c=n.memoizedState!==null,s!==null?s.memoizedState!==null!==c&&(n.flags|=8192):c&&(n.flags|=8192),c?(i&536870912)!==0&&(n.flags&128)===0&&(us(n),n.subtreeFlags&6&&(n.flags|=8192)):us(n),i=n.updateQueue,i!==null&&Kd(n,i.retryQueue),i=null,s!==null&&s.memoizedState!==null&&s.memoizedState.cachePool!==null&&(i=s.memoizedState.cachePool.pool),c=null,n.memoizedState!==null&&n.memoizedState.cachePool!==null&&(c=n.memoizedState.cachePool.pool),c!==i&&(n.flags|=2048),s!==null&&ge(_i),null;
vendor: 22,904 bytes, line 25
25case 24:return i=null,s!==null&&(i=s.memoizedState.cache),n.memoizedState.cache!==i&&(n.flags|=2048),tr(Rs),us(n),null;case 25:return null;case 30:return null}throw Error(o(156,n.tag))}function fS(s,n){switch(xh(n),n.tag){case 1:return s=n.flags,s&65536?(n.flags=s&-65537|128,n):null;case 3:return tr(Rs),me(),s=n.flags,(s&65536)!==0&&(s&128)===0?(n.flags=s&-65537|128,n):null;case 26:case 27:case 5:return Ie(n),null;case 31:if(n.memoizedState!==null){if(Ua(n),n.alternate===null)throw Error(o(340));Hi()}return s=n.flags,s&65536?(n.flags=s&-65537|128,n):null;case 13:if(Ua(n),s=n.memoizedState,s!==null&&s.dehydrated!==null){if(n.alternate===null)throw Error(o(340));Hi()}return s=n.flags,s&65536?(n.flags=s&-65537|128,n):null;case 19:return ge(As),null;case 4:return me(),null;case 10:return tr(n.type),null;case 22:case 23:return Ua(n),zh(),s!==null&&ge(_i),s=n.flags,s&65536?(n.flags=s&-65537|128,n):null;case 24:return tr(Rs),null;case 25:return null;default:return null}}function ky(s,n){switch(xh(n),n.tag){case 3:tr(Rs),me();break;case 26:case 27:case 5:Ie(n);break;case 4:me();break;case 31:n.memoizedState!==null&&Ua(n);break;case 13:Ua(n);break;case 19:ge(As);break;case 10:tr(n.type);break;case 22:case 23:Ua(n),zh(),s!==null&&ge(_i);break;case 24:tr(Rs)}}function Bl(s,n){try{var i=n.updateQueue,c=i!==null?i.lastEffect:null;if(c!==null){var h=c.next;i=h;do{if((i.tag&s)===s){c=void 0;var f=i.create,j=i.inst;c=f(),j.destroy=c}i=i.next}while(i!==h)}}catch(R){Qt(n,n.return,R)}}function Kr(s,n,i){try{var c=n.updateQueue,h=c!==null?c.lastEffect:null;if(h!==null){var f=h.next;c=f;do{if((c.tag&s)===s){var j=c.inst,R=j.destroy;if(R!==void 0){j.destroy=void 0,h=n;var F=i,ne=R;try{ne()}catch(ce){Qt(h,F,ce)}}}c=c.next}while(c!==f)}}catch(ce){Qt(n,n.return,ce)}}function Ty(s){var n=s.updateQueue;if(n!==null){var i=s.stateNode;try{gb(n,i)}catch(c){Qt(s,s.return,c)}}}function Ay(s,n,i){i.props=Ui(s.type,s.memoizedProps),i.state=s.memoizedState;try{i.componentWillUnmount()}catch(c){Qt(s,n,c)}}function $l(s,n){try{var i=s.ref;if(i!==null){switch(s.tag){case 26:case 27:case 5:var c=s.stateNode;break;case 30:c=s.stateNode;break;default:c=s.stateNode}typeof i=="function"?s.refCleanup=i(c):i.current=c}}catch(h){Qt(s,n,h)}}function _n(s,n){var i=s.ref,c=s.refCleanup;if(i!==null)if(typeof c=="function")try{c()}catch(h){Qt(s,n,h)}finally{s.refCleanup=null,s=s.alternate,s!=null&&(s.refCleanup=null)}else if(typeof i=="function")try{i(null)}catch(h){Qt(s,n,h)}else i.current=null}function Ey(s){var n=s.type,i=s.memoizedProps,c=s.stateNode;try{e:switch(n){case"button":case"input":case"select":case"textarea":i.autoFocus&&c.focus();break e;case"img":i.src?c.src=i.src:i.srcSet&&(c.srcset=i.srcSet)}}catch(h){Qt(s,s.return,h)}}function cp(s,n,i){try{var c=s.stateNode;MS(c,s.type,i,n),c[He]=n}catch(h){Qt(s,s.return,h)}}function Hy(s){return s.tag===5||s.tag===3||s.tag===26||s.tag===27&&qr(s.type)||s.tag===4}function dp(s){e:for(;;){for(;s.sibling===null;){if(s.return===null||Hy(s.return))return null;s=s.return}for(s.sibling.return=s.return,s=s.sibling;s.tag!==5&&s.tag!==6&&s.tag!==18;){if(s.tag===27&&qr(s.type)||s.flags&2||s.child===null||s.tag===4)continue e;s.child.return=s,s=s.child}if(!(s.flags&2))return s.stateNode}}function up(s,n,i){var c=s.tag;if(c===5||c===6)s=s.stateNode,n?(i.nodeType===9?i.body:i.nodeName==="HTML"?i.ownerDocument.body:i).insertBefore(s,n):(n=i.nodeType===9?i.body:i.nodeName==="HTML"?i.ownerDocument.body:i,n.appendChild(s),i=i._reactRootContainer,i!=null||n.onclick!==null||(n.onclick=re));else if(c!==4&&(c===27&&qr(s.type)&&(i=s.stateNode,n=null),s=s.child,s!==null))for(up(s,n,i),s=s.sibling;s!==null;)up(s,n,i),s=s.sibling}function Id(s,n,i){var c=s.tag;if(c===5||c===6)s=s.stateNode,n?i.insertBefore(s,n):i.appendChild(s);else if(c!==4&&(c===27&&qr(s.type)&&(i=s.stateNode),s=s.child,s!==null))for(Id(s,n,i),s=s.sibling;s!==null;)Id(s,n,i),s=s.sibling}function zy(s){var n=s.stateNode,i=s.memoizedProps;try{for(var c=s.type,h=n.attributes;h.length;)n.removeAttributeNode(h[0]);ra(n,c,i),n[Ee]=s,n[He]=i}catch(f){Qt(s,s.return,f)}}var ir=!1,Ds=!1,mp=!1,Ry=typeof WeakSet=="function"?WeakSet:Set,Gs=null;function xS(s,n){if(s=s.containerInfo,_p=lu,s=Vg(s),rh(s)){if("selectionStart"in s)var i={start:s.selectionStart,end:s.selectionEnd};else e:{i=(i=s.ownerDocument)&&i.defaultView||window;var c=i.getSelection&&i.getSelection();if(c&&c.rangeCount!==0){i=c.anchorNode;var h=c.anchorOffset,f=c.focusNode;c=c.focusOffset;try{i.nodeType,f.nodeType}catch{i=null;break e}var j=0,R=-1,F=-1,ne=0,ce=0,pe=s,ie=null;t:for(;;){for(var oe;pe!==i||h!==0&&pe.nodeType!==3||(R=j+h),pe!==f||c!==0&&pe.nodeType!==3||(F=j+c),pe.nodeType===3&&(j+=pe.nodeValue.length),(oe=pe.firstChild)!==null;)ie=pe,pe=oe;for(;;){if(pe===s)break t;if(ie===i&&++ne===h&&(R=j),ie===f&&++ce===c&&(F=j),(oe=pe.nextSibling)!==null)break;pe=ie,ie=pe.parentNode}pe=oe}i=R===-1||F===-1?null:{start:R,end:F}}else i=null}i=i||{start:0,end:0}}else i=null;for(Lp={focusedElem:s,selectionRange:i},lu=!1,Gs=n;Gs!==null;)if(n=Gs,s=n.child,(n.subtreeFlags&1028)!==0&&s!==null)s.return=n,Gs=s;else for(;Gs!==null;){switch(n=Gs,f=n.alternate,s=n.flags,n.tag){case 0:if((s&4)!==0&&(s=n.updateQueue,s=s!==null?s.events:null,s!==null))for(i=0;i<s.length;i++)h=s[i],h.ref.impl=h.nextImpl;break;case 11:case 15:break;case 1:if((s&1024)!==0&&f!==null){s=void 0,i=n,h=f.memoizedProps,f=f.memoizedState,c=i.stateNode;try{var Oe=Ui(i.type,h);s=c.getSnapshotBeforeUpdate(Oe,f),c.__reactInternalSnapshotBeforeUpdate=s}catch(Je){Qt(i,i.return,Je)}}break;case 3:if((s&1024)!==0){if(s=n.stateNode.containerInfo,i=s.nodeType,i===9)Mp(s);else if(i===1)switch(s.nodeName){case"HEAD":case"HTML":case"BODY":Mp(s);break;default:s.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if((s&1024)!==0)throw Error(o(163))}if(s=n.sibling,s!==null){s.return=n.return,Gs=s;break}Gs=n.return}}function _y(s,n,i){var c=i.flags;switch(i.tag){case 0:case 11:case 15:lr(s,i),c&4&&Bl(5,i);break;case 1:if(lr(s,i),c&4)if(s=i.stateNode,n===null)try{s.componentDidMount()}catch(j){Qt(i,i.return,j)}else{var h=Ui(i.type,n.memoizedProps);n=n.memoizedState;try{s.componentDidUpdate(h,n,s.__reactInternalSnapshotBeforeUpdate)}catch(j){Qt(i,i.return,j)}}c&64&&Ty(i),c&512&&$l(i,i.return);break;case 3:if(lr(s,i),c&64&&(s=i.updateQueue,s!==null)){if(n=null,i.child!==null)switch(i.child.tag){case 27:case 5:n=i.child.stateNode;break;case 1:n=i.child.stateNode}try{gb(s,n)}catch(j){Qt(i,i.return,j)}}break;case 27:n===null&&c&4&&zy(i);case 26:case 5:lr(s,i),n===null&&c&4&&Ey(i),c&512&&$l(i,i.return);break;case 12:lr(s,i);break;case 31:lr(s,i),c&4&&Oy(s,i);break;case 13:lr(s,i),c&4&&My(s,i),c&64&&(s=i.memoizedState,s!==null&&(s=s.dehydrated,s!==null&&(i=CS.bind(null,i),FS(s,i))));break;case 22:if(c=i.memoizedState!==null||ir,!c){n=n!==null&&n.memoizedState!==null||Ds,h=ir;var f=Ds;ir=c,(Ds=n)&&!f?cr(s,i,(i.subtreeFlags&8772)!==0):lr(s,i),ir=h,Ds=f}break;case 30:break;default:lr(s,i)}}function Ly(s){var n=s.alternate;n!==null&&(s.alternate=null,Ly(n)),s.child=null,s.deletions=null,s.sibling=null,s.tag===5&&(n=s.stateNode,n!==null&&kt(n)),s.stateNode=null,s.return=null,s.dependencies=null,s.memoizedProps=null,s.memoizedState=null,s.pendingProps=null,s.stateNode=null,s.updateQueue=null}var hs=null,Na=!1;function or(s,n,i){for(i=i.child;i!==null;)Dy(s,n,i),i=i.sibling}function Dy(s,n,i){if(Xe&&typeof Xe.onCommitFiberUnmount=="function")try{Xe.onCommitFiberUnmount(et,i)}catch{}switch(i.tag){case 26:Ds||_n(i,n),or(s,n,i),i.memoizedState?i.memoizedState.count--:i.stateNode&&(i=i.stateNode,i.parentNode.removeChild(i));break;case 27:Ds||_n(i,n);var c=hs,h=Na;qr(i.type)&&(hs=i.stateNode,Na=!1),or(s,n,i),Xl(i.stateNode),hs=c,Na=h;break;case 5:Ds||_n(i,n);case 6:if(c=hs,h=Na,hs=null,or(s,n,i),hs=c,Na=h,hs!==null)if(Na)try{(hs.nodeType===9?hs.body:hs.nodeName==="HTML"?hs.ownerDocument.body:hs).removeChild(i.stateNode)}catch(f){Qt(i,n,f)}else try{hs.removeChild(i.stateNode)}catch(f){Qt(i,n,f)}break;case 18:hs!==null&&(Na?(s=hs,Tv(s.nodeType===9?s.body:s.nodeName==="HTML"?s.ownerDocument.body:s,i.stateNode),Uo(s)):Tv(hs,i.stateNode));break;case 4:c=hs,h=Na,hs=i.stateNode.containerInfo,Na=!0,or(s,n,i),hs=c,Na=h;break;case 0:case 11:case 14:case 15:Kr(2,i,n),Ds||Kr(4,i,n),or(s,n,i);break;case 1:Ds||(_n(i,n),c=i.stateNode,typeof c.componentWillUnmount=="function"&&Ay(i,n,c)),or(s,n,i);break;case 21:or(s,n,i);break;case 22:Ds=(c=Ds)||i.memoizedState!==null,or(s,n,i),Ds=c;break;default:or(s,n,i)}}function Oy(s,n){if(n.memoizedState===null&&(s=n.alternate,s!==null&&(s=s.memoizedState,s!==null))){s=s.dehydrated;try{Uo(s)}catch(i){Qt(n,n.return,i)}}}function My(s,n){if(n.memoizedState===null&&(s=n.alternate,s!==null&&(s=s.memoizedState,s!==null&&(s=s.dehydrated,s!==null))))try{Uo(s)}catch(i){Qt(n,n.return,i)}}function gS(s){switch(s.tag){case 31:case 13:case 19:var n=s.stateNode;return n===null&&(n=s.stateNode=new Ry),n;case 22:return s=s.stateNode,n=s._retryCache,n===null&&(n=s._retryCache=new Ry),n;default:throw Error(o(435,s.tag))}}function Bd(s,n){var i=gS(s);n.forEach(function(c){if(!i.has(c)){i.add(c);var h=kS.bind(null,s,c);c.then(h,h)}})}function Sa(s,n){var i=n.deletions;if(i!==null)for(var c=0;c<i.length;c++){var h=i[c],f=s,j=n,R=j;e:for(;R!==null;){switch(R.tag){case 27:if(qr(R.type)){hs=R.stateNode,Na=!1;break e}break;case 5:hs=R.stateNode,Na=!1;break e;case 3:case 4:hs=R.stateNode.containerInfo,Na=!0;break e}R=R.return}if(hs===null)throw Error(o(160));Dy(f,j,h),hs=null,Na=!1,f=h.alternate,f!==null&&(f.return=null),h.return=null}if(n.subtreeFlags&13886)for(n=n.child;n!==null;)Uy(n,s),n=n.sibling}var gn=null;function Uy(s,n){var i=s.alternate,c=s.flags;switch(s.tag){case 0:case 11:case 14:case 15:Sa(n,s),Ca(s),c&4&&(Kr(3,s,s.return),Bl(3,s),Kr(5,s,s.return));break;case 1:Sa(n,s),Ca(s),c&512&&(Ds||i===null||_n(i,i.return)),c&64&&ir&&(s=s.updateQueue,s!==null&&(c=s.callbacks,c!==null&&(i=s.shared.hiddenCallbacks,s.shared.hiddenCallbacks=i===null?c:i.concat(c))));break;case 26:var h=gn;if(Sa(n,s),Ca(s),c&512&&(Ds||i===null||_n(i,i.return)),c&4){var f=i!==null?i.memoizedState:null;if(c=s.memoizedState,i===null)if(c===null)if(s.stateNode===null){e:{c=s.type,i=s.memoizedProps,h=h.ownerDocument||h;t:switch(c){case"title":f=h.getElementsByTagName("title")[0],(!f||f[wt]||f[Ee]||f.namespaceURI==="http://www.w3.org/2000/svg"||f.hasAttribute("itemprop"))&&(f=h.createElement(c),h.head.insertBefore(f,h.querySelector("head > title"))),ra(f,c,i),f[Ee]=s,bt(f),c=f;break e;case"link":var j=Uv("link","href",h).get(c+(i.href||""));if(j){for(var R=0;R<j.length;R++)if(f=j[R],f.getAttribute("href")===(i.href==null||i.href===""?null:i.href)&&f.getAttribute("rel")===(i.rel==null?null:i.rel)&&f.getAttribute("title")===(i.title==null?null:i.title)&&f.getAttribute("crossorigin")===(i.crossOrigin==null?null:i.crossOrigin)){j.splice(R,1);break t}}f=h.createElement(c),ra(f,c,i),h.head.appendChild(f);break;case"meta":if(j=Uv("meta","content",h).get(c+(i.content||""))){for(R=0;R<j.length;R++)if(f=j[R],f.getAttribute("content")===(i.content==null?null:""+i.content)&&f.getAttribute("name")===(i.name==null?null:i.name)&&f.getAttribute("property")===(i.property==null?null:i.property)&&f.getAttribute("http-equiv")===(i.httpEquiv==null?null:i.httpEquiv)&&f.getAttribute("charset")===(i.charSet==null?null:i.charSet)){j.splice(R,1);break t}}f=h.createElement(c),ra(f,c,i),h.head.appendChild(f);break;default:throw Error(o(468,c))}f[Ee]=s,bt(f),c=f}s.stateNode=c}else Pv(h,s.type,s.stateNode);else s.stateNode=Mv(h,c,s.memoizedProps);else f!==c?(f===null?i.stateNode!==null&&(i=i.stateNode,i.parentNode.removeChild(i)):f.count--,c===null?Pv(h,s.type,s.stateNode):Mv(h,c,s.memoizedProps)):c===null&&s.stateNode!==null&&cp(s,s.memoizedProps,i.memoizedProps)}break;case 27:Sa(n,s),Ca(s),c&512&&(Ds||i===null||_n(i,i.return)),i!==null&&c&4&&cp(s,s.memoizedProps,i.memoizedProps);break;case 5:if(Sa(n,s),Ca(s),c&512&&(Ds||i===null||_n(i,i.return)),s.flags&32){h=s.stateNode;try{Er(h,"")}catch(Oe){Qt(s,s.return,Oe)}}c&4&&s.stateNode!=null&&(h=s.memoizedProps,cp(s,h,i!==null?i.memoizedProps:h)),c&1024&&(mp=!0);break;case 6:if(Sa(n,s),Ca(s),c&4){if(s.stateNode===null)throw Error(o(162));c=s.memoizedProps,i=s.stateNode;try{i.nodeValue=c}catch(Oe){Qt(s,s.return,Oe)}}break;case 3:if(nu=null,h=gn,gn=su(n.containerInfo),Sa(n,s),gn=h,Ca(s),c&4&&i!==null&&i.memoizedState.isDehydrated)try{Uo(n.containerInfo)}catch(Oe){Qt(s,s.return,Oe)}mp&&(mp=!1,Py(s));break;case 4:c=gn,gn=su(s.stateNode.containerInfo),Sa(n,s),Ca(s),gn=c;break;case 12:Sa(n,s),Ca(s);break;case 31:Sa(n,s),Ca(s),c&4&&(c=s.updateQueue,c!==null&&(s.updateQueue=null,Bd(s,c)));break;case 13:Sa(n,s),Ca(s),s.child.flags&8192&&s.memoizedState!==null!=(i!==null&&i.memoizedState!==null)&&(Vd=Mt()),c&4&&(c=s.updateQueue,c!==null&&(s.updateQueue=null,Bd(s,c)));break;case 22:h=s.memoizedState!==null;var F=i!==null&&i.memoizedState!==null,ne=ir,ce=Ds;if(ir=ne||h,Ds=ce||F,Sa(n,s),Ds=ce,ir=ne,Ca(s),c&8192)e:for(n=s.stateNode,n._visibility=h?n._visibility&-2:n._visibility|1,h&&(i===null||F||ir||Ds||Pi(s)),i=null,n=s;;){if(n.tag===5||n.tag===26){if(i===null){F=i=n;try{if(f=F.stateNode,h)j=f.style,typeof j.setProperty=="function"?j.setProperty("display","none","important"):j.display="none";else{R=F.stateNode;var pe=F.memoizedProps.style,ie=pe!=null&&pe.hasOwnProperty("display")?pe.display:null;R.style.display=ie==null||typeof ie=="boolean"?"":(""+ie).trim()}}catch(Oe){Qt(F,F.return,Oe)}}}else if(n.tag===6){if(i===null){F=n;try{F.stateNode.nodeValue=h?"":F.memoizedProps}catch(Oe){Qt(F,F.return,Oe)}}}else if(n.tag===18){if(i===null){F=n;try{var oe=F.stateNode;h?Av(oe,!0):Av(F.stateNode,!1)}catch(Oe){Qt(F,F.return,Oe)}}}else if((n.tag!==22&&n.tag!==23||n.memoizedState===null||n===s)&&n.child!==null){n.child.return=n,n=n.child;continue}if(n===s)break e;for(;n.sibling===null;){if(n.return===null||n.return===s)break e;i===n&&(i=null),n=n.return}i===n&&(i=null),n.sibling.return=n.return,n=n.sibling}c&4&&(c=s.updateQueue,c!==null&&(i=c.retryQueue,i!==null&&(c.retryQueue=null,Bd(s,i))));break;case 19:Sa(n,s),Ca(s),c&4&&(c=s.updateQueue,c!==null&&(s.updateQueue=null,Bd(s,c)));break;case 30:break;case 21:break;default:Sa(n,s),Ca(s)}}function Ca(s){var n=s.flags;if(n&2){try{for(var i,c=s.return;c!==null;){if(Hy(c)){i=c;break}c=c.return}if(i==null)throw Error(o(160));switch(i.tag){case 27:var h=i.stateNode,f=dp(s);Id(s,f,h);break;case 5:var j=i.stateNode;i.flags&32&&(Er(j,""),i.flags&=-33);var R=dp(s);Id(s,R,j);break;case 3:case 4:var F=i.stateNode.containerInfo,ne=dp(s);up(s,ne,F);break;default:throw Error(o(161))}}catch(ce){Qt(s,s.return,ce)}s.flags&=-3}n&4096&&(s.flags&=-4097)}function Py(s){if(s.subtreeFlags&1024)for(s=s.child;s!==null;){var n=s;Py(n),n.tag===5&&n.flags&1024&&n.stateNode.reset(),s=s.sibling}}function lr(s,n){if(n.subtreeFlags&8772)for(n=n.child;n!==null;)_y(s,n.alternate,n),n=n.sibling}function Pi(s){for(s=s.child;s!==null;){var n=s;switch(n.tag){case 0:case 11:case 14:case 15:Kr(4,n,n.return),Pi(n);break;case 1:_n(n,n.return);var i=n.stateNode;typeof i.componentWillUnmount=="function"&&Ay(n,n.return,i),Pi(n);break;case 27:Xl(n.stateNode);case 26:case 5:_n(n,n.return),Pi(n);break;case 22:n.memoizedState===null&&Pi(n);break;case 30:Pi(n);break;default:Pi(n)}s=s.sibling}}function cr(s,n,i){for(i=i&&(n.subtreeFlags&8772)!==0,n=n.child;n!==null;){var c=n.alternate,h=s,f=n,j=f.flags;switch(f.tag){case 0:case 11:case 15:cr(h,f,i),Bl(4,f);break;case 1:if(cr(h,f,i),c=f,h=c.stateNode,typeof h.componentDidMount=="function")try{h.componentDidMount()}catch(ne){Qt(c,c.return,ne)}if(c=f,h=c.updateQueue,h!==null){var R=c.stateNode;try{var F=h.shared.hiddenCallbacks;if(F!==null)for(h.shared.hiddenCallbacks=null,h=0;h<F.length;h++)xb(F[h],R)}catch(ne){Qt(c,c.return,ne)}}i&&j&64&&Ty(f),$l(f,f.return);break;case 27:zy(f);case 26:case 5:cr(h,f,i),i&&c===null&&j&4&&Ey(f),$l(f,f.return);break;case 12:cr(h,f,i);break;case 31:cr(h,f,i),i&&j&4&&Oy(h,f);break;case 13:cr(h,f,i),i&&j&4&&My(h,f);break;case 22:f.memoizedState===null&&cr(h,f,i),$l(f,f.return);break;case 30:break;default:cr(h,f,i)}n=n.sibling}}function hp(s,n){var i=null;s!==null&&s.memoizedState!==null&&s.memoizedState.cachePool!==null&&(i=s.memoizedState.cachePool.pool),s=null,n.memoizedState!==null&&n.memoizedState.cachePool!==null&&(s=n.memoizedState.cachePool.pool),s!==i&&(s!=null&&s.refCount++,i!=null&&El(i))}function pp(s,n){s=null,n.alternate!==null&&(s=n.alternate.memoizedState.cache),n=n.memoizedState.cache,n!==s&&(n.refCount++,s!=null&&El(s))}function bn(s,n,i,c){if(n.subtreeFlags&10256)for(n=n.child;n!==null;)Ky(s,n,i,c),n=n.sibling}function Ky(s,n,i,c){var h=n.flags;switch(n.tag){case 0:case 11:case 15:bn(s,n,i,c),h&2048&&Bl(9,n);break;case 1:bn(s,n,i,c);break;case 3:bn(s,n,i,c),h&2048&&(s=null,n.alternate!==null&&(s=n.alternate.memoizedState.cache),n=n.memoizedState.cache,n!==s&&(n.refCount++,s!=null&&El(s)));break;case 12:if(h&2048){bn(s,n,i,c),s=n.stateNode;try{var f=n.memoizedProps,j=f.id,R=f.onPostCommit;typeof R=="function"&&R(j,n.alternate===null?"mount":"update",s.passiveEffectDuration,-0)}catch(F){Qt(n,n.return,F)}}else bn(s,n,i,c);break;case 31:bn(s,n,i,c);break;case 13:bn(s,n,i,c);break;case 23:break;case 22:f=n.stateNode,j=n.alternate,n.memoizedState!==null?f._visibility&2?bn(s,n,i,c):Vl(s,n):f._visibility&2?bn(s,n,i,c):(f._visibility|=2,To(s,n,i,c,(n.subtreeFlags&10256)!==0||!1)),h&2048&&hp(j,n);break;case 24:bn(s,n,i,c),h&2048&&pp(n.alternate,n);break;default:bn(s,n,i,c)}}function To(s,n,i,c,h){for(h=h&&((n.subtreeFlags&10256)!==0||!1),n=n.child;n!==null;){var f=s,j=n,R=i,F=c,ne=j.flags;switch(j.tag){case 0:case 11:case 15:To(f,j,R,F,h),Bl(8,j);break;case 23:break;case 22:var ce=j.stateNode;j.memoizedState!==null?ce._visibility&2?To(f,j,R,F,h):Vl(f,j):(ce._visibility|=2,To(f,j,R,F,h)),h&&ne&2048&&hp(j.alternate,j);break;case 24:To(f,j,R,F,h),h&&ne&2048&&pp(j.alternate,j);break;default:To(f,j,R,F,h)}n=n.sibling}}function Vl(s,n){if(n.subtreeFlags&10256)for(n=n.child;n!==null;){var i=s,c=n,h=c.flags;switch(c.tag){case 22:Vl(i,c),h&2048&&hp(c.alternate,c);break;case 24:Vl(i,c),h&2048&&pp(c.alternate,c);break;default:Vl(i,c)}n=n.sibling}}var Fl=8192;function Ao(s,n,i){if(s.subtreeFlags&Fl)for(s=s.child;s!==null;)Iy(s,n,i),s=s.sibling}function Iy(s,n,i){switch(s.tag){case 26:Ao(s,n,i),s.flags&Fl&&s.memoizedState!==null&&a4(i,gn,s.memoizedState,s.memoizedProps);break;case 5:Ao(s,n,i);break;case 3:case 4:var c=gn;gn=su(s.stateNode.containerInfo),Ao(s,n,i),gn=c;break;case 22:s.memoizedState===null&&(c=s.alternate,c!==null&&c.memoizedState!==null?(c=Fl,Fl=16777216,Ao(s,n,i),Fl=c):Ao(s,n,i));break;default:Ao(s,n,i)}}function By(s){var n=s.alternate;if(n!==null&&(s=n.child,s!==null)){n.child=null;do n=s.sibling,s.sibling=null,s=n;while(s!==null)}}function Wl(s){var n=s.deletions;if((s.flags&16)!==0){if(n!==null)for(var i=0;i<n.length;i++){var c=n[i];Gs=c,Vy(c,s)}By(s)}if(s.subtreeFlags&10256)for(s=s.child;s!==null;)$y(s),s=s.sibling}function $y(s){switch(s.tag){case 0:case 11:case 15:Wl(s),s.flags&2048&&Kr(9,s,s.return);break;case 3:Wl(s);break;case 12:Wl(s);break;case 22:var n=s.stateNode;s.memoizedState!==null&&n._visibility&2&&(s.return===null||s.return.tag!==13)?(n._visibility&=-3,$d(s)):Wl(s);break;default:Wl(s)}}function $d(s){var n=s.deletions;if((s.flags&16)!==0){if(n!==null)for(var i=0;i<n.length;i++){var c=n[i];Gs=c,Vy(c,s)}By(s)}for(s=s.child;s!==null;){switch(n=s,n.tag){case 0:case 11:case 15:Kr(8,n,n.return),$d(n);break;case 22:i=n.stateNode,i._visibility&2&&(i._visibility&=-3,$d(n));break;default:$d(n)}s=s.sibling}}function Vy(s,n){for(;Gs!==null;){var i=Gs;switch(i.tag){case 0:case 11:case 15:Kr(8,i,n);break;case 23:case 22:if(i.memoizedState!==null&&i.memoizedState.cachePool!==null){var c=i.memoizedState.cachePool.pool;c!=null&&c.refCount++}break;case 24:El(i.memoizedState.cache)}if(c=i.child,c!==null)c.return=i,Gs=c;else e:for(i=s;Gs!==null;){c=Gs;var h=c.sibling,f=c.return;if(Ly(c),c===i){Gs=null;break e}if(h!==null){h.return=f,Gs=h;break e}Gs=f}}}var bS={getCacheForType:function(s){var n=aa(Rs),i=n.data.get(s);return i===void 0&&(i=s(),n.data.set(s,i)),i},cacheSignal:function(){return aa(Rs).controller.signal}},yS=typeof WeakMap=="function"?WeakMap:Map,$t=0,rs=null,yt=null,Nt=0,Xt=0,Pa=null,Ir=!1,Eo=!1,fp=!1,dr=0,Ss=0,Br=0,Ki=0,xp=0,Ka=0,Ho=0,ql=null,ka=null,gp=!1,Vd=0,Fy=0,Fd=1/0,Wd=null,$r=null,Bs=0,Vr=null,zo=null,ur=0,bp=0,yp=null,Wy=null,Yl=0,vp=null;function Ia(){return($t&2)!==0&&Nt!==0?Nt&-Nt:k.T!==null?kp():fe()}function qy(){if(Ka===0)if((Nt&536870912)===0||At){var s=ue;ue<<=1,(ue&3932160)===0&&(ue=262144),Ka=s}else Ka=536870912;return s=Ma.current,s!==null&&(s.flags|=32),Ka}function Ta(s,n,i){(s===rs&&(Xt===2||Xt===9)||s.cancelPendingCommit!==null)&&(Ro(s,0),Fr(s,Nt,Ka,!1)),ba(s,i),(($t&2)===0||s!==rs)&&(s===rs&&(($t&2)===0&&(Ki|=i),Ss===4&&Fr(s,Nt,Ka,!1)),Ln(s))}function Yy(s,n,i){if(($t&6)!==0)throw Error(o(327));var c=!i&&(n&127)===0&&(n&s.expiredLanes)===0||Ct(s,n),h=c?wS(s,n):wp(s,n,!0),f=c;do{if(h===0){Eo&&!c&&Fr(s,n,0,!1);break}else{if(i=s.current.alternate,f&&!vS(i)){h=wp(s,n,!1),f=!1;continue}if(h===2){if(f=n,s.errorRecoveryDisabledLanes&f)var j=0;else j=s.pendingLanes&-536870913,j=j!==0?j:j&536870912?536870912:0;if(j!==0){n=j;e:{var R=s;h=ql;var F=R.current.memoizedState.isDehydrated;if(F&&(Ro(R,j).flags|=256),j=wp(R,j,!1),j!==2){if(fp&&!F){R.errorRecoveryDisabledLanes|=f,Ki|=f,h=4;break e}f=ka,ka=h,f!==null&&(ka===null?ka=f:ka.push.apply(ka,f))}h=j}if(f=!1,h!==2)continue}}if(h===1){Ro(s,0),Fr(s,n,0,!0);break}e:{switch(c=s,f=h,f){case 0:case 1:throw Error(o(345));case 4:if((n&4194048)!==n)break;case 6:Fr(c,n,Ka,!Ir);break e;case 2:ka=null;break;case 3:case 5:break;default:throw Error(o(329))}if((n&62914560)===n&&(h=Vd+300-Mt(),10<h)){if(Fr(c,n,Ka,!Ir),ns(c,0,!0)!==0)break e;ur=n,c.timeoutHandle=Cv(Gy.bind(null,c,i,ka,Wd,gp,n,Ka,Ki,Ho,Ir,f,"Throttled",-0,0),h);break e}Gy(c,i,ka,Wd,gp,n,Ka,Ki,Ho,Ir,f,null,-0,0)}}break}while(!0);Ln(s)}function Gy(s,n,i,c,h,f,j,R,F,ne,ce,pe,ie,oe){if(s.timeoutHandle=-1,pe=n.subtreeFlags,pe&8192||(pe&16785408)===16785408){pe={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:re},Iy(n,f,pe);var Oe=(f&62914560)===f?Vd-Mt():(f&4194048)===f?Fy-Mt():0;if(Oe=n4(pe,Oe),Oe!==null){ur=f,s.cancelPendingCommit=Oe(av.bind(null,s,n,f,i,c,h,j,R,F,ce,pe,null,ie,oe)),Fr(s,f,j,!ne);return}}av(s,n,f,i,c,h,j,R,F)}function vS(s){for(var n=s;;){var i=n.tag;if((i===0||i===11||i===15)&&n.flags&16384&&(i=n.updateQueue,i!==null&&(i=i.stores,i!==null)))for(var c=0;c<i.length;c++){var h=i[c],f=h.getSnapshot;h=h.value;try{if(!Da(f(),h))return!1}catch{return!1}}if(i=n.child,n.subtreeFlags&16384&&i!==null)i.return=n,n=i;else{if(n===s)break;for(;n.sibling===null;){if(n.return===null||n.return===s)return!0;n=n.return}n.sibling.return=n.return,n=n.sibling}}return!0}
vendor: 12,976 bytes, line 25
25function Fr(s,n,i,c){n&=~xp,n&=~Ki,s.suspendedLanes|=n,s.pingedLanes&=~n,c&&(s.warmLanes|=n),c=s.expirationTimes;for(var h=n;0<h;){var f=31-De(h),j=1<<f;c[f]=-1,h&=~j}i!==0&&wi(s,i,n)}function qd(){return($t&6)===0?(Gl(0),!1):!0}function jp(){if(yt!==null){if(Xt===0)var s=yt.return;else s=yt,er=zi=null,Mh(s),wo=null,zl=0,s=yt;for(;s!==null;)ky(s.alternate,s),s=s.return;yt=null}}function Ro(s,n){var i=s.timeoutHandle;i!==-1&&(s.timeoutHandle=-1,KS(i)),i=s.cancelPendingCommit,i!==null&&(s.cancelPendingCommit=null,i()),ur=0,jp(),rs=s,yt=i=Xn(s.current,null),Nt=n,Xt=0,Pa=null,Ir=!1,Eo=Ct(s,n),fp=!1,Ho=Ka=xp=Ki=Br=Ss=0,ka=ql=null,gp=!1,(n&8)!==0&&(n|=n&32);var c=s.entangledLanes;if(c!==0)for(s=s.entanglements,c&=n;0<c;){var h=31-De(c),f=1<<h;n|=s[h],c&=~f}return dr=n,pd(),i}function Zy(s,n){ut=null,k.H=Pl,n===jo||n===wd?(n=mb(),Xt=3):n===Ch?(n=mb(),Xt=4):Xt=n===Qh?8:n!==null&&typeof n=="object"&&typeof n.then=="function"?6:1,Pa=n,yt===null&&(Ss=1,Od(s,Ya(n,s.current)))}function Jy(){var s=Ma.current;return s===null?!0:(Nt&4194048)===Nt?Xa===null:(Nt&62914560)===Nt||(Nt&536870912)!==0?s===Xa:!1}function Xy(){var s=k.H;return k.H=Pl,s===null?Pl:s}function Qy(){var s=k.A;return k.A=bS,s}function Yd(){Ss=4,Ir||(Nt&4194048)!==Nt&&Ma.current!==null||(Eo=!0),(Br&134217727)===0&&(Ki&134217727)===0||rs===null||Fr(rs,Nt,Ka,!1)}function wp(s,n,i){var c=$t;$t|=2;var h=Xy(),f=Qy();(rs!==s||Nt!==n)&&(Wd=null,Ro(s,n)),n=!1;var j=Ss;e:do try{if(Xt!==0&&yt!==null){var R=yt,F=Pa;switch(Xt){case 8:jp(),j=6;break e;case 3:case 2:case 9:case 6:Ma.current===null&&(n=!0);var ne=Xt;if(Xt=0,Pa=null,_o(s,R,F,ne),i&&Eo){j=0;break e}break;default:ne=Xt,Xt=0,Pa=null,_o(s,R,F,ne)}}jS(),j=Ss;break}catch(ce){Zy(s,ce)}while(!0);return n&&s.shellSuspendCounter++,er=zi=null,$t=c,k.H=h,k.A=f,yt===null&&(rs=null,Nt=0,pd()),j}function jS(){for(;yt!==null;)ev(yt)}function wS(s,n){var i=$t;$t|=2;var c=Xy(),h=Qy();rs!==s||Nt!==n?(Wd=null,Fd=Mt()+500,Ro(s,n)):Eo=Ct(s,n);e:do try{if(Xt!==0&&yt!==null){n=yt;var f=Pa;t:switch(Xt){case 1:Xt=0,Pa=null,_o(s,n,f,1);break;case 2:case 9:if(db(f)){Xt=0,Pa=null,tv(n);break}n=function(){Xt!==2&&Xt!==9||rs!==s||(Xt=7),Ln(s)},f.then(n,n);break e;case 3:Xt=7;break e;case 4:Xt=5;break e;case 7:db(f)?(Xt=0,Pa=null,tv(n)):(Xt=0,Pa=null,_o(s,n,f,7));break;case 5:var j=null;switch(yt.tag){case 26:j=yt.memoizedState;case 5:case 27:var R=yt;if(j?Kv(j):R.stateNode.complete){Xt=0,Pa=null;var F=R.sibling;if(F!==null)yt=F;else{var ne=R.return;ne!==null?(yt=ne,Gd(ne)):yt=null}break t}}Xt=0,Pa=null,_o(s,n,f,5);break;case 6:Xt=0,Pa=null,_o(s,n,f,6);break;case 8:jp(),Ss=6;break e;default:throw Error(o(462))}}NS();break}catch(ce){Zy(s,ce)}while(!0);return er=zi=null,k.H=c,k.A=h,$t=i,yt!==null?0:(rs=null,Nt=0,pd(),Ss)}function NS(){for(;yt!==null&&!js();)ev(yt)}function ev(s){var n=Sy(s.alternate,s,dr);s.memoizedProps=s.pendingProps,n===null?Gd(s):yt=n}function tv(s){var n=s,i=n.alternate;switch(n.tag){case 15:case 0:n=by(i,n,n.pendingProps,n.type,void 0,Nt);break;case 11:n=by(i,n,n.pendingProps,n.type.render,n.ref,Nt);break;case 5:Mh(n);default:ky(i,n),n=yt=Qg(n,dr),n=Sy(i,n,dr)}s.memoizedProps=s.pendingProps,n===null?Gd(s):yt=n}function _o(s,n,i,c){er=zi=null,Mh(n),wo=null,zl=0;var h=n.return;try{if(uS(s,h,n,i,Nt)){Ss=1,Od(s,Ya(i,s.current)),yt=null;return}}catch(f){if(h!==null)throw yt=h,f;Ss=1,Od(s,Ya(i,s.current)),yt=null;return}n.flags&32768?(At||c===1?s=!0:Eo||(Nt&536870912)!==0?s=!1:(Ir=s=!0,(c===2||c===9||c===3||c===6)&&(c=Ma.current,c!==null&&c.tag===13&&(c.flags|=16384))),sv(n,s)):Gd(n)}function Gd(s){var n=s;do{if((n.flags&32768)!==0){sv(n,Ir);return}s=n.return;var i=pS(n.alternate,n,dr);if(i!==null){yt=i;return}if(n=n.sibling,n!==null){yt=n;return}yt=n=s}while(n!==null);Ss===0&&(Ss=5)}function sv(s,n){do{var i=fS(s.alternate,s);if(i!==null){i.flags&=32767,yt=i;return}if(i=s.return,i!==null&&(i.flags|=32768,i.subtreeFlags=0,i.deletions=null),!n&&(s=s.sibling,s!==null)){yt=s;return}yt=s=i}while(s!==null);Ss=6,yt=null}function av(s,n,i,c,h,f,j,R,F){s.cancelPendingCommit=null;do Zd();while(Bs!==0);if(($t&6)!==0)throw Error(o(327));if(n!==null){if(n===s.current)throw Error(o(177));if(f=n.lanes|n.childLanes,f|=dh,Tr(s,i,f,j,R,F),s===rs&&(yt=rs=null,Nt=0),zo=n,Vr=s,ur=i,bp=f,yp=h,Wy=c,(n.subtreeFlags&10256)!==0||(n.flags&10256)!==0?(s.callbackNode=null,s.callbackPriority=0,TS(ws,function(){return lv(),null})):(s.callbackNode=null,s.callbackPriority=0),c=(n.flags&13878)!==0,(n.subtreeFlags&13878)!==0||c){c=k.T,k.T=null,h=K.p,K.p=2,j=$t,$t|=4;try{xS(s,n,i)}finally{$t=j,K.p=h,k.T=c}}Bs=1,nv(),rv(),iv()}}function nv(){if(Bs===1){Bs=0;var s=Vr,n=zo,i=(n.flags&13878)!==0;if((n.subtreeFlags&13878)!==0||i){i=k.T,k.T=null;var c=K.p;K.p=2;var h=$t;$t|=4;try{Uy(n,s);var f=Lp,j=Vg(s.containerInfo),R=f.focusedElem,F=f.selectionRange;if(j!==R&&R&&R.ownerDocument&&$g(R.ownerDocument.documentElement,R)){if(F!==null&&rh(R)){var ne=F.start,ce=F.end;if(ce===void 0&&(ce=ne),"selectionStart"in R)R.selectionStart=ne,R.selectionEnd=Math.min(ce,R.value.length);else{var pe=R.ownerDocument||document,ie=pe&&pe.defaultView||window;if(ie.getSelection){var oe=ie.getSelection(),Oe=R.textContent.length,Je=Math.min(F.start,Oe),ss=F.end===void 0?Je:Math.min(F.end,Oe);!oe.extend&&Je>ss&&(j=ss,ss=Je,Je=j);var Q=Bg(R,Je),Z=Bg(R,ss);if(Q&&Z&&(oe.rangeCount!==1||oe.anchorNode!==Q.node||oe.anchorOffset!==Q.offset||oe.focusNode!==Z.node||oe.focusOffset!==Z.offset)){var ae=pe.createRange();ae.setStart(Q.node,Q.offset),oe.removeAllRanges(),Je>ss?(oe.addRange(ae),oe.extend(Z.node,Z.offset)):(ae.setEnd(Z.node,Z.offset),oe.addRange(ae))}}}}for(pe=[],oe=R;oe=oe.parentNode;)oe.nodeType===1&&pe.push({element:oe,left:oe.scrollLeft,top:oe.scrollTop});for(typeof R.focus=="function"&&R.focus(),R=0;R<pe.length;R++){var he=pe[R];he.element.scrollLeft=he.left,he.element.scrollTop=he.top}}lu=!!_p,Lp=_p=null}finally{$t=h,K.p=c,k.T=i}}s.current=n,Bs=2}}function rv(){if(Bs===2){Bs=0;var s=Vr,n=zo,i=(n.flags&8772)!==0;if((n.subtreeFlags&8772)!==0||i){i=k.T,k.T=null;var c=K.p;K.p=2;var h=$t;$t|=4;try{_y(s,n.alternate,n)}finally{$t=h,K.p=c,k.T=i}}Bs=3}}function iv(){if(Bs===4||Bs===3){Bs=0,Ws();var s=Vr,n=zo,i=ur,c=Wy;(n.subtreeFlags&10256)!==0||(n.flags&10256)!==0?Bs=5:(Bs=0,zo=Vr=null,ov(s,s.pendingLanes));var h=s.pendingLanes;if(h===0&&($r=null),ee(i),n=n.stateNode,Xe&&typeof Xe.onCommitFiberRoot=="function")try{Xe.onCommitFiberRoot(et,n,void 0,(n.current.flags&128)===128)}catch{}if(c!==null){n=k.T,h=K.p,K.p=2,k.T=null;try{for(var f=s.onRecoverableError,j=0;j<c.length;j++){var R=c[j];f(R.value,{componentStack:R.stack})}}finally{k.T=n,K.p=h}}(ur&3)!==0&&Zd(),Ln(s),h=s.pendingLanes,(i&261930)!==0&&(h&42)!==0?s===vp?Yl++:(Yl=0,vp=s):Yl=0,Gl(0)}}function ov(s,n){(s.pooledCacheLanes&=n)===0&&(n=s.pooledCache,n!=null&&(s.pooledCache=null,El(n)))}function Zd(){return nv(),rv(),iv(),lv()}function lv(){if(Bs!==5)return!1;var s=Vr,n=bp;bp=0;var i=ee(ur),c=k.T,h=K.p;try{K.p=32>i?32:i,k.T=null,i=yp,yp=null;var f=Vr,j=ur;if(Bs=0,zo=Vr=null,ur=0,($t&6)!==0)throw Error(o(331));var R=$t;if($t|=4,$y(f.current),Ky(f,f.current,j,i),$t=R,Gl(0,!1),Xe&&typeof Xe.onPostCommitFiberRoot=="function")try{Xe.onPostCommitFiberRoot(et,f)}catch{}return!0}finally{K.p=h,k.T=c,ov(s,n)}}function cv(s,n,i){n=Ya(i,n),n=Xh(s.stateNode,n,2),s=Mr(s,n,2),s!==null&&(ba(s,2),Ln(s))}function Qt(s,n,i){if(s.tag===3)cv(s,s,i);else for(;n!==null;){if(n.tag===3){cv(n,s,i);break}else if(n.tag===1){var c=n.stateNode;if(typeof n.type.getDerivedStateFromError=="function"||typeof c.componentDidCatch=="function"&&($r===null||!$r.has(c))){s=Ya(i,s),i=dy(2),c=Mr(n,i,2),c!==null&&(uy(i,c,n,s),ba(c,2),Ln(c));break}}n=n.return}}function Np(s,n,i){var c=s.pingCache;if(c===null){c=s.pingCache=new yS;var h=new Set;c.set(n,h)}else h=c.get(n),h===void 0&&(h=new Set,c.set(n,h));h.has(i)||(fp=!0,h.add(i),s=SS.bind(null,s,n,i),n.then(s,s))}function SS(s,n,i){var c=s.pingCache;c!==null&&c.delete(n),s.pingedLanes|=s.suspendedLanes&i,s.warmLanes&=~i,rs===s&&(Nt&i)===i&&(Ss===4||Ss===3&&(Nt&62914560)===Nt&&300>Mt()-Vd?($t&2)===0&&Ro(s,0):xp|=i,Ho===Nt&&(Ho=0)),Ln(s)}function dv(s,n){n===0&&(n=Qs()),s=Ai(s,n),s!==null&&(ba(s,n),Ln(s))}function CS(s){var n=s.memoizedState,i=0;n!==null&&(i=n.retryLane),dv(s,i)}function kS(s,n){var i=0;switch(s.tag){case 31:case 13:var c=s.stateNode,h=s.memoizedState;h!==null&&(i=h.retryLane);break;case 19:c=s.stateNode;break;case 22:c=s.stateNode._retryCache;break;default:throw Error(o(314))}c!==null&&c.delete(n),dv(s,i)}function TS(s,n){return Jt(s,n)}var Jd=null,Lo=null,Sp=!1,Xd=!1,Cp=!1,Wr=0;function Ln(s){s!==Lo&&s.next===null&&(Lo===null?Jd=Lo=s:Lo=Lo.next=s),Xd=!0,Sp||(Sp=!0,ES())}function Gl(s,n){if(!Cp&&Xd){Cp=!0;do for(var i=!1,c=Jd;c!==null;){if(s!==0){var h=c.pendingLanes;if(h===0)var f=0;else{var j=c.suspendedLanes,R=c.pingedLanes;f=(1<<31-De(42|s)+1)-1,f&=h&~(j&~R),f=f&201326741?f&201326741|1:f?f|2:0}f!==0&&(i=!0,pv(c,f))}else f=Nt,f=ns(c,c===rs?f:0,c.cancelPendingCommit!==null||c.timeoutHandle!==-1),(f&3)===0||Ct(c,f)||(i=!0,pv(c,f));c=c.next}while(i);Cp=!1}}function AS(){uv()}function uv(){Xd=Sp=!1;var s=0;Wr!==0&&PS()&&(s=Wr);for(var n=Mt(),i=null,c=Jd;c!==null;){var h=c.next,f=mv(c,n);f===0?(c.next=null,i===null?Jd=h:i.next=h,h===null&&(Lo=i)):(i=c,(s!==0||(f&3)!==0)&&(Xd=!0)),c=h}Bs!==0&&Bs!==5||Gl(s),Wr!==0&&(Wr=0)}function mv(s,n){for(var i=s.suspendedLanes,c=s.pingedLanes,h=s.expirationTimes,f=s.pendingLanes&-62914561;0<f;){var j=31-De(f),R=1<<j,F=h[j];F===-1?((R&i)===0||(R&c)!==0)&&(h[j]=Ut(R,n)):F<=n&&(s.expiredLanes|=R),f&=~R}if(n=rs,i=Nt,i=ns(s,s===n?i:0,s.cancelPendingCommit!==null||s.timeoutHandle!==-1),c=s.callbackNode,i===0||s===n&&(Xt===2||Xt===9)||s.cancelPendingCommit!==null)return c!==null&&c!==null&&vs(c),s.callbackNode=null,s.callbackPriority=0;if((i&3)===0||Ct(s,i)){if(n=i&-i,n===s.callbackPriority)return n;switch(c!==null&&vs(c),ee(i)){case 2:case 8:i=Wt;break;case 32:i=ws;break;case 268435456:i=qt;break;default:i=ws}return c=hv.bind(null,s),i=Jt(i,c),s.callbackPriority=n,s.callbackNode=i,n}return c!==null&&c!==null&&vs(c),s.callbackPriority=2,s.callbackNode=null,2}function hv(s,n){if(Bs!==0&&Bs!==5)return s.callbackNode=null,s.callbackPriority=0,null;var i=s.callbackNode;if(Zd()&&s.callbackNode!==i)return null;var c=Nt;return c=ns(s,s===rs?c:0,s.cancelPendingCommit!==null||s.timeoutHandle!==-1),c===0?null:(Yy(s,c,n),mv(s,Mt()),s.callbackNode!=null&&s.callbackNode===i?hv.bind(null,s):null)}function pv(s,n){if(Zd())return null;Yy(s,n,!0)}function ES(){IS(function(){($t&6)!==0?Jt(ps,AS):uv()})}function kp(){if(Wr===0){var s=yo;s===0&&(s=qs,qs<<=1,(qs&261888)===0&&(qs=256)),Wr=s}return Wr}function fv(s){return s==null||typeof s=="symbol"||typeof s=="boolean"?null:typeof s=="function"?s:Si(""+s)}function xv(s,n){var i=n.ownerDocument.createElement("input");return i.name=n.name,i.value=n.value,s.id&&i.setAttribute("form",s.id),n.parentNode.insertBefore(i,n),s=new FormData(s),i.parentNode.removeChild(i),s}function HS(s,n,i,c,h){if(n==="submit"&&i&&i.stateNode===h){var f=fv((h[He]||null).action),j=c.submitter;j&&(n=(n=j[He]||null)?fv(n.formAction):j.getAttribute("formAction"),n!==null&&(f=n,j=null));var R=new dd("action","action",null,c,h);s.push({event:R,listeners:[{instance:null,listener:function(){if(c.defaultPrevented){if(Wr!==0){var F=j?xv(h,j):new FormData(h);Wh(i,{pending:!0,data:F,method:h.method,action:f},null,F)}}else typeof f=="function"&&(R.preventDefault(),F=j?xv(h,j):new FormData(h),Wh(i,{pending:!0,data:F,method:h.method,action:f},f,F))},currentTarget:h}]})}}for(var Tp=0;Tp<ch.length;Tp++){var Ap=ch[Tp],zS=Ap.toLowerCase(),RS=Ap[0].toUpperCase()+Ap.slice(1);xn(zS,"on"+RS)}xn(qg,"onAnimationEnd"),xn(Yg,"onAnimationIteration"),xn(Gg,"onAnimationStart"),xn("dblclick","onDoubleClick"),xn("focusin","onFocus"),xn("focusout","onBlur"),xn(YN,"onTransitionRun"),xn(GN,"onTransitionStart"),xn(ZN,"onTransitionCancel"),xn(Zg,"onTransitionEnd"),fs("onMouseEnter",["mouseout","mouseover"]),fs("onMouseLeave",["mouseout","mouseover"]),fs("onPointerEnter",["pointerout","pointerover"]),fs("onPointerLeave",["pointerout","pointerover"]),da("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),da("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),da("onBeforeInput",["compositionend","keypress","textInput","paste"]),da("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),da("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),da("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Zl="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(" "),_S=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(Zl));
vendor: 4,202 bytes, line 25
25function gv(s,n){n=(n&4)!==0;for(var i=0;i<s.length;i++){var c=s[i],h=c.event;c=c.listeners;e:{var f=void 0;if(n)for(var j=c.length-1;0<=j;j--){var R=c[j],F=R.instance,ne=R.currentTarget;if(R=R.listener,F!==f&&h.isPropagationStopped())break e;f=R,h.currentTarget=ne;try{f(h)}catch(ce){hd(ce)}h.currentTarget=null,f=F}else for(j=0;j<c.length;j++){if(R=c[j],F=R.instance,ne=R.currentTarget,R=R.listener,F!==f&&h.isPropagationStopped())break e;f=R,h.currentTarget=ne;try{f(h)}catch(ce){hd(ce)}h.currentTarget=null,f=F}}}}function vt(s,n){var i=n[$e];i===void 0&&(i=n[$e]=new Set);var c=s+"__bubble";i.has(c)||(bv(n,s,2,!1),i.add(c))}function Ep(s,n,i){var c=0;n&&(c|=4),bv(i,s,c,n)}var Qd="_reactListening"+Math.random().toString(36).slice(2);function Hp(s){if(!s[Qd]){s[Qd]=!0,ca.forEach(function(i){i!=="selectionchange"&&(_S.has(i)||Ep(i,!1,s),Ep(i,!0,s))});var n=s.nodeType===9?s:s.ownerDocument;n===null||n[Qd]||(n[Qd]=!0,Ep("selectionchange",!1,n))}}function bv(s,n,i,c){switch(qv(n)){case 2:var h=o4;break;case 8:h=l4;break;default:h=Fp}i=h.bind(null,n,i,s),h=void 0,!yl||n!=="touchstart"&&n!=="touchmove"&&n!=="wheel"||(h=!0),c?h!==void 0?s.addEventListener(n,i,{capture:!0,passive:h}):s.addEventListener(n,i,!0):h!==void 0?s.addEventListener(n,i,{passive:h}):s.addEventListener(n,i,!1)}function zp(s,n,i,c,h){var f=c;if((n&1)===0&&(n&2)===0&&c!==null)e:for(;;){if(c===null)return;var j=c.tag;if(j===3||j===4){var R=c.stateNode.containerInfo;if(R===h)break;if(j===4)for(j=c.return;j!==null;){var F=j.tag;if((F===3||F===4)&&j.stateNode.containerInfo===h)return;j=j.return}for(;R!==null;){if(j=Gt(R),j===null)return;if(F=j.tag,F===5||F===6||F===26||F===27){c=f=j;continue e}R=R.parentNode}}c=c.return}Ys(function(){var ne=f,ce=Pe(i),pe=[];e:{var ie=Jg.get(s);if(ie!==void 0){var oe=dd,Oe=s;switch(s){case"keypress":if(ld(i)===0)break e;case"keydown":case"keyup":oe=kN;break;case"focusin":Oe="focus",oe=eh;break;case"focusout":Oe="blur",oe=eh;break;case"beforeblur":case"afterblur":oe=eh;break;case"click":if(i.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":oe=kg;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":oe=pN;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":oe=EN;break;case qg:case Yg:case Gg:oe=gN;break;case Zg:oe=zN;break;case"scroll":case"scrollend":oe=mN;break;case"wheel":oe=_N;break;case"copy":case"cut":case"paste":oe=yN;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":oe=Ag;break;case"toggle":case"beforetoggle":oe=DN}var Je=(n&4)!==0,ss=!Je&&(s==="scroll"||s==="scrollend"),Q=Je?ie!==null?ie+"Capture":null:ie;Je=[];for(var Z=ne,ae;Z!==null;){var he=Z;if(ae=he.stateNode,he=he.tag,he!==5&&he!==26&&he!==27||ae===null||Q===null||(he=Ts(Z,Q),he!=null&&Je.push(Jl(Z,he,ae))),ss)break;Z=Z.return}0<Je.length&&(ie=new oe(ie,Oe,null,i,ce),pe.push({event:ie,listeners:Je}))}}if((n&7)===0){e:{if(ie=s==="mouseover"||s==="pointerover",oe=s==="mouseout"||s==="pointerout",ie&&i!==Ne&&(Oe=i.relatedTarget||i.fromElement)&&(Gt(Oe)||Oe[ke]))break e;if((oe||ie)&&(ie=ce.window===ce?ce:(ie=ce.ownerDocument)?ie.defaultView||ie.parentWindow:window,oe?(Oe=i.relatedTarget||i.toElement,oe=ne,Oe=Oe?Gt(Oe):null,Oe!==null&&(ss=d(Oe),Je=Oe.tag,Oe!==ss||Je!==5&&Je!==27&&Je!==6)&&(Oe=null)):(oe=null,Oe=ne),oe!==Oe)){if(Je=kg,he="onMouseLeave",Q="onMouseEnter",Z="mouse",(s==="pointerout"||s==="pointerover")&&(Je=Ag,he="onPointerLeave",Q="onPointerEnter",Z="pointer"),ss=oe==null?ie:ea(oe),ae=Oe==null?ie:ea(Oe),ie=new Je(he,Z+"leave",oe,i,ce),ie.target=ss,ie.relatedTarget=ae,he=null,Gt(ce)===ne&&(Je=new Je(Q,Z+"enter",Oe,i,ce),Je.target=ae,Je.relatedTarget=ss,he=Je),ss=he,oe&&Oe)t:{for(Je=LS,Q=oe,Z=Oe,ae=0,he=Q;he;he=Je(he))ae++;he=0;for(var Ge=Z;Ge;Ge=Je(Ge))he++;for(;0<ae-he;)Q=Je(Q),ae--;for(;0<he-ae;)Z=Je(Z),he--;for(;ae--;){if(Q===Z||Z!==null&&Q===Z.alternate){Je=Q;break t}Q=Je(Q),Z=Je(Z)}Je=null}else Je=null;oe!==null&&yv(pe,ie,oe,Je,!1),Oe!==null&&ss!==null&&yv(pe,ss,Oe,Je,!0)}}
vendor: 1,698 bytes, line 25
25e:{if(ie=ne?ea(ne):window,oe=ie.nodeName&&ie.nodeName.toLowerCase(),oe==="select"||oe==="input"&&ie.type==="file")var Pt=Og;else if(Lg(ie))if(Mg)Pt=FN;else{Pt=$N;var Be=BN}else oe=ie.nodeName,!oe||oe.toLowerCase()!=="input"||ie.type!=="checkbox"&&ie.type!=="radio"?ne&&bl(ne.elementType)&&(Pt=Og):Pt=VN;if(Pt&&(Pt=Pt(s,ne))){Dg(pe,Pt,i,ce);break e}Be&&Be(s,ie,ne),s==="focusout"&&ne&&ie.type==="number"&&ne.memoizedProps.value!=null&&fl(ie,"number",ie.value)}switch(Be=ne?ea(ne):window,s){case"focusin":(Lg(Be)||Be.contentEditable==="true")&&(uo=Be,ih=ne,kl=null);break;case"focusout":kl=ih=uo=null;break;case"mousedown":oh=!0;break;case"contextmenu":case"mouseup":case"dragend":oh=!1,Fg(pe,i,ce);break;case"selectionchange":if(qN)break;case"keydown":case"keyup":Fg(pe,i,ce)}var mt;if(sh)e:{switch(s){case"compositionstart":var St="onCompositionStart";break e;case"compositionend":St="onCompositionEnd";break e;case"compositionupdate":St="onCompositionUpdate";break e}St=void 0}else co?Rg(s,i)&&(St="onCompositionEnd"):s==="keydown"&&i.keyCode===229&&(St="onCompositionStart");St&&(Eg&&i.locale!=="ko"&&(co||St!=="onCompositionStart"?St==="onCompositionEnd"&&co&&(mt=Sg()):(Hr=ce,Jm="value"in Hr?Hr.value:Hr.textContent,co=!0)),Be=eu(ne,St),0<Be.length&&(St=new Tg(St,s,null,i,ce),pe.push({event:St,listeners:Be}),mt?St.data=mt:(mt=_g(i),mt!==null&&(St.data=mt)))),(mt=MN?UN(s,i):PN(s,i))&&(St=eu(ne,"onBeforeInput"),0<St.length&&(Be=new Tg("onBeforeInput","beforeinput",null,i,ce),pe.push({event:Be,listeners:St}),Be.data=mt)),HS(pe,s,ne,i,ce)}gv(pe,n)})}function Jl(s,n,i){return{instance:s,listener:n,currentTarget:i}}function eu(s,n){for(var i=n+"Capture",c=[];s!==null;){var h=s,f=h.stateNode;
vendor: 7,856 bytes, lines 25-26
25if(h=h.tag,h!==5&&h!==26&&h!==27||f===null||(h=Ts(s,i),h!=null&&c.unshift(Jl(s,h,f)),h=Ts(s,n),h!=null&&c.push(Jl(s,h,f))),s.tag===3)return c;s=s.return}return[]}function LS(s){if(s===null)return null;do s=s.return;while(s&&s.tag!==5&&s.tag!==27);return s||null}function yv(s,n,i,c,h){for(var f=n._reactName,j=[];i!==null&&i!==c;){var R=i,F=R.alternate,ne=R.stateNode;if(R=R.tag,F!==null&&F===c)break;R!==5&&R!==26&&R!==27||ne===null||(F=ne,h?(ne=Ts(i,f),ne!=null&&j.unshift(Jl(i,ne,F))):h||(ne=Ts(i,f),ne!=null&&j.push(Jl(i,ne,F)))),i=i.return}j.length!==0&&s.push({event:n,listeners:j})}var DS=/\r\n?/g,OS=/\u0000|\uFFFD/g;function vv(s){return(typeof s=="string"?s:""+s).replace(DS,`
26`).replace(OS,"")}function jv(s,n){return n=vv(n),vv(s)===n}function ts(s,n,i,c,h,f){switch(i){case"children":typeof c=="string"?n==="body"||n==="textarea"&&c===""||Er(s,c):(typeof c=="number"||typeof c=="bigint")&&n!=="body"&&Er(s,""+c);break;case"className":_a(s,"class",c);break;case"tabIndex":_a(s,"tabindex",c);break;case"dir":case"role":case"viewBox":case"width":case"height":_a(s,i,c);break;case"style":lo(s,c,f);break;case"data":if(n!=="object"){_a(s,"data",c);break}case"src":case"href":if(c===""&&(n!=="a"||i!=="href")){s.removeAttribute(i);break}if(c==null||typeof c=="function"||typeof c=="symbol"||typeof c=="boolean"){s.removeAttribute(i);break}c=Si(""+c),s.setAttribute(i,c);break;case"action":case"formAction":if(typeof c=="function"){s.setAttribute(i,"javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')");break}else typeof f=="function"&&(i==="formAction"?(n!=="input"&&ts(s,n,"name",h.name,h,null),ts(s,n,"formEncType",h.formEncType,h,null),ts(s,n,"formMethod",h.formMethod,h,null),ts(s,n,"formTarget",h.formTarget,h,null)):(ts(s,n,"encType",h.encType,h,null),ts(s,n,"method",h.method,h,null),ts(s,n,"target",h.target,h,null)));if(c==null||typeof c=="symbol"||typeof c=="boolean"){s.removeAttribute(i);break}c=Si(""+c),s.setAttribute(i,c);break;case"onClick":c!=null&&(s.onclick=re);break;case"onScroll":c!=null&&vt("scroll",s);break;case"onScrollEnd":c!=null&&vt("scrollend",s);break;case"dangerouslySetInnerHTML":if(c!=null){if(typeof c!="object"||!("__html"in c))throw Error(o(61));if(i=c.__html,i!=null){if(h.children!=null)throw Error(o(60));s.innerHTML=i}}break;case"multiple":s.multiple=c&&typeof c!="function"&&typeof c!="symbol";break;case"muted":s.muted=c&&typeof c!="function"&&typeof c!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(c==null||typeof c=="function"||typeof c=="boolean"||typeof c=="symbol"){s.removeAttribute("xlink:href");break}i=Si(""+c),s.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",i);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":c!=null&&typeof c!="function"&&typeof c!="symbol"?s.setAttribute(i,""+c):s.removeAttribute(i);break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":c&&typeof c!="function"&&typeof c!="symbol"?s.setAttribute(i,""):s.removeAttribute(i);break;case"capture":case"download":c===!0?s.setAttribute(i,""):c!==!1&&c!=null&&typeof c!="function"&&typeof c!="symbol"?s.setAttribute(i,c):s.removeAttribute(i);break;case"cols":case"rows":case"size":case"span":c!=null&&typeof c!="function"&&typeof c!="symbol"&&!isNaN(c)&&1<=c?s.setAttribute(i,c):s.removeAttribute(i);break;case"rowSpan":case"start":c==null||typeof c=="function"||typeof c=="symbol"||isNaN(c)?s.removeAttribute(i):s.setAttribute(i,c);break;case"popover":vt("beforetoggle",s),vt("toggle",s),hn(s,"popover",c);break;case"xlinkActuate":at(s,"http://www.w3.org/1999/xlink","xlink:actuate",c);break;case"xlinkArcrole":at(s,"http://www.w3.org/1999/xlink","xlink:arcrole",c);break;case"xlinkRole":at(s,"http://www.w3.org/1999/xlink","xlink:role",c);break;case"xlinkShow":at(s,"http://www.w3.org/1999/xlink","xlink:show",c);break;case"xlinkTitle":at(s,"http://www.w3.org/1999/xlink","xlink:title",c);break;case"xlinkType":at(s,"http://www.w3.org/1999/xlink","xlink:type",c);break;case"xmlBase":at(s,"http://www.w3.org/XML/1998/namespace","xml:base",c);break;case"xmlLang":at(s,"http://www.w3.org/XML/1998/namespace","xml:lang",c);break;case"xmlSpace":at(s,"http://www.w3.org/XML/1998/namespace","xml:space",c);break;case"is":hn(s,"is",c);break;case"innerText":case"textContent":break;default:(!(2<i.length)||i[0]!=="o"&&i[0]!=="O"||i[1]!=="n"&&i[1]!=="N")&&(i=rd.get(i)||i,hn(s,i,c))}}function Rp(s,n,i,c,h,f){switch(i){case"style":lo(s,c,f);break;case"dangerouslySetInnerHTML":if(c!=null){if(typeof c!="object"||!("__html"in c))throw Error(o(61));if(i=c.__html,i!=null){if(h.children!=null)throw Error(o(60));s.innerHTML=i}}break;case"children":typeof c=="string"?Er(s,c):(typeof c=="number"||typeof c=="bigint")&&Er(s,""+c);break;case"onScroll":c!=null&&vt("scroll",s);break;case"onScrollEnd":c!=null&&vt("scrollend",s);break;case"onClick":c!=null&&(s.onclick=re);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!ya.hasOwnProperty(i))e:{if(i[0]==="o"&&i[1]==="n"&&(h=i.endsWith("Capture"),n=i.slice(2,h?i.length-7:void 0),f=s[He]||null,f=f!=null?f[i]:null,typeof f=="function"&&s.removeEventListener(n,f,h),typeof c=="function")){typeof f!="function"&&f!==null&&(i in s?s[i]=null:s.hasAttribute(i)&&s.removeAttribute(i)),s.addEventListener(n,c,h);break e}i in s?s[i]=c:c===!0?s.setAttribute(i,""):hn(s,i,c)}}}function ra(s,n,i){switch(n){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":vt("error",s),vt("load",s);var c=!1,h=!1,f;for(f in i)if(i.hasOwnProperty(f)){var j=i[f];if(j!=null)switch(f){case"src":c=!0;break;case"srcSet":h=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(o(137,n));default:ts(s,n,f,j,i,null)}}h&&ts(s,n,"srcSet",i.srcSet,i,null),c&&ts(s,n,"src",i.src,i,null);return;case"input":vt("invalid",s);var R=f=j=h=null,F=null,ne=null;for(c in i)if(i.hasOwnProperty(c)){var ce=i[c];if(ce!=null)switch(c){case"name":h=ce;break;case"type":j=ce;break;case"checked":F=ce;break;case"defaultChecked":ne=ce;break;case"value":f=ce;break;case"defaultValue":R=ce;break;case"children":case"dangerouslySetInnerHTML":if(ce!=null)throw Error(o(137,n));break;default:ts(s,n,c,ce,i,null)}}ad(s,f,R,F,ne,j,h,!1);return;case"select":vt("invalid",s),c=j=f=null;for(h in i)if(i.hasOwnProperty(h)&&(R=i[h],R!=null))switch(h){case"value":f=R;break;case"defaultValue":j=R;break;case"multiple":c=R;default:ts(s,n,h,R,i,null)}n=f,i=j,s.multiple=!!c,n!=null?Ar(s,!!c,n,!1):i!=null&&Ar(s,!!c,i,!0);return;case"textarea":vt("invalid",s),f=h=c=null;for(j in i)if(i.hasOwnProperty(j)&&(R=i[j],R!=null))switch(j){case"value":c=R;break;case"defaultValue":h=R;break;case"children":f=R;break;case"dangerouslySetInnerHTML":if(R!=null)throw Error(o(91));break;default:ts(s,n,j,R,i,null)}xl(s,c,h,f);return;case"option":for(F in i)if(i.hasOwnProperty(F)&&(c=i[F],c!=null))switch(F){case"selected":s.selected=c&&typeof c!="function"&&typeof c!="symbol";break;default:ts(s,n,F,c,i,null)}return;case"dialog":vt("beforetoggle",s),vt("toggle",s),vt("cancel",s),vt("close",s
vendor: 4,588 bytes, line 26
26);break;case"iframe":case"object":vt("load",s);break;case"video":case"audio":for(c=0;c<Zl.length;c++)vt(Zl[c],s);break;case"image":vt("error",s),vt("load",s);break;case"details":vt("toggle",s);break;case"embed":case"source":case"link":vt("error",s),vt("load",s);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(ne in i)if(i.hasOwnProperty(ne)&&(c=i[ne],c!=null))switch(ne){case"children":case"dangerouslySetInnerHTML":throw Error(o(137,n));default:ts(s,n,ne,c,i,null)}return;default:if(bl(n)){for(ce in i)i.hasOwnProperty(ce)&&(c=i[ce],c!==void 0&&Rp(s,n,ce,c,i,void 0));return}}for(R in i)i.hasOwnProperty(R)&&(c=i[R],c!=null&&ts(s,n,R,c,i,null))}function MS(s,n,i,c){switch(n){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var h=null,f=null,j=null,R=null,F=null,ne=null,ce=null;for(oe in i){var pe=i[oe];if(i.hasOwnProperty(oe)&&pe!=null)switch(oe){case"checked":break;case"value":break;case"defaultValue":F=pe;default:c.hasOwnProperty(oe)||ts(s,n,oe,null,c,pe)}}for(var ie in c){var oe=c[ie];if(pe=i[ie],c.hasOwnProperty(ie)&&(oe!=null||pe!=null))switch(ie){case"type":f=oe;break;case"name":h=oe;break;case"checked":ne=oe;break;case"defaultChecked":ce=oe;break;case"value":j=oe;break;case"defaultValue":R=oe;break;case"children":case"dangerouslySetInnerHTML":if(oe!=null)throw Error(o(137,n));break;default:oe!==pe&&ts(s,n,ie,oe,c,pe)}}Ni(s,j,R,F,ne,ce,f,h);return;case"select":oe=j=R=ie=null;for(f in i)if(F=i[f],i.hasOwnProperty(f)&&F!=null)switch(f){case"value":break;case"multiple":oe=F;default:c.hasOwnProperty(f)||ts(s,n,f,null,c,F)}for(h in c)if(f=c[h],F=i[h],c.hasOwnProperty(h)&&(f!=null||F!=null))switch(h){case"value":ie=f;break;case"defaultValue":R=f;break;case"multiple":j=f;default:f!==F&&ts(s,n,h,f,c,F)}n=R,i=j,c=oe,ie!=null?Ar(s,!!i,ie,!1):!!c!=!!i&&(n!=null?Ar(s,!!i,n,!0):Ar(s,!!i,i?[]:"",!1));return;case"textarea":oe=ie=null;for(R in i)if(h=i[R],i.hasOwnProperty(R)&&h!=null&&!c.hasOwnProperty(R))switch(R){case"value":break;case"children":break;default:ts(s,n,R,null,c,h)}for(j in c)if(h=c[j],f=i[j],c.hasOwnProperty(j)&&(h!=null||f!=null))switch(j){case"value":ie=h;break;case"defaultValue":oe=h;break;case"children":break;case"dangerouslySetInnerHTML":if(h!=null)throw Error(o(91));break;default:h!==f&&ts(s,n,j,h,c,f)}nd(s,ie,oe);return;case"option":for(var Oe in i)if(ie=i[Oe],i.hasOwnProperty(Oe)&&ie!=null&&!c.hasOwnProperty(Oe))switch(Oe){case"selected":s.selected=!1;break;default:ts(s,n,Oe,null,c,ie)}for(F in c)if(ie=c[F],oe=i[F],c.hasOwnProperty(F)&&ie!==oe&&(ie!=null||oe!=null))switch(F){case"selected":s.selected=ie&&typeof ie!="function"&&typeof ie!="symbol";break;default:ts(s,n,F,ie,c,oe)}return;case"img":case"link":case"area":case"base":case"br":case"col":case"embed":case"hr":case"keygen":case"meta":case"param":case"source":case"track":case"wbr":case"menuitem":for(var Je in i)ie=i[Je],i.hasOwnProperty(Je)&&ie!=null&&!c.hasOwnProperty(Je)&&ts(s,n,Je,null,c,ie);for(ne in c)if(ie=c[ne],oe=i[ne],c.hasOwnProperty(ne)&&ie!==oe&&(ie!=null||oe!=null))switch(ne){case"children":case"dangerouslySetInnerHTML":if(ie!=null)throw Error(o(137,n));break;default:ts(s,n,ne,ie,c,oe)}return;default:if(bl(n)){for(var ss in i)ie=i[ss],i.hasOwnProperty(ss)&&ie!==void 0&&!c.hasOwnProperty(ss)&&Rp(s,n,ss,void 0,c,ie);for(ce in c)ie=c[ce],oe=i[ce],!c.hasOwnProperty(ce)||ie===oe||ie===void 0&&oe===void 0||Rp(s,n,ce,ie,c,oe);return}}for(var Q in i)ie=i[Q],i.hasOwnProperty(Q)&&ie!=null&&!c.hasOwnProperty(Q)&&ts(s,n,Q,null,c,ie);for(pe in c)ie=c[pe],oe=i[pe],!c.hasOwnProperty(pe)||ie===oe||ie==null&&oe==null||ts(s,n,pe,ie,c,oe)}function wv(s){switch(s){case"css":case"script":case"font":case"img":case"image":case"input":case"link":return!0;default:return!1}}function US(){if(typeof performance.getEntriesByType=="function"){for(var s=0,n=0,i=performance.getEntriesByType("resource"),c=0;c<i.length;c++){var h=i[c],f=h.transferSize,j=h.initiatorType,R=h.duration;if(f&&R&&wv(j)){for(j=0,R=h.responseEnd,c+=1;c<i.length;c++){var F=i[c],ne=F.startTime;if(ne>R)break;var ce=F.transferSize,pe=F.initiatorType;ce&&wv(pe)&&(F=F.responseEnd,j+=ce*(F<R?1:(R-ne)/(F-ne)))}if(--c,n+=8*(f+j)/(h.duration/1e3),s++,10<s)break}}if(0<s)return n/s/1e6}return navigator.connection&&(s=navigator.connection.downlink,typeof s=="number")?s:5}var _p=null,Lp=null;function tu(s){return s.nodeType===9?s:s.ownerDocument}function Nv(s){switch(s){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}
vendor: 17,296 bytes, line 26
26function Sv(s,n){if(s===0)switch(n){case"svg":return 1;case"math":return 2;default:return 0}return s===1&&n==="foreignObject"?0:s}function Dp(s,n){return s==="textarea"||s==="noscript"||typeof n.children=="string"||typeof n.children=="number"||typeof n.children=="bigint"||typeof n.dangerouslySetInnerHTML=="object"&&n.dangerouslySetInnerHTML!==null&&n.dangerouslySetInnerHTML.__html!=null}var Op=null;function PS(){var s=window.event;return s&&s.type==="popstate"?s===Op?!1:(Op=s,!0):(Op=null,!1)}var Cv=typeof setTimeout=="function"?setTimeout:void 0,KS=typeof clearTimeout=="function"?clearTimeout:void 0,kv=typeof Promise=="function"?Promise:void 0,IS=typeof queueMicrotask=="function"?queueMicrotask:typeof kv<"u"?function(s){return kv.resolve(null).then(s).catch(BS)}:Cv;function BS(s){setTimeout(function(){throw s})}function qr(s){return s==="head"}function Tv(s,n){var i=n,c=0;do{var h=i.nextSibling;if(s.removeChild(i),h&&h.nodeType===8)if(i=h.data,i==="/$"||i==="/&"){if(c===0){s.removeChild(h),Uo(n);return}c--}else if(i==="$"||i==="$?"||i==="$~"||i==="$!"||i==="&")c++;else if(i==="html")Xl(s.ownerDocument.documentElement);else if(i==="head"){i=s.ownerDocument.head,Xl(i);for(var f=i.firstChild;f;){var j=f.nextSibling,R=f.nodeName;f[wt]||R==="SCRIPT"||R==="STYLE"||R==="LINK"&&f.rel.toLowerCase()==="stylesheet"||i.removeChild(f),f=j}}else i==="body"&&Xl(s.ownerDocument.body);i=h}while(i);Uo(n)}function Av(s,n){var i=s;s=0;do{var c=i.nextSibling;if(i.nodeType===1?n?(i._stashedDisplay=i.style.display,i.style.display="none"):(i.style.display=i._stashedDisplay||"",i.getAttribute("style")===""&&i.removeAttribute("style")):i.nodeType===3&&(n?(i._stashedText=i.nodeValue,i.nodeValue=""):i.nodeValue=i._stashedText||""),c&&c.nodeType===8)if(i=c.data,i==="/$"){if(s===0)break;s--}else i!=="$"&&i!=="$?"&&i!=="$~"&&i!=="$!"||s++;i=c}while(i)}function Mp(s){var n=s.firstChild;for(n&&n.nodeType===10&&(n=n.nextSibling);n;){var i=n;switch(n=n.nextSibling,i.nodeName){case"HTML":case"HEAD":case"BODY":Mp(i),kt(i);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(i.rel.toLowerCase()==="stylesheet")continue}s.removeChild(i)}}function $S(s,n,i,c){for(;s.nodeType===1;){var h=i;if(s.nodeName.toLowerCase()!==n.toLowerCase()){if(!c&&(s.nodeName!=="INPUT"||s.type!=="hidden"))break}else if(c){if(!s[wt])switch(n){case"meta":if(!s.hasAttribute("itemprop"))break;return s;case"link":if(f=s.getAttribute("rel"),f==="stylesheet"&&s.hasAttribute("data-precedence"))break;if(f!==h.rel||s.getAttribute("href")!==(h.href==null||h.href===""?null:h.href)||s.getAttribute("crossorigin")!==(h.crossOrigin==null?null:h.crossOrigin)||s.getAttribute("title")!==(h.title==null?null:h.title))break;return s;case"style":if(s.hasAttribute("data-precedence"))break;return s;case"script":if(f=s.getAttribute("src"),(f!==(h.src==null?null:h.src)||s.getAttribute("type")!==(h.type==null?null:h.type)||s.getAttribute("crossorigin")!==(h.crossOrigin==null?null:h.crossOrigin))&&f&&s.hasAttribute("async")&&!s.hasAttribute("itemprop"))break;return s;default:return s}}else if(n==="input"&&s.type==="hidden"){var f=h.name==null?null:""+h.name;if(h.type==="hidden"&&s.getAttribute("name")===f)return s}else return s;if(s=Qa(s.nextSibling),s===null)break}return null}function VS(s,n,i){if(n==="")return null;for(;s.nodeType!==3;)if((s.nodeType!==1||s.nodeName!=="INPUT"||s.type!=="hidden")&&!i||(s=Qa(s.nextSibling),s===null))return null;return s}function Ev(s,n){for(;s.nodeType!==8;)if((s.nodeType!==1||s.nodeName!=="INPUT"||s.type!=="hidden")&&!n||(s=Qa(s.nextSibling),s===null))return null;return s}function Up(s){return s.data==="$?"||s.data==="$~"}function Pp(s){return s.data==="$!"||s.data==="$?"&&s.ownerDocument.readyState!=="loading"}function FS(s,n){var i=s.ownerDocument;if(s.data==="$~")s._reactRetry=n;else if(s.data!=="$?"||i.readyState!=="loading")n();else{var c=function(){n(),i.removeEventListener("DOMContentLoaded",c)};i.addEventListener("DOMContentLoaded",c),s._reactRetry=c}}function Qa(s){for(;s!=null;s=s.nextSibling){var n=s.nodeType;if(n===1||n===3)break;if(n===8){if(n=s.data,n==="$"||n==="$!"||n==="$?"||n==="$~"||n==="&"||n==="F!"||n==="F")break;if(n==="/$"||n==="/&")return null}}return s}var Kp=null;function Hv(s){s=s.nextSibling;for(var n=0;s;){if(s.nodeType===8){var i=s.data;if(i==="/$"||i==="/&"){if(n===0)return Qa(s.nextSibling);n--}else i!=="$"&&i!=="$!"&&i!=="$?"&&i!=="$~"&&i!=="&"||n++}s=s.nextSibling}return null}function zv(s){s=s.previousSibling;for(var n=0;s;){if(s.nodeType===8){var i=s.data;if(i==="$"||i==="$!"||i==="$?"||i==="$~"||i==="&"){if(n===0)return s;n--}else i!=="/$"&&i!=="/&"||n++}s=s.previousSibling}return null}function Rv(s,n,i){switch(n=tu(i),s){case"html":if(s=n.documentElement,!s)throw Error(o(452));return s;case"head":if(s=n.head,!s)throw Error(o(453));return s;case"body":if(s=n.body,!s)throw Error(o(454));return s;default:throw Error(o(451))}}function Xl(s){for(var n=s.attributes;n.length;)s.removeAttributeNode(n[0]);kt(s)}var en=new Map,_v=new Set;function su(s){return typeof s.getRootNode=="function"?s.getRootNode():s.nodeType===9?s:s.ownerDocument}var mr=K.d;K.d={f:WS,r:qS,D:YS,C:GS,L:ZS,m:JS,X:QS,S:XS,M:e4};function WS(){var s=mr.f(),n=qd();return s||n}function qS(s){var n=nt(s);n!==null&&n.tag===5&&n.type==="form"?Zb(n):mr.r(s)}var Do=typeof document>"u"?null:document;function Lv(s,n,i){var c=Do;if(c&&typeof n=="string"&&n){var h=ta(n);h='link[rel="'+s+'"][href="'+h+'"]',typeof i=="string"&&(h+='[crossorigin="'+i+'"]'),_v.has(h)||(_v.add(h),s={rel:s,crossOrigin:i,href:n},c.querySelector(h)===null&&(n=c.createElement("link"),ra(n,"link",s),bt(n),c.head.appendChild(n)))}}function YS(s){mr.D(s),Lv("dns-prefetch",s,null)}function GS(s,n){mr.C(s,n),Lv("preconnect",s,n)}function ZS(s,n,i){mr.L(s,n,i);var c=Do;if(c&&s&&n){var h='link[rel="preload"][as="'+ta(n)+'"]';n==="image"&&i&&i.imageSrcSet?(h+='[imagesrcset="'+ta(i.imageSrcSet)+'"]',typeof i.imageSizes=="string"&&(h+='[imagesizes="'+ta(i.imageSizes)+'"]')):h+='[href="'+ta(s)+'"]';var f=h;switch(n){case"style":f=Oo(s);break;case"script":f=Mo(s)}en.has(f)||(s=y({rel:"preload",href:n==="image"&&i&&i.imageSrcSet?void 0:s,as:n},i),en.set(f,s),c.querySelector(h)!==null||n==="style"&&c.querySelector(Ql(f))||n==="script"&&c.querySelector(ec(f))||(n=c.createElement("link"),ra(n,"link",s),bt(n),c.head.appendChild(n)))}}function JS(s,n){mr.m(s,n);var i=Do;if(i&&s){var c=n&&typeof n.as=="string"?n.as:"script",h='link[rel="modulepreload"][as="'+ta(c)+'"][href="'+ta(s)+'"]',f=h;switch(c){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":f=Mo(s)}if(!en.has(f)&&(s=y({rel:"modulepreload",href:s},n),en.set(f,s),i.querySelector(h)===null)){switch(c){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(i.querySelector(ec(f)))return}c=i.createElement("link"),ra(c,"link",s),bt(c),i.head.appendChild(c)}}}function XS(s,n,i){mr.S(s,n,i);var c=Do;if(c&&s){var h=Tt(c).hoistableStyles,f=Oo(s);n=n||"default";var j=h.get(f);if(!j){var R={loading:0,preload:null};if(j=c.querySelector(Ql(f)))R.loading=5;else{s=y({rel:"stylesheet",href:s,"data-precedence":n},i),(i=en.get(f))&&Ip(s,i);var F=j=c.createElement("link");bt(F),ra(F,"link",s),F._p=new Promise(function(ne,ce){F.onload=ne,F.onerror=ce}),F.addEventListener("load",function(){R.loading|=1}),F.addEventListener("error",function(){R.loading|=2}),R.loading|=4,au(j,n,c)}j={type:"stylesheet",instance:j,count:1,state:R},h.set(f,j)}}}function QS(s,n){mr.X(s,n);var i=Do;if(i&&s){var c=Tt(i).hoistableScripts,h=Mo(s),f=c.get(h);f||(f=i.querySelector(ec(h)),f||(s=y({src:s,async:!0},n),(n=en.get(h))&&Bp(s,n),f=i.createElement("script"),bt(f),ra(f,"link",s),i.head.appendChild(f)),f={type:"script",instance:f,count:1,state:null},c.set(h,f))}}function e4(s,n){mr.M(s,n);var i=Do;if(i&&s){var c=Tt(i).hoistableScripts,h=Mo(s),f=c.get(h);f||(f=i.querySelector(ec(h)),f||(s=y({src:s,async:!0,type:"module"},n),(n=en.get(h))&&Bp(s,n),f=i.createElement("script"),bt(f),ra(f,"link",s),i.head.appendChild(f)),f={type:"script",instance:f,count:1,state:null},c.set(h,f))}}function Dv(s,n,i,c){var h=(h=We.current)?su(h):null;if(!h)throw Error(o(446));switch(s){case"meta":case"title":return null;case"style":return typeof i.precedence=="string"&&typeof i.href=="string"?(n=Oo(i.href),i=Tt(h).hoistableStyles,c=i.get(n),c||(c={type:"style",instance:null,count:0,state:null},i.set(n,c)),c):{type:"void",instance:null,count:0,state:null};case"link":if(i.rel==="stylesheet"&&typeof i.href=="string"&&typeof i.precedence=="string"){s=Oo(i.href);var f=Tt(h).hoistableStyles,j=f.get(s);if(j||(h=h.ownerDocument||h,j={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},f.set(s,j),(f=h.querySelector(Ql(s)))&&!f._p&&(j.instance=f,j.state.loading=5),en.has(s)||(i={rel:"preload",as:"style",href:i.href,crossOrigin:i.crossOrigin,integrity:i.integrity,media:i.media,hrefLang:i.hrefLang,referrerPolicy:i.referrerPolicy},en.set(s,i),f||t4(h,s,i,j.state))),n&&c===null)throw Error(o(528,""));return j}if(n&&c!==null)throw Error(o(529,""));return null;case"script":return n=i.async,i=i.src,typeof i=="string"&&n&&typeof n!="function"&&typeof n!="symbol"?(n=Mo(i),i=Tt(h).hoistableScripts,c=i.get(n),c||(c={type:"script",instance:null,count:0,state:null},i.set(n,c)),c):{type:"void",instance:null,count:0,state:null};default:throw Error(o(444,s))}}function Oo(s){return'href="'+ta(s)+'"'}function Ql(s){return'link[rel="stylesheet"]['+s+"]"}function Ov(s){return y({},s,{"data-precedence":s.precedence,precedence:null})}function t4(s,n,i,c){s.querySelector('link[rel="preload"][as="style"]['+n+"]")?c.loading=1:(n=s.createElement("link"),c.preload=n,n.addEventListener("load",function(){return c.loading|=1}),n.addEventListener("error",function(){return c.loading|=2}),ra(n,"link",i),bt(n),s.head.appendChild(n))}function Mo(s){return'[src="'+ta(s)+'"]'}function ec(s){return"script[async]"+s}function Mv(s,n,i){if(n.count++,n.instance===null)switch(n.type){case"style":var c=s.querySelector('style[data-href~="'+ta(i.href)+'"]');if(c)return n.instance=c,bt(c),c;var h=y({},i,{"data-href":i.href,"data-precedence":i.precedence,href:null,precedence:null});return c=(s.ownerDocument||s).createElement("style"),bt(c),ra(c,"style",h),au(c,i.precedence,s),n.instance=c;case"stylesheet":h=Oo(i.href);var f=s.querySelector(Ql(h));if(f)return n.state.loading|=4,n.instance=f,bt(f),f;c=Ov(i),(h=en.get(h))&&Ip(c,h),f=(s.ownerDocument||s).createElement("link"),bt(f);var j=f;return j._p=new Promise(function(R,F){j.onload=R,j.onerror=F}),ra(f,"link",c),n.state.loading|=4,au(f,i.precedence,s),n.instance=f;case"script":return f=Mo(i.src),(h=s.querySelector(ec(f)))?(n.instance=h,bt(h),h):(c=i,(h=en.get(f))&&(c=y({},i),Bp(c,h)),s=s.ownerDocument||s,h=s.createElement("script"),bt(h),ra(h,"link",c),s.head.appendChild(h),n.instance=h);case"void":return null;default:throw Error(o(443,n.type))}else n.type==="stylesheet"&&(n.state.loading&4)===0&&(c=n.instance,n.state.loading|=4,au(c,i.precedence,s));return n.instance}function au(s,n,i){for(var c=i.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),h=c.length?c[c.length-1]:null,f=h,j=0;j<c.length;j++){var R=c[j];if(R.dataset.precedence===n)f=R;else if(f!==h)break}f?f.parentNode.insertBefore(s,f.nextSibling):(n=i.nodeType===9?i.head:i,n.insertBefore(s,n.firstChild))}function Ip(s,n){s.crossOrigin==null&&(s.crossOrigin=n.crossOrigin),s.referrerPolicy==null&&(s.referrerPolicy=n.referrerPolicy),s.title==null&&(s.title=n.title)}function Bp(s,n){s.crossOrigin==null&&(s.crossOrigin=n.crossOrigin),s.referrerPolicy==null&&(s.referrerPolicy=n.referrerPolicy),s.integrity==null&&(s.integrity=n.integrity)}var nu=null;function Uv(s,n,i){if(nu===null){var c=new Map,h=nu=new Map;h.set(i,c)}else h=nu,c=h.get(i),c||(c=new Map,h.set(i,c));if(c.has(s))return c;for(c.set(s,null),i=i.getElementsByTagName(s),h=0;h<i.length;h++){var f=i[h];if(!(f[wt]||f[Ee]||s==="link"&&f.getAttribute("rel")==="stylesheet")&&f.namespaceURI!=="http://www.w3.org/2000/svg"){var j=f.getAttribute(n)||"";j=s+j;var R=c.get(j);R?R.push(f):c.set(j,[f])}}return c}function Pv(s,n,i){s=s.ownerDocument||s,s.head.insertBefore(i,n==="title"?s.querySelector("head > title"):null)}function s4(s,n,i){if(i===1||n.itemProp!=null)return!1;switch(s){case"meta":case"title":return!0;case"style":if(typeof n.precedence!="string"||typeof n.href!="string"||n.href==="")break;return!0;case"link":if(typeof n.rel!="string"||typeof n.href!="string"||n.href===""||n.onLoad||n.onError)break;switch(n.rel){case"stylesheet":return s=n.disabled,typeof n.precedence=="string"&&s==null;default:return!0}case"script":if(n.async&&typeof n.async!="function"&&typeof n.async!="symbol"&&!n.onLoad&&!n.onError&&n.src&&typeof n.src=="string")return!0}return!1}function Kv(s){return!(s.type==="stylesheet"&&(s.state.loading&3)===0)}function a4(s,n,i,c){if(i.type==="stylesheet"&&(typeof c.media!="string"||matchMedia(c.media).matches!==!1)&&(i.state.loading&4)===0){if(i.instance===null){var h=Oo(c.href),f=n.querySelector(Ql(h));if(f){n=f._p,n!==null&&typeof n=="object"&&typeof n.then=="function"&&(s.count++,s=ru.bind(s),n.then(s,s)),i.state.loading|=4,i.instance=f,bt(f);return}f=n.ownerDocument||n,c=Ov(c),(h=en.get(h))&&Ip(c,h),f=f.createElement("link"),bt(f);var j=f;j._p=new Promise(function(R,F){j.onload=R,j.onerror=F}),ra(f,"link",c),i.instance=f}s.stylesheets===null&&(s.stylesheets=new Map),s.stylesheets.set(i,n),(n=i.state.preload)&&(i.state.loading&3)===0&&(s.count++,i=ru.bind(s),n.addEventListener("load",i),n.addEventListener("error",i))}}var $p=0;function n4(s,n){return s.stylesheets&&s.count===0&&ou(s,s.stylesheets),0<s.count||0<s.imgCount?function(i){var c=setTimeout(function(){if(s.stylesheets&&ou(s,s.stylesheets),s.unsuspend){var f=s.unsuspend;s.unsuspend=null,f()}},6e4+n);0<s.imgBytes&&$p===0&&($p=62500*US());var h=setTimeout(function(){if(s.waitingForImages=!1,s.count===0&&(s.stylesheets&&ou(s,s.stylesheets),s.unsuspend)){var f=s.unsuspend;s.unsuspend=null,f()}},(s.imgBytes>$p?50:800)+n);return s.unsuspend=i,function(){s.unsuspend=null,clearTimeout(c),clearTimeout(h)}}:null}function ru(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)ou(this,this.stylesheets);else if(this.unsuspend){var s=this.unsuspend;this.unsuspend=null,s()}}}var iu=null;function ou(s,n){s.stylesheets=null,s.unsuspend!==null&&(s.count++,iu=new Map,n.forEach(r4,s),iu=null,ru.call(s))}function r4(s,n){if(!(n.state.loading&4)){var i=iu.get(s);if(i)var c=i.get(null);else{i=new Map,iu.set(s,i);for(var h=s.querySelectorAll("link[data-precedence],style[data-precedence]"),f=0;f<h.length;f++){var j=h[f];(j.nodeName==="LINK"||j.getAttribute("media")!=="not all")&&(i.set(j.dataset.precedence,j),c=j)}c&&i.set(null,c)}h=n.instance,j=h.getAttribute("data-precedence"),f=i.get(j)||c,f===c&&i.set(null,h),i.set(j,h),this.count++,c=ru.bind(this),h.addEventListener("load",c),h.addEventListener("error",c),f?f.parentNode.insertBefore(h,f.nextSibling):(s=s.nodeType===9?s.head:s,s.insertBefore(h,s.firstChild)),n.state.loading|=4}}var tc={$$typeof:M,Provider:null,Consumer:null,_currentValue:L,_currentValue2:L,_threadCount:0};function i4(s,n,i,c,h,f,j,R,F){this.tag=1,this.containerInfo=s,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=Is(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Is(0),this.hiddenUpdates=Is(null),this.identifierPrefix=c,this.onUncaughtError=h,this.onCaughtError=f,this.onRecoverableError=j,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=F,this.incompleteTransitions=new Map}function Iv(s,n,i,c,h,f,j,R,F,ne,ce,pe){return s=new i4(s,n,i,j,F,ne,ce,pe,R),n=1,f===!0&&(n|=24),f=Oa(3,null,null,n),s.current=f,f.stateNode=s,n=wh(),n.refCount++,s.pooledCache=n,n.refCount++,f.memoizedState={element:c,isDehydrated:i,cache:n},kh(f),s}function Bv(s){return s?(s=po,s):po}function $v(s,n,i,c,h,f){h=Bv(h),c.context===null?c.context=h:c.pendingContext=h,c=Or(n),c.payload={element:i},f=f===void 0?null:f,f!==null&&(c.callback=f),i=Mr(s,c,n),i!==null&&(Ta(i,s,n),_l(i,s,n))}function Vv(s,n){if(s=s.memoizedState,s!==null&&s.dehydrated!==null){var i=s.retryLane;s.retryLane=i!==0&&i<n?i:n}}function Vp(s,n){Vv(s,n),(s=s.alternate)&&Vv(s,n)}function Fv(s){if(s.tag===13||s.tag===31){var n=Ai(s,67108864);n!==null&&Ta(n,s,67108864),Vp(s,67108864)}}function Wv(s){if(s.tag===13||s.tag===31){var n=Ia();n=G(n);var i=Ai(s,n);i!==null&&Ta(i,s,n),Vp(s,n)}}var lu=!0;function o4(s,n,i,c){var h=k.T;k.T=null;var f=K.p;try{K.p=2,Fp(s,n,i,c)}finally{K.p=f,k.T=h}}function l4(s,n,i,c){var h=k.T;k.T=null;var f=K.p;try{K.p=8,Fp(s,n,i,c)}finally{K.p=f,k.T=h}}function Fp(s,n,i,c){if(lu){var h=Wp(c);if(h===null)zp(s,n,c,cu,i),Yv(s,c);else if(d4(h,s,n,i,c))c.stopPropagation();else if(Yv(s,c),n&4&&-1<c4.indexOf(s)){for(;h!==null;){var f=nt(h);if(f!==null)switch(f.tag){case 3:if(f=f.stateNode,f.current.memoizedState.isDehydrated){var j=_t(f.pen
vendor: 7,061 bytes, line 26
26dingLanes);if(j!==0){var R=f;for(R.pendingLanes|=2,R.entangledLanes|=2;j;){var F=1<<31-De(j);R.entanglements[1]|=F,j&=~F}Ln(f),($t&6)===0&&(Fd=Mt()+500,Gl(0))}}break;case 31:case 13:R=Ai(f,2),R!==null&&Ta(R,f,2),qd(),Vp(f,2)}if(f=Wp(c),f===null&&zp(s,n,c,cu,i),f===h)break;h=f}h!==null&&c.stopPropagation()}else zp(s,n,c,null,i)}}function Wp(s){return s=Pe(s),qp(s)}var cu=null;function qp(s){if(cu=null,s=Gt(s),s!==null){var n=d(s);if(n===null)s=null;else{var i=n.tag;if(i===13){if(s=u(n),s!==null)return s;s=null}else if(i===31){if(s=m(n),s!==null)return s;s=null}else if(i===3){if(n.stateNode.current.memoizedState.isDehydrated)return n.tag===3?n.stateNode.containerInfo:null;s=null}else n!==s&&(s=null)}}return cu=s,null}function qv(s){switch(s){case"beforetoggle":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"toggle":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 2;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"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 8;case"message":switch(jt()){case ps:return 2;case Wt:return 8;case ws:case os:return 32;case qt:return 268435456;default:return 32}default:return 32}}var Yp=!1,Yr=null,Gr=null,Zr=null,sc=new Map,ac=new Map,Jr=[],c4="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".split(" ");function Yv(s,n){switch(s){case"focusin":case"focusout":Yr=null;break;case"dragenter":case"dragleave":Gr=null;break;case"mouseover":case"mouseout":Zr=null;break;case"pointerover":case"pointerout":sc.delete(n.pointerId);break;case"gotpointercapture":case"lostpointercapture":ac.delete(n.pointerId)}}function nc(s,n,i,c,h,f){return s===null||s.nativeEvent!==f?(s={blockedOn:n,domEventName:i,eventSystemFlags:c,nativeEvent:f,targetContainers:[h]},n!==null&&(n=nt(n),n!==null&&Fv(n)),s):(s.eventSystemFlags|=c,n=s.targetContainers,h!==null&&n.indexOf(h)===-1&&n.push(h),s)}function d4(s,n,i,c,h){switch(n){case"focusin":return Yr=nc(Yr,s,n,i,c,h),!0;case"dragenter":return Gr=nc(Gr,s,n,i,c,h),!0;case"mouseover":return Zr=nc(Zr,s,n,i,c,h),!0;case"pointerover":var f=h.pointerId;return sc.set(f,nc(sc.get(f)||null,s,n,i,c,h)),!0;case"gotpointercapture":return f=h.pointerId,ac.set(f,nc(ac.get(f)||null,s,n,i,c,h)),!0}return!1}function Gv(s){var n=Gt(s.target);if(n!==null){var i=d(n);if(i!==null){if(n=i.tag,n===13){if(n=u(i),n!==null){s.blockedOn=n,xe(s.priority,function(){Wv(i)});return}}else if(n===31){if(n=m(i),n!==null){s.blockedOn=n,xe(s.priority,function(){Wv(i)});return}}else if(n===3&&i.stateNode.current.memoizedState.isDehydrated){s.blockedOn=i.tag===3?i.stateNode.containerInfo:null;return}}}s.blockedOn=null}function du(s){if(s.blockedOn!==null)return!1;for(var n=s.targetContainers;0<n.length;){var i=Wp(s.nativeEvent);if(i===null){i=s.nativeEvent;var c=new i.constructor(i.type,i);Ne=c,i.target.dispatchEvent(c),Ne=null}else return n=nt(i),n!==null&&Fv(n),s.blockedOn=i,!1;n.shift()}return!0}function Zv(s,n,i){du(s)&&i.delete(n)}function u4(){Yp=!1,Yr!==null&&du(Yr)&&(Yr=null),Gr!==null&&du(Gr)&&(Gr=null),Zr!==null&&du(Zr)&&(Zr=null),sc.forEach(Zv),ac.forEach(Zv)}function uu(s,n){s.blockedOn===n&&(s.blockedOn=null,Yp||(Yp=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,u4)))}var mu=null;function Jv(s){mu!==s&&(mu=s,t.unstable_scheduleCallback(t.unstable_NormalPriority,function(){mu===s&&(mu=null);for(var n=0;n<s.length;n+=3){var i=s[n],c=s[n+1],h=s[n+2];if(typeof c!="function"){if(qp(c||i)===null)continue;break}var f=nt(i);f!==null&&(s.splice(n,3),n-=3,Wh(f,{pending:!0,data:h,method:i.method,action:c},c,h))}}))}function Uo(s){function n(F){return uu(F,s)}Yr!==null&&uu(Yr,s),Gr!==null&&uu(Gr,s),Zr!==null&&uu(Zr,s),sc.forEach(n),ac.forEach(n);for(var i=0;i<Jr.length;i++){var c=Jr[i];c.blockedOn===s&&(c.blockedOn=null)}for(;0<Jr.length&&(i=Jr[0],i.blockedOn===null);)Gv(i),i.blockedOn===null&&Jr.shift();if(i=(s.ownerDocument||s).$$reactFormReplay,i!=null)for(c=0;c<i.length;c+=3){var h=i[c],f=i[c+1],j=h[He]||null;if(typeof f=="function")j||Jv(i);else if(j){var R=null;if(f&&f.hasAttribute("formAction")){if(h=f,j=f[He]||null)R=j.formAction;else if(qp(h)!==null)continue}else R=j.action;typeof R=="function"?i[c+1]=R:(i.splice(c,3),c-=3),Jv(i)}}}function Xv(){function s(f){f.canIntercept&&f.info==="react-transition"&&f.intercept({handler:function(){return new Promise(function(j){return h=j})},focusReset:"manual",scroll:"manual"})}function n(){h!==null&&(h(),h=null),c||setTimeout(i,20)}function i(){if(!c&&!navigation.transition){var f=navigation.currentEntry;f&&f.url!=null&&navigation.navigate(f.url,{state:f.getState(),info:"react-transition",history:"replace"})}}if(typeof navigation=="object"){var c=!1,h=null;return navigation.addEventListener("navigate",s),navigation.addEventListener("navigatesuccess",n),navigation.addEventListener("navigateerror",n),setTimeout(i,100),function(){c=!0,navigation.removeEventListener("navigate",s),navigation.removeEventListener("navigatesuccess",n),navigation.removeEventListener("navigateerror",n),h!==null&&(h(),h=null)}}}function Gp(s){this._internalRoot=s}hu.prototype.render=Gp.prototype.render=function(s){var n=this._internalRoot;if(n===null)throw Error(o(409));var i=n.current,c=Ia();$v(i,c,s,n,null,null)},hu.prototype.unmount=Gp.prototype.unmount=function(){var s=this._internalRoot;if(s!==null){this._internalRoot=null;var n=s.containerInfo;$v(s.current,2,null,s,null,null),qd(),n[ke]=null}};function hu(s){this._internalRoot=s}hu.prototype.unstable_scheduleHydration=function(s){if(s){var n=fe();s={blockedOn:null,target:s,priority:n};for(var i=0;i<Jr.length&&n!==0&&n<Jr[i].priority;i++);Jr.splice(i,0,s),i===0&&Gv(s)}};var Qv=a.version;if(Qv!=="19.2.8")throw Error(o(527,Qv,"19.2.8"));K.findDOMNode=function(s){var n=s._reactInternals;if(n===void 0)throw typeof s.render=="function"?Error(o(188)):(s=Object.keys(s).join(","),Error(o(268,s)));return s=x(n),s=s!==null?b(s):null,s=s===null?null:s.stateNode,s};var m4={bundleType:0,version:"19.2.8",rendererPackageName:"react-dom",currentDispatcherRef:k,reconcilerVersion:"19.2.8"};
26if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var pu=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!pu.isDisabled&&pu.supportsFiber)try{et=pu.inject(m4),Xe=pu}catch{}}return rc.createRoot=function(s,n){if(!l(s))throw Error(o(299));var i=!1,c="",h=iy,f=oy,j=ly;return n!=null&&(n.unstable_strictMode===!0&&(i=!0),n.identifierPrefix!==void 0&&(c=n.identifierPrefix),n.onUncaughtError!==void 0&&(h=n.onUncaughtError),n.onCaughtError!==void 0&&(f=n.onCaughtError),n.onRecoverableError!==void 0&&(j=n.onRecoverableError)),n=Iv(s,1,!1,null,null,i,c,null,h,f,j,Xv),s[ke]=n.current,Hp(s),new Gp(n)},rc.hydrateRoot=function(s,n,i){if(!l(s))throw Error(o(299));var c=!1,h="",f=iy,j=oy,R=ly,F=null;return i!=null&&(i.unstable_strictMode===!0&&(c=!0),i.identifierPrefix!==void 0&&(h=i.identifierPrefix),i.onUncaughtError!==void 0&&(f=i.onUncaughtError),i.onCaughtError!==void 0&&(j=i.onCaughtError),i.onRecoverableError!==void 0&&(R=i.onRecoverableError),i.formState!==void 0&&(F=i.formState)),n=Iv(s,1,!0,n,i??null,c,h,F,f,j,R,Xv),n.context=Bv(null),i=n.current,c=Ia(),c=G(c),h=Or(c),h.callback=null,Mr(i,h,c),i=c,n.current.lanes=i,ba(n,i),Ln(n),s[ke]=n.current,Hp(s),new hu(n)},rc.version="19.2.8",rc}var r0;function C4(){if(r0)return Zp.exports;r0=1;function t(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(t)}catch(a){console.error(a)}}return t(),Zp.exports=S4(),Zp.exports}var i0=C4();let oa=(function(t){return t.CHARSET="charset",t.CSS_TEXT="cssText",t.HREF="href",t.HTTPEQUIV="http-equiv",t.INNER_HTML="innerHTML",t.ITEM_PROP="itemprop",t.NAME="name",t.PROPERTY="property",t.REL="rel",t.SRC="src",t.TARGET="target",t})({}),is=(function(t){return t.BASE="base",t.BODY="body",t.FRAGMENT="Symbol(react.fragment)",t.HEAD="head",t.HTML="html",t.LINK="link",t.META="meta",t.NOSCRIPT="noscript",t.SCRIPT="script",t.STYLE="style",t.TITLE="title",t})({});const Qp={link:{rel:["amphtml","canonical","alternate"]},meta:{charset:"",name:["generator","robots","description"],property:["og:type","og:title","og:url","og:image","og:image:alt","og:description","twitter:url","twitter:title","twitter:description","twitter:image","twitter:image:alt","twitter:card","twitter:site"]},script:{type:["application/ld+json"]}},o0=Object.values(is),Vx={accesskey:"accessKey",charset:"charSet",class:"className",contenteditable:"contentEditable",contextmenu:"contextMenu","http-equiv":"httpEquiv",itemprop:"itemProp",tabindex:"tabIndex"},Tc=(()=>{const t={};for(const[a,r]of Object.entries(Vx))t[r]=a;return t})(),wr="data-rh",k4=!!(typeof window<"u"&&window.document.createElement);function Jo(t,a){for(let r=t.length-1;r>=0;--r){const o=t[r][1][a];if(o!==void 0)return o}}function T4(t){let a=Jo(t,is.TITLE);const r=Jo(t,"titleTemplate");if(Array.isArray(a)&&(a=a.join("")),r&&a)return r.replace(/%s/g,()=>a);const o=Jo(t,"defaultTitle");return(a||o)??void 0}function ef(t,a){const r={};for(const o of a){const l=o[1][t];l&&Object.assign(r,l)}return r}function A4(t){for(let a=t.length-1;a>=0;--a){const r=t[a][1].base;if(r!=null&&r.href||r!=null&&r.target)return r}}function E4(t,a){let r;for(const o of Object.keys(t)){const l=o;a.includes(l)&&!(r===oa.REL&&t[r].toLowerCase()==="canonical")&&!(l===oa.REL&&t[l].toLowerCase()==="stylesheet")&&(r=l),a.includes(l)&&(l===oa.INNER_HTML||l===oa.CSS_TEXT||l===oa.ITEM_PROP)&&(r=l)}return r??null}function ic(t,a,r){const o={};return r.map(([,l])=>l).filter(l=>Array.isArray(l[t])?!0:(typeof l[t]<"u"&&console.warn(`Helmet: ${t} should be of type "Array". Instead found type "${typeof l[t]}"`),!1)).map(l=>l[t]).reverse().reduce((l,d)=>{const u={};d.filter(p=>{const x=E4(p,a);if(!x||!p[x])return!1;const b=p[x].toLowerCase();return o[x]||(o[x]={}),u[x]||(u[x]={}),o[x][b]?!1:(u[x][b]=!0,!0)}).reverse().forEach(p=>{l.push(p)});const m=Object.keys(u);for(const p of m){const x={...o[p],...u[p]};o[p]=x}return l},[]).reverse()}function H4(t,a){for(const[,r]of t)if(r[a])return!0;return!1}function h1(t){return Array.isArray(t)?t.join(""):t}function z4(t,a){var r;for(const o of Object.keys(t))if((r=a[o])!=null&&r.includes(t[o]))return!0;return!1}function tf(t,a){const r={default:Array(),priority:Array()};if(t)for(const o of t)z4(o,a)?r.priority.push(o):r.default.push(o);return r}function R4(t){const a={};for(const[r,o]of Object.entries(t))a[r]=Array.isArray(o)?o.slice():o;return a}function _4(t,a){const r=t;for(const[o,l]of Object.entries(a))if(Array.isArray(l)){const d=r[o];r[o]=d?d.concat(l):l}else r[o]=l}function sf(t,a,r){const o=t[a];o?o.push(r):t[a]=[r]}function Pf(t){let a=ic(is.LINK,[oa.REL,oa.HREF],t),r=ic("meta",[oa.NAME,"charSet","httpEquiv",oa.PROPERTY,"itemProp"],t),o=ic("script",[oa.SRC,oa.INNER_HTML],t);const l=H4(t,"prioritizeSeoTags");let d;if(l){const u=tf(a,Qp.link);a=u.default;const m=tf(r,Qp.meta);r=m.default;const p=tf(o,Qp.script);o=p.default,d={links:u.priority,meta:m.priority,script:p.priority}}return{base:A4(t),bodyAttributes:ef("bodyAttributes",t),defer:Jo(t,"defer"),encodeSpecialCharacters:Jo(t,"encodeSpecialCharacters")??!0,htmlAttributes:ef("htmlAttributes",t),links:a,meta:r,noscript:ic("noscript",[oa.INNER_HTML],t),onChangeClientState:Jo(t,"onChangeClientState"),priority:d,script:o,style:ic("style",[oa.CSS_TEXT],t),title:T4(t),titleAttributes:ef("titleAttributes",t)}}function L4(t){return Tc[t]??t}function Ko(t,a){const r=document.head||document.querySelector(is.HEAD),o=r.querySelectorAll(`${t}[${wr}]`),l=[],d=[...o],u=[];for(const m of a){const p=document.createElement(t);for(const[b,y]of Object.entries(m))if(Object.prototype.hasOwnProperty.call(m,b)){const v=Tc[b]??b;v===oa.INNER_HTML?p.innerHTML=y:v===oa.CSS_TEXT?p.styleSheet?p.styleSheet.cssText=m.cssText:p.appendChild(document.createTextNode(m.cssText)):p.setAttribute(v,y??"")}p.setAttribute(wr,"true");const x={};for(const{name:b,value:y}of p.attributes)x[b]=y;l.push(x);for(let b=0;;++b){if(p.isEqualNode(d[b])){d.splice(b,1);break}if(b>=d.length){u.push(p);break}}}return d.forEach(m=>{var p;(p=m.parentNode)==null||p.removeChild(m)}),u.forEach(m=>{r.appendChild(m)}),{allTags:l,newTags:u,oldTags:d}}function Kf(t,a){const[r]=document.getElementsByTagName(t);if(!r)return;const o=r.getAttribute(wr),l=o?o.split(","):[],d=[...l],u=[];for(const m of Object.keys(a))u.push(Tc[m]??m);for(const[m,p]of Object.entries(a)){const x=Tc[m]??m;r.getAttribute(x)!==p&&r.setAttribute(x,p??""),l.includes(x)||l.push(x);const b=d.indexOf(x);b!==-1&&d.splice(b,1)}for(let m=d.length-1;m>=0;m-=1)r.removeAttribute(d[m]);l.length===d.length?r.removeAttribute(wr):r.getAttribute(wr)!==u.join(",")&&r.setAttribute(wr,u.join(","))}function D4(t,a){t!==void 0&&document.title!==t&&(document.title=h1(t)),Kf(is.TITLE,a)}function l0(t,a){const{base:r,bodyAttributes:o,defer:l,htmlAttributes:d,links:u,meta:m,noscript:p,onChangeClientState:x,priority:b,script:y,style:v,title:w,titleAttributes:C}=t;Kf(is.BODY,o??{}),Kf(is.HTML,d??{}),D4(w,C);const A={baseTag:Ko(is.BASE,r?[r]:[]),linkTags:Ko(is.LINK,[...(b==null?void 0:b.links)??[],...u??[]]),metaTags:Ko(is.META,[...(b==null?void 0:b.meta)??[],...m??[]]),noscriptTags:Ko(is.NOSCRIPT,p??[]),scriptTags:Ko(is.SCRIPT,[...(b==null?void 0:b.script)??[],...y??[]]),styleTags:Ko(is.STYLE,v??[])},S={baseTag:[],bodyAttributes:{},defer:l??!1,htmlAttributes:{},linkTags:[],metaTags:[],noscriptTags:[],onChangeClientState:x??(()=>{}),scriptTags:[],styleTags:[],title:w??"",titleAttributes:{}},z={},T={};Object.keys(A).forEach(M=>{const{allTags:P,newTags:E,oldTags:U}=A[M];S[M]=P,E.length&&(z[M]=E),U.length&&(T[M]=A[M].oldTags)}),(a||Object.keys(z).length||Object.keys(T).length)&&(x==null||x(S,z,T))}const O4=[is.NOSCRIPT,is.SCRIPT,is.STYLE],p1=(t,a=!0)=>a?t.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#x27;"):t;function If(t){let a="";for(const[r,o]of Object.entries(t)){const l=L4(r),d=o===void 0?l:`${l}="${o}"`;d&&a&&(a+=" "),a+=d}return a}const M4=(t,a,r)=>{let o=If(a);o&&(o=` ${o}`);const l=h1(t);return`<title ${wr}="true"${o}>${p1(l,r)}</title>`};function hr(t,a,r){let o="";for(const l of a){let d="";const u=Object.entries(l);for(const[x,b]of u)if(!(x===oa.INNER_HTML||x===oa.CSS_TEXT)){const y=Tc[x]??x;let v;if(b===void 0)v=y;else{const w=typeof b=="string"?b:String(b);v=`${y}="${p1(w,r)}"`}d?d+=` ${v}`:d=v}const m=l.innerHTML??l.cssText??"",p=!O4.includes(t);o+=`<${t} ${wr}="true" ${d}${p?"/>":`>${m}</${t}>`}`}return o}function Mu(t,a={}){const r={};a.addHelmetDataAttr&&(r[wr]=!0),a.addKey!==void 0&&(r.key=a.addKey);for(const[o,l]of Object.entries(t)){const d=Vx[o]??o;switch(d){case"cssText":case"innerHTML":r.dangerouslySetInnerHTML={__html:l};break;default:r[d]=l}}return r}function U4(t,a){return[e.jsx("title",{...Mu(a,{addHelmetDataAttr:!0}),children:t},t)]}function P4(t,a,r){return g.createElement(t,Mu(a,{addHelmetDataAttr:!0,addKey:r}))}function pr(t,a){const r=[];for(let o=0;o<a.length;++o)r.push(P4(t,a[o],o));return r}function K4(t){const a=()=>(t.state??(t.state=Pf(t.helmets)),t.state);return{base:{toComponent(){const r=a().base;return r?pr("base",[r]):[]},toString(){const r=a();return r.base?hr("base",[r.base],r.encodeSpecialCharacters):""}},bodyAttributes:{toComponent(){const r=a().bodyAttributes;return Mu(r??{})},toString(){const r=a().bodyAttributes;return If(r??{})}},htmlAttributes:{toComponent(){const r=a().htmlAttributes;return Mu(r??{})},toString(){const r=a().htmlAttributes;return If(r??{})}},link:{toComponent(){return pr("link",a().links??[])},toString(){const r=a();return hr("link",r.links??[],r.encodeSpecialCharacters)}},meta:{toComponent(){return pr("meta",a().meta??[])},toString(){const r=a();return hr("meta",r.meta??[],r.encodeSpecialCharacters)}},noscript:{toComponent(){return pr("noscript",a().noscript??[])},toString(){const r=a();return hr("noscript",r.noscript??[],r.encodeSpecialCharacters)}},priority:{toComponent(){var o,l,d;const r=a();return[...pr("meta",((o=r.priority)==null?void 0:o.meta)??[]),...pr("link",((l=r.priority)==null?void 0:l.links)??[]),...pr("script",((d=r.priority)==null?void 0:d.script)??[])]},toString(){var m,p,x;const r=a(),o=hr("meta",((m=r.priority)==null?void 0:m.meta)??[],r.encodeSpecialCharacters),l=hr("link",((p=r.priority)==null?void 0:p.links)??[],r.encodeSpecialCharacters),d=hr("script",((x=r.priority)==null?void 0:x.script)??[],r.encodeSpecialCharacters);let u=o;return l&&(u&&(u+=" "),u+=l),d&&(u&&(u+=" "),u+=d),u}},script:{toComponent(){return pr("script",a().script??[])},toString(){const r=a();return hr("script",r.script??[],r.encodeSpecialCharacters)}},style:{toComponent(){return pr("style",a().style??[])},toString(){const r=a();return hr("style",r.style??[],r.encodeSpecialCharacters)}},title:{toComponent(){const r=a();return U4(r.title??"",r.titleAttributes??{})},toString(){const r=a();return M4(r.title??"",r.titleAttributes??{},r.encodeSpecialCharacters)}}}}const f1=g.createContext(void 0),I4=({children:t,context:a})=>{const{current:r}
26=g.useRef({firstRender:!0,helmets:[],state:void 0}),o=g.useRef(null);return o.current??(o.current={clientApply(){k4&&!r.state&&(r.state=Pf(r.helmets),r.state.defer?r.nextAnimFrameId??(r.nextAnimFrameId=requestAnimationFrame(()=>{r.state??(r.state=Pf(r.helmets)),l0(r.state,r.firstRender),r.firstRender=!1,delete r.nextAnimFrameId})):(r.nextAnimFrameId!==void 0&&(cancelAnimationFrame(r.nextAnimFrameId),delete r.nextAnimFrameId),l0(r.state,r.firstRender),r.firstRender=!1))},update(l,d){const u=r.helmets.findIndex(m=>m[0]===l);u>=0?(delete r.state,d?r.helmets[u][1]=d:r.helmets.splice(u,1)):d&&(delete r.state,r.helmets.push([l,d]))}}),a&&(!a.helmet||a.helmet!==r.serverState)&&(r.serverState??(r.serverState=K4(r)),a.helmet=r.serverState),e.jsx(f1,{value:o.current,children:t})};function B4(t,a){if(typeof t!="string")throw Error("You may be attempting to nest <Helmet> components within each other, which is not allowed. Refer to our API for more information.");if(!o0.includes(t))throw Error(`Only elements types ${o0.join(", ")} are allowed. Helmet does not support rendering <${t}> elements. Refer to our API for more information.`);if(!(!a||typeof a=="string"||Array.isArray(a)))throw Error(`Helmet expects a string as a child of <${t}>. Did you forget to wrap your children in braces? ( <${t}>{\`\`}</${t}> ) Refer to our API for more information.`)}function af(t){const a=Vx[t];return a&&console.warn(`"${t}" is not a valid JSX prop, replace it by "${a}"`),a??t}function Bf(t){const a=R4(t);for(const r of Object.values(t))if(Array.isArray(r)){for(const o of r)if(o)for(const l of Object.keys(o)){const d=af(l);d!==l&&(o[d]=o[l],delete o[l])}}else if(r&&typeof r=="object"){const o=r;for(const l of Object.keys(o)){const d=af(l);d!==l&&(o[d]=o[l],delete o[l])}}return g.Children.forEach(t.children,r=>{if(r==null)return;if(typeof r!="object"||!("props"in r))throw Error(`"${typeof r}" is not a valid <Helmet> descendant`);let o;const l={};if(r.props)for(const[m,p]of Object.entries(r.props))m==="children"?o=p:l[af(m)]=p;let{type:d}=r;typeof d=="symbol"&&(d=d.toString()),B4(d,o);function u(m){typeof m!="string"&&console.error(`child of ${d} element should be a string`)}switch(d){case is.BASE:a.base=l;break;case is.BODY:a.bodyAttributes=l;break;case is.FRAGMENT:_4(a,Bf({children:o}));break;case is.HTML:a.htmlAttributes=l;break;case is.LINK:case is.META:if(o)throw Error(`<${d} /> elements are self-closing and can not contain children. Refer to our API for more information.`);sf(a,d,l);break;
26case is.NOSCRIPT:case is.SCRIPT:o!==void 0&&(u(o),l.innerHTML=o),sf(a,d,l);break;case is.STYLE:u(o),l.cssText=o,sf(a,d,l);break;case is.TITLE:a.titleAttributes=l,typeof o=="string"?a.title=o:Array.isArray(o)&&(a.title=o.join(""));break;case is.HEAD:}}),delete a.children,a}const we=t=>{const a=g.use(f1);if(!a)throw Error("<Helmet> component must be within a <HelmetProvider> children tree");const r=g.useId();return a.update(r,Bf(t)),g.useEffect(()=>{a.update(r,Bf(t)),a.clientApply()}),g.useEffect(()=>()=>{a.update(r,void 0),a.clientApply()},[a,r]),null},$4="modulepreload",V4=function(t){return"/"+t},c0={},Fx=function(a,r,o){let l=Promise.resolve();if(r&&r.length>0){let u=function(x){return Promise.all(x.map(b=>Promise.resolve(b).then(y=>({status:"fulfilled",value:y}),y=>({status:"rejected",reason:y}))))};document.getElementsByTagName("link");const m=document.querySelector("meta[property=csp-nonce]"),p=(m==null?void 0:m.nonce)||(m==null?void 0:m.getAttribute("nonce"));l=u(r.map(x=>{if(x=V4(x),x in c0)return;c0[x]=!0;const b=x.endsWith(".css"),y=b?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${x}"]${y}`))return;const v=document.createElement("link");if(v.rel=b?"stylesheet":$4,b||(v.as="script"),v.crossOrigin="",v.href=x,p&&v.setAttribute("nonce",p),document.head.appendChild(v),b)return new Promise((w,C)=>{v.addEventListener("load",w),v.addEventListener("error",()=>C(new Error(`Unable to preload CSS for ${x}`)))})}))}function d(u){const m=new Event("vite:preloadError",{cancelable:!0});if(m.payload=u,window.dispatchEvent(m),!m.defaultPrevented)throw u}return l.then(u=>{for(const m of u||[])m.status==="rejected"&&d(m.reason);return a().catch(d)})};/**
27 * react-router v8.3.0
28 *
29 * Copyright (c) Remix Software Inc.
30 *
31 * This source code is licensed under the MIT license found in the
32 * LICENSE.md file in the root directory of this source tree.
33 *
34 * @license MIT
35 */const Dm=/^(?:[a-z][a-z0-9+.-]*:|[\\/]{2})/i,Wx=/^[\\/]{2}/;function x1(t,a){return a+t.replace(/\\/g,"/")}/**
36 * react-router v8.3.0
37 *
38 * Copyright (c) Remix Software Inc.
39 *
40 * This source code is licensed under the MIT license found in the
41 * LICENSE.md file in the root directory of this source tree.
42 *
43 * @license MIT
44 */const d0="popstate";function u0(t){return typeof t=="object"&&t!=null&&"pathname"in t&&"search"in t&&"hash"in t&&"state"in t&&"key"in t}function F4(t={}){function a(o,l){var x;let d=(x=l.state)==null?void 0:x.masked,{pathname:u,search:m,hash:p}=d||o.location;return Ac("",{pathname:u,search:m,hash:p},l.state&&l.state.usr||null,l.state&&l.state.key||"default",d?{pathname:o.location.pathname,search:o.location.search,hash:o.location.hash}:void 0)}function r(o,l){return typeof l=="string"?l:qn(l)}return q4(a,r,null,t)}function pt(t,a){if(t===!1||t===null||typeof t>"u")throw new Error(a)}function Fs(t,a){if(!t){typeof console<"u"&&console.warn(a);try{throw new Error(a)}catch{}}}function W4(){return Math.random().toString(36).substring(2,10)}function m0(t,a){return{usr:t.state,key:t.key,idx:a,masked:t.mask?{pathname:t.pathname,search:t.search,hash:t.hash}:void 0}}function Ac(t,a,r=null,o,l){return{pathname:typeof t=="string"?t:t.pathname,search:"",hash:"",...typeof a=="string"?Zn(a):a,state:r,key:a&&a.key||o||W4(),mask:l}}function qn({pathname:t="/",search:a="",hash:r=""}){return a&&a!=="?"&&(t+=a.charAt(0)==="?"?a:"?"+a),r&&r!=="#"&&(t+=r.charAt(0)==="#"?r:"#"+r),t}function Zn(t){let a={};if(t){let r=t.indexOf("#");r>=0&&(a.hash=t.substring(r),t=t.substring(0,r));let o=t.indexOf("?");o>=0&&(a.search=t.substring(o),t=t.substring(0,o)),t&&(a.pathname=t)}return a}function q4(t,a,r,o={}){let{window:l=document.defaultView,v5Compat:d=!1}=o,u=l.history,m="POP",p=null,x=b();x==null&&(x=0,u.replaceState({...u.state,idx:x},""));function b(){return(u.state||{idx:null}).idx}function y(){m="POP";let S=b(),z=S==null?null:S-x;x=S,p&&p({action:m,location:A.location,delta:z})}function v(S,z){m="PUSH";let T=u0(S)?S:Ac(A.location,S,z);x=b()+1;let M=m0(T,x),P=A.createHref(T.mask||T);try{u.pushState(M,"",P)}catch(E){if(E instanceof DOMException&&E.name==="DataCloneError")throw E;l.location.assign(P)}d&&p&&p({action:m,location:A.location,delta:1})}function w(S,z){m="REPLACE";let T=u0(S)?S:Ac(A.location,S,z);x=b();let M=m0(T,x),P=A.createHref(T.mask||T);u.replaceState(M,"",P),d&&p&&p({action:m,location:A.location,delta:0})}function C(S){return g1(l,S)}let A={get action(){return m},get location(){return t(l,u)},listen(S){if(p)throw new Error("A history only accepts one active listener");return l.addEventListener(d0,y),p=S,()=>{l.removeEventListener(d0,y),p=null}},createHref(S){return a(l,S)},createURL:C,encodeLocation(S){let z=C(S);return{pathname:z.pathname,search:z.search,hash:z.hash}},push:v,replace:w,go(S){return u.go(S)}};return A}function g1(t,a,r=!1){let o="http://localhost";t&&(o=t.location.origin!=="null"?t.location.origin:t.location.href),pt(o,"No window.location.(origin|href) available to create URL");
44let l=typeof a=="string"?a:qn(a);return l=l.replace(/ $/,"%20"),!r&&Wx.test(l)&&(l=o+l),new URL(l,o)}/**
45 * react-router v8.3.0
46 *
47 * Copyright (c) Remix Software Inc.
48 *
49 * This source code is licensed under the MIT license found in the
50 * LICENSE.md file in the root directory of this source tree.
51 *
52 * @license MIT
53 */var tl,gw,h0=(gw=class{constructor(t){Po(this,tl,new Map);if(t)for(let[a,r]of t)this.set(a,r)}get(t){if(Ba(this,tl).has(t))return Ba(this,tl).get(t);if(t.defaultValue!==void 0)return t.defaultValue;throw new Error("No value found for context")}set(t,a){Ba(this,tl).set(t,a)}},tl=new WeakMap,gw);const Y4=new Set(["lazy","caseSensitive","path","id","index","children"]);function G4(t){return Y4.has(t)}const Z4=new Set(["lazy","caseSensitive","path","id","index","middleware","children"]);function J4(t){return Z4.has(t)}function X4(t){return t.index===!0}function b1(t){let a={};return t.Component&&Object.assign(a,{element:g.createElement(t.Component),Component:void 0}),t.HydrateFallback&&Object.assign(a,{hydrateFallbackElement:g.createElement(t.HydrateFallback),HydrateFallback:void 0}),t.ErrorBoundary&&Object.assign(a,{errorElement:g.createElement(t.ErrorBoundary),ErrorBoundary:void 0}),a}function Ec(t,a=b1,r=[],o={},l=!1){return t.map((d,u)=>{let m=[...r,String(u)],p=typeof d.id=="string"?d.id:m.join("-");if(pt(d.index!==!0||!d.children,"Cannot specify children on an index route"),pt(l||!o[p],`Found a route id collision on i
53d "${p}".  Route id's must be globally unique within Data Router usages`),X4(d)){let x={...d,id:p};return o[p]=p0(x,a(x)),x}else{let x={...d,id:p,children:void 0};return o[p]=p0(x,a(x)),d.children&&(x.children=Ec(d.children,a,m,o,l)),x}})}function p0(t,a){return Object.assign(t,{...a,...typeof a.lazy=="object"&&a.lazy!=null?{lazy:{...t.lazy,...a.lazy}}:{}})}function y1(t,a,r="/"){return jn(t,a,r,!1)}function jn(t,a,r,o,l){let d=on((typeof a=="string"?Zn(a):a).pathname||"/",r);if(d==null)return null;let u=l??Au(t),m=null,p=u5(d);for(let x=0;m==null&&x<u.length;++x)m=d5(u[x],p,o);return m}function v1(t,a){let{route:r,pathname:o,params:l}=t;return{id:r.id,pathname:o,params:l,loaderData:a[r.id],handle:r.handle}}function Au(t){let a=j1(t);return Q4(a),a}function j1(t,a=[],r=[],o="",l=!1){let d=(u,m,p=l,x)=>{let b={relativePath:x===void 0?u.path||"":x,caseSensitive:u.caseSensitive===!0,childrenIndex:m,route:u};if(b.relativePath.startsWith("/")){if(!b.relativePath.startsWith(o)&&p)return;pt(b.relativePath.startsWith(o),`Absolute route path "${b.relativePath}" nested under path "${o}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),b.relativePath=b.relativePath.slice(o.length)}let y=rn([o,b.relativePath]),v=r.concat(b);u.children&&u.children.length>0&&(pt(u.index!==!0,`Index routes must not have child routes. Please remove all child routes from route path "${y}".`),j1(u.children,a,v,y,p)),!(u.path==null&&!u.index)&&a.push({path:y,score:l5(y,u.index),routesMeta:v.map((w,C)=>{let[A,S]=S1(w.relativePath,w.caseSensitive,C===v.length-1);return{...w,matcher:A,compiledParams:S}})})};return t.forEach((u,m)=>{var p;if(u.path===""||!((p=u.path)!=null&&p.includes("?")))d(u,m);else for(let x of w1(u.path))d(u,m,!0,x)}),a}function w1(t){let a=t.split("/");if(a.length===0)return[];let[r,...o]=a,l=r.endsWith("?"),d=r.replace(/\?$/,"");if(o.length===0)return l?[d,""]:[d];let u=w1(o.join("/")),m=[];return m.push(...u.map(p=>p===""?d:[d,p].join("/"))),l&&m.push(...u),m.map(p=>t.startsWith("/")&&p===""?"/":p)}function Q4(t){t.sort((a,r)=>a.score!==r.score?r.score-a.score:c5(a.routesMeta.map(o=>o.childrenIndex),r.routesMeta.map(o=>o.childrenIndex)))}const e5=/^:[\w-]+$/,t5=/^:[\w-]+/,s5=3.5,a5=3,n5=2,r5=1,i5=10,o5=-2,f0=t=>t==="*";function l5(t,a){let r=t.split("/"),o=r.length;return r.some(f0)&&(o+=o5),a&&(o+=n5),r.filter(l=>!f0(l)).reduce((l,d)=>l+(e5.test(d)?a5:t5.test(d)?s5:d===""?r5:i5),o)}function c5(t,a){return t.length===a.length&&t.slice(0,-1).every((r,o)=>r===a[o])?t[t.length-1]-a[a.length-1]:0}function d5(t,a,r=!1){let{routesMeta:o}=t,l={},d="/",u=[];for(let m=0;m<o.length;++m){let p=o[m],x=m===o.length-1,b=d==="/"?a:a.slice(d.length)||"/",y={path:p.relativePath,caseSensitive:p.caseSensitive,end:x},v=p.matcher&&p.compiledParams?N1(y,b,p.matcher,p.compiledParams):Uu(y,b),w=p.route;if(!v&&x&&r&&!o[o.length-1].route.index&&(v=Uu({path:p.relativePath,caseSensitive:p.caseSensitive,end:!1},b)),!v)return null;
53Object.assign(l,v.params),u.push({params:l,pathname:rn([d,v.pathname]),pathnameBase:p5(rn([d,v.pathnameBase])),route:w}),v.pathnameBase!=="/"&&(d=rn([d,v.pathnameBase]))}return u}function Uu(t,a){typeof t=="string"&&(t={path:t,caseSensitive:!1,end:!0});let[r,o]=S1(t.path,t.caseSensitive,t.end);return N1(t,a,r,o)}function N1(t,a,r,o){let l=a.match(r);if(!l)return null;let d=l[0],u=d.replace(/(.)\/+$/,"$1"),m=l.slice(1);return{params:o.reduce((p,{paramName:x,isOptional:b},y)=>{if(x==="*"){let w=m[y]||"";u=d.slice(0,d.length-w.length).replace(/(.)\/+$/,"$1")}const v=m[y];return b&&!v?p[x]=void 0:p[x]=(v||"").replace(/%2F/g,"/"),p},{}),pathname:d,pathnameBase:u,pattern:t}}function S1(t,a=!1,r=!0){Fs(t==="*"||!t.endsWith("*")||t.endsWith("/*"),`Route path "${t}" will be treated as if it were "${t.replace(/\*$/,"/*")}" because the \`*\` character must always follow a \`/\` in the pattern. To get rid of this warning, please change the route path to "${t.replace(/\*$/,"/*")}".`);let o=[],l="^"+t.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(d,u,m,p,x)=>{if(o.push({paramName:u,isOptional:m!=null}),m){let b=x.charAt(p+d.length);return b&&b!=="/"?"/([^\\/]*)":"(?:/([^\\/]*))?"}return"/([^\\/]+)"}).replace(/\/([\w-]+)\?(?=\/|$|\()/g,"(?:/$1)?");return t.endsWith("*")?(o.push({paramName:"*"}),l+=t==="*"||t==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):r?l+="\\/*$":t!==""&&t!=="/"&&(l+="(?:(?=\\/|$))"),[new RegExp(l,a?void 0:"i"),o]}function u5(t){try{return t.split("/").map(a=>decodeURIComponent(a).replace(/\//g,"%2F")).join("/")}catch(a){return Fs(!1,`The URL path "${t}" could not be decoded because it is a malformed URL segment. This is probably due to a bad percent encoding (${a}).`),t}}function on(t,a){if(a==="/")return t;if(!t.toLowerCase().startsWith(a.toLowerCase()))return null;let r=a.endsWith("/")?a.length-1:a.length,o=t.charAt(r);return o&&o!=="/"?null:t.slice(r)||"/"}function m5({basename:t,pathname:a}){return a==="/"?t:rn([t,a])}const qx=t=>Dm.test(t);function h5(t,a="/"){let{pathname:r,search:o="",hash:l=""}=typeof t=="string"?Zn(t):t,d;return r?(r=Yx(r),r.startsWith("/")?d=x0(r.substring(1),"/"):d=x0(r,a)):d=a,{pathname:d,search:f5(o),hash:x5(l)}}function x0(t,a){let r=k1(a).split("/");return t.split("/").forEach(o=>{o===".."?r.length>1&&r.pop():o!=="."&&r.push(o)}),r.length>1?r.join("/"):"/"}function nf(t,a,r,o){return`Cannot include a '${t}' character in a manually specified \`to.${a}\` field [${JSON.stringify(o)}].  Please separate it out to the \`to.${r}\` field. Alternatively you may provide the full path as a string in <Link to="..."> and the router will parse it for you.`}function C1(t){return t.filter((a,r)=>r===0||a.route.path&&a.route.path.length>0)}function Om(t){let a=C1(t);return a.map((r,o)=>o===a.length-1?r.pathname:r.pathnameBase)}function qc(t,a,r,o=!1){let l;typeof t=="string"?l=Zn(t):(l={...t},pt(!l.pathname||!l.pathname.includes("?"),nf("?","pathname","search",l)),pt(!l.pathname||!l.pathname.includes("#"),nf("#","pathname","hash",l)),pt(!l.search||!l.search.includes("#"),nf("#","search","hash",l)));let d=t===""||l.pathname==="",u=d?"/":l.pathname,m;if(u==null)m=r;else{let y=a.length-1;if(!o&&u.startsWith("..")){let v=u.split("/");for(;v[0]==="..";)v.shift(),y-=1;l.pathname=v.join("/")}m=y>=0?a[y]:"/"}let p=h5(l,m),x=u&&u!=="/"&&u.endsWith("/"),b=(d||u===".")&&r.endsWith("/");return!p.pathname.endsWith("/")&&(x||b)&&(p.pathname+="/"),p}const Yx=t=>t.replace(/[\\/]{2,}/g,"/"),rn=t=>Yx(t.join("/")),k1=t=>t.replace(/\/+$/,""),p5=t=>k1(t).replace(/^\/*/,"/"),f5=t=>!t||t==="?"?"":t.startsWith("?")?t:"?"+t,x5=t=>!t||t==="#"?"":t.startsWith("#")?t:"#"+t,g5=["EvalError","RangeError","ReferenceError","SyntaxError","TypeError","URIError"];var Yc=class{constructor(t,a,r,o=!1){ma(this,"status");ma(this,"statusText");ma(this,"data");ma(this,"error");ma(this,"internal");this.status=t,this.statusText=a||"",this.internal=o,r instanceof Error?(this.data=r.toString(),this.error=r):this.data=r}};function Hc(t){return t!=null&&typeof t.status=="number"&&typeof t.statusText=="string"&&typeof t.internal=="boolean"&&"data"in t}function ll(t){return rn(t.map(a=>
53a.route.path).filter(Boolean))||"/"}function Gx(t,a){let r=new URL(typeof t=="string"||t instanceof URL?t:t.url),o=typeof a=="string"?Zn(a):a;if(r.pathname=o.pathname||"/",o.search){let l=new URLSearchParams(o.search),d=l.getAll("index");l.delete("index");for(let m of d.filter(Boolean))l.append("index",m);let u=l.toString();r.search=u?`?${u}`:""}else r.search="";return r.hash=o.hash||"",r}const T1=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";function A1(t,a){let r=t;if(typeof r!="string"||!Dm.test(r))return{absoluteURL:void 0,isExternal:!1,to:r};let o=r,l=!1;if(T1)try{let d=new URL(window.location.href),u=Wx.test(r)?new URL(x1(r,d.protocol)):new URL(r),m=on(u.pathname,a);u.origin===d.origin&&m!=null?r=m+u.search+u.hash:l=!0}catch{Fs(!1,`<Link to="${r}"> contains an invalid URL which will probably break when clicked - please update to a valid URL path.`)}return{absoluteURL:o,isExternal:l,to:r}}/**
54 * react-router v8.3.0
55 *
56 * Copyright (c) Remix Software Inc.
57 *
58 * This source code is licensed under the MIT license found in the
59 * LICENSE.md file in the root directory of this source tree.
60 *
61 * @license MIT
62 */const E1=Symbol("Uninstrumented");let wc=new WeakMap;function b5(t,a){let r={lazy:[],"lazy.loader":[],"lazy.action":[],"lazy.middleware":[],middleware:[],loader:[],action:[]};t.forEach(l=>l({id:a.id,index:a.index,path:a.path,instrument(d){d.lazy!=null&&r.lazy.push(d.lazy),d["lazy.loader"]!=null&&r["lazy.loader"].push(d["lazy.loader"]),d["lazy.action"]!=null&&r["lazy.action"].push(d["lazy.action"]),d["lazy.middleware"]!=null&&r["lazy.middleware"].push(d["lazy.middleware"]),d.middleware!=null&&r.middleware.push(d.middleware),d.loader!=null&&r.loader.push(d.loader),d.action!=null&&r.action.push(d.action)}}));let o={};if(typeof a.lazy=="function"&&r.lazy.length>0){let l=a.lazy;o.lazy=async(...d)=>br(await In(r.lazy,void 0,()=>l(...d),yr))}if(typeof a.lazy=="object"){let l=a.lazy;if(typeof l.middleware=="function"&&r["lazy.middleware"].length>0){let d=l.middleware;o.lazy=Object.assign(o.lazy||{},{middleware:async(...u)=>br(await In(r["lazy.middleware"],void 0,()=>d(...u),yr))})}if(typeof l.loader=="function"&&r["lazy.loader"].length>0){let d=l.loader;o.lazy=Object.assign(o.lazy||{},{loader:async(...u)=>br(await In(r["lazy.loader"],void 0,()=>d(...u),yr))})}if(typeof l.action=="function"&&r["lazy.action"].length>0){let d=l.action;o.lazy=Object.assign(o.lazy||{},{action:async(...u)=>br(await In(r["lazy.action"],void 0,()=>d(...u),yr))})}}if(typeof a.loader=="function"&&r.loader.length>0){let l=Nc(a.loader),d=async(...u)=>br(await In(r.loader,rf(u[0]),()=>l(...u),yr));l.hydrate===!0&&(d.hydrate=!0),Sc(d,l),o.loader=d}if(typeof a.action=="function"&&r.action.length>0){let l=Nc(a.action),d=async(...u)=>br(await In(r.action,rf(u[0]),()=>l(...u),yr));Sc(d,l),o.action=d}return a.middleware&&a.middleware.length>0&&r.middleware.length>0&&(o.middleware=a.middleware.map(l=>{let d=Nc(l),u=async(...m)=>br(await In(r.middleware,rf(m[0]),()=>d(...m),yr));return Sc(u,d),u})),o}function y5(t,a){let r={navigate:[],fetch:[]};if(a.forEach(o=>o({instrument(l){l.navigate!=null&&r.navigate.push(l.navigate),l.fetch!=null&&r.fetch.push(l.fetch)}})),r.navigate.length>0){let o=Nc(t.navigate),l=async(...d)=>{let[u,m]=d,p,x={to:typeof u=="number"||typeof u=="string"?u:u?qn(u):".",...y0(t,m??{})};return br(await In(r.navigate,x,async()=>{if(typeof u=="number")return await o(...d);let b=g0(t,y=>{p=y});try{return await o(...d)}finally{b()}},b=>({...yr(b),meta:p})))};Sc(l,o),t.navigate=l}if(r.fetch.length>0){let o=Nc(t.fetch),l=async(...d)=>{let[u,m,p,x]=d,b;return br(await In(r.fetch,{href:p??".",fetcherKey:u,...y0(t,x??{})},async()=>{let y=g0(t,v=>{b=v});try{return await o(...d)}finally{y()}},y=>({...yr(y),meta:b})))};Sc(l,o),t.fetch=l}return t}function Nc(t){return t[E1]??t}function Sc(t,a){t[E1]=a}function g0(t,a){return wc.set(t,a),()=>{wc.get(t)===a&&wc.delete(t)}}function b0(t){let a=wc.get(t);return wc.delete(t),a}function br(t){if(t.type==="error")throw t.value;return t.value}async function In(t,a,r,o,l={result:null,innerResult:null},d=t.length-1){let u=t[d];if(u){let m,p=async()=>(m?console.error("You cannot call instrumented handlers more than once"):m=In(t,a,r,o,l,d-1),await m,pt(l.innerResult,"Expected an inner result"),l.innerResult);try{await u(p,a)}catch(x){console.error("An instrumentation function threw an error:",x)}m||await p(),await m}else{try{l.result={type:"success",value:await r()}}catch(m){l.result={type:"error",value:m}}l.innerResult=o(l.result,a)}return l.result||(l.result={type:"error",value:new Error("No result assigned in instrumentation chain.")},l.innerResult=o(l.result,a)),l.result}function yr(t){return t.type==="error"&&t.value instanceof Error?{status:"error",error:t.value}:{status:"success",error:void 0}}function rf(t){let{request:a,context:r,params:o}=t;return{...t,request:v5(a),params:{...o}
62,context:j5(r)}}function y0(t,a){return{currentUrl:qn(t.state.location),..."formMethod"in a?{formMethod:a.formMethod}:{},..."formEncType"in a?{formEncType:a.formEncType}:{},..."formData"in a?{formData:a.formData}:{},..."body"in a?{body:a.body}:{}}}function v5(t){return{method:t.method,url:t.url,headers:{get:(...a)=>t.headers.get(...a)}}}function j5(t){return{get:a=>t.get(a)}}/**
63 * react-router v8.3.0
64 *
65 * Copyright (c) Remix Software Inc.
66 *
67 * This source code is licensed under the MIT license found in the
68 * LICENSE.md file in the root directory of this source tree.
69 *
70 * @license MIT
71 */const H1=["POST","PUT","PATCH","DELETE"],w5=new Set(H1),N5=["GET",...H1],S5=new Set(N5),z1=new Set([301,302,303,307,308]),C5=new Set([307,308]),of={state:"idle",location:void 0,matches:void 0,historyAction:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},k5={state:"idle",data:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},oc={state:"unblocked",proceed:void 0,reset:void 0,location:void 0},R1="remix-router-transitions",_1=Symbol("ResetLoaderData");var di,Zi,jr,Ji,bw,T5=(bw=class{constructor(a){Po(this,di);Po(this,Zi);Po(this,jr);Po(this,Ji);yn(this,di,a),yn(this,Zi,Au(a))}get stableRoutes(){return Ba(this,di)}get activeRoutes(){return Ba(this,jr)??Ba(this,di)}get branches(){return Ba(this,Ji)??Ba(this,Zi)}get hasHMRRoutes(){return Ba(this,jr)!=null}setRoutes(a){yn(this,di,a),yn(this,Zi,Au(a))}setHmrRoutes(a){yn(this,jr,a),yn(this,Ji,Au(a))}commitHmrRoutes(){Ba(this,jr)&&(yn(this,di,Ba(this,jr)),yn(this,Zi,Ba(this,Ji)),yn(this,jr,void 0),yn(this,Ji,void 0))}},di=new WeakMap,Zi=new WeakMap,jr=new WeakMap,Ji=new WeakMap,bw);function A5(t){const a=t.window?t.window:typeof window<"u"?window:void 0,r=typeof a<"u"&&typeof a.document<"u"&&typeof a.document.createElement<"u";pt(t.routes.length>0,"You must provide a non-empty routes array to createRouter");let o=t.hydrationRouteProperties||[],l=t.mapRouteProperties,d=l||(()=>({}));if(t.instrumentations){let V=t.instrumentations;d=G=>({...l==null?void 0:l(G),...b5(V.map(ee=>ee.route).filter(Boolean),G)})}let u={},m=new T5(Ec(t.routes,d,void 0,u)),p=t.basename||"/";p.startsWith("/")||(p=`/${p}`);let x=t.dataStrategy||_5,b={...t.future},y=null,v=new Set,w=null,C=null,A=null,S=null,z=t.hydrationData!=null,T=jn(m.activeRoutes,t.history.location,p,!1,m.branches),M=!1,P=null,E,U;if(T==null&&!t.patchRoutesOnNavigation){let V=sn(404,{pathname:t.history.location.pathname}),{matches:G,route:ee}=fu(m.activeRoutes);E=!0,U=!E,T=G,P={[ee.id]:V}}else if(T&&!t.hydrationData&&Is(T,m.activeRoutes,t.history.location.pathname).active&&(T=null),T)if(T.some(V=>V.route.lazy))E=!1,U=!E;else if(!T.some(V=>Zx(V.route)))E=!0,U=!E;else{let V=t.hydrationData?t.hydrationData.loaderData:null,G=t.hydrationData?t.hydrationData.errors:null,ee=T;if(G){let fe=T.findIndex(xe=>G[xe.route.id]!==void 0);ee=ee.slice(0,fe+1)}U=!1,E=!0,ee.forEach(fe=>{let xe=L1(fe.route,V,G);U=U||xe.renderFallback,E=E&&!xe.shouldLoad})}else{E=!1,U=!E,T=[];let V=Is(null,m.activeRoutes,t.history.location.pathname);V.active&&V.matches&&(M=!0,T=V.matches)}let q,H={historyAction:t.history.action,location:t.history.location,matches:T,initialized:E,renderFallback:U,navigation:of,restoreScrollPosition:t.hydrationData!=null?!1:null,preventScrollReset:!1,revalidation:"idle",loaderData:t.hydrationData&&t.hydrationData.loaderData||{},actionData:t.hydrationData&&t.hydrationData.actionData||null,errors:t.hydrationData&&t.hydrationData.errors||P,fetchers:new Map,blockers:new Map},J="POP",B=null,Y=!1,$,D=!1,W=new Map,I=null,k=!1,K=!1,L=new Set,se=new Map,X=0,le=-1,ge=new Map,Se=new Set,Me=new Map,st=new Map,We=new Set,Ye=new Map,te,me=null;function Le(){if(y=t.history.listen(({action:V,location:G,delta:ee})=>{if(te){te(),te=void 0;return}Fs(Ye.size===0||ee!=null,"You are trying to use a blocker on a POP navigation to a location that was not created by @remix-run/router. This will fail silently in production. This can happen if you are navigating outside the router via `window.history.pushState`/`window.location.hash` instead of using router navigation APIs.  This can also happen if you are using createHashRouter and the user manually changes the URL.");let fe=be({currentLocation:H.location,nextLocation:G,historyAction:V});if(fe&&ee!=null){let xe=new Promise(Re=>{te=Re});t.history.go(ee*-1),ue(fe,{state:"blocked",location:G,proceed(){ue(fe,{state:"proceeding",proceed:void 0,reset:void 0,location:G}),xe.then(()=>t.history.go(ee))},reset(){let Re=new Map(H.blockers);Re.set(fe,oc),ze({blockers:Re})}}),B==null||B.resolve(),B=null;return}return Et(V,G)}),r){X5(a,W);let V=()=>Q5(a,W);a.addEventListener("pagehide",V),I=()=>a.removeEventListener("pagehide",V)}return H.initialized||Et("POP",H.location,{initialHydration:!0}),q}function Ie(){y&&y(),I&&I(),v.clear(),$&&$.abort(),H.fetchers.forEac
71h((V,G)=>et(H.fetchers,G)),H.blockers.forEach((V,G)=>qs(G))}function ve(V){if(v.add(V),w){let{newErrors:G}=w;w=null,V(H,{deletedFetchers:[],newErrors:G,viewTransitionOpts:void 0,flushSync:!1})}return()=>v.delete(V)}function ze(V,G={}){V.matches&&(V.matches=V.matches.map(xe=>{let Re=u[xe.route.id],Ee=xe.route;return Ee.element!==Re.element||Ee.errorElement!==Re.errorElement||Ee.hydrateFallbackElement!==Re.hydrateFallbackElement?{...xe,route:Re}:xe})),H={...H,...V};let ee=[],fe=[];H.fetchers.forEach((xe,Re)=>{xe.state==="idle"&&(We.has(Re)?ee.push(Re):fe.push(Re))}),We.forEach(xe=>{!H.fetchers.has(xe)&&!se.has(xe)&&ee.push(xe)}),v.size===0&&(w={newErrors:V.errors??null}),[...v].forEach(xe=>xe(H,{deletedFetchers:ee,newErrors:V.errors??null,viewTransitionOpts:G.viewTransitionOpts,flushSync:G.flushSync===!0})),ee.forEach(xe=>et(H.fetchers,xe)),fe.forEach(xe=>H.fetchers.delete(xe))}function Ue(V,G,{flushSync:ee}={}){var Ze,qe;let fe=H.actionData!=null&&H.navigation.formMethod!=null&&fa(H.navigation.formMethod)&&H.navigation.state==="loading"&&((Ze=V.state)==null?void 0:Ze._isRedirect)!==!0,xe;G.actionData?Object.keys(G.actionData).length>0?xe=G.actionData:xe=null:fe?xe=H.actionData:xe=null;let Re=G.loaderData?E0(H.loaderData,G.loaderData,G.matches||[],G.errors):H.loaderData,Ee=H.blockers;Ee.size>0&&!k&&(Ee=new Map(Ee),Ee.forEach((Qe,wt)=>Ee.set(wt,oc)));let He=k?!1:Qs(V,G.matches||H.matches),ke=Y===!0||H.navigation.formMethod!=null&&fa(H.navigation.formMethod)&&((qe=V.state)==null?void 0:qe._isRedirect)!==!0;m.commitHmrRoutes(),k||J==="POP"||(J==="PUSH"?t.history.push(V,V.state):J==="REPLACE"&&t.history.replace(V,V.state));let $e;if(J==="POP"){let Qe=W.get(H.location.pathname);Qe&&Qe.has(V.pathname)?$e={currentLocation:H.location,nextLocation:V}:W.has(V.pathname)&&($e={currentLocation:V,nextLocation:H.location})}else if(D){let Qe=W.get(H.location.pathname);Qe?Qe.add(V.pathname):(Qe=new Set([V.pathname]),W.set(H.location.pathname,Qe)),$e={currentLocation:H.location,nextLocation:V}}ze({...G,actionData:xe,loaderData:Re,historyAction:J,location:V,initialized:!0,renderFallback:!1,navigation:of,revalidation:"idle",restoreScrollPosition:He,preventScrollReset:ke,blockers:Ee},{viewTransitionOpts:$e,flushSync:ee===!0}),J="POP",Y=!1,D=!1,k=!1,K=!1,B==null||B.resolve(),B=null,me==null||me.resolve(),me=null}async function ct(V,G){if(B==null||B.resolve(),B=null,typeof V=="number"){B||(B=L0());let kt=B.promise;return t.history.go(V),kt}let ee=b0(q),{path:fe,submission:xe,error:Re}=v0(!1,$f(H.location,H.matches,p,V,G==null?void 0:G.fromRouteId,G==null?void 0:G.relative),G),Ee;G!=null&&G.mask&&(Ee={pathname:"",search:"",hash:"",...typeof G.mask=="string"?Zn(G.mask):{...H.location.mask,...G.mask}});let He=H.location,ke=Ac(He,fe,G&&G.state,void 0,Ee);ke={...ke,...t.history.encodeLocation(ke)};let $e=G&&G.replace!=null?G.replace:void 0,Ze="PUSH";$e===!0?Ze="REPLACE":$e===!1||xe!=null&&fa(xe.formMethod)&&xe.formAction===H.location.pathname+H.location.search&&(Ze="REPLACE");let qe=G&&"preventScrollReset"in G?G.preventScrollReset===!0:void 0,Qe=(G&&G.flushSync)===!0,wt=be({currentLocation:He,nextLocation:ke,historyAction:Ze});if(wt){ue(wt,{state:"blocked",location:ke,proceed(){ue(wt,{state:"proceeding",proceed:void 0,reset:void 0,location:ke}),ct(V,G)},reset(){let kt=new Map(H.blockers);kt.set(wt,oc),ze({blockers:kt})}});return}await Et(Ze,ke,{submission:xe,pendingError:Re,preventScrollReset:qe,replace:G&&G.replace,enableViewTransition:G&&G.viewTransition,flushSync:Qe,callSiteDefaultShouldRevalidate:G&&G.defaultShouldRevalidate,instrumentationNavigateMetaReceiver:ee})}function Ot(){me||(me=L0()),ws(),ze({revalidation:"loading"});let V=me.promise;return H.navigation.state==="submitting"?V:H.navigation.state==="idle"?(Et(H.historyAction,H.location,{startUninterruptedRevalidation:!0}),V):(Et(J||H.historyAction,H.navigation.location,{overrideNavigation:H.navigation,enableViewTransition:D===!0}),V)}async function Et(V,G,ee){$&&$.abort(),$=null,J=V,k=(ee&&ee.startUninterruptedRevalidation)===!0,Ut(H.location,H.matches),Y=(ee&&ee.preventScrollReset)===!0,D=(ee&&ee.enableViewTransition)===!0;let fe=m.activeRoutes,xe=ee!=null&&ee.initialHydration&&H.matches&&H.matches.length>0&&!M?H.matches:jn(fe,G,p,!1,m.branches),Re=(ee&&ee.flushSync)===!0;
71if(xe&&H.initialized&&!K&&B5(H.location,G)&&!(ee&&ee.submission&&fa(ee.submission.formMethod))){Ue(G,{matches:xe},{flushSync:Re});return}let Ee=Is(xe,fe,G.pathname);if(Ee.active&&Ee.matches&&(xe=Ee.matches),ee!=null&&ee.instrumentationNavigateMetaReceiver){let nt=R0(t.history,G,xe);ee.instrumentationNavigateMetaReceiver(nt)}if(!xe){let{error:nt,notFoundMatches:ea,route:Tt}=_t(G.pathname);Ue(G,{matches:ea,loaderData:{},errors:{[Tt.id]:nt}},{flushSync:Re});return}let He=ee&&ee.overrideNavigation?{...ee.overrideNavigation,matches:xe,historyAction:V}:void 0;$=new AbortController;let ke=Yo(t.history,G,$.signal,ee&&ee.submission),$e=t.getContext?await t.getContext():new h0,Ze;if(ee&&ee.pendingError)Ze=[ci(xe).route.id,{type:"error",error:ee.pendingError}];else if(ee&&ee.submission&&fa(ee.submission.formMethod)){let nt=await Zt(ke,G,ee.submission,xe,V,$e,Ee.active,ee&&ee.initialHydration===!0,{replace:ee.replace,flushSync:Re});if(nt.shortCircuited)return;if(nt.pendingActionResult){let[ea,Tt]=nt.pendingActionResult;if($a(Tt)&&Hc(Tt.error)&&Tt.error.status===404){$=null,Ue(G,{matches:nt.matches,loaderData:{},errors:{[ea]:Tt.error}});return}}xe=nt.matches||xe,Ze=nt.pendingActionResult,He=lf(G,xe,V,ee.submission),Re=!1,Ee.active=!1,ke=Yo(t.history,ke.url,ke.signal)}let{shortCircuited:qe,matches:Qe,loaderData:wt,errors:kt,workingFetchers:Gt}=await as(ke,G,xe,V,$e,Ee.active,He,ee&&ee.submission,ee&&ee.fetcherSubmission,ee&&ee.replace,ee&&ee.initialHydration===!0,Re,Ze,ee&&ee.callSiteDefaultShouldRevalidate);qe||($=null,Ue(G,{matches:Qe||xe,...H0(Ze),loaderData:wt,errors:kt,...Gt?{fetchers:Gt}:{}}))}async function Zt(V,G,ee,fe,xe,Re,Ee,He,ke={}){if(ws(),ze({navigation:Z5(G,fe,xe,ee)},{flushSync:ke.flushSync===!0}),Ee){let qe=await ba(fe,G.pathname,V.signal);if(qe.type==="aborted")return{shortCircuited:!0};if(qe.type==="error"){if(qe.partialMatches.length===0){let{matches:wt,route:kt}=fu(m.activeRoutes);return{matches:wt,pendingActionResult:[kt.id,{type:"error",error:qe.error}]}}let Qe=ci(qe.partialMatches).route.id;return{matches:qe.partialMatches,pendingActionResult:[Qe,{type:"error",error:qe.error}]}}else if(qe.matches)fe=qe.matches;else{let{notFoundMatches:Qe,error:wt,route:kt}=_t(G.pathname);return{matches:Qe,pendingActionResult:[kt.id,{type:"error",error:wt}]}}}let $e,Ze=Eu(fe,G);if(!Ze.route.action&&!Ze.route.lazy)$e={type:"error",error:sn(405,{method:V.method,pathname:G.pathname,routeId:Ze.route.id})};else{let qe=await ps(V,G,Xo(d,u,V,G,fe,Ze,He?[]:o,Re),Re,null);if($e=qe[Ze.route.id],!$e){for(let Qe of fe)if(qe[Qe.route.id]){$e=qe[Qe.route.id];break}}if(V.signal.aborted)return{shortCircuited:!0}}if(Gi($e)){let qe;return ke&&ke.replace!=null?qe=ke.replace:qe=k0($e.response.headers.get("Location"),new URL(V.url),p,t.history)===H.location.pathname+H.location.search,await jt(V,$e,!0,{submission:ee,replace:qe}),{shortCircuited:!0}}if($a($e)){let qe=ci(fe,Ze.route.id);return(ke&&ke.replace)!==!0&&(J="PUSH"),{matches:fe,pendingActionResult:[qe.route.id,$e,Ze.route.id]}}return{matches:fe,pendingActionResult:[Ze.route.id,$e]}}async function as(V,G,ee,fe,xe,Re,Ee,He,ke,$e,Ze,qe,Qe,wt){let kt=Ee||lf(G,ee,fe,He),Gt=He||ke||_0(kt),nt=!k&&!Ze;if(Re){if(nt){let Ht=Jt(Qe);ze({navigation:kt,...Ht!==void 0?{actionData:Ht}:{}},{flushSync:qe})}let at=await ba(ee,G.pathname,V.signal);if(at.type==="aborted")return{shortCircuited:!0};if(at.type==="error"){if(at.partialMatches.length===0){let{matches:zt,route:pn}=fu(m.activeRoutes);return{matches:zt,loaderData:{},errors:{[pn.id]:at.error}}}let Ht=ci(at.partialMatches).route.id;return{matches:at.partialMatches,loaderData:{},errors:{[Ht]:at.error}}}else if(at.matches)ee=at.matches;else{let{error:Ht,notFoundMatches:zt,route:pn}=_t(G.pathname);return{matches:zt,loaderData:{},errors:{[pn.id]:Ht}}}}let ea=m.activeRoutes,{dsMatches:Tt,revalidatingFetchers:bt}=j0(V,xe,d,u,t.history,H,ee,Gt,G,Ze?[]:o,Ze===!0,K,L,We,Me,Se,ea,p,t.patchRoutesOnNavigation!=null,m.branches,Qe,wt);if(le=++X,!t.dataStrategy&&!Tt.some(at=>at.shouldLoad)&&!Tt.some(at=>at.route.middleware&&at.route.middleware.length>0)&&bt.length===0){let at=new Map(H.fetchers),Ht=ft(at);return Ue(G,{matches:ee,loaderData:{},errors:Qe&&$a(Qe[1])?{[Qe[0]]:Qe[1].error}:null,...H0(Qe),...Ht?{fetchers:at}:{}},{flushSync:qe}),{shortCircuited:!0}}if(nt){let at={};if(!Re){at.navigation=kt;let Ht=Jt(Qe);Ht!==void 0&&(at.actionData=Ht)}bt.length>0&&(at.fetchers=vs(bt)),ze(at,{flushSync:qe})}bt.forEach(at=>{Ae(at.key),at.controller&&se.set(at.key,at.controller)});let ca=()=>bt.forEach(at=>Ae(at.key));$&&$.signal.addEventListener("abort",ca);let{loaderResults:ya,fetcherResults:da}=await Wt(Tt,bt,V,G,xe);if(V.signal.aborted)return{shortCircuited:!0};$&&$.signal.removeEventListener("abort",ca),bt.forEach(at=>se.delete(at.key));let fs=xu(ya);if(fs)return await jt(V,fs.result,!0,{replace:$e}),{shortCircuited:!0};if(fs=xu(da),fs)return Se.add(fs.key),await jt(V,fs.result,!0,{replace:$e}),{shortCircuited:!0};let un=new Map(H.fetchers),{loaderData:Ra,errors:Wa}=A0(H,ee,ya,Qe,bt,da,un);Ze&&H.errors&&(Wa={...H.errors,...Wa});let mn=ft(un),hn=Yt(le,un),_a=mn||hn||bt.length>0;return{matches:ee,loaderData:Ra,errors:Wa,..._a?{workingFetchers:un}:{}}}function Jt(V){if(V&&!$a(V[1]))return{[V[0]]:V[1].data};if(H.actionData)return Object.keys(H.actionData).length===0?null:H.actionData}function vs(V){let G=new Map(H.fetchers);
71return V.forEach(ee=>{let fe=G.get(ee.key),xe=lc(void 0,fe?fe.data:void 0);G.set(ee.key,xe)}),G}async function js(V,G,ee,fe){Ae(V);let xe=(fe&&fe.flushSync)===!0,Re=b0(q),Ee=m.activeRoutes,He=$f(H.location,H.matches,p,ee,G,fe==null?void 0:fe.relative),ke=jn(Ee,He,p,!1,m.branches),$e=Is(ke,Ee,He);if($e.active&&$e.matches&&(ke=$e.matches),Re&&Re(R0(t.history,He,ke)),!ke){qt(V,G,sn(404,{pathname:He}),{flushSync:xe});return}let{path:Ze,submission:qe,error:Qe}=v0(!0,He,fe);if(Qe){qt(V,G,Qe,{flushSync:xe});return}let wt=t.getContext?await t.getContext():new h0,kt=(fe&&fe.preventScrollReset)===!0;if(qe&&fa(qe.formMethod)){await Ws(V,G,Ze,ke,wt,$e.active,xe,kt,qe,fe&&fe.defaultShouldRevalidate);return}Me.set(V,{routeId:G,path:Ze}),await Mt(V,G,Ze,ke,wt,$e.active,xe,kt,qe)}async function Ws(V,G,ee,fe,xe,Re,Ee,He,ke,$e){ws(),Me.delete(V),os(V,J5(ke,H.fetchers.get(V)),{flushSync:Ee});let Ze=new AbortController,qe=Yo(t.history,ee,Ze.signal,ke);if(Re){let Bt=await ba(fe,new URL(qe.url).pathname,qe.signal,V);if(Bt.type==="aborted")return;if(Bt.type==="error"){qt(V,G,Bt.error,{flushSync:Ee});return}else if(Bt.matches)fe=Bt.matches;else{qt(V,G,sn(404,{pathname:ee}),{flushSync:Ee});return}}let Qe=Eu(fe,ee);if(!Qe.route.action&&!Qe.route.lazy){qt(V,G,sn(405,{method:ke.formMethod,pathname:ee,routeId:G}),{flushSync:Ee});return}se.set(V,Ze);let wt=X,kt=Xo(d,u,qe,ee,fe,Qe,o,xe),Gt=await ps(qe,ee,kt,xe,V),nt=Gt[Qe.route.id];if(!nt){for(let Bt of kt)if(Gt[Bt.route.id]){nt=Gt[Bt.route.id];break}}if(qe.signal.aborted){se.get(V)===Ze&&se.delete(V);return}
71if(We.has(V)){if(Gi(nt)||$a(nt)){os(V,On(void 0));return}}else{if(Gi(nt))if(se.delete(V),le>wt){os(V,On(void 0));return}else return Se.add(V),os(V,lc(ke)),jt(qe,nt,!1,{fetcherSubmission:ke,preventScrollReset:He});if($a(nt)){qt(V,G,nt.error);return}}let ea=H.navigation.location||H.location,Tt=Yo(t.history,ea,Ze.signal),bt=m.activeRoutes,ca=H.navigation.state!=="idle"?jn(bt,H.navigation.location,p,!1,m.branches):H.matches;pt(ca,"Didn't find any matches after fetcher action");let ya=++X;ge.set(V,ya);let{dsMatches:da,revalidatingFetchers:fs}=j0(Tt,xe,d,u,t.history,H,ca,ke,ea,o,!1,K,L,We,Me,Se,bt,p,t.patchRoutesOnNavigation!=null,m.branches,[Qe.route.id,nt],$e),un=lc(ke,nt.data),Ra=new Map(H.fetchers);Ra.set(V,un),fs.filter(Bt=>Bt.key!==V).forEach(Bt=>{let ua=Bt.key,oo=Ra.get(ua),ta=lc(void 0,oo?oo.data:void 0);Ra.set(ua,ta),Ae(ua),Bt.controller&&se.set(ua,Bt.controller)}),ze({fetchers:Ra});let Wa=()=>fs.forEach(Bt=>Ae(Bt.key));Ze.signal.addEventListener("abort",Wa);let{loaderResults:mn,fetcherResults:hn}=await Wt(da,fs,Tt,ea,xe);if(Ze.signal.aborted)return;Ze.signal.removeEventListener("abort",Wa),ge.delete(V),se.delete(V),fs.forEach(Bt=>se.delete(Bt.key));let _a=H.fetchers.has(V),at=Bt=>{if(!_a)return Bt;let ua=new Map(Bt.fetchers);return ua.set(V,On(nt.data)),{...Bt,fetchers:ua}},Ht=xu(mn);if(Ht)return H=at(H),jt(Tt,Ht.result,!1,{preventScrollReset:He});if(Ht=xu(hn),Ht)return Se.add(Ht.key),H=at(H),jt(Tt,Ht.result,!1,{preventScrollReset:He});let zt=new Map(H.fetchers);_a&&zt.set(V,On(nt.data));let{loaderData:pn,errors:fn}=A0(H,ca,mn,void 0,fs,hn,zt);Yt(ya,zt),H.navigation.state==="loading"&&ya>le?(pt(J,"Expected pending action"),$&&$.abort(),Ue(H.navigation.location,{matches:ca,loaderData:pn,errors:fn,fetchers:zt})):(ze({errors:fn,loaderData:E0(H.loaderData,pn,ca,fn),fetchers:zt}),K=!1)}async function Mt(V,G,ee,fe,xe,Re,Ee,He,ke){let $e=H.fetchers.get(V);os(V,lc(ke,$e?$e.data:void 0),{flushSync:Ee});let Ze=new AbortController,qe=Yo(t.history,ee,Ze.signal);if(Re){let nt=await ba(fe,new URL(qe.url).pathname,qe.signal,V);if(nt.type==="aborted")return;if(nt.type==="error"){qt(V,G,nt.error,{flushSync:Ee});return}else if(nt.matches)fe=nt.matches;else{qt(V,G,sn(404,{pathname:ee}),{flushSync:Ee});return}}let Qe=Eu(fe,ee);se.set(V,Ze);let wt=X,kt=await ps(qe,ee,Xo(d,u,qe,ee,fe,Qe,o,xe),xe,V),Gt=kt[Qe.route.id];if(!Gt){for(let nt of fe)if(kt[nt.route.id]){Gt=kt[nt.route.id];break}}if(se.get(V)===Ze&&se.delete(V),!qe.signal.aborted){if(We.has(V)){os(V,On(void 0));return}if(Gi(Gt))if(le>wt){os(V,On(void 0));return}else{Se.add(V),await jt(qe,Gt,!1,{preventScrollReset:He});return}if($a(Gt)){qt(V,G,Gt.error);return}os(V,On(Gt.data))}}async function jt(V,G,ee,{submission:fe,fetcherSubmission:xe,preventScrollReset:Re,replace:Ee}={}){ee||(B==null||B.resolve(),B=null),G.response.headers.has("X-Remix-Revalidate")&&(K=!0);let He=G.response.headers.get("Location");pt(He,"Expected a Location header on the redirect Response"),He=k0(He,new URL(V.url),p,t.history);let ke=Ac(H.location,He,{_isRedirect:!0});if(r){let kt=!1;if(G.response.headers.has("X-Remix-Reload-Document"))kt=!0;else if(qx(He)){const Gt=g1(a,He,!0);kt=Gt.origin!==a.location.origin||on(Gt.pathname,p)==null}if(kt){Ee?a.location.replace(He):a.location.assign(He);return}}$=null;let $e=Ee===!0||G.response.headers.has("X-Remix-Replace")?"REPLACE":"PUSH",{formMethod:Ze,formAction:qe,formEncType:Qe}=H.navigation;!fe&&!xe&&Ze&&qe&&Qe&&(fe=_0(H.navigation));let wt=fe||xe;C5.has(G.response.status)&&wt&&fa(wt.formMethod)?await Et($e,ke,{submission:{...wt,formAction:He},preventScrollReset:Re||Y,enableViewTransition:ee?D:void 0}):await Et($e,ke,{overrideNavigation:lf(ke,[],$e,fe),fetcherSubmission:xe,preventScrollReset:Re||Y,enableViewTransition:ee?D:void 0})}async function ps(V,G,ee,fe,xe){var He;let Re,Ee={};try{Re=await D5(x,V,G,ee,xe,fe,!1)}catch(ke){return ee.filter($e=>$e.shouldLoad).forEach($e=>{Ee[$e.route.id]={type:"error",error:ke}}),Ee}if(V.signal.aborted)return Ee;if(!fa(V.method))for(let ke of ee){if(((He=Re[ke.route.id])==null?void 0:He.type)==="error")break;!Re.hasOwnProperty(ke.route.id)&&!H.loaderData.hasOwnProperty(ke.route.id)&&
71(!H.errors||!H.errors.hasOwnProperty(ke.route.id))&&ke.shouldCallHandler()&&(Re[ke.route.id]={type:"error",result:new Error(`No result returned from dataStrategy for route ${ke.route.id}`)})}for(let[ke,$e]of Object.entries(Re))if(W5($e)){let Ze=$e.result;Ee[ke]={type:"redirect",response:P5(Ze,V,ke,ee,p)}}else Ee[ke]=await U5($e);return Ee}async function Wt(V,G,ee,fe,xe){let Re=ps(ee,fe,V,xe,null),Ee=Promise.all(G.map(async He=>{if(He.matches&&He.match&&He.request&&He.controller){let ke=(await ps(He.request,He.path,He.matches,xe,He.key))[He.match.route.id];return{[He.key]:ke}}else return Promise.resolve({[He.key]:{type:"error",error:sn(404,{pathname:He.path})}})}));return{loaderResults:await Re,fetcherResults:(await Ee).reduce((He,ke)=>Object.assign(He,ke),{})}}function ws(){K=!0,Me.forEach((V,G)=>{se.has(G)&&L.add(G),Ae(G)})}function os(V,G,ee={}){let fe=new Map(H.fetchers);fe.set(V,G),ze({fetchers:fe},{flushSync:(ee&&ee.flushSync)===!0})}function qt(V,G,ee,fe={}){let xe=ci(H.matches,G),Re=new Map(H.fetchers);et(Re,V),ze({errors:{[xe.route.id]:ee},fetchers:Re},{flushSync:(fe&&fe.flushSync)===!0})}function je(V){return st.set(V,(st.get(V)||0)+1),We.has(V)&&We.delete(V),H.fetchers.get(V)||k5}function gt(V,G){Ae(V,G==null?void 0:G.reason),os(V,On(null))}function et(V,G){let ee=H.fetchers.get(G);se.has(G)&&!(ee&&ee.state==="loading"&&ge.has(G))&&Ae(G),Me.delete(G),ge.delete(G),Se.delete(G),We.delete(G),L.delete(G),V.delete(G)}function Xe(V){let G=(st.get(V)||0)-1;G<=0?(st.delete(V),We.add(V)):st.set(V,G),ze({fetchers:new Map(H.fetchers)})}function Ae(V,G){let ee=se.get(V);ee&&(ee.abort(G),se.delete(V))}function De(V,G){for(let ee of V){let fe=G.get(ee);pt(fe,`Expected fetcher: ${ee}`);let xe=On(fe.data);G.set(ee,xe)}}function ft(V){let G=[],ee=!1;for(let fe of Se){let xe=V.get(fe);pt(xe,`Expected fetcher: ${fe}`),xe.state==="loading"&&(Se.delete(fe),G.push(fe),ee=!0)}return De(G,V),ee}function Yt(V,G){let ee=[];for(let[fe,xe]of ge)if(xe<V){let Re=G.get(fe);pt(Re,`Expected fetcher: ${fe}`),Re.state==="loading"&&(Ae(fe),ge.delete(fe),ee.push(fe))}return De(ee,G),ee.length>0}function ls(V,G){let ee=H.blockers.get(V)||oc;return Ye.get(V)!==G&&Ye.set(V,G),ee}function qs(V){H.blockers.delete(V),Ye.delete(V)}function ue(V,G){let ee=H.blockers.get(V)||oc;pt(ee.state==="unblocked"&&G.state==="blocked"||ee.state==="blocked"&&G.state==="blocked"||ee.state==="blocked"&&G.state==="proceeding"||ee.state==="blocked"&&G.state==="unblocked"||ee.state==="proceeding"&&G.state==="unblocked",`Invalid blocker state transition: ${ee.state} -> ${G.state}`);let fe=new Map(H.blockers);fe.set(V,G),ze({blockers:fe})}function be({currentLocation:V,nextLocation:G,historyAction:ee}){if(Ye.size===0)return;Ye.size>1&&Fs(!1,"A router only supports one blocker at a time");let fe=Array.from(Ye.entries()),[xe,Re]=fe[fe.length-1],Ee=H.blockers.get(xe);if(!(Ee&&Ee.state==="proceeding")&&Re({currentLocation:V,nextLocation:G,historyAction:ee}))return xe}function _t(V){let G=sn(404,{pathname:V}),ee=m.activeRoutes,{matches:fe,route:xe}=fu(ee);return{notFoundMatches:fe,route:xe,error:G}}function ns(V,G,ee){if(C=V,S=G,A=ee||null,!z&&H.navigation===of){z=!0;let fe=Qs(H.location,H.matches);fe!=null&&ze({restoreScrollPosition:fe})}return()=>{C=null,S=null,A=null}}function Ct(V,G){return A&&A(V,G.map(ee=>v1(ee,H.loaderData)))||V.key}function Ut(V,G){if(C&&S){let ee=Ct(V,G);C[ee]=S()}}function Qs(V,G){if(C){let ee=Ct(V,G),fe=C[ee];if(typeof fe=="number")return fe}return null}function Is(V,G,ee){if(t.patchRoutesOnNavigation){let fe=m.branches;if(V){if(Object.keys(V[0].params).length>0)return{active:!0,matches:jn(G,ee,p,!0,fe)}}else return{active:!0,matches:jn(G,ee,p,!0,fe)||[]}}return{active:!1,matches:null}}async function ba(V,G,ee,fe){if(!t.patchRoutesOnNavigation)return{type:"success",matches:V};let xe=V;for(;;){let Re=u;try{await t.patchRoutesOnNavigation({signal:ee,path:G,matches:xe,fetcherKey:fe,patch:($e,Ze)=>{ee.aborted||w0($e,Ze,m,Re,d,!1)}})}catch($e){return{type:"error",error:$e,partialMatches:xe}}if(ee.aborted)return{type:"aborted"};let Ee=m.branches,He=jn(m.activeRoutes,G,p,!1,Ee),ke=null;if(He){if(Object.keys(He[0].params).length===0)return{type:"success",matches:He};if(ke=jn(m.activeRoutes,G,p,!0,Ee),!(ke&&xe.length<ke.length&&Tr(xe,ke.slice(0,xe.length))))return{type:"success",matches:He}}
71if(ke||(ke=jn(m.activeRoutes,G,p,!0,Ee)),!ke||Tr(xe,ke))return{type:"success",matches:null};xe=ke}}function Tr(V,G){return V.length===G.length&&V.every((ee,fe)=>ee.route.id===G[fe].route.id)}function wi(V){u={},m.setHmrRoutes(Ec(V,d,void 0,u))}function Jn(V,G,ee=!1){w0(V,G,m,u,d,ee),m.hasHMRRoutes||ze({})}return q={get basename(){return p},get future(){return b},get state(){return H},get routes(){return m.stableRoutes},get branches(){return m.branches},get manifest(){return u},get window(){return a},initialize:Le,subscribe:ve,enableScrollRestoration:ns,navigate:ct,fetch:js,revalidate:Ot,createHref:V=>t.history.createHref(V),encodeLocation:V=>t.history.encodeLocation(V),getFetcher:je,resetFetcher:gt,deleteFetcher:Xe,dispose:Ie,getBlocker:ls,deleteBlocker:qs,patchRoutes:Jn,_internalFetchControllers:se,_internalSetRoutes:wi,_internalSetStateDoNotUseOrYouWillBreakYourApp(V){ze(V)}},t.instrumentations&&(q=y5(q,t.instrumentations.map(V=>V.router).filter(Boolean))),q}function E5(t){return t!=null&&("formData"in t&&t.formData!=null||"body"in t&&t.body!==void 0)}function $f(t,a,r,o,l,d){let u,m;if(l){u=[];for(let x of a)if(u.push(x),x.route.id===l){m=x;break}}else u=a,m=a[a.length-1];let p=qc(o||".",Om(u),on(t.pathname,r)||t.pathname,d==="path");if(o==null&&(p.search=t.search,p.hash=t.hash),(o==null||o===""||o===".")&&m){let x=Xx(p.search);if(m.route.index&&!x)p.search=p.search?p.search.replace(/^\?/,"?index&"):"?index";else if(!m.route.index&&x){let b=new URLSearchParams(p.search),y=b.getAll("index");b.delete("index"),y.filter(w=>w).forEach(w=>b.append("index",w));let v=b.toString();p.search=v?`?${v}`:""}}return r!=="/"&&(p.pathname=m5({basename:r,pathname:p.pathname})),qn(p)}function v0(t,a,r){if(!r||!E5(r))return{path:a};if(r.formMethod&&!G5(r.formMethod))return{path:a,error:sn(405,{method:r.formMethod})};let o=()=>({path:a,error:sn(400,{type:"invalid-body"})}),l=(r.formMethod||"get").toUpperCase(),d=K1(a);if(r.body!==void 0){if(r.formEncType==="text/plain"){if(!fa(l))return o();let b=typeof r.body=="string"?r.body:r.body instanceof FormData||r.body instanceof URLSearchParams?Array.from(r.body.entries()).reduce((y,[v,w])=>`${y}${v}=${w}
72`,""):String(r.body);return{path:a,submission:{formMethod:l,formAction:d,formEncType:r.formEncType,formData:void 0,json:void 0,text:b}}}else if(r.formEncType==="application/json"){if(!fa(l))return o();try{let b=typeof r.body=="string"?JSON.parse(r.body):r.body;return{path:a,submission:{formMethod:l,formAction:d,formEncType:r.formEncType,formData:void 0,json:b,text:void 0}}}catch{return o()}}}pt(typeof FormData=="function","FormData is not available in this environment");let u,m;if(r.formData)u=Wf(r.formData),m=r.formData;else if(r.body instanceof FormData)u=Wf(r.body),m=r.body;else if(r.body instanceof URLSearchParams)u=r.body,m=T0(u);else if(r.body==null)u=new URLSearchParams,m=new FormData;else try{u=new URLSearchParams(r.body),m=T0(u)}catch{return o()}let p={formMethod:l,formAction:d,formEncType:r&&r.formEncType||"application/x-www-form-urlencoded",formData:m,json:void 0,text:void 0};if(fa(p.formMethod))return{path:a,submission:p};let x=Zn(a);return t&&x.search&&Xx(x.search)&&u.append("index",""),x.search=`?${u}`,{path:qn(x),submission:p}}function j0(t,a,r,o,l,d,u,m,p,x,b,y,v,w,C,A,S,z,T,M,P,E){var k;let U=P?$a(P[1])?P[1].error:P[1].data:void 0,q=l.createURL(d.location),H=l.createURL(p),J;if(b&&d.errors){let K=Object.keys(d.errors)[0];J=u.findIndex(L=>L.route.id===K)}else if(P&&$a(P[1])){let K=P[0];J=u.findIndex(L=>L.route.id===K)-1}let B=P?P[1].statusCode:void 0,Y=B&&B>=400,$={currentUrl:q,currentParams:((k=d.matches[0])==null?void 0:k.params)||{},nextUrl:H,nextParams:u[0].params,...m,actionResult:U,actionStatus:B},D=ll(u),W=u.map((K,L)=>{let{route:se}=K,X=null;if(J!=null&&L>J)X=!1;else if(se.lazy)X=!0;else if(!Zx(se))X=!1;else if(b){let{shouldLoad:Se}=L1(se,d.loaderData,d.errors);X=Se}else H5(d.loaderData,d.matches[L],K)&&(X=!0);if(X!==null)return Vf(r,o,t,p,D,K,x,a,X);let le=!1;typeof E=="boolean"?le=E:Y?le=!1:(y||q.pathname+q.search===H.pathname+H.search||q.search!==H.search||z5(d.matches[L],K))&&(le=!0);let ge={...$,defaultShouldRevalidate:le};return Vf(r,o,t,p,D,K,x,a,Cc(K,ge),ge,E)}),I=[];
72return C.forEach((K,L)=>{if(b||!u.some(We=>We.route.id===K.routeId)||w.has(L))return;let se=d.fetchers.get(L),X=se&&se.state!=="idle"&&se.data===void 0,le=jn(S,K.path,z??"/",!1,M);if(!le){if(T&&X)return;I.push({key:L,routeId:K.routeId,path:K.path,matches:null,match:null,request:null,controller:null});return}if(A.has(L))return;let ge=Eu(le,K.path),Se=new AbortController,Me=Yo(l,K.path,Se.signal),st=null;if(v.has(L))v.delete(L),st=Xo(r,o,Me,K.path,le,ge,x,a);else if(X)y&&(st=Xo(r,o,Me,K.path,le,ge,x,a));else{let We;typeof E=="boolean"?We=E:Y?We=!1:We=y;let Ye={...$,defaultShouldRevalidate:We};Cc(ge,Ye)&&(st=Xo(r,o,Me,K.path,le,ge,x,a,Ye))}st&&I.push({key:L,routeId:K.routeId,path:K.path,matches:st,match:ge,request:Me,controller:Se})}),{dsMatches:W,revalidatingFetchers:I}}function Zx(t){return t.loader!=null||t.middleware!=null&&t.middleware.length>0}function L1(t,a,r){if(t.lazy)return{shouldLoad:!0,renderFallback:!0};if(!Zx(t))return{shouldLoad:!1,renderFallback:!1};let o=a!=null&&t.id in a,l=r!=null&&r[t.id]!==void 0;if(!o&&l)return{shouldLoad:!1,renderFallback:!1};if(typeof t.loader=="function"&&t.loader.hydrate===!0)return{shouldLoad:!0,renderFallback:!o};let d=!o&&!l;return{shouldLoad:d,renderFallback:d}}function H5(t,a,r){let o=!a||r.route.id!==a.route.id,l=!t.hasOwnProperty(r.route.id);return o||l}function z5(t,a){let r=t.route.path;return t.pathname!==a.pathname||r!=null&&r.endsWith("*")&&t.params["*"]!==a.params["*"]}function Cc(t,a){if(t.route.shouldRevalidate){let r=t.route.shouldRevalidate(a);if(typeof r=="boolean")return r}return a.defaultShouldRevalidate}function w0(t,a,r,o,l,d){let u;if(t){let x=o[t];pt(x,`No route found to patch children into: routeId = ${t}`),x.children||(x.children=[]),u=x.children}else u=r.activeRoutes;let m=[],p=[];if(a.forEach(x=>{let b=u.find(y=>D1(x,y));b?p.push({existingRoute:b,newRoute:x}):m.push(x)}),m.length>0){let x=Ec(m,l,[t||"_","patch",String((u==null?void 0:u.length)||"0")],o);u.push(...x)}if(d&&p.length>0)for(let x=0;x<p.length;x++){let{existingRoute:b,newRoute:y}=p[x],v=b,[w]=Ec([y],l,[],{},!0);Object.assign(v,{element:w.element?w.element:v.element,errorElement:w.errorElement?w.errorElement:v.errorElement,hydrateFallbackElement:w.hydrateFallbackElement?w.hydrateFallbackElement:v.hydrateFallbackElement})}r.hasHMRRoutes||r.setRoutes([...r.activeRoutes])}function D1(t,a){var r;return"id"in t&&"id"in a&&t.id===a.id?!0:t.index===a.index&&t.path===a.path&&t.caseSensitive===a.caseSensitive?(!t.children||t.children.length===0)&&(!a.children||a.children.length===0)?!0:((r=t.children)==null?void 0:r.every((o,l)=>{var d;return(d=a.children)==null?void 0:d.some(u=>D1(o,u))}))??!1:!1}const N0=new WeakMap,O1=({key:t,route:a,manifest:r,mapRouteProperties:o})=>{let l=r[a.id];if(pt(l,"No route found in manifest"),!l.lazy||typeof l.lazy!="object")return;let d=l.lazy[t];if(!d)return;let u=N0.get(l);u||(u={},N0.set(l,u));let m=u[t];if(m)return m;let p=(async()=>{let x=G4(t),b=l[t]!==void 0;if(x)Fs(!x,"Route property "+t+" is not a supported lazy route property. This property will be ignored."),u[t]=Promise.resolve();else if(b)Fs(!1,`Route "${l.id}" has a static property "${t}" defined. The lazy property will be ignored.`);else{let y=await d();y!=null&&(Object.assign(l,{[t]:y}),Object.assign(l,o(l)))}typeof l.lazy=="object"&&(l.lazy[t]=void 0,Object.values(l.lazy).every(y=>y===void 0)&&(l.lazy=void 0))})();return u[t]=p,p},S0=new WeakMap;function R5(t,a,r,o,l){let d=r[t.id];if(pt(d,"No route found in manifest"),!t.lazy)return{lazyRoutePromise:void 0,lazyHandlerPromise:void 0};if(typeof t.lazy=="function"){let b=S0.get(d);if(b)return{lazyRoutePromise:b,lazyHandlerPromise:b};let y=(async()=>{pt(typeof t.lazy=="function","No lazy route function found");let v=await t.lazy(),w={};for(let C in v){let A=v[C];if(A===void 0)continue;let S=J4(C),z=d[C]!==void 0;S?Fs(!S,"Route property "+C+" is not a supported property to be returned from a lazy route function. This property will be ignored."):z?Fs(!z,`Route "${d.id}" has a static property "${C}" defined but its lazy function is also returning a value for this property. The lazy route property "${C}" will be ignored.`):w[C]=A}Object.assign(d,w),Object.assign(d,{...o(d),lazy:void 0})})();return S0.set(d,y),y.catch(()=>{}),{lazyRoutePromise:y,lazyHandlerPromise:y}}let u=Object.keys(t.lazy),m=[],p;for(let b of u){if(l&&l.includes(b))continue;let y=O1({key:b,route:t,manifest:r,mapRouteProperties:o});
72y&&(m.push(y),b===a&&(p=y))}let x=m.length>0?Promise.all(m).then(()=>{}):void 0;return x==null||x.catch(()=>{}),p==null||p.catch(()=>{}),{lazyRoutePromise:x,lazyHandlerPromise:p}}async function C0(t){let a=t.matches.filter(o=>o.shouldLoad),r={};return(await Promise.all(a.map(o=>o.resolve()))).forEach((o,l)=>{r[a[l].route.id]=o}),r}async function _5(t){return t.matches.some(a=>a.route.middleware)?M1(t,()=>C0(t)):C0(t)}function M1(t,a){return L5(t,a,o=>{if(Y5(o))throw o;return o},V5,r);async function r(o,l,d){var u;if(d)return Object.assign(d.value,{[l]:{type:"error",result:o}});{let{matches:m}=t,p=Math.min(Math.max(m.findIndex(b=>b.route.id===l),0),Math.max(m.findIndex(b=>b.shouldCallHandler()),0)),x=m[p].route.id;for(let b of m.slice(0,p+1))try{await((u=b._lazyPromises)==null?void 0:u.route)}catch{x=b.route.id;break}return{[ci(m,x).route.id]:{type:"error",result:o}}}}}async function L5(t,a,r,o,l){let{matches:d,...u}=t;return await U1(u,d.flatMap(m=>m.route.middleware?m.route.middleware.map(p=>[m.route.id,p]):[]),a,r,o,l)}async function U1(t,a,r,o,l,d,u=0){let{request:m}=t;if(m.signal.aborted)throw m.signal.reason??new Error(`Request aborted: ${m.method} ${m.url}`);let p=a[u];if(!p)return await r();let[x,b]=p,y,v=async()=>{if(y)throw new Error("You may only call `next()` once per middleware");try{return y={value:await U1(t,a,r,o,l,d,u+1)},y.value}catch(w){return y={value:await d(w,x,y)},y.value}};try{let w=await b(t,v),C=w!=null?o(w):void 0;return l(C)?C:y?C??y.value:(y={value:await v()},y.value)}catch(w){return await d(w,x,y)}}function P1(t,a,r,o,l){let d=O1({key:"middleware",route:o.route,manifest:a,mapRouteProperties:t}),u=R5(o.route,fa(r.method)?"action":"loader",a,t,l);return{middleware:d,route:u.lazyRoutePromise,handler:u.lazyHandlerPromise}}function Vf(t,a,r,o,l,d,u,m,p,x=null,b){let y=!1,v=P1(t,a,r,d,u);return{...d,_lazyPromises:v,shouldLoad:p,shouldRevalidateArgs:x,shouldCallHandler(w){return y=!0,x?typeof b=="boolean"?Cc(d,{...x,defaultShouldRevalidate:b}):typeof w=="boolean"?Cc(d,{...x,defaultShouldRevalidate:w}):Cc(d,x):p},resolve(w){let{lazy:C,loader:A,middleware:S}=d.route,z=y||p||w&&!fa(r.method)&&(C||A),T=S&&S.length>0&&!A&&!C;return z&&(fa(r.method)||!T)?O5({request:r,path:o,pattern:l,match:d,lazyHandlerPromise:v==null?void 0:v.handler,lazyRoutePromise:v==null?void 0:v.route,handlerOverride:w,scopedContext:m}):Promise.resolve({type:"data",result:void 0})}}}function Xo(t,a,r,o,l,d,u,m,p=null){return l.map(x=>x.route.id!==d.route.id?{...x,shouldLoad:!1,shouldRevalidateArgs:p,shouldCallHandler:()=>!1,_lazyPromises:P1(t,a,r,x,u),resolve:()=>Promise.resolve({type:"data",result:void 0})}:Vf(t,a,r,o,ll(l),x,u,m,!0,p))}async function D5(t,a,r,o,l,d,u){o.some(b=>{var y;return(y=b._lazyPromises)==null?void 0:y.middleware})&&await Promise.all(o.map(b=>{var y;return(y=b._lazyPromises)==null?void 0:y.middleware}));let m={request:a,url:Gx(a,r),pattern:ll(o),params:o[0].params,context:d,matches:o},x=await t({...m,fetcherKey:l,runClientMiddleware:b=>{let y=m;return M1(y,()=>b({...y,fetcherKey:l,runClientMiddleware:()=>{throw new Error("Cannot call `runClientMiddleware()` from within an `runClientMiddleware` handler")}}))}});try{await Promise.all(o.flatMap(b=>{var y,v;return[(y=b._lazyPromises)==null?void 0:y.handler,(v=b._lazyPromises)==null?void 0:v.route]}))}catch{}return x}async function O5({request:t,path:a,pattern:r,match:o,lazyHandlerPromise:l,lazyRoutePromise:d,handlerOverride:u,scopedContext:m}){let p,x,b=fa(t.method),y=b?"action":"loader",v=w=>{let C,A=new Promise((T,M)=>C=M);x=()=>C(),t.signal.addEventListener("abort",x);let S=T=>typeof w!="function"?Promise.reject(new Error(`You cannot call the handler for a route which defines a boolean "${y}" [routeId: ${o.route.id}]`)):w({request:t,url:Gx(t,a),pattern:r,params:o.params,context:m},...T!==void 0?[T]:[]),z=(async()=>{try{return{type:"data",result:await(u?u(T=>S(T)):S())}}catch(T){return{type:"error",result:T}}})();return Promise.race([z,A])};try{let w=b?o.route.action:o.route.loader;if(l||d)if(w){let C,[A]=await Promise.all([v(w).catch(S=>{C=S}),l,d]);if(C!==void 0)throw C;p=A}else{await l;let C=b?o.route.action:o.route.loader;if(C)[p]=await Promise.all([v(C),d]);else if(y==="action"){let A=new URL(t.url),S=A.pathname+A.search;throw sn(405,{method:t.method,pathname:S,routeId:o.route.id})}else return{type:"data",result:void 0}}else if(w)p=await v(w);else{let C=new URL(t.url);throw sn(404,{pathname:C.pathname+C.search})}}catch(w){return{type:"error",result:w}}finally{x&&t.signal.removeEventListener("abort",x)}return p}async function M5(t){let a=t.headers.get("Content-Type");return a&&/\bapplication\/json\b/.test(a)?t.body==null?null:t.json():t.text()}async function U5(t){var o,l,d,u,m;let{result:a,type:r}=t;if(Jx(a)){let p;try{p=await M5(a)}catch(x){return{type:"error",error:x}}return r==="error"?{type:"error",error:new Yc(a.status,a.statusText,p),statusCode:a.status,headers:a.headers}:{type:"data",data:p,statusCode:a.status,headers:a.headers}}return r==="error"?z0(a)?a.data instanceof Error?{type:"error",error:a.data,statusCode:(o=a.init)==null?void 0:o.status,headers:(l=a.init)!=null&&l.headers?new Headers(a.init.headers):void 0}:{type:"error",error:$5(a),statusCode:Hc(a)?a.status:void 0,headers:(d=a.init)!=null&&d.headers?new Headers(a.init.headers):void 0}:{type:"error",error:a,statusCode:Hc(a)?a.status:void 0}:z0(a)?{type:"data",data:a.data,statusCode:(u=a.init)==null?void 0:u.status,headers:(m=a.init)!=null&&m.headers?new Headers(a.init.headers):void 0}:{type:"data",data:a}}function P5(t,a,r,o,l){let d=t.headers.get("Location");if(pt(d,"Redirects returned/thrown from loaders/actions must have a Location header"),!qx(d)){let u=o.slice(0,o.findIndex(m=>m.route.id===r)+1);d=$f(new URL(a.url),u,l,d),t.headers.set("Location",d)}return t}const K5=["about:","blob:","chrome:","chrome-untrusted:","content:","data:","devtools:","file:","filesystem:","javascript:"];function Ff(t){try{return K5.includes(new URL(t).protocol)}catch{return!1}}function k0(t,a,r,o){if(qx(t)){let l=t,d=Wx.test(l)?new URL(x1(l,a.protocol)):new URL(l);if(Ff(d.toString()))throw new Error("Invalid redirect location");let u=on(d.pathname,r)!=null;if(d.origin===a.origin&&u)return Yx(d.pathname)+d.search+d.hash}try{if(Ff(o.createURL(t).toString()))throw new Error("Invalid redirect location")}catch{}return t}function Yo(t,a,r,o){let l=t.createURL(K1(a)).toString(),d={signal:r};if(o&&fa(o.formMethod)){let{formMethod:u,formEncType:m}=o;d.method=u.toUpperCase(),m==="application/json"?(d.headers=new Headers({"Content-Type":m}),d.body=JSON.stringify(o.json)):m==="text/plain"?d.body=o.text:m==="application/x-www-form-urlencoded"&&o.formData?d.body=Wf(o.formData):d.body=o.formData}
72return new Request(l,d)}function Wf(t){let a=new URLSearchParams;for(let[r,o]of t.entries())a.append(r,typeof o=="string"?o:o.name);return a}function T0(t){let a=new FormData;for(let[r,o]of t.entries())a.append(r,o);return a}function I5(t,a,r,o=!1,l=!1){let d={},u=null,m,p=!1,x={},b=r&&$a(r[1])?r[1].error:void 0;return t.forEach(y=>{if(!(y.route.id in a))return;let v=y.route.id,w=a[v];if(pt(!Gi(w),"Cannot handle redirect results in processLoaderData"),$a(w)){let C=w.error;if(b!==void 0&&(C=b,b=void 0),u=u||{},l)u[v]=C;else{let A=ci(t,v);u[A.route.id]==null&&(u[A.route.id]=C)}o||(d[v]=_1),p||(p=!0,m=Hc(w.error)?w.error.status:500),w.headers&&(x[v]=w.headers)}else d[v]=w.data,w.statusCode&&w.statusCode!==200&&!p&&(m=w.statusCode),w.headers&&(x[v]=w.headers)}),b!==void 0&&r&&(u={[r[0]]:b},r[2]&&(d[r[2]]=void 0)),{loaderData:d,errors:u,statusCode:m||200,loaderHeaders:x}}function A0(t,a,r,o,l,d,u){let{loaderData:m,errors:p}=I5(a,r,o);return l.filter(x=>!x.matches||x.matches.some(b=>b.shouldLoad)).forEach(x=>{let{key:b,match:y,controller:v}=x;if(v&&v.signal.aborted)return;let w=d[b];if(pt(w,"Did not find corresponding fetcher result"),$a(w)){let C=ci(t.matches,y==null?void 0:y.route.id);p&&p[C.route.id]||(p={...p,[C.route.id]:w.error}),u.delete(b)}else if(Gi(w))pt(!1,"Unhandled fetcher revalidation redirect");else{let C=On(w.data);u.set(b,C)}}),{loaderData:m,errors:p}}function E0(t,a,r,o){let l=Object.entries(a).filter(([,d])=>d!==_1).reduce((d,[u,m])=>(d[u]=m,d),{});for(let d of r){let u=d.route.id;if(!a.hasOwnProperty(u)&&t.hasOwnProperty(u)&&d.route.loader&&(l[u]=t[u]),o&&o.hasOwnProperty(u))break}return l}function H0(t){return t?$a(t[1])?{actionData:{}}:{actionData:{[t[0]]:t[1].data}}:{}}function ci(t,a){return(a?t.slice(0,t.findIndex(r=>r.route.id===a)+1):[...t]).reverse().find(r=>r.route.ErrorBoundary!=null||r.route.errorElement!=null)||t[0]}function fu(t){let a=t.length===1?t[0]:t.find(r=>r.index||!r.path||r.path==="/")||{id:"__shim-error-route__"};return{matches:[{params:{},pathname:"",pathnameBase:"",route:a}],route:a}}function sn(t,{pathname:a,routeId:r,method:o,type:l,message:d}={}){let u="Unknown Server Error",m="Unknown @remix-run/router error";return t===400?(u="Bad Request",o&&a&&r?m=`You made a ${o} request to "${a}" but did not provide a \`loader\` for route "${r}", so there is no way to handle the request.`:l==="invalid-body"&&(m="Unable to encode submission body")):t===403?(u="Forbidden",m=`Route "${r}" does not match URL "${a}"`):t===404?(u="Not Found",m=`No route matches URL "${a}"`):t===405&&(u="Method Not Allowed",o&&a&&r?m=`You made a ${o.toUpperCase()} request to "${a}" but did not provide an \`action\` for route "${r}", so there is no way to handle the request.`:o&&(m=`Invalid request method "${o.toUpperCase()}"`)),new Yc(t||500,u,new Error(m),!0)}function xu(t){let a=Object.entries(t);for(let r=a.length-1;r>=0;r--){let[o,l]=a[r];if(Gi(l))return{key:o,result:l}}}function K1(t){return qn({...typeof t=="string"?Zn(t):t,hash:""})}function B5(t,a){return t.pathname!==a.pathname||t.search!==a.search?!1:t.hash===""?a.hash!=="":t.hash===a.hash?!0:a.hash!==""}function $5(t){var a,r;return new Yc(((a=t.init)==null?void 0:a.status)??500,((r=t.init)==null?void 0:r.statusText)??"Internal Server Error",t.data)}function V5(t){return t!=null&&typeof t=="object"&&Object.entries(t).every(([a,r])=>typeof a=="string"&&F5(r))}function F5(t){return t!=null&&typeof t=="object"&&"type"in t&&"result"in t&&(t.type==="data"||t.type==="error")}function W5(t){return Jx(t.result)&&z1.has(t.result.status)}function $a(t){return t.type==="error"}function Gi(t){return(t&&t.type)==="redirect"}function z0(t){return typeof t=="object"&&t!=null&&"type"in t&&"data"in t&&"init"in t&&t.type==="DataWithResponseInit"}function Jx(t){return t!=null&&typeof t.status=="number"&&typeof t.statusText=="string"&&typeof t.headers=="object"&&typeof t.body<"u"}function q5(t){return z1.has(t)}function Y5(t){return Jx(t)&&q5(t.status)&&t.headers.has("Location")}function G5(t){return S5.has(t.toUpperCase())}function fa(t){return w5.has(t.toUpperCase())}function Xx(t){return new URLSearchParams(t).getAll("index").some(a=>a==="")}
72function Eu(t,a){let r=typeof a=="string"?Zn(a).search:a.search;if(t[t.length-1].route.index&&Xx(r||""))return t[t.length-1];let o=C1(t);return o[o.length-1]}function R0(t,a,r){var o;return{url:Gx(t.createURL(a),a),pattern:r?ll(r):"",params:(o=r==null?void 0:r[0])!=null&&o.params?{...r[0].params}:{}}}function _0(t){let{formMethod:a,formAction:r,formEncType:o,text:l,formData:d,json:u}=t;if(!(!a||!r||!o)){if(l!=null)return{formMethod:a,formAction:r,formEncType:o,formData:void 0,json:void 0,text:l};if(d!=null)return{formMethod:a,formAction:r,formEncType:o,formData:d,json:void 0,text:void 0};if(u!==void 0)return{formMethod:a,formAction:r,formEncType:o,formData:void 0,json:u,text:void 0}}}function lf(t,a,r,o){return o?{state:"loading",location:t,matches:a,historyAction:r,formMethod:o.formMethod,formAction:o.formAction,formEncType:o.formEncType,formData:o.formData,json:o.json,text:o.text}:{state:"loading",location:t,matches:a,historyAction:r,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0}}function Z5(t,a,r,o){return{state:"submitting",location:t,matches:a,historyAction:r,formMethod:o.formMethod,formAction:o.formAction,formEncType:o.formEncType,formData:o.formData,json:o.json,text:o.text}}function lc(t,a){return t?{state:"loading",formMethod:t.formMethod,formAction:t.formAction,formEncType:t.formEncType,formData:t.formData,json:t.json,text:t.text,data:a}:{state:"loading",formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:a}}function J5(t,a){return{state:"submitting",formMethod:t.formMethod,formAction:t.formAction,formEncType:t.formEncType,formData:t.formData,json:t.json,text:t.text,data:a?a.data:void 0}}function On(t){return{state:"idle",formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:t}}function X5(t,a){try{let r=t.sessionStorage.getItem(R1);if(r){let o=JSON.parse(r);for(let[l,d]of Object.entries(o||{}))d&&Array.isArray(d)&&a.set(l,new Set(d||[]))}}catch{}}function Q5(t,a){if(a.size>0){let r={};for(let[o,l]of a)r[o]=[...l];try{t.sessionStorage.setItem(R1,JSON.stringify(r))}catch(o){Fs(!1,`Failed to save applied view transitions in sessionStorage (${o}).`)}}}function L0(){let t,a,r=new Promise((o,l)=>{t=async d=>{o(d);try{await r}catch{}},a=async d=>{l(d);try{await r}catch{}}});return{promise:r,resolve:t,reject:a}}/**
73 * react-router v8.3.0
74 *
75 * Copyright (c) Remix Software Inc.
76 *
77 * This source code is licensed under the MIT license found in the
78 * LICENSE.md file in the root directory of this source tree.
79 *
80 * @license MIT
81 */const ro=g.createContext(null);ro.displayName="DataRouter";const cl=g.createContext(null);cl.displayName="DataRouterState";const I1=g.createContext(!1);function B1(){return g.useContext(I1)}const Qx=g.createContext({isTransitioning:!1});Qx.displayName="ViewTransition";const $1=g.createContext(new Map);$1.displayName="Fetchers";const e3=g.createContext(null);e3.displayName="Await";const za=g.createContext(null);za.displayName="Navigation";const Mm=g.createContext(null);Mm.displayName="Location";const cn=g.createContext({outlet:null,matches:[],isDataRoute:!1});cn.displayName="Route";const eg=g.createContext(null);eg.displayName="RouteError";/**
82 * react-router v8.3.0
83 *
84 * Copyright (c) Remix Software Inc.
85 *
86 * This source code is licensed under the MIT license found in the
87 * LICENSE.md file in the root directory of this source tree.
88 *
89 * @license MIT
90 */const V1="REACT_ROUTER_ERROR",t3="REDIRECT",s3="ROUTE_ERROR_RESPONSE";function a3(t){if(t.startsWith(`${V1}:${t3}:{`))try{let a=JSON.parse(t.slice(28));if(typeof a=="object"&&a&&typeof a.status=="number"&&typeof a.statusText=="string"&&typeof a.location=="string"&&typeof a.reloadDocument=="boolean"&&typeof a.replace=="boolean")return a}catch{}}function n3(t){if(t.startsWith(`${V1}:${s3}:{`))try{let a=JSON.parse(t.slice(40));if(typeof a=="object"&&a&&typeof a.status=="number"&&typeof a.statusText=="string")return new Yc(a.status,a.statusText,a.data)}catch{}}/**
91 * react-router v8.3.0
92 *
93 * Copyright (c) Remix Software Inc.
94 *
95 * This source code is licensed under the MIT license found in the
96 * LICENSE.md file in the root directory of this source tree.
97 *
98 * @license MIT
99 */function r3(t,{relative:a}={}){pt(dl(),"useHref() may be used only in the context of a <Router> component.");let{basename:r,navigator:o}=g.useContext(za),{hash:l,pathname:d,search:u}=Gc(t,{relative:a}),m=d;return r!=="/"&&(m=d==="/"?r:rn([r,d])),o.createHref({pathname:m,search:u,hash:l})}function dl(){return g.useContext(Mm)!=null}function la(){return pt(dl(),"useLocation() may be used only in the context of a <Router> component."),g.useContext(Mm).location}const F1="You should call navigate() in a React.useEffect(), not when your component is first rendered.";function ga(){let{isDataRoute:t}=g.useContext(cn);return t?j3():i3()}function i3(){pt(dl(),"useNavigate() may be used only in the context of a <Router> component.");let t=g.useContext(ro),{basename:a,navigator:r}=g.useContext(za),{matches:o}=g.useContext(cn),{pathname:l}=la(),d=JSON.stringify(Om(o)),u=g.useRef(!1);return g.useLayoutEffect(()=>{u.current=!0}),g.useCallback((m,p={})=>
99{if(Fs(u.current,F1),!u.current)return;if(typeof m=="number"){r.go(m);return}let x=qc(m,JSON.parse(d),l,p.relative==="path");t==null&&a!=="/"&&(x.pathname=x.pathname==="/"?a:rn([a,x.pathname])),(p.replace?r.replace:r.push)(x,p.state,p)},[a,r,d,l,t])}const o3=g.createContext(null);function l3(t){let a=g.useContext(cn).outlet;return g.useMemo(()=>a&&g.createElement(o3.Provider,{value:t},a),[a,t])}function W1(){var a;let{matches:t}=g.useContext(cn);return((a=t[t.length-1])==null?void 0:a.params)??{}}function Gc(t,{relative:a}={}){let{matches:r}=g.useContext(cn),{pathname:o}=la(),l=JSON.stringify(Om(r));return g.useMemo(()=>qc(t,JSON.parse(l),o,a==="path"),[t,l,o,a])}function c3(t,a,r){pt(dl(),"useRoutes() may be used only in the context of a <Router> component.");let{navigator:o}=g.useContext(za),{matches:l}=g.useContext(cn),d=l[l.length-1],u=d?d.params:{};d&&d.pathname;let m=d?d.pathnameBase:"/";d&&d.route;let p=la(),x;x=p;let b=x.pathname||"/",y=b;if(m!=="/"){let C=m.replace(/^\//,"").split("/");y="/"+b.replace(/^\//,"").split("/").slice(C.length).join("/")}let v=r&&r.state.matches.length?r.state.matches.map(C=>Object.assign(C,{route:r.manifest[C.route.id]||C.route})):y1(t,{pathname:y});return f3(v&&v.map(C=>Object.assign({},C,{params:Object.assign({},u,C.params),pathname:rn([m,o.encodeLocation?o.encodeLocation(C.pathname.replace(/%/g,"%25").replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:C.pathname]),pathnameBase:C.pathnameBase==="/"?m:rn([m,o.encodeLocation?o.encodeLocation(C.pathnameBase.replace(/%/g,"%25").replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:C.pathnameBase])})),l,r)}function d3(){let t=v3(),a=Hc(t)?`${t.status} ${t.statusText}`:t instanceof Error?t.message:JSON.stringify(t),r=t instanceof Error?t.stack:null;return g.createElement(g.Fragment,null,g.createElement("h2",null,"Unexpected Application Error!"),g.createElement("h3",{style:{fontStyle:"italic"}},a),r?g.createElement("pre",{style:{padding:"0.5rem",backgroundColor:"rgba(200,200,200, 0.5)"}},r):null,null)}const u3=g.createElement(d3,null);var Uf,m3=(Uf=class extends g.Component{constructor(t){super(t),this.state={location:t.location,revalidation:t.revalidation,error:t.error}}static getDerivedStateFromError(t){return{error:t}}static getDerivedStateFromProps(t,a){return a.location!==t.location||a.revalidation!=="idle"&&t.revalidation==="idle"?{error:t.error,location:t.location,revalidation:t.revalidation}:{error:t.error!==void 0?t.error:a.error,location:a.location,revalidation:t.revalidation||a.revalidation}}componentDidCatch(t,a){this.props.onError?this.props.onError(t,a):console.error("React Router caught the following error during render",t)}render(){let t=this.state.error;if(this.context&&typeof t=="object"&&t&&"digest"in t&&typeof t.digest=="string"){const r=n3(t.digest);r&&(t=r)}let a=t!==void 0?g.createElement(cn.Provider,{value:this.props.routeContext},g.createElement(eg.Provider,{value:t,children:this.props.component})):this.props.children;return this.context?g.createElement(h3,{error:t},a):a}},ma(Uf,"contextType",I1),Uf);const cf=new WeakMap;function h3({children:t,error:a}){let{basename:r}=g.useContext(za);if(typeof a=="object"&&a&&"digest"in a&&typeof a.digest=="string"){let o=a3(a.digest);if(o){let l=cf.get(a);if(l)throw l;let d=A1(o.location,r),u=d.absoluteURL||d.to;if(Ff(u))throw new Error("Invalid redirect location");if(T1&&!cf.get(a))if(d.isExternal||o.reloadDocument)window.location.href=u;else{const m=Promise.resolve().then(()=>window.__reactRouterDataRouter.navigate(d.to,{replace:o.replace}));throw cf.set(a,m),m}return g.createElement("meta",{httpEquiv:"refresh",content:`0;url=${u}`})}}return t}function p3({routeContext:t,match:a,children:r}){let o=g.useContext(ro);return o&&o.static&&o.staticContext&&(a.route.errorElement||a.route.ErrorBoundary)&&(o.staticContext._deepestRenderedBoundaryId=a.route.id),g.createElement(cn.Provider,{value:t},r)}function f3(t,a=[],r){let o=r==null?void 0:r.state;if(t==null){if(!o)return null;if(o.errors)t=o.matches;else if(a.length===0&&!o.initialized&&o.matches.length>0)t=o.matches;else return null}let l=t,d=o==null?void 0:o.errors;if(d!=null){let b=l.findIndex(y=>y.route.id&&(d==null?void 0:d[y.route.id])!==void 0);pt(b>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(d).join(",")}`),l=l.slice(0,Math.min(l.length,b+1))}let u=!1,m=-1;if(r&&o){u=o.renderFallback;for(let b=0;b<l.length;b++){let y=l[b];if((y.route.HydrateFallback||y.route.hydrateFallbackElement)&&(m=b),y.route.id){let{loaderData:v,errors:w}
99=o,C=y.route.loader&&!v.hasOwnProperty(y.route.id)&&(!w||w[y.route.id]===void 0);if(y.route.lazy||C){r.isStatic&&(u=!0),m>=0?l=l.slice(0,m+1):l=[l[0]];break}}}}let p=r==null?void 0:r.onError,x=o&&p?(b,y)=>{var v,w;p(b,{location:o.location,params:((w=(v=o.matches)==null?void 0:v[0])==null?void 0:w.params)??{},pattern:ll(o.matches),errorInfo:y})}:void 0;return l.reduceRight((b,y,v)=>{let w,C=!1,A=null,S=null;o&&(w=d&&y.route.id?d[y.route.id]:void 0,A=y.route.errorElement||u3,u&&(m<0&&v===0?(w3("route-fallback",!1,"No `HydrateFallback` element provided to render during initial hydration"),C=!0,S=null):m===v&&(C=!0,S=y.route.hydrateFallbackElement||null)));let z=a.concat(l.slice(0,v+1)),T=()=>{let M;return w?M=A:C?M=S:y.route.Component?M=g.createElement(y.route.Component,null):y.route.element?M=y.route.element:M=b,g.createElement(p3,{match:y,routeContext:{outlet:b,matches:z,isDataRoute:o!=null},children:M})};return o&&(y.route.ErrorBoundary||y.route.errorElement||v===0)?g.createElement(m3,{location:o.location,revalidation:o.revalidation,component:A,error:w,children:T(),routeContext:{outlet:null,matches:z,isDataRoute:!0},onError:x}):T()},null)}function tg(t){return`${t} must be used within a data router.  See https://reactrouter.com/en/main/routers/picking-a-router.`}function x3(t){let a=g.useContext(ro);return pt(a,tg(t)),a}function Um(t){let a=g.useContext(cl);return pt(a,tg(t)),a}function g3(t){let a=g.useContext(cn);return pt(a,tg(t)),a}function Pm(t){let a=g3(t),r=a.matches[a.matches.length-1];return pt(r.route.id,`${t} can only be used on routes that contain a unique "id"`),r.route.id}function b3(){return Pm("useRouteId")}function y3(){let t=Um("useNavigation");return g.useMemo(()=>{let{matches:a,historyAction:r,...o}=t.navigation;return o},[t.navigation])}function q1(){let{matches:t,loaderData:a}=Um("useMatches");return g.useMemo(()=>t.map(r=>v1(r,a)),[t,a])}function sg(){let t=Um("useLoaderData"),a=Pm("useLoaderData");return t.loaderData[a]}function v3(){var o;let t=g.useContext(eg),a=Um("useRouteError"),r=Pm("useRouteError");return t!==void 0?t:(o=a.errors)==null?void 0:o[r]}function j3(){let{router:t}=x3("useNavigate"),a=Pm("useNavigate"),r=g.useRef(!1);return g.useLayoutEffect(()=>{r.current=!0}),g.useCallback(async(o,l={})=>{Fs(r.current,F1),r.current&&(typeof o=="number"?await t.navigate(o):await t.navigate(o,{fromRouteId:a,...l}))},[t,a])}const D0={};function w3(t,a,r){D0[t]||(D0[t]=!0,Fs(!1,r))}/**
100 * react-router v8.3.0
101 *
102 * Copyright (c) Remix Software Inc.
103 *
104 * This source code is licensed under the MIT license found in the
105 * LICENSE.md file in the root directory of this source tree.
106 *
107 * @license MIT
108 */const O0={};function M0(t,a){!t&&!O0[a]&&(O0[a]=!0,console.warn(a))}/**
109 * react-router v8.3.0
110 *
111 * Copyright (c) Remix Software Inc.
112 *
113 * This source code is licensed under the MIT license found in the
114 * LICENSE.md file in the root directory of this source tree.
115 *
116 * @license MIT
117 */const N3=["HydrateFallback","hydrateFallbackElement"];var S3=class{constructor(){ma(this,"status","pending");ma(this,"promise");ma(this,"resolve");ma(this,"reject");this.promise=new Promise((t,a)=>{this.resolve=r=>{this.status==="pending"&&(this.status="resolved",t(r))},this.reject=r=>{this.status==="pending"&&(this.status="rejected",a(r))}})}};function C3({router:t,flushSync:a,onError:r,useTransitions:o}){o=B1()||o;let[l,d]=g.useState(t.state),[u,m]=g.useOptimistic(l),[p,x]=g.useState(),[b,y]=g.useState({isTransitioning:!1}),[v,w]=g.useState(),[C,A]=g.useState(),[S,z]=g.useState(),T=g.useRef(new Map),M=g.useCallback((q,{deletedFetchers:H,newErrors:J,flushSync:B,viewTransitionOpts:Y})=>{J&&r&&Object.values(J).forEach(D=>{var W;return r(D,{location:q.location,params:((W=q.matches[0])==null?void 0:W.params)??{},pattern:ll(q.matches)})}),q.fetchers.forEach((D,W)=>{D.data!==void 0&&T.current.set(W,D.data)}),H.forEach(D=>T.current.delete(D)),M0(B===!1||a!=null,'You provided the `flushSync` option to a router update, but you are not using the `<RouterProvider>` from `react-router/dom` so `ReactDOM.flushSync()` is unavailable.  Please update your app to `import { RouterProvider } from "react-router/dom"` and ensure you have `react-dom` installed as a dependency to use the `flushSync` option.');let $=t.window!=null&&t.window.document!=null&&typeof t.window.document.startViewTransition=="function";if(M0(Y==null||$,"You provided the `viewTransition` option to a router update, but you do not appear to be running in a DOM environment as `window.startViewTransition` is not available."),!Y||!$){a&&B?a(()=>d(q)):o===!1?d(q):g.startTransition(()=>{o===!0&&m(D=>U0(D,q)),d(q)});return}if(a&&B){a(()=>{C&&(v==null||v.resolve(),C.skipTransition()),y({isTransitioning:!0,flushSync:!0,currentLocation:Y.currentLocation,nextLocation:Y.nextLocation})});let D=t.window.document.startViewTransition(()=>{a(()=>d(q))});D.finished.finally(()=>{a(()=>{w(void 0),A(void 0),x(void 0),y({isTransitioning:!1})})}),a(()=>A(D));return}C?(v==null||v.resolve(),C.skipTransition(),z({state:q,currentLocation:Y.currentLocation,nextLocation:Y.nextLocation})):(x(q),y({isTransitioning:!0,flushSync:!1,currentLocation:Y.currentLocation,nextLocation:Y.nextLocation}))},[t.window,a,C,v,o,m,r]);g.useLayoutEffect(()=>t.subscribe(M),[t,M]),g.useEffect(()=>{b.isTransitioning&&!b.flushSync&&w(new S3)},[b]),g.useEffect(()=>{if(v&&p&&t.window){let q=p,H=v.promise,J=t.window.document.startViewTransition(async()=>{o===!1?d(q):g.startTransition(()=>{o===!0&&m(B=>U0(B,q)),d(q)}),await H});J.finished.finally(()=>{w(void 0),A(void 0),x(void 0),y({isTransitioning:!1})}),A(J)}},[p,v,t.window,o,m]),g.useEffect(()=>{v&&p&&u.location.key===p.location.key&&v.resolve()},[v,C,u.location,p]),g.useEffect(()=>{!b.isTransitioning&&S&&(x(S.state),y({isTransitioning:!0,flushSync:!1,currentLocation:S.currentLocation,nextLocation:S.nextLocation}),z(void 0))},[b.isTransitioning,S]);let P=g.useMemo(()=>({createHref:t.createHref,encodeLocation:t.encodeLocation,go:q=>t.navigate(q),push:(q,H,J)=>t.navigate(q,{state:H,preventScrollReset:J==null?void 0:J.preventScrollReset}),replace:(q,H,J)=>t.navigate(q,{replace:!0,state:H,preventScrollReset:J==null?void 0:J.preventScrollReset})}),[t]),E=t.basename||"/",U=g.useMemo(()=>({router:t,navigator:P,static:!1,basename:E,onError:r}),[t,P,E,r]);return g.createElement(g.Fragment,null,g.createElement(ro.Provider,{value:U},g.createElement(cl.Provider,{value:u}
117,g.createElement($1.Provider,{value:T.current},g.createElement(Qx.Provider,{value:b},g.createElement(E3,{basename:E,location:u.location,navigationType:u.historyAction,navigator:P,useTransitions:o},g.createElement(k3,{routes:t.routes,manifest:t.manifest,future:t.future,state:u,isStatic:!1,onError:r})))))),null)}function U0(t,a){return{...t,navigation:a.navigation.state!=="idle"?a.navigation:t.navigation,revalidation:a.revalidation!=="idle"?a.revalidation:t.revalidation,actionData:a.navigation.state!=="submitting"?a.actionData:t.actionData,fetchers:a.fetchers}}const k3=g.memo(T3);function T3({routes:t,manifest:a,future:r,state:o,isStatic:l,onError:d}){return c3(t,void 0,{manifest:a,state:o,isStatic:l,onError:d})}function yi({to:t,replace:a,state:r,relative:o}){pt(dl(),"<Navigate> may be used only in the context of a <Router> component.");let{static:l}=g.useContext(za);Fs(!l,"<Navigate> must not be used on the initial render in a <StaticRouter>. This is a no-op, but you should modify your code so the <Navigate> is only ever rendered in response to some user interaction or state change.");let{matches:d}=g.useContext(cn),{pathname:u}=la(),m=ga(),p=qc(t,Om(d),u,o==="path"),x=JSON.stringify(p);return g.useEffect(()=>{m(JSON.parse(x),{replace:a,state:r,relative:o})},[m,x,o,a,r]),null}function A3(t){return l3(t.context)}function E3({basename:t="/",children:a=null,location:r,navigationType:o="POP",navigator:l,static:d=!1,useTransitions:u}){pt(!dl(),"You cannot render a <Router> inside another <Router>. You should never have more than one in your app.");let m=t.replace(/^\/*/,"/"),p=g.useMemo(()=>({basename:m,navigator:l,static:d,useTransitions:u,future:{}}),[m,l,d,u]);typeof r=="string"&&(r=Zn(r));let{pathname:x="/",search:b="",hash:y="",state:v=null,key:w="default",mask:C}=r,A=g.useMemo(()=>{let S=on(x,m);return S==null?null:{location:{pathname:S,search:b,hash:y,state:v,key:w,mask:C},navigationType:o}}
117,[m,x,b,y,v,w,o,C]);return Fs(A!=null,`<Router basename="${m}"> is not able to match the URL "${x}${b}${y}" because it does not start with the basename, so the <Router> won't render anything.`),A==null?null:g.createElement(za.Provider,{value:p},g.createElement(Mm.Provider,{children:a,value:A}))}/**
118 * react-router v8.3.0
119 *
120 * Copyright (c) Remix Software Inc.
121 *
122 * This source code is licensed under the MIT license found in the
123 * LICENSE.md file in the root directory of this source tree.
124 *
125 * @license MIT
126 */const Hu="application/x-www-form-urlencoded";function Km(t){return typeof HTMLElement<"u"&&t instanceof HTMLElement}function H3(t){return Km(t)&&t.tagName.toLowerCase()==="button"}function z3(t){return Km(t)&&t.tagName.toLowerCase()==="form"}function R3(t){return Km(t)&&t.tagName.toLowerCase()==="input"}function _3(t){return!!(t.metaKey||t.altKey||t.ctrlKey||t.shiftKey)}function L3(t,a){return t.button===0&&(!a||a==="_self")&&!_3(t)}function qf(t=""){return new URLSearchParams(typeof t=="string"||Array.isArray(t)||t instanceof URLSearchParams?t:Object.keys(t).reduce((a,r)=>{let o=t[r];return a.concat(Array.isArray(o)?o.map(l=>[r,l]):[[r,o]])},[]))}function D3(t,a){let r=qf(t);return a&&a.forEach((o,l)=>{r.has(l)||a.getAll(l).forEach(d=>{r.append(l,d)})}),r}let gu=null;function O3(){if(gu===null)try{new FormData(document.createElement("form"),0),gu=!1}catch{gu=!0}return gu}const M3=new Set(["application/x-www-form-urlencoded","multipart/form-data","text/plain"]);function df(t){return t!=null&&!M3.has(t)?(Fs(!1,`"${t}" is not a valid \`encType\` for \`<Form>\`/\`<fetcher.Form>\` and will default to "${Hu}"`),null):t}function U3(t,a){let r,o,l,d,u;if(z3(t)){let m=t.getAttribute("action");o=m?on(m,a):null,r=t.getAttribute("method")||"get",l=df(t.getAttribute("enctype"))||Hu,d=new FormData(t)}else if(H3(t)||R3(t)&&(t.type==="submit"||t.type==="image")){let m=t.form;if(m==null)throw new Error('Cannot submit a <button> or <input type="submit"> without a <form>');let p=t.getAttribute("formaction")||m.getAttribute("action");if(o=p?on(p,a):null,r=t.getAttribute("formmethod")||m.getAttribute("method")||"get",l=df(t.getAttribute("formenctype"))||df(m.getAttribute("enctype"))||Hu,d=new FormData(m,t),!O3()){let{name:x,type:b,value:y}=t;if(b==="image"){let v=x?`${x}.`:"";d.append(`${v}x`,"0"),d.append(`${v}y`,"0")}else x&&d.append(x,y)}}else{if(Km(t))throw new Error('Cannot submit element that is not <form>, <button>, or <input type="submit|image">');r="get",o=null,l=Hu,u=t}return d&&l==="text/plain"&&(u=d,d=void 0),{action:o,method:r.toLowerCase(),encType:l,formData:d,body:u}}/**
127 * react-router v8.3.0
128 *
129 * Copyright (c) Remix Software Inc.
130 *
131 * This source code is licensed under the MIT license found in the
132 * LICENSE.md file in the root directory of this source tree.
133 *
134 * @license MIT
135 */function ag(t,a){if(t===!1||t===null||typeof t>"u")throw new Error(a)}/**
136 * react-router v8.3.0
137 *
138 * Copyright (c) Remix Software Inc.
139 *
140 * This source code is licensed under the MIT license found in the
141 * LICENSE.md file in the root directory of this source tree.
142 *
143 * @license MIT
144 */const P3={"&":"\\u0026",">":"\\u003e","<":"\\u003c","\u2028":"\\u2028","\u2029":"\\u2029"},K3=/[&><\u2028\u2029]/g;function P0(t){return t.replace(K3,a=>P3[a])}/**
145 * react-router v8.3.0
146 *
147 * Copyright (c) Remix Software Inc.
148 *
149 * This source code is licensed under the MIT license found in the
150 * LICENSE.md file in the root directory of this source tree.
151 *
152 * @license MIT
153 */function Y1(t,a){let r=typeof t=="string"?new URL(t,typeof window>"u"?"server://singlefetch/":window.location.origin):t;return r.pathname.endsWith("/")?r.pathname=`${r.pathname}_.${a}`:r.pathname=`${r.pathname}.${a}`,r}/**
154 * react-router v8.3.0
155 *
156 * Copyright (c) Remix Software Inc.
157 *
158 * This source code is licensed under the MIT license found in the
159 * LICENSE.md file in the root directory of this source tree.
160 *
161 * @license MIT
162 */async function I3(t,a){if(t.id in a)return a[t.id];try{let r=await import(t.module);return a[t.id]=r,r}catch(r){return console.error(`Error loading route module \`${t.module}\`, reloading page...`),console.error(r),window.__reactRouterContext&&window.__reactRouterContext.
162isSpaMode,window.location.reload(),new Promise(()=>{})}}/**
163 * react-router v8.3.0
164 *
165 * Copyright (c) Remix Software Inc.
166 *
167 * This source code is licensed under the MIT license found in the
168 * LICENSE.md file in the root directory of this source tree.
169 *
170 * @license MIT
171 */function B3(t){return t==null?!1:t.href==null?t.rel==="preload"&&typeof t.imageSrcSet=="string"&&typeof t.imageSizes=="string":typeof t.rel=="string"&&typeof t.href=="string"}async function $3(t,a,r){return q3((await Promise.all(t.map(async o=>{let l=a.routes[o.route.id];if(l){let d=await I3(l,r);return d.links?d.links():[]}return[]}))).flat(1).filter(B3).filter(o=>o.rel==="stylesheet"||o.rel==="preload").map(o=>o.rel==="stylesheet"?{...o,rel:"prefetch",as:"style"}:{...o,rel:"prefetch"}))}function K0(t,a,r,o,l,d){let u=(p,x)=>r[x]?p.route.id!==r[x].route.id:!0,m=(p,x)=>{var b;return r[x].pathname!==p.pathname||((b=r[x].route.path)==null?void 0:b.endsWith("*"))&&r[x].params["*"]!==p.params["*"]};return d==="assets"?a.filter((p,x)=>u(p,x)||m(p,x)):d==="data"?a.filter((p,x)=>{var y;let b=o.routes[p.route.id];if(!b||!b.hasLoader)return!1;if(u(p,x)||m(p,x))return!0;if(p.route.shouldRevalidate){let v=p.route.shouldRevalidate({currentUrl:new URL(l.pathname+l.search+l.hash,window.origin),currentParams:((y=r[0])==null?void 0:y.params)||{},nextUrl:new URL(t,window.origin),nextParams:p.params,defaultShouldRevalidate:!0});if(typeof v=="boolean")return v}return!0}):[]}function V3(t,a,{includeHydrateFallback:r}={}){return F3(t.map(o=>{let l=a.routes[o.route.id];if(!l)return[];let d=[l.module];return l.clientActionModule&&(d=d.concat(l.clientActionModule)),l.clientLoaderModule&&(d=d.concat(l.clientLoaderModule)),r&&l.hydrateFallbackModule&&(d=d.concat(l.hydrateFallbackModule)),l.imports&&(d=d.concat(l.imports)),d}).flat(1))}function F3(t){return[...new Set(t)]}function W3(t){let a={},r=Object.keys(t).sort();for(let o of r)a[o]=t[o];return a}function q3(t,a){let r=new Set;
171return new Set(a),t.reduce((o,l)=>{let d=JSON.stringify(W3(l));return r.has(d)||(r.add(d),o.push({key:d,link:l})),o},[])}/**
172 * react-router v8.3.0
173 *
174 * Copyright (c) Remix Software Inc.
175 *
176 * This source code is licensed under the MIT license found in the
177 * LICENSE.md file in the root directory of this source tree.
178 *
179 * @license MIT
180 */function Y3(){let t=g.useContext(ro);return ag(t,"You must render this element inside a <DataRouterContext.Provider> element"),t}function G3(){let t=g.useContext(cl);return ag(t,"You must render this element inside a <DataRouterStateContext.Provider> element"),t}const Im=g.createContext(void 0);Im.displayName="FrameworkContext";function ng(){let t=g.useContext(Im);return ag(t,"You must render this element inside a <HydratedRouter> element"),t}function Z3(t,a){let r=g.useContext(Im),[o,l]=g.useState(!1),[d,u]=g.useState(!1),{onFocus:m,onBlur:p,onMouseEnter:x,onMouseLeave:b,onTouchStart:y}=a,v=g.useRef(null);g.useEffect(()=>{if(t==="render"&&u(!0),t==="viewport"){let A=z=>{z.forEach(T=>{u(T.isIntersecting)})},S=new IntersectionObserver(A,{threshold:.5});return v.current&&S.observe(v.current),()=>{S.disconnect()}}},[t]),g.useEffect(()=>{if(o){let A=setTimeout(()=>{u(!0)},100);return()=>{clearTimeout(A)}}},[o]);let w=()=>{l(!0)},C=()=>{l(!1),u(!1)};return r?t!=="intent"?[d,v,{}]:[d,v,{onFocus:cc(m,w),onBlur:cc(p,C),onMouseEnter:cc(x,w),onMouseLeave:cc(b,C),onTouchStart:cc(y,w)}]:[!1,v,{}]}function cc(t,a){return r=>{t&&t(r),r.defaultPrevented||a(r)}}function J3({page:t,...a}){let r=B1(),{nonce:o}=ng(),{router:l}=Y3(),d=g.useMemo(()=>y1(l.routes,t,l.basename),[l.routes,t,l.basename]);return d?(a.nonce==null&&o&&(a={...a,nonce:o}),r?g.createElement(Q3,{page:t,matches:d,...a}):g.createElement(eC,{page:t,matches:d,...a})):null}function X3(t){let{manifest:a,routeModules:r}=ng(),[o,l]=g.useState([]);return g.useEffect(()=>{let d=!1;return $3(t,a,r).then(u=>{d||l(u)}),()=>{d=!0}},[t,a,r]),o}function Q3({page:t,matches:a,...r}){let o=la(),l=g.useMemo(()=>{if(t===o.pathname+o.search+o.hash)return[];let d=Y1(t,"rsc"),u=!1,m=[];for(let p of a)typeof p.route.shouldRevalidate=="function"?u=!0:m.push(p.route.id);return u&&m.length>0&&d.searchParams.set("_routes",m.join(",")),[d.pathname+d.search]},[t,o,a]);return g.createElement(g.Fragment,null,l.map(d=>g.createElement("link",{key:d,rel:"prefetch",as:"fetch",href:d,...r})))}function eC({page:t,matches:a,...r}){let o=la(),{manifest:l,routeModules:d}=ng(),{loaderData:u,matches:m}=G3(),p=g.useMemo(()=>K0(t,a,m,l,o,"data"),[t,a,m,l,o]),x=g.useMemo(()=>K0(t,a,m,l,o,"assets"),[t,a,m,l,o]),b=g.useMemo(()=>{if(t===o.pathname+o.search+o.hash)return[];let w=new Set,C=!1;if(a.forEach(S=>{var T;let z=l.routes[S.route.id];!z||!z.hasLoader||(!p.some(M=>M.route.id===S.route.id)&&S.route.id in u&&((T=d[S.route.id])!=null&&T.shouldRevalidate)||z.hasClientLoader?C=!0:w.add(S.route.id))}),w.size===0)return[];let A=Y1(t,"data");return C&&w.size>0&&A.searchParams.set("_routes",a.filter(S=>w.has(S.route.id)).map(S=>S.route.id).join(",")),[A.pathname+A.search]},[u,o,l,p,a,t,d]),y=g.useMemo(()=>V3(x,l),[x,l]),v=X3(x);return g.createElement(g.Fragment,null,b.map(w=>g.createElement("link",{key:w,rel:"prefetch",as:"fetch",href:w,...r})),y.map(w=>g.createElement("link",{key:w,rel:"modulepreload",href:w,...r})),v.map(({key:w,link:C})=>g.createElement("link",{key:w,nonce:r.nonce,...C,crossOrigin:C.crossOrigin??r.crossOrigin})))}function tC(...t){return a=>{t.forEach(r=>{typeof r=="function"?r(a):r!=null&&(r.current=a)})}}/**
181 * react-router v8.3.0
182 *
183 * Copyright (c) Remix Software Inc.
184 *
185 * This source code is licensed under the MIT license found in the
186 * LICENSE.md file in the root directory of this source tree.
187 *
188 * @license MIT
189 */const sC=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";try{sC&&(window.__reactRouterVersion="8.3.0")}catch{}function aC(t,a){return A5({basename:a==null?void 0:a.basename,getContext:a==null?void 0:a.getContext,future:a==null?void 0:a.future,history:F4({window:a==null?void 0:a.window}),hydrationData:nC(),routes:t,mapRouteProperties:b1,hydrationRouteProperties:N3,dataStrategy:a==null?void 0:a.dataStrategy,patchRoutesOnNavigation:a==null?void 0:a.patchRoutesOnNavigation,window:a==null?void 0:a.window,instrumentations:a==null?void 0:a.instrumentations}).initialize()}function nC(){let t=window==null?void 0:window.__staticRouterHydrationData;return t&&t.errors&&(t={...t,errors:rC(t.errors)}),t}function rC(t){if(!t)return null;let a=Object.entries(t),r={};for(let[o,l]of a)if(l&&l.__type==="RouteErrorResponse")r[o]=new Yc(l.status,l.statusText,l.data,l.internal===!0);else if(l&&l.__type==="Error"){if(typeof l.__subType=="string"&&g5.includes(l.__subType)){let d=window[l.__subType];if(typeof d=="function")try{let u=new d(l.message);u.stack="",r[o]=u}catch{}}if(r[o]==null){let d=new Error(l.message);d.stack="",r[o]=d}}else r[o]=l;return r}const O=g.forwardRef(function({onClick:a,discover:r="render",prefetch:o="none",relative:l,reloadDocument:d,replace:u,mask:m,state:p,target:x,to:b,preventScrollReset:y,viewTransition:v,defaultShouldRevalidate:w,...C},A){let{basename:S,navigator:z,useTransitions:T}
189=g.useContext(za),M=typeof b=="string"&&Dm.test(b),P=A1(b,S);b=P.to;let E=r3(b,{relative:l}),U=la(),q=null;if(m){let I=qc(m,[],U.mask?U.mask.pathname:"/",!0);S!=="/"&&(I.pathname=I.pathname==="/"?S:rn([S,I.pathname])),q=z.createHref(I)}let[H,J,B]=Z3(o,C),Y=cC(b,{replace:u,mask:m,state:p,target:x,preventScrollReset:y,relative:l,viewTransition:v,defaultShouldRevalidate:w,useTransitions:T});function $(I){a&&a(I),I.defaultPrevented||Y(I)}let D=!(P.isExternal||d),W=g.createElement("a",{...C,...B,href:(D?q:void 0)||P.absoluteURL||E,onClick:D?$:a,ref:tC(A,J),target:x,"data-discover":!M&&r==="render"?"true":void 0});return H&&!M?g.createElement(g.Fragment,null,W,g.createElement(J3,{page:E})):W});O.displayName="Link";const iC=g.forwardRef(function({"aria-current":a="page",caseSensitive:r=!1,className:o="",end:l=!1,style:d,to:u,viewTransition:m,children:p,...x},b){let y=Gc(u,{relative:x.relative}),v=la(),w=g.useContext(cl),{navigator:C,basename:A}=g.useContext(za),S=w!=null&&xC(y)&&m===!0,z=C.encodeLocation?C.encodeLocation(y).pathname:y.pathname,T=v.pathname,M=w&&w.navigation&&w.navigation.location?w.navigation.location.pathname:null;r||(T=T.toLowerCase(),M=M?M.toLowerCase():null,z=z.toLowerCase()),M&&A&&(M=on(M,A)||M);const P=z!=="/"&&z.endsWith("/")?z.length-1:z.length;let E=T===z||!l&&T.startsWith(z)&&T.charAt(P)==="/",U=M!=null&&(M===z||!l&&M.startsWith(z)&&M.charAt(P)==="/"),q={isActive:E,isPending:U,isTransitioning:S},H=E?a:void 0,J;typeof o=="function"?J=o(q):J=[o,E?"active":null,U?"pending":null,S?"transitioning":null].filter(Boolean).join(" ");let B=typeof d=="function"?d(q):d;return g.createElement(O,{...x,"aria-current":H,className:J,ref:b,style:B,to:u,viewTransition:m},typeof p=="function"?p(q):p)});iC.displayName="NavLink";const oC=g.forwardRef(({discover:t="render",fetcherKey:a,navigate:r,reloadDocument:o,replace:l,state:d,method:u="get",action:m,onSubmit:p,relative:x,preventScrollReset:b,viewTransition:y,defaultShouldRevalidate:v,...w},C)=>{let{useTransitions:A}=g.useContext(za),S=mC(),z=hC(m,{relative:x}),T=u.toLowerCase()==="get"?"get":"post",M=typeof m=="string"&&Dm.test(m),P=E=>{if(p&&p(E),E.defaultPrevented)return;E.preventDefault();let U=E.nativeEvent.submitter,q=(U==null?void 0:U.getAttribute("formmethod"))||u,H=()=>S(U||E.currentTarget,{fetcherKey:a,method:q,navigate:r,replace:l,state:d,relative:x,preventScrollReset:b,viewTransition:y,defaultShouldRevalidate:v});A&&r!==!1?g.startTransition(()=>H()):H()};return g.createElement("form",{ref:C,method:T,action:z,onSubmit:o?p:P,...w,"data-discover":!M&&t==="render"?"true":void 0})});oC.displayName="Form";function G1({getKey:t,storageKey:a,...r}){let o=g.useContext(Im),{basename:l}=g.useContext(za),d=la(),u=q1();pC({getKey:t,storageKey:a});let m=g.useMemo(()=>{if(!o||!t)return null;let x=Gf(d,u,l,t);return x!==d.key?x:null},[]);if(!o||o.isSpaMode)return null;let p=((x,b)=>{if(!window.history.state||!window.history.state.key){let y=Math.random().toString(32).slice(2);window.history.replaceState({key:y},"")}try{let y=JSON.parse(sessionStorage.getItem(x)||"{}")[b||window.history.state.key];typeof y=="number"&&window.scrollTo(0,y)}catch(y){console.error(y),sessionStorage.removeItem(x)}}).toString();return r.nonce==null&&(o!=null&&o.nonce)&&(r.nonce=o.nonce),g.createElement("script",{...r,suppressHydrationWarning:!0,dangerouslySetInnerHTML:{__html:`(${p})(${P0(JSON.stringify(a||Yf))}, ${P0(JSON.stringify(m))})`}})}G1.displayName="ScrollRestoration";function Z1(t){return`${t} must be used within a data router.  See https://reactrouter.com/en/main/routers/picking-a-router.`}function rg(t){let a=g.useContext(ro);return pt(a,Z1(t)),a}function lC(t){let a=g.useContext(cl);return pt(a,Z1(t)),a}function cC(t,{target:a,replace:r,mask:o,state:l,preventScrollReset:d,relative:u,viewTransition:m,defaultShouldRevalidate:p,useTransitions:x}={}){let b=ga(),y=la(),v=Gc(t,{relative:u});return g.useCallback(w=>{if(L3(w,a)){w.preventDefault();let C=r!==void 0?r:qn(y)===qn(v),A=()=>b(t,{replace:C,mask:o,state:l,preventScrollReset:d,relative:u,viewTransition:m,defaultShouldRevalidate:p});x?g.startTransition(()=>A()):A()}},[y,b,v,r,o,l,a,t,d,u,m,p,x])}function Bm(t){Fs(typeof URLSearchParams<"u","You cannot use the `useSearchParams` hook in a browser that does not support the URLSearchParams API. If you need to support Internet Explorer 11, we recommend you load a polyfill such as https://github.com/ungap/url-search-params.");let a=g.useRef(qf(t)),r=g.useRef(!1),o=la(),l=g.useMemo(()=>D3(o.search,r.current?null:a.current),[o.search]),d=ga();return[l,g.useCallback((u,m)=>{const p=qf(typeof u=="function"?u(new URLSearchParams(l)):u);r.current=!0,d("?"+p,m)},[d,l])]}let dC=0,uC=()=>`__${String(++dC)}__`;function mC(){let{router:t}=rg("useSubmit"),{basename:a}=g.useContext(za),r=b3(),o=t.fetch,l=t.navigate;return g.useCallback(async(d,u={})=>{let{action:m,method:p,encType:x,formData:b,body:y}=U3(d,a);u.navigate===!1?await o(u.fetcherKey||uC(),r,u.action||m,{defaultShouldRevalidate:u.defaultShouldRevalidate,preventScrollReset:u.preventScrollReset,formData:b,body:y,formMethod:u.method||p,formEncType:u.encType||x,flushSync:u.flushSync}):await l(u.action||m,{defaultShouldRevalidate:u.defaultShouldRevalidate,preventScrollReset:u.preventScrollReset,formData:b,body:y,formMethod:u.method||p,formEncType:u.encType||x,replace:u.replace,state:u.state,fromRouteId:r,flushSync:u.flushSync,viewTransition:u.viewTransition})},[o,l,a,r])}function hC(t,{relative:a}={}){let{basename:r}=g.useContext(za),o=g.useContext(cn);pt(o,"useFormAction must be used inside a RouteContext");let[l]=o.matches.slice(-1),d={...Gc(t||".",{relative:a})},u=la();if(t==null){d.search=u.search;let m=new URLSearchParams(d.search),p=m.getAll("index");if(p.some(x=>x==="")){m.delete("index"),p.filter(b=>b).forEach(b=>m.append("index",b));let x=m.toString();d.search=x?`?${x}`:""}}return(!t||t===".")&&l.route.index&&(d.search=d.search?d.search.replace(/^\?/,"?index&"):"?index"),r!=="/"&&(d.pathname=d.pathname==="/"?r:rn([r,d.pathname])),qn(d)}const Yf="react-router-scroll-positions";let bu={};function Gf(t,a,r,o){let l=null;return o&&(r!=="/"?l=o({...t,pathname:on(t.pathname,r)||t.pathname},a):l=o(t,a)),l==null&&(l=t.key),l}function pC({getKey:t,storageKey:a}={}){let{router:r}=rg("useScrollRestoration"),{restoreScrollPosition:o,preventScrollReset:l}
189=lC("useScrollRestoration"),{basename:d}=g.useContext(za),u=la(),m=q1(),p=y3();g.useEffect(()=>(window.history.scrollRestoration="manual",()=>{window.history.scrollRestoration="auto"}),[]),fC(g.useCallback(()=>{if(p.state==="idle"){let x=Gf(u,m,d,t);bu[x]=window.scrollY}try{sessionStorage.setItem(a||Yf,JSON.stringify(bu))}catch(x){Fs(!1,`Failed to save scroll positions in sessionStorage, <ScrollRestoration /> will not work properly (${x}).`)}window.history.scrollRestoration="auto"},[p.state,t,d,u,m,a])),typeof document<"u"&&(g.useLayoutEffect(()=>{try{let x=sessionStorage.getItem(a||Yf);x&&(bu=JSON.parse(x))}catch{}},[a]),g.useLayoutEffect(()=>{let x=r==null?void 0:r.enableScrollRestoration(bu,()=>window.scrollY,t?(b,y)=>Gf(b,y,d,t):void 0);return()=>x&&x()},[r,d,t]),g.useLayoutEffect(()=>{if(o!==!1){if(typeof o=="number"){window.scrollTo(0,o);return}try{if(u.hash){let x=document.getElementById(decodeURIComponent(u.hash.slice(1)));if(x){x.scrollIntoView();return}}}catch{Fs(!1,`"${u.hash.slice(1)}" is not a decodable element ID. The view will not scroll to it.`)}l!==!0&&window.scrollTo(0,0)}},[u,o,l]))}function fC(t,a){let{capture:r}={};g.useEffect(()=>{let o=r!=null?{capture:r}:void 0;return window.addEventListener("pagehide",t,o),()=>{window.removeEventListener("pagehide",t,o)}},[t,r])}function xC(t,{relative:a}={}){let r=g.useContext(Qx);pt(r!=null,"`useViewTransitionState` must be used within `react-router/dom`'s `RouterProvider`.  Did you accidentally import `RouterProvider` from `react-router`?");let{basename:o}=rg("useViewTransitionState"),l=Gc(t,{relative:a});if(!r.isTransitioning)return!1;let d=on(r.currentLocation.pathname,o)||r.currentLocation.pathname,u=on(r.nextLocation.pathname,o)||r.nextLocation.pathname;return Uu(l.pathname,u)!=null||Uu(l.pathname,d)!=null}/**
190 * react-router v8.3.0
191 *
192 * Copyright (c) Remix Software Inc.
193 *
194 * This source code is licensed under the MIT license found in the
195 * LICENSE.md file in the root directory of this source tree.
196 *
197 * @license MIT
198 */function gC(t){return g.createElement(C3,{flushSync:v4.flushSync,...t})}class bC extends g.Component{constructor(a){super(a),this.state={hasError:!1}}static getDerivedStateFromError(a){return{hasError:!0}}componentDidCatch(a,r){console.warn("CookieBanner error boundary caught an error:",a,r)}render(){return this.state.hasError?null:this.props.children}}/**
199 * @license lucide-react v0.454.0 - ISC
200 *
201 * This source code is licensed under the ISC license.
202 * See the LICENSE file in the root directory of this source tree.
203 */const yC=t=>t.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),J1=(...t)=>t.filter((a,r,o)=>!!a&&a.trim()!==""&&o.indexOf(a)===r).join(" ").trim();/**
204 * @license lucide-react v0.454.0 - ISC
205 *
206 * This source code is licensed under the ISC license.
207 * See the LICENSE file in the root directory of this source tree.
208 */var vC={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"};/**
209 * @license lucide-react v0.454.0 - ISC
210 *
211 * This source code is licensed under the ISC license.
212 * See the LICENSE file in the root directory of this source tree.
213 */const jC=g.forwardRef(({color:t="currentColor",size:a=24,strokeWidth:r=2,absoluteStrokeWidth:o,className:l="",children:d,iconNode:u,...m},p)=>g.createElement("svg",{ref:p,...vC,width:a,height:a,stroke:t,strokeWidth:o?Number(r)*24/Number(a):r,className:J1("lucide",l),...m},[...u.map(([x,b])=>g.createElement(x,b)),...Array.isArray(d)?d:[d]]));/**
214 * @license lucide-react v0.454.0 - ISC
215 *
216 * This source code is licensed under the ISC license.
217 * See the LICENSE file in the root directory of this source tree.
218 */const Te=(t,a)=>{const r=g.forwardRef(({className:o,...l},d)=>g.createElement(jC,{ref:d,iconNode:a,className:J1(`lucide-${yC(t)}`,o),...l}));return r.displayName=`${t}`,r};/**
219 * @license lucide-react v0.454.0 - ISC
220 *
221 * This source code is licensed under the ISC license.
222 * See the LICENSE file in the root directory of this source tree.
223 */const X1=Te("ArchiveRestore",[["rect",{width:"20",height:"5",x:"2",y:"3",rx:"1",key:"1wp1u1"}],["path",{d:"M4 8v11a2 2 0 0 0 2 2h2",key:"tvwodi"}],["path",{d:"M20 8v11a2 2 0 0 1-2 2h-2",key:"1gkqxj"}],["path",{d:"m9 15 3-3 3 3",key:"1pd0qc"}],["path",{d:"M12 12v9",key:"192myk"}]]);/**
224 * @license lucide-react v0.454.0 - ISC
225 *
226 * This source code is licensed under the ISC license.
227 * See the LICENSE file in the root directory of this source tree.
228 */const Qi=Te("Archive",[["rect",{width:"20",height:"5",x:"2",y:"3",rx:"1",key:"1wp1u1"}],["path",{d:"M4 8v11a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8",key:"1s80jp"}],["path",{d:"M10 12h4",key:"a56b0p"}]]);/**
229 * @license lucide-react v0.454.0 - ISC
230 *
231 * This source code is licensed under the ISC license.
232 * See the LICENSE file in the root directory of this source tree.
233 */const wC=Te("ArrowLeft",[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]]);/**
234 * @license lucide-react v0.454.0 - ISC
235 *
236 * This source code is licensed under the ISC license.
237 * See the LICENSE file in the root directory of this source tree.
238 */const NC=Te("ArrowRight",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"m12 5 7 7-7 7",key:"xquz4c"}]]);/**
239 * @license lucide-react v0.454.0 - ISC
240 *
241 * This source code is licensed under the ISC license.
242 * See the LICENSE file in the root directory of this source tree.
243 */const SC=Te("Award",[["path",{d:"m15.477 12.89 1.515 8.526a.5.5 0 0 1-.81.47l-3.58-2.687a1 1 0 0 0-1.197 0l-3.586 2.686a.5.5 0 0 1-.81-.469l1.514-8.526",key:"1yiouv"}],["circle",{cx:"12",cy:"8",r:"6",key:"1vp47v"}]]);/**
244 * @license lucide-react v0.454.0 - ISC
245 *
246 * This source code is licensed under the ISC license.
247 * See the LICENSE file in the root directory of this source tree.
248 */const Q1=Te("Bell",[["path",{d:"M6 8a6 6 0 0 1 12 0c0 7 3 9 3 9H3s3-2 3-9",key:"1qo2s2"}],["path",{d:"M10.3 21a1.94 1.94 0 0 0 3.4 0",key:"qgo35s"}]]);/**
249 * @license lucide-react v0.454.0 - ISC
250 *
251 * This source code is licensed under the ISC license.
252 * See the LICENSE file in the root directory of this source tree.
253 */const ys=Te("CalendarDays",[["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"}],["path",{d:"M8 14h.01",key:"6423bh"}],["path",{d:"M12 14h.01",key:"1etili"}],["path",{d:"M16 14h.01",key:"1gbofw"}],["path",{d:"M8 18h.01",key:"lrp35t"}],["path",{d:"M12 18h.01",key:"mhygvu"}],["path",{d:"M16 18h.01",key:"kzsmim"}]]);/**
254 * @license lucide-react v0.454.0 - ISC
255 *
256 * This source code is licensed under the ISC license.
257 * See the LICENSE file in the root directory of this source tree.
258 */const CC=Te("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"}]]);/**
259 * @license lucide-react v0.454.0 - ISC
260 *
261 * This source code is licensed under the ISC license.
262 * See the LICENSE file in the root directory of this source tree.
263 */const zc=Te("Camera",[["path",{d:"M14.5 4h-5L7 7H4a2 2 0 0 0-2 2v9a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2V9a2 2 0 0 0-2-2h-3l-2.5-3z",key:"1tc9qg"}],["circle",{cx:"12",cy:"13",r:"3",key:"1vg3eu"}]]);/**
264 * @license lucide-react v0.454.0 - ISC
265 *
266 * This source code is licensed under the ISC license.
267 * See the LICENSE file in the root directory of this source tree.
268 */const kC=Te("ChartNoAxesColumn",[["line",{x1:"18",x2:"18",y1:"20",y2:"10",key:"1xfpm4"}],["line",{x1:"12",x2:"12",y1:"20",y2:"4",key:"be30l9"}],["line",{x1:"6",x2:"6",y1:"20",y2:"14",key:"1r4le6"}]]);/**
269 * @license lucide-react v0.454.0 - ISC
270 *
271 * This source code is licensed under the ISC license.
272 * See the LICENSE file in the root directory of this source tree.
273 */const Ea=Te("Check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]);/**
274 * @license lucide-react v0.454.0 - ISC
275 *
276 * This source code is licensed under the ISC license.
277 * See the LICENSE file in the root directory of this source tree.
278 */const $n=Te("ChevronDown",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]);/**
279 * @license lucide-react v0.454.0 - ISC
280 *
281 * This source code is licensed under the ISC license.
282 * See the LICENSE file in the root directory of this source tree.
283 */const En=Te("ChevronLeft",[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]]);/**
284 * @license lucide-react v0.454.0 - ISC
285 *
286 * This source code is licensed under the ISC license.
287 * See the LICENSE file in the root directory of this source tree.
288 */const Lt=Te("ChevronRight",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]);/**
289 * @license lucide-react v0.454.0 - ISC
290 *
291 * This source code is licensed under the ISC license.
292 * See the LICENSE file in the root directory of this source tree.
293 */const Zc=Te("ChevronUp",[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]]);/**
294 * @license lucide-react v0.454.0 - ISC
295 *
296 * This source code is licensed under the ISC license.
297 * See the LICENSE file in the root directory of this source tree.
298 */const Xi=Te("CircleAlert",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]]);/**
299 * @license lucide-react v0.454.0 - ISC
300 *
301 * This source code is licensed under the ISC license.
302 * See the LICENSE file in the root directory of this source tree.
303 */const eo=Te("CircleCheckBig",[["path",{d:"M21.801 10A10 10 0 1 1 17 3.335",key:"yps3ct"}],["path",{d:"m9 11 3 3L22 4",key:"1pflzl"}]]);/**
304 * @license lucide-react v0.454.0 - ISC
305 *
306 * This source code is licensed under the ISC license.
307 * See the LICENSE file in the root directory of this source tree.
308 */const kn=Te("CircleCheck",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]]);/**
309 * @license lucide-react v0.454.0 - ISC
310 *
311 * This source code is licensed under the ISC license.
312 * See the LICENSE file in the root directory of this source tree.
313 */const TC=Te("CirclePause",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"10",x2:"10",y1:"15",y2:"9",key:"c1nkhi"}],["line",{x1:"14",x2:"14",y1:"15",y2:"9",key:"h65svq"}]]);/**
314 * @license lucide-react v0.454.0 - ISC
315 *
316 * This source code is licensed under the ISC license.
317 * See the LICENSE file in the root directory of this source tree.
318 */const Rc=Te("CirclePlay",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["polygon",{points:"10 8 16 12 10 16 10 8",key:"1cimsy"}]]);/**
319 * @license lucide-react v0.454.0 - ISC
320 *
321 * This source code is licensed under the ISC license.
322 * See the LICENSE file in the root directory of this source tree.
323 */const sl=Te("CirclePlus",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M8 12h8",key:"1wcyev"}],["path",{d:"M12 8v8",key:"napkw2"}]]);/**
324 * @license lucide-react v0.454.0 - ISC
325 *
326 * This source code is licensed under the ISC license.
327 * See the LICENSE file in the root directory of this source tree.
328 */const $m=Te("CircleX",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m15 9-6 6",key:"1uzhvr"}],["path",{d:"m9 9 6 6",key:"z0biqf"}]]);/**
329 * @license lucide-react v0.454.0 - ISC
330 *
331 * This source code is licensed under the ISC license.
332 * See the LICENSE file in the root directory of this source tree.
333 */const Ms=Te("Clock",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["polyline",{points:"12 6 12 12 16 14",key:"68esgv"}]]);/**
334 * @license lucide-react v0.454.0 - ISC
335 *
336 * This source code is licensed under the ISC license.
337 * See the LICENSE file in the root directory of this source tree.
338 */const Qo=Te("Copy",[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]]);/**
339 * @license lucide-react v0.454.0 - ISC
340 *
341 * This source code is licensed under the ISC license.
342 * See the LICENSE file in the root directory of this source tree.
343 */const AC=Te("DollarSign",[["line",{x1:"12",x2:"12",y1:"2",y2:"22",key:"7eqyqh"}],["path",{d:"M17 5H9.5a3.5 3.5 0 0 0 0 7h5a3.5 3.5 0 0 1 0 7H6",key:"1b0p4s"}]]);/**
344 * @license lucide-react v0.454.0 - ISC
345 *
346 * This source code is licensed under the ISC license.
347 * See the LICENSE file in the root directory of this source tree.
348 */const I0=Te("Download",[["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}],["polyline",{points:"7 10 12 15 17 10",key:"2ggqvy"}],["line",{x1:"12",x2:"12",y1:"15",y2:"3",key:"1vk2je"}]]);/**
349 * @license lucide-react v0.454.0 - ISC
350 *
351 * This source code is licensed under the ISC license.
352 * See the LICENSE file in the root directory of this source tree.
353 */const dt=Te("ExternalLink",[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"M10 14 21 3",key:"gplh6r"}],["path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6",key:"a6xqqp"}]]);/**
354 * @license lucide-react v0.454.0 - ISC
355 *
356 * This source code is licensed under the ISC license.
357 * See the LICENSE file in the root directory of this source tree.
358 */const to=Te("EyeOff",[["path",{d:"M10.733 5.076a10.744 10.744 0 0 1 11.205 6.575 1 1 0 0 1 0 .696 10.747 10.747 0 0 1-1.444 2.49",key:"ct8e1f"}],["path",{d:"M14.084 14.158a3 3 0 0 1-4.242-4.242",key:"151rxh"}],["path",{d:"M17.479 17.499a10.75 10.75 0 0 1-15.417-5.151 1 1 0 0 1 0-.696 10.75 10.75 0 0 1 4.446-5.143",key:"13bj9a"}],["path",{d:"m2 2 20 20",key:"1ooewy"}]]);/**
359 * @license lucide-react v0.454.0 - ISC
360 *
361 * This source code is licensed under the ISC license.
362 * See the LICENSE file in the root directory of this source tree.
363 */const xa=Te("Eye",[["path",{d:"M2.062 12.348a1 1 0 0 1 0-.696 10.75 10.75 0 0 1 19.876 0 1 1 0 0 1 0 .696 10.75 10.75 0 0 1-19.876 0",key:"1nclc0"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]]);/**
364 * @license lucide-react v0.454.0 - ISC
365 *
366 * This source code is licensed under the ISC license.
367 * See the LICENSE file in the root directory of this source tree.
368 */const Vm=Te("Facebook",[["path",{d:"M18 2h-3a5 5 0 0 0-5 5v3H7v4h3v8h4v-8h3l1-4h-4V7a1 1 0 0 1 1-1h3z",key:"1jg4f8"}]]);/**
369 * @license lucide-react v0.454.0 - ISC
370 *
371 * This source code is licensed under the ISC license.
372 * See the LICENSE file in the root directory of this source tree.
373 */const e2=Te("FileText",[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z",key:"1rqfz7"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["path",{d:"M10 9H8",key:"b1mrlr"}],["path",{d:"M16 13H8",key:"t4e002"}],["path",{d:"M16 17H8",key:"z1uh3a"}]]);/**
374 * @license lucide-react v0.454.0 - ISC
375 *
376 * This source code is licensed under the ISC license.
377 * See the LICENSE file in the root directory of this source tree.
378 */const Zf=Te("FileUp",[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z",key:"1rqfz7"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["path",{d:"M12 12v6",key:"3ahymv"}],["path",{d:"m15 15-3-3-3 3",key:"15xj92"}]]);/**
379 * @license lucide-react v0.454.0 - ISC
380 *
381 * This source code is licensed under the ISC license.
382 * See the LICENSE file in the root directory of this source tree.
383 */const Yn=Te("Film",[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M7 3v18",key:"bbkbws"}],["path",{d:"M3 7.5h4",key:"zfgn84"}],["path",{d:"M3 12h18",key:"1i2n21"}],["path",{d:"M3 16.5h4",key:"1230mu"}],["path",{d:"M17 3v18",key:"in4fa5"}],["path",{d:"M17 7.5h4",key:"myr1c1"}],["path",{d:"M17 16.5h4",key:"go4c1d"}]]);/**
384 * @license lucide-react v0.454.0 - ISC
385 *
386 * This source code is licensed under the ISC license.
387 * See the LICENSE file in the root directory of this source tree.
388 */const t2=Te("Flag",[["path",{d:"M4 15s1-1 4-1 5 2 8 2 4-1 4-1V3s-1 1-4 1-5-2-8-2-4 1-4 1z",key:"i9b6wo"}],["line",{x1:"4",x2:"4",y1:"22",y2:"15",key:"1cm3nv"}]]);/**
389 * @license lucide-react v0.454.0 - ISC
390 *
391 * This source code is licensed under the ISC license.
392 * See the LICENSE file in the root directory of this source tree.
393 */const Pu=Te("Gamepad2",[["line",{x1:"6",x2:"10",y1:"11",y2:"11",key:"1gktln"}],["line",{x1:"8",x2:"8",y1:"9",y2:"13",key:"qnk9ow"}],["line",{x1:"15",x2:"15.01",y1:"12",y2:"12",key:"krot7o"}],["line",{x1:"18",x2:"18.01",y1:"10",y2:"10",key:"1lcuu1"}],["path",{d:"M17.32 5H6.68a4 4 0 0 0-3.978 3.59c-.006.052-.01.101-.017.152C2.604 9.416 2 14.456 2 16a3 3 0 0 0 3 3c1 0 1.5-.5 2-1l1.414-1.414A2 2 0 0 1 9.828 16h4.344a2 2 0 0 1 1.414.586L17 18c.5.5 1 1 2 1a3 3 0 0 0 3-3c0-1.545-.604-6.584-.685-7.258-.007-.05-.011-.1-.017-.151A4 4 0 0 0 17.32 5z",key:"mfqc10"}]]);/**
394 * @license lucide-react v0.454.0 - ISC
395 *
396 * This source code is licensed under the ISC license.
397 * See the LICENSE file in the root directory of this source tree.
398 */const Ku=Te("Globe",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20",key:"13o1zl"}],["path",{d:"M2 12h20",key:"9i4pu4"}]]);/**
399 * @license lucide-react v0.454.0 - ISC
400 *
401 * This source code is licensed under the ISC license.
402 * See the LICENSE file in the root directory of this source tree.
403 */const _c=Te("Heart",[["path",{d:"M19 14c1.49-1.46 3-3.21 3-5.5A5.5 5.5 0 0 0 16.5 3c-1.76 0-3 .5-4.5 2-1.5-1.5-2.74-2-4.5-2A5.5 5.5 0 0 0 2 8.5c0 2.3 1.5 4.05 3 5.5l7 7Z",key:"c3ymky"}]]);/**
404 * @license lucide-react v0.454.0 - ISC
405 *
406 * This source code is licensed under the ISC license.
407 * See the LICENSE file in the root directory of this source tree.
408 */const EC=Te("ImageOff",[["line",{x1:"2",x2:"22",y1:"2",y2:"22",key:"a6p6uj"}],["path",{d:"M10.41 10.41a2 2 0 1 1-2.83-2.83",key:"1bzlo9"}],["line",{x1:"13.5",x2:"6",y1:"13.5",y2:"21",key:"1q0aeu"}],["line",{x1:"18",x2:"21",y1:"12",y2:"15",key:"5mozeu"}],["path",{d:"M3.59 3.59A1.99 1.99 0 0 0 3 5v14a2 2 0 0 0 2 2h14c.55 0 1.052-.22 1.41-.59",key:"mmje98"}],["path",{d:"M21 15V5a2 2 0 0 0-2-2H9",key:"43el77"}]]);/**
409 * @license lucide-react v0.454.0 - ISC
410 *
411 * This source code is licensed under the ISC license.
412 * See the LICENSE file in the root directory of this source tree.
413 */const Jf=Te("ImagePlus",[["path",{d:"M16 5h6",key:"1vod17"}],["path",{d:"M19 2v6",key:"4bpg5p"}],["path",{d:"M21 11.5V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h7.5",key:"1ue2ih"}],["path",{d:"m21 15-3.086-3.086a2 2 0 0 0-2.828 0L6 21",key:"1xmnt7"}],["circle",{cx:"9",cy:"9",r:"2",key:"af1f0g"}]]);/**
414 * @license lucide-react v0.454.0 - ISC
415 *
416 * This source code is licensed under the ISC license.
417 * See the LICENSE file in the root directory of this source tree.
418 */const s2=Te("Image",[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",ry:"2",key:"1m3agn"}],["circle",{cx:"9",cy:"9",r:"2",key:"af1f0g"}],["path",{d:"m21 15-3.086-3.086a2 2 0 0 0-2.828 0L6 21",key:"1xmnt7"}]]);/**
419 * @license lucide-react v0.454.0 - ISC
420 *
421 * This source code is licensed under the ISC license.
422 * See the LICENSE file in the root directory of this source tree.
423 */const Xf=Te("Info",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 16v-4",key:"1dtifu"}],["path",{d:"M12 8h.01",key:"e9boi3"}]]);/**
424 * @license lucide-react v0.454.0 - ISC
425 *
426 * This source code is licensed under the ISC license.
427 * See the LICENSE file in the root directory of this source tree.
428 */const a2=Te("Instagram",[["rect",{width:"20",height:"20",x:"2",y:"2",rx:"5",ry:"5",key:"2e1cvw"}],["path",{d:"M16 11.37A4 4 0 1 1 12.63 8 4 4 0 0 1 16 11.37z",key:"9exkf1"}],["line",{x1:"17.5",x2:"17.51",y1:"6.5",y2:"6.5",key:"r4j83e"}]]);/**
429 * @license lucide-react v0.454.0 - ISC
430 *
431 * This source code is licensed under the ISC license.
432 * See the LICENSE file in the root directory of this source tree.
433 */const Lc=Te("Link",[["path",{d:"M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71",key:"1cjeqo"}],["path",{d:"M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71",key:"19qd67"}]]);/**
434 * @license lucide-react v0.454.0 - ISC
435 *
436 * This source code is licensed under the ISC license.
437 * See the LICENSE file in the root directory of this source tree.
438 */const Rt=Te("LoaderCircle",[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]]);/**
439 * @license lucide-react v0.454.0 - ISC
440 *
441 * This source code is licensed under the ISC license.
442 * See the LICENSE file in the root directory of this source tree.
443 */const so=Te("Lock",[["rect",{width:"18",height:"11",x:"3",y:"11",rx:"2",ry:"2",key:"1w4ew1"}],["path",{d:"M7 11V7a5 5 0 0 1 10 0v4",key:"fwvmzm"}]]);/**
444 * @license lucide-react v0.454.0 - ISC
445 *
446 * This source code is licensed under the ISC license.
447 * See the LICENSE file in the root directory of this source tree.
448 */const n2=Te("LogIn",[["path",{d:"M15 3h4a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2h-4",key:"u53s6r"}],["polyline",{points:"10 17 15 12 10 7",key:"1ail0h"}],["line",{x1:"15",x2:"3",y1:"12",y2:"12",key:"v6grx8"}]]);/**
449 * @license lucide-react v0.454.0 - ISC
450 *
451 * This source code is licensed under the ISC license.
452 * See the LICENSE file in the root directory of this source tree.
453 */const HC=Te("LogOut",[["path",{d:"M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4",key:"1uf3rs"}],["polyline",{points:"16 17 21 12 16 7",key:"1gabdz"}],["line",{x1:"21",x2:"9",y1:"12",y2:"12",key:"1uyos4"}]]);/**
454 * @license lucide-react v0.454.0 - ISC
455 *
456 * This source code is licensed under the ISC license.
457 * See the LICENSE file in the root directory of this source tree.
458 */const nn=Te("Mail",[["rect",{width:"20",height:"16",x:"2",y:"4",rx:"2",key:"18n3k1"}],["path",{d:"m22 7-8.97 5.7a1.94 1.94 0 0 1-2.06 0L2 7",key:"1ocrg3"}]]);/**
459 * @license lucide-react v0.454.0 - ISC
460 *
461 * This source code is licensed under the ISC license.
462 * See the LICENSE file in the root directory of this source tree.
463 */const ul=Te("MapPin",[["path",{d:"M20 10c0 4.993-5.539 10.193-7.399 11.799a1 1 0 0 1-1.202 0C9.539 20.193 4 14.993 4 10a8 8 0 0 1 16 0",key:"1r0f0z"}],["circle",{cx:"12",cy:"10",r:"3",key:"ilqhr7"}]]);/**
464 * @license lucide-react v0.454.0 - ISC
465 *
466 * This source code is licensed under the ISC license.
467 * See the LICENSE file in the root directory of this source tree.
468 */const zC=Te("MessageCircle",[["path",{d:"M7.9 20A9 9 0 1 0 4 16.1L2 22Z",key:"vv11sd"}]]);/**
469 * @license lucide-react v0.454.0 - ISC
470 *
471 * This source code is licensed under the ISC license.
472 * See the LICENSE file in the root directory of this source tree.
473 */const ig=Te("MessageSquare",[["path",{d:"M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z",key:"1lielz"}]]);/**
474 * @license lucide-react v0.454.0 - ISC
475 *
476 * This source code is licensed under the ISC license.
477 * See the LICENSE file in the root directory of this source tree.
478 */const RC=Te("Monitor",[["rect",{width:"20",height:"14",x:"2",y:"3",rx:"2",key:"48i651"}],["line",{x1:"8",x2:"16",y1:"21",y2:"21",key:"1svkeh"}],["line",{x1:"12",x2:"12",y1:"17",y2:"21",key:"vw1qmm"}]]);/**
479 * @license lucide-react v0.454.0 - ISC
480 *
481 * This source code is licensed under the ISC license.
482 * See the LICENSE file in the root directory of this source tree.
483 */const og=Te("Music",[["path",{d:"M9 18V5l12-2v13",key:"1jmyc2"}],["circle",{cx:"6",cy:"18",r:"3",key:"fqmcym"}],["circle",{cx:"18",cy:"16",r:"3",key:"1hluhg"}]]);/**
484 * @license lucide-react v0.454.0 - ISC
485 *
486 * This source code is licensed under the ISC license.
487 * See the LICENSE file in the root directory of this source tree.
488 */const Vn=Te("Pencil",[["path",{d:"M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z",key:"1a8usu"}],["path",{d:"m15 5 4 4",key:"1mk7zo"}]]);/**
489 * @license lucide-react v0.454.0 - ISC
490 *
491 * This source code is licensed under the ISC license.
492 * See the LICENSE file in the root directory of this source tree.
493 */const lg=Te("Phone",[["path",{d:"M22 16.92v3a2 2 0 0 1-2.18 2 19.79 19.79 0 0 1-8.63-3.07 19.5 19.5 0 0 1-6-6 19.79 19.79 0 0 1-3.07-8.67A2 2 0 0 1 4.11 2h3a2 2 0 0 1 2 1.72 12.84 12.84 0 0 0 .7 2.81 2 2 0 0 1-.45 2.11L8.09 9.91a16 16 0 0 0 6 6l1.27-1.27a2 2 0 0 1 2.11-.45 12.84 12.84 0 0 0 2.81.7A2 2 0 0 1 22 16.92z",key:"foiqr5"}]]);/**
494 * @license lucide-react v0.454.0 - ISC
495 *
496 * This source code is licensed under the ISC license.
497 * See the LICENSE file in the root directory of this source tree.
498 */const Iu=Te("Plus",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]]);/**
499 * @license lucide-react v0.454.0 - ISC
500 *
501 * This source code is licensed under the ISC license.
502 * See the LICENSE file in the root directory of this source tree.
503 */const B0=Te("Puzzle",[["path",{d:"M19.439 7.85c-.049.322.059.648.289.878l1.568 1.568c.47.47.706 1.087.706 1.704s-.235 1.233-.706 1.704l-1.611 1.611a.98.98 0 0 1-.837.276c-.47-.07-.802-.48-.968-.925a2.501 2.501 0 1 0-3.214 3.214c.446.166.855.497.925.968a.979.979 0 0 1-.276.837l-1.61 1.61a2.404 2.404 0 0 1-1.705.707 2.402 2.402 0 0 1-1.704-.706l-1.568-1.568a1.026 1.026 0 0 0-.877-.29c-.493.074-.84.504-1.02.968a2.5 2.5 0 1 1-3.237-3.237c.464-.18.894-.527.967-1.02a1.026 1.026 0 0 0-.289-.877l-1.568-1.568A2.402 2.402 0 0 1 1.998 12c0-.617.236-1.234.706-1.704L4.23 8.77c.24-.24.581-.353.917-.303.515.077.877.528 1.073 1.01a2.5 2.5 0 1 0 3.259-3.259c-.482-.196-.933-.558-1.01-1.073-.05-.336.062-.676.303-.917l1.525-1.525A2.402 2.402 0 0 1 12 1.998c.617 0 1.234.236 1.704.706l1.568 1.568c.23.23.556.338.877.29.493-.074.84-.504 1.02-.968a2.5 2.5 0 1 1 3.237 3.237c-.464.18-.894.527-.967 1.02Z",key:"i0oyt7"}]]);/**
504 * @license lucide-react v0.454.0 - ISC
505 *
506 * This source code is licensed under the ISC license.
507 * See the LICENSE file in the root directory of this source tree.
508 */const Ft=Te("Radio",[["path",{d:"M4.9 19.1C1 15.2 1 8.8 4.9 4.9",key:"1vaf9d"}],["path",{d:"M7.8 16.2c-2.3-2.3-2.3-6.1 0-8.5",key:"u1ii0m"}],["circle",{cx:"12",cy:"12",r:"2",key:"1c9p78"}],["path",{d:"M16.2 7.8c2.3 2.3 2.3 6.1 0 8.5",key:"1j5fej"}],["path",{d:"M19.1 4.9C23 8.8 23 15.1 19.1 19",key:"10b0cb"}]]);/**
509 * @license lucide-react v0.454.0 - ISC
510 *
511 * This source code is licensed under the ISC license.
512 * See the LICENSE file in the root directory of this source tree.
513 */const $0=Te("RefreshCw",[["path",{d:"M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8",key:"v9h5vc"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}],["path",{d:"M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16",key:"3uifl3"}],["path",{d:"M8 16H3v5",key:"1cv678"}]]);/**
514 * @license lucide-react v0.454.0 - ISC
515 *
516 * This source code is licensed under the ISC license.
517 * See the LICENSE file in the root directory of this source tree.
518 */const r2=Te("RotateCcw",[["path",{d:"M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8",key:"1357e3"}],["path",{d:"M3 3v5h5",key:"1xhq8a"}]]);/**
519 * @license lucide-react v0.454.0 - ISC
520 *
521 * This source code is licensed under the ISC license.
522 * See the LICENSE file in the root directory of this source tree.
523 */const _C=Te("Save",[["path",{d:"M15.2 3a2 2 0 0 1 1.4.6l3.8 3.8a2 2 0 0 1 .6 1.4V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2z",key:"1c8476"}],["path",{d:"M17 21v-7a1 1 0 0 0-1-1H8a1 1 0 0 0-1 1v7",key:"1ydtos"}],["path",{d:"M7 3v4a1 1 0 0 0 1 1h7",key:"t51u73"}]]);/**
524 * @license lucide-react v0.454.0 - ISC
525 *
526 * This source code is licensed under the ISC license.
527 * See the LICENSE file in the root directory of this source tree.
528 */const pi=Te("Search",[["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}],["path",{d:"m21 21-4.3-4.3",key:"1qie3q"}]]);/**
529 * @license lucide-react v0.454.0 - ISC
530 *
531 * This source code is licensed under the ISC license.
532 * See the LICENSE file in the root directory of this source tree.
533 */const fi=Te("Send",[["path",{d:"M14.536 21.686a.5.5 0 0 0 .937-.024l6.5-19a.496.496 0 0 0-.635-.635l-19 6.5a.5.5 0 0 0-.024.937l7.93 3.18a2 2 0 0 1 1.112 1.11z",key:"1ffxy3"}],["path",{d:"m21.854 2.147-10.94 10.939",key:"12cjpa"}]]);/**
534 * @license lucide-react v0.454.0 - ISC
535 *
536 * This source code is licensed under the ISC license.
537 * See the LICENSE file in the root directory of this source tree.
538 */const LC=Te("Share2",[["circle",{cx:"18",cy:"5",r:"3",key:"gq8acd"}],["circle",{cx:"6",cy:"12",r:"3",key:"w7nqdw"}],["circle",{cx:"18",cy:"19",r:"3",key:"1xt0gg"}],["line",{x1:"8.59",x2:"15.42",y1:"13.51",y2:"17.49",key:"47mynk"}],["line",{x1:"15.41",x2:"8.59",y1:"6.51",y2:"10.49",key:"1n3mei"}]]);/**
539 * @license lucide-react v0.454.0 - ISC
540 *
541 * This source code is licensed under the ISC license.
542 * See the LICENSE file in the root directory of this source tree.
543 */const cg=Te("ShieldCheck",[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",ke
543y:"oel41y"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]]);/**
544 * @license lucide-react v0.454.0 - ISC
545 *
546 * This source code is licensed under the ISC license.
547 * See the LICENSE file in the root directory of this source tree.
548 */const ml=Te("ShoppingCart",[["circle",{cx:"8",cy:"21",r:"1",key:"jimo8o"}],["circle",{cx:"19",cy:"21",r:"1",key:"13723u"}],["path",{d:"M2.05 2.05h2l2.66 12.42a2 2 0 0 0 2 1.58h9.78a2 2 0 0 0 1.95-1.57l1.65-7.43H5.12",key:"9zh506"}]]);/**
549 * @license lucide-react v0.454.0 - ISC
550 *
551 * This source code is licensed under the ISC license.
552 * See the LICENSE file in the root directory of this source tree.
553 */const i2=Te("Smile",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M8 14s1.5 2 4 2 4-2 4-2",key:"1y1vjs"}],["line",{x1:"9",x2:"9.01",y1:"9",y2:"9",key:"yxxnd0"}],["line",{x1:"15",x2:"15.01",y1:"9",y2:"9",key:"1p4y9e"}]]);/**
554 * @license lucide-react v0.454.0 - ISC
555 *
556 * This source code is licensed under the ISC license.
557 * See the LICENSE file in the root directory of this source tree.
558 */const V0=Te("Star",[["path",{d:"M11.525 2.295a.53.53 0 0 1 .95 0l2.31 4.679a2.123 2.123 0 0 0 1.595 1.16l5.166.756a.53.53 0 0 1 .294.904l-3.736 3.638a2.123 2.123 0 0 0-.611 1.878l.882 5.14a.53.53 0 0 1-.771.56l-4.618-2.428a2.122 2.122 0 0 0-1.973 0L6.396 21.01a.53.53 0 0 1-.77-.56l.881-5.139a2.122 2.122 0 0 0-.611-1.879L2.16 9.795a.53.53 0 0 1 .294-.906l5.165-.755a2.122 2.122 0 0 0 1.597-1.16z",key:"r04s7s"}]]);/**
559 * @license lucide-react v0.454.0 - ISC
560 *
561 * This source code is licensed under the ISC license.
562 * See the LICENSE file in the root directory of this source tree.
563 */const Qf=Te("Tag",[["path",{d:"M12.586 2.586A2 2 0 0 0 11.172 2H4a2 2 0 0 0-2 2v7.172a2 2 0 0 0 .586 1.414l8.704 8.704a2.426 2.426 0 0 0 3.42 0l6.58-6.58a2.426 2.426 0 0 0 0-3.42z",key:"vktsd0"}],["circle",{cx:"7.5",cy:"7.5",r:".5",fill:"currentColor",key:"kqv944"}]]);/**
564 * @license lucide-react v0.454.0 - ISC
565 *
566 * This source code is licensed under the ISC license.
567 * See the LICENSE file in the root directory of this source tree.
568 */const Gn=Te("ThumbsUp",[["path",{d:"M7 10v12",key:"1qc93n"}],["path",{d:"M15 5.88 14 10h5.83a2 2 0 0 1 1.92 2.56l-2.33 8A2 2 0 0 1 17.5 22H4a2 2 0 0 1-2-2v-8a2 2 0 0 1 2-2h2.76a2 2 0 0 0 1.79-1.11L12 2a3.13 3.13 0 0 1 3 3.88Z",key:"emmmcr"}]]);/**
569 * @license lucide-react v0.454.0 - ISC
570 *
571 * This source code is licensed under the ISC license.
572 * See the LICENSE file in the root directory of this source tree.
573 */const Tn=Te("Trash2",[["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6",key:"4alrt4"}],["path",{d:"M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2",key:"v07s0e"}],["line",{x1:"10",x2:"10",y1:"11",y2:"17",key:"1uufr5"}],["line",{x1:"14",x2:"14",y1:"11",y2:"17",key:"xtxkd"}]]);/**
574 * @license lucide-react v0.454.0 - ISC
575 *
576 * This source code is licensed under the ISC license.
577 * See the LICENSE file in the root directory of this source tree.
578 */const Xs=Te("Trophy",[["path",{d:"M6 9H4.5a2.5 2.5 0 0 1 0-5H6",key:"17hqa7"}],["path",{d:"M18 9h1.5a2.5 2.5 0 0 0 0-5H18",key:"lmptdp"}],["path",{d:"M4 22h16",key:"57wxv0"}],["path",{d:"M10 14.66V17c0 .55-.47.98-.97 1.21C7.85 18.75 7 20.24 7 22",key:"1nw9bq"}],["path",{d:"M14 14.66V17c0 .55.47.98.97 1.21C16.15 18.75 17 20.24 17 22",key:"1np0yb"}],["path",{d:"M18 2H6v7a6 6 0 0 0 12 0V2Z",key:"u46fv3"}]]);/**
579 * @license lucide-react v0.454.0 - ISC
580 *
581 * This source code is licensed under the ISC license.
582 * See the LICENSE file in the root directory of this source tree.
583 */const ex=Te("TvMinimal",[["path",{d:"M7 21h10",key:"1b0cd5"}],["rect",{width:"20",height:"14",x:"2",y:"3",rx:"2",key:"48i651"}]]);/**
584 * @license lucide-react v0.454.0 - ISC
585 *
586 * This source code is licensed under the ISC license.
587 * See the LICENSE file in the root directory of this source tree.
588 */const Fn=Te("Tv",[["rect",{width:"20",height:"15",x:"2",y:"7",rx:"2",ry:"2",key:"10ag99"}],["polyline",{points:"17 2 12 7 7 2",key:"11pgbg"}]]);/**
589 * @license lucide-react v0.454.0 - ISC
590 *
591 * This source code is licensed under the ISC license.
592 * See the LICENSE file in the root directory of this source tree.
593 */const ln=Te("Upload",[["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}],["polyline",{points:"17 8 12 3 7 8",key:"t8dd8p"}],["line",{x1:"12",x2:"12",y1:"3",y2:"15",key:"widbto"}]]);/**
594 * @license lucide-react v0.454.0 - ISC
595 *
596 * This source code is licensed under the ISC license.
597 * See the LICENSE file in the root directory of this source tree.
598 */const DC=Te("UserCheck",[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}],["polyline",{points:"16 11 18 13 22 9",key:"1pwet4"}]]);/**
599 * @license lucide-react v0.454.0 - ISC
600 *
601 * This source code is licensed under the ISC license.
602 * See the LICENSE file in the root directory of this source tree.
603 */const Dc=Te("UserPlus",[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}],["line",{x1:"19",x2:"19",y1:"8",y2:"14",key:"1bvyxn"}],["line",{x1:"22",x2:"16",y1:"11",y2:"11",key:"1shjgl"}]]);/**
604 * @license lucide-react v0.454.0 - ISC
605 *
606 * This source code is licensed under the ISC license.
607 * See the LICENSE file in the root directory of this source tree.
608 */const Ha=Te("User",[["path",{d:"M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2",key:"975kel"}],["circle",{cx:"12",cy:"7",r:"4",key:"17ys0d"}]]);/**
609 * @license lucide-react v0.454.0 - ISC
610 *
611 * This source code is licensed under the ISC license.
612 * See the LICENSE file in the root directory of this source tree.
613 */const o2=Te("Users",[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}],["path",{d:"M22 21v-2a4 4 0 0 0-3-3.87",key:"kshegd"}],["path",{d:"M16 3.13a4 4 0 0 1 0 7.75",key:"1da9ce"}]]);/**
614 * @license lucide-react v0.454.0 - ISC
615 *
616 * This source code is licensed under the ISC license.
617 * See the LICENSE file in the root directory of this source tree.
618 */const Vs=Te("Video",[["path",{d:"m16 13 5.223 3.482a.5.5 0 0 0 .777-.416V7.87a.5.5 0 0 0-.752-.432L16 10.5",key:"ftymec"}],["rect",{x:"2",y:"6",width:"14",height:"12",rx:"2",key:"158x01"}]]);/**
619 * @license lucide-react v0.454.0 - ISC
620 *
621 * This source code is licensed under the ISC license.
622 * See the LICENSE file in the root directory of this source tree.
623 */const OC=Te("Wifi",[["path",{d:"M12 20h.01",key:"zekei9"}],["path",{d:"M2 8.82a15 15 0 0 1 20 0",key:"dnpr2z"}],["path",{d:"M5 12.859a10 10 0 0 1 14 0",key:"1x1e6c"}],["path",{d:"M8.5 16.429a5 5 0 0 1 7 0",key:"1bycff"}]]);/**
624 * @license lucide-react v0.454.0 - ISC
625 *
626 * This source code is licensed under the ISC license.
627 * See the LICENSE file in the root directory of this source tree.
628 */const Vt=Te("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]);/**
629 * @license lucide-react v0.454.0 - ISC
630 *
631 * This source code is licensed under the ISC license.
632 * See the LICENSE file in the root directory of this source tree.
633 */const Fm=Te("Youtube",[["path",{d:"M2.5 17a24.12 24.12 0 0 1 0-10 2 2 0 0 1 1.4-1.4 49.56 49.56 0 0 1 16.2 0A2 2 0 0 1 21.5 7a24.12 24.12 0 0 1 0 10 2 2 0 0 1-1.4 1.4 49.55 49.55 0 0 1-16.2 0A2 2 0 0 1 2.5 17",key:"1q2vi4"}],["path",{d:"m10 15 5-3-5-3z",key:"1jp15x"}]]);function MC({size:t}){return e.jsx("svg",{width:t,height:t,viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":"true",children:e.jsx("path",{d:"M18.244 2.25h3.308l-7.227 8.26 8.502 11.24H16.17l-4.714-6.231-5.401 6.231H2.746l7.73-8.835L1.254 2.25H8.08l4.253 5.622 5.911-5.622Zm-1.161 17.52h1.833L7.084 4.126H5.117z"})})}const UC=[{label:"Our Mission",href:"/mission"},{label:"Membership Tiers",href:"/membership"},{label:"Upcoming Events",href:"/events"},{label:"Donate",href:"/donations"},{label:"Technical Support",href:"/tech-support"},{label:"Link to Us",href:"/link-to-totalhorsechannel-com"},{label:"Official AHA Media Partner",href:"/aha-media-partner"},{label:"Add Video / Live",href:"/add-video-live"},{label:"Add Event",href:"/add-event"},{label:"Advertising Options",href:"/advertise"},{label:"Community Guidelines",href:"/community-guidelines"},{label:"Terms of Service",href:"/terms-of-service"},{label:"Privacy Policy",href:"/privacy-policy"}],PC=[{label:"Horse Health",href:"/category/horse-health"},{label:"How To Videos",href:"/category/how-to-videos"},{label:"Horse Racing",href:"/category/horse-racing"},{label:"Show Jumping",href:"/category/show-jumping"},{label:"Quarter Horse",href:"/category/quarter-horse"},{label:"Campdraft",href:"/category/campdraft"}
633,{label:"Cutting Horse",href:"/category/cutting-horse"},{label:"Reined Cow Horse",href:"/category/reined-cow-horse"},{label:"Eventing",href:"/category/eventing"},{label:"Reining",href:"/category/reining"}];function KC(){return e.jsxs("footer",{style:{background:"hsl(var(--thc-footer))"},children:[e.jsx("div",{className:"max-w-[1280px] mx-auto px-4 py-10",children:e.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-8",children:[e.jsxs("div",{children:[e.jsx("h3",{className:"text-white font-semibold text-base mb-4 uppercase tracking-wide",children:"Helpful Links"}),e.jsx("ul",{className:"space-y-2",children:UC.map(t=>e.jsx("li",{children:e.jsx(O,{to:t.href,className:"text-gray-400 hover:text-white text-sm transition-colors",children:t.label})},t.label))})]}),e.jsxs("div",{children:[e.jsx("h3",{className:"text-white font-semibold text-base mb-4 uppercase tracking-wide",children:"Top Categories"}),e.jsx("ul",{className:"space-y-2",children:PC.map(t=>e.jsx("li",{children:e.jsx(O,{to:t.href,className:"text-gray-400 hover:text-white text-sm transition-colors",children:String(t.label)})},t.label))})]})]})}),e.jsx("div",{className:"border-t border-gray-700",children:e.jsxs("div",{className:"max-w-[1280px] mx-auto px-4 py-4 flex flex-col md:flex-row items-center justify-between gap-3",children:[e.jsx("p",{className:"text-gray-500 text-xs text-center",children:"Copyright 2026 © Total Horse Channel Horse Videos and Live Events All rights reserved"}),e.jsxs("div",{className:"flex items-center gap-3",children:[e.jsx("a",{href:"https://www.facebook.com/THCNetwork1",target:"_blank",rel:"noopener noreferrer",className:"text-gray-500 hover:text-white transition-colors",children:e.jsx(Vm,{size:16})}),e.jsx("a",{href:"https://x.com/TotalHorseChann",target:"_blank",rel:"noopener noreferrer",className:"text-gray-500 hover:text-white transition-colors",children:e.jsx(MC,{size:16})}),e.jsx("a",{href:"https://www.instagram.com/totalhorsechannel/",target:"_blank",rel:"noopener noreferrer",className:"text-gray-500 hover:text-white transition-colors",children:e.jsx(a2,{size:16})}),e.jsx("a",{href:"https://www.youtube.com/user/Prowinda",target:"_blank",rel:"noopener noreferrer",className:"text-gray-500 hover:text-white transition-colors",children:e.jsx(Fm,{size:16})}),e.jsx("a",{href:"https://rumble.com/c/TotalHorseChannel",target:"_blank",rel:"noopener noreferrer",className:"text-gray-500 hover:text-white transition-colors flex items-center",children:e.jsx("svg",{width:16,height:16,viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":"true",children:e.jsx("path",{d:"M12 2C6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10S17.523 2 12 2zm3.84 10.933-5.372 3.097A1.07 1.07 0 0 1 8.93 15V9a1.07 1.07 0 0 1 1.538-.93l5.372 3.003a1.07 1.07 0 0 1 0 1.86z"})})})]})]})})]})}const IC={overrides:{}};function dg(t){return!!t&&typeof t=="object"&&!Array.isArray(t)}function BC(t){return t==="bound-expression"||t==="content-key"||t==="content-key-template"}function $C(t){return dg(t)?typeof t.file=="string"&&typeof t.tagName=="string"&&BC(t.sourceKind)&&(t.contentKey===void 0||t.contentKey===null||typeof t.contentKey=="string")&&(t.contentKeyTemplate===void 0||t.contentKeyTemplate===null||typeof t.contentKeyTemplate=="string")&&(t.expressionHash===void 0||t.expressionHash===null||typeof t.expressionHash=="string"):!1}function VC(t){return dg(t)?(t.bold===void 0||typeof t.bold=="boolean")&&(t.italic===void 0||typeof t.italic=="boolean")&&(t.color===void 0||t.color===null||typeof t.color=="string")&&(t.fontSize===void 0||typeof t.fontSize=="string"):!1}function FC(t){return dg(t)?$C(t.target)&&VC(t.marks)&&typeof t.updatedAt=="string":!1}function Io(t){return t??null}function WC(t){const a=t.replace(/\\/g,"/"),r=a.indexOf("/src/");return r!==-1?a.slice(r+1):a.replace(/^\/+/,"")}function qC(t){const a=t.split("/");return a.some(r=>!/^[a-zA-Z0-9_-]+$/.test(r))?null:a.map(r=>r.toLowerCase()).join("/")}function YC(t){const a=WC(t),r=/^src\/pages\/(.+)\.[jt]sx?$/.exec(a);if(!(r!=null&&r[1]))return{key:"shared",filePath:"format-overrides/shared.json"};const o=qC(r[1]);return o?{key:`pages/${o}`,filePath:`format-overrides/pages/${o}.json`}:{key:"shared",filePath:"format-overrides/shared.json"}}function GC(t,a){return t.file===a.file&&t.tagName===a.tagName&&t.sourceKind===a.sourceKind&&Io(t.contentKey)===Io(a.contentKey)&&Io(t.contentKeyTemplate)===Io(a.contentKeyTemplate)&&Io(t.expressionH
633ash)===Io(a.expressionHash)}function ZC(t,a,r){const o=YC(r.file),d=(t.scopes[o.key]??IC).overrides[a];return d?FC(d)?GC(d.target,r)?{status:"applicable",marks:d.marks}:{status:"guard-mismatch",expected:d.target,actual:r}:(o.key,{status:"missing"}):{status:"missing"}}const JC={"0.75rem":"1rem","0.875rem":"1.25rem","1rem":"1.5rem","1.125rem":"1.75rem","1.25rem":"1.75rem","1.5rem":"2rem","1.875rem":"2.25rem","2.25rem":"2.5rem","3rem":"1","3.75rem":"1","4.5rem":"1","6rem":"1","8rem":"1"};function XC(t){const a=t.fontSize?JC[t.fontSize]:void 0;return{...t.bold?{fontWeight:700}:{},...t.italic?{fontStyle:"italic"}:{},...t.color?{color:t.color}:{},...t.fontSize?{fontSize:t.fontSize}:{},...a?{lineHeight:a}:{}}}const QC={version:1,scopes:{}},F0=new Set;let ek=QC;function W0(){return ek}function tk(t){return F0.add(t),()=>{F0.delete(t)}}function sk(){return g.useSyncExternalStore(tk,W0,W0)}function _({devId:t,guard:a,children:r}){const o=sk(),l=ZC(o,t,a);if(l.status==="missing")return e.jsx(e.Fragment,{children:r});if(l.status==="guard-mismatch")return e.jsx(e.Fragment,{children:r});const d=l.marks;return e.jsx("span",{"data-airo-formatted-bound-text":"true","data-airo-format-bold":d.bold?"true":void 0,"data-airo-format-italic":d.italic?"true":void 0,"data-airo-format-color":d.color||void 0,"data-airo-format-size":d.fontSize||void 0,style:XC(d),children:r})}function q0(t,a){typeof window<"u"&&typeof window.gtag=="function"&&window.gtag("event",t,a)}function Jc({bannerId:t,placement:a,href:r,children:o,className:l,target:d="_blank",rel:u="noopener noreferrer"}){const m=g.useRef(null),p=g.useRef(!1);g.useEffect(()=>{const b=m.current;if(!b)return;const y=new IntersectionObserver(v=>{v.forEach(w=>{w.isIntersecting&&!p.current&&(p.current=!0,q0("banner_impression",{banner_id:t,placement:a}))})},{threshold:.5});return y.observe(b),()=>y.disconnect()},[t,a]);function x(){q0("banner_click",{banner_id:t,placement:a,destination:r})}return e.jsx("a",{ref:m,href:r,target:d,rel:u,className:l,onClick:x,children:e.jsx(_,{devId:"2f7140",guard:{file:"src/components/TrackedBanner.tsx",tagName:"a",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:10910087de24bfcabe854fda62b5023a61fe531705043b9979fdf00f12c4c0ec"},children:o})})}function yu({event:t,close:a}){return e.jsxs(O,{to:`/live/${t.slug}`,onClick:a,className:"flex items-center gap-3 px-3 py-2.5 hover:bg-muted transition-colors border-b border-border/50 last:border-0",children:[e.jsx("div",{className:"w-12 h-9 rounded shrink-0 bg-muted border border-border overflow-hidden flex items-center justify-center",children:t.thumbnailUrl?e.jsx("img",{src:t.thumbnailUrl,alt:t.title,className:"w-full h-full object-cover",width:48,height:36,loading:"lazy"}):e.jsx(Vs,{size:16,className:"text-muted-foreground",strokeWidth:1.5})}),e.jsxs("div",{className:"min-w-0 flex-1",children:[e.jsx("p",{className:"text-sm font-semibold text-foreground truncate leading-tight",children:e.jsx(_,{devId:"70d0fd",guard:{file:"src/components/MemberSearch.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:b893322d77b54ddd3b75aaf3a20c3209577a9c72c9311f63a879f09f6c47cab6"},children:t.title})}),t.category&&e.jsx("span",{className:"text-[10px] text-muted-foreground truncate",children:e.jsx(_,{devId:"971bbf",guard:{file:"src/components/MemberSearch.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:f0aeb76661a7b19f97511dd1a5a9ac2eb14437fec504e84838ebbd8da52a5e1b"},children:t.category})})]})]})}function ak(){const t=ga(),[a,r]=g.useState(""),[o,l]=g.useState({categories:[],events:[],members:[]}),[d,u]=g.useState(!1),[m,p]=g.useState(!1),[x,b]=g.useState(!1),y=g.useRef(null),v=g.useRef(null),w=g.useRef(null);g.useEffect(()=>{function D(W){y.current&&!y.current.contains(W.target)&&p(!1)}return document.addEventListener("mousedown",D),()=>document.removeEventListener("mousedown",D)},[]);const C=g.useCallback(async D=>{if(!D.trim()){l({categories:[],events:[],members:[]}),p(!1),b(!1);return}u(!0),p(!0);try{const W=await fetch(`/api/search?q=${encodeURIComponent(D.trim())}`);if(W.ok){const I=await W.json();l(I),b(!0)}}catch{}finally{u(!1)}},[]);function A(D){const W=D.target.value;r(W),w.current&&clearTimeout(w.current),w.current=setTimeout(()=>C(W),280)}
633function S(D){if(D.key==="Escape"){p(!1);return}D.key==="Enter"&&a.trim()&&(p(!1),t(`/search?q=${encodeURIComponent(a.trim())}`))}function z(D){D.preventDefault(),a.trim()&&(p(!1),t(`/search?q=${encodeURIComponent(a.trim())}`))}function T(){a.trim()&&x&&p(!0)}function M(){r(""),p(!1),b(!1),l({categories:[],events:[],members:[]}),w.current&&clearTimeout(w.current),requestAnimationFrame(()=>{var D;return(D=v.current)==null?void 0:D.focus()})}function P(){p(!1),r(""),b(!1),l({categories:[],events:[],members:[]})}const E=o.categories.length>0,U=o.events.length>0,q=o.members.length>0,H=x&&!d&&!E&&!U&&!q,J=o.events.filter(D=>!D.isArchived&&D.videoType==="live"),B=o.events.filter(D=>!D.isArchived&&D.videoType==="upcoming"),Y=o.events.filter(D=>!D.isArchived&&D.videoType==="video"),$=o.events.filter(D=>!!D.isArchived);return e.jsxs("div",{ref:y,className:"relative flex-1 max-w-xs",children:[e.jsx("form",{onSubmit:z,children:e.jsxs("div",{className:"flex items-center border border-border rounded-full overflow-hidden bg-white",children:[e.jsx("input",{ref:v,type:"text",value:a,onChange:A,onKeyDown:S,onFocus:T,placeholder:"Search videos & members...",className:"flex-1 px-4 py-2 text-sm outline-none bg-white text-foreground","aria-label":"Search videos and members",autoComplete:"off"}),a&&e.jsx("button",{type:"button",onClick:M,className:"px-2 py-2 text-muted-foreground bg-white hover:text-foreground transition-colors","aria-label":"Clear search",children:e.jsx(Vt,{size:14})}),e.jsx("button",{type:"submit",className:"px-3 py-2 text-muted-foreground bg-white hover:text-primary transition-colors","aria-label":"Go to search results",children:e.jsx(pi,{size:16})})]})}),m&&e.jsxs("div",{className:"absolute top-full left-0 right-0 mt-1 bg-card border border-border shadow-xl z-[200] rounded-sm overflow-hidden max-h-[520px] overflow-y-auto",children:[d&&e.jsx("div",{className:"flex justify-center py-4",children:e.jsx("div",{className:"w-5 h-5 border-2 border-primary border-t-transparent rounded-full animate-spin"})}),H&&e.jsx("div",{className:"px-4 py-3 text-sm text-muted-foreground",children:"No results found."}),!d&&q&&e.jsxs(e.Fragment,{children:[e.jsx("div",{className:"px-3 py-1.5 bg-muted border-b border-border",children:e.jsx("span",{className:"text-xs font-bold uppercase tracking-wide text-muted-foreground",children:"Members"})}),o.members.map(D=>e.jsxs(O,{to:`/u/${D.username}`,onClick:P,className:"flex items-center gap-3 px-3 py-2.5 hover:bg-muted transition-colors border-b border-border/50 last:border-0",children:[e.jsx("div",{className:"w-8 h-8 rounded-full bg-muted border border-border overflow-hidden shrink-0 flex items-center justify-center",children:D.avatarUrl?e.jsx("img",{src:D.avatarUrl,alt:D.name??D.username,className:"w-full h-full object-cover",width:32,height:32}):e.jsx(Ha,{size:15,className:"text-muted-foreground",strokeWidth:1.5})}),e.jsxs("div",{className:"min-w-0",children:[e.jsx("p",{className:"text-sm font-semibold text-foreground truncate leading-tight",children:D.name??D.username}),e.jsxs("p",{className:"text-xs text-muted-foreground truncate",children:["@",D.username]})]})]},D.username))]}),!d&&E&&e.jsxs(e.Fragment,{children:[e.jsx("div",{className:"px-3 py-1.5 bg-muted border-b border-border border-t border-t-border",children:e.jsx("span",{className:"text-xs font-bold uppercase tracking-wide text-muted-foreground",children:"Categories"})}),o.categories.map(D=>e.jsxs(O,{to:`/category/${D.slug}`,onClick:P,className:"flex items-center gap-3 px-3 py-2.5 hover:bg-muted transition-colors border-b border-border/50 last:border-0",children:[e.jsx("div",{className:"w-7 h-7 rounded shrink-0 bg-primary/10 flex items-center justify-center",children:e.jsx(Qf,{size:13,className:"text-primary"})}),e.jsxs("div",{className:"min-w-0",children:[e.jsx("p",{className:"text-sm font-semibold text-foreground truncate leading-tight",children:D.label}),e.jsx("p",{className:"text-xs text-muted-foreground",children:"Category page"})]})]},D.slug))]}),!d&&J.length>0&&e.jsxs(e.Fragment,{children:[e.jsx("div",{className:"px-3 py-1.5 bg-muted border-b border-border border-t border-t-border",children:e.jsxs("span",{className:"text-xs font-bold uppercase tracking-wide text-primary flex items-center gap-1",children:[e.jsx(Ft,{size:10}),"Live"]})}),J.map(D=>e.jsx(yu,{event:D,close:P},D.id))]}),!d&&B.length>0&&e.jsxs(e.Fragment,{children:[e.jsx("div",{className:"px-3 py-1.5 bg-muted border-b border-border border-t border-t-border",children:e.jsxs("span",{className:"text-xs font-bold uppercase tracking-wide text-accent flex items-center gap-1",children:[e.jsx(Ft,{size:10}),"Upcoming"]})}),B.map(D=>e.jsx(yu,{event:D,close:P},D.id))]}),!d&&Y.length>0&&e.jsxs(e.Fragment,{children:[e.jsx("div",{className:"px-3 py-1.5 bg-muted border-b border-border border-t border-t-border",children:e.jsxs("span",{className:"text-xs font-bold uppercase tracking-wide text-muted-foreground flex items-center gap-1",children:[e.jsx(Vs,{size:10}),"Video"]})}),Y.map(D=>e.jsx(yu,{event:D,close:P},D.id))]}),!d&&$.length>0&&e.jsxs(e.Fragment,{children:[e.jsx("div",{className:"px-3 py-1.5 bg-muted border-b border-border border-t border-t-border",children:e.jsxs("span",{className:"text-xs font-bold uppercase tracking-wide text-muted-foreground flex items-center gap-1",children:[e.jsx(Vs,{size:10}),"Archive"]})}),$.map(D=>e.jsx(yu,{event:D,close:P},D.id))]}),!d&&x&&(U||q||E)&&e.jsxs(O,{to:`/search?q=${encodeURIComponent(a.trim())}`,onClick:P,className:"flex items-center justify-center gap-1.5 px-3 py-2.5 bg-primary/5 hover:bg-primary/10 transition-colors border-t border-border text-sm font-semibold text-primary",children:[e.jsx(pi,{size:13}),"See all results for “",a,"”"]}
633)]})]})}var nk={};const zu=Object.create(null),dc=t=>{var a;return nk||((a=globalThis.Deno)==null?void 0:a.env.toObject())||globalThis.__env__||(t?zu:globalThis)},ii=new Proxy(zu,{get(t,a){return dc()[a]??zu[a]},has(t,a){return a in dc()||a in zu},set(t,a,r){const o=dc(!0);return o[a]=r,!0},deleteProperty(t,a){if(!a)return!1;const r=dc(!0);return delete r[a],!0},ownKeys(){const t=dc(!0);return Object.keys(t)}});ii.NODE_ENV;var Ru=class extends Error{constructor(t,a){super(t,a),this.name="BetterAuthError",this.message=t,this.stack=""}};const rk=47;function l2(t){let a=t.length;for(;a>0&&t.charCodeAt(a-1)===rk;)a--;return a===t.length?t:t.slice(0,a)}function ik(t){try{return(l2(new URL(t).pathname)||"/")!=="/"}catch{throw new Ru(`Invalid base URL: ${t}. Please provide a valid base URL.`)}}function ok(t){try{const a=new URL(t);if(a.protocol!=="http:"&&a.protocol!=="https:")throw new Ru(`Invalid base URL: ${t}. URL must include 'http://' or 'https://'`)}catch(a){throw a instanceof Ru?a:new Ru(`Invalid base URL: ${t}. Please provide a valid base URL.`,{cause:a})}}function uf(t,a="/api/auth"){if(ok(t),ik(t))return t;const r=l2(t);return!a||a==="/"?r:(a=a.startsWith("/")?a:`/${a}`,`${r}${a}`)}function lk(t,a,r,o,l){if(t)return uf(t,a);{const d=ii.BETTER_AUTH_URL||ii.NEXT_PUBLIC_BETTER_AUTH_URL||ii.PUBLIC_BETTER_AUTH_URL||ii.NUXT_PUBLIC_BETTER_AUTH_URL||ii.NUXT_PUBLIC_AUTH_URL||(ii.BASE_URL!=="/"?ii.BASE_URL:void 0);if(d)return uf(d,a)}if(typeof window<"u"&&window.location)return uf(window.location.origin,a)}const ck={proto:/"(?:_|\\u0{2}5[Ff]){2}(?:p|\\u0{2}70)(?:r|\\u0{2}72)(?:o|\\u0{2}6[Ff])(?:t|\\u0{2}74)(?:o|\\u0{2}6[Ff])(?:_|\\u0{2}5[Ff]){2}"\s*:/,constructor:/"(?: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*:/,protoShort:/"__proto__"\s*:/,constructorShort:/"constructor"\s*:/},dk=/^\s*["[{]|^\s*-?\d{1,16}(\.\d{1,17})?([Ee][+-]?\d+)?\s*$/,Y0={true:!0,false:!1,null:null,undefined:void 0,nan:NaN,infinity:Number.POSITIVE_INFINITY,"-infinity":Number.NEGATIVE_INFINITY},uk=/^(\d{4})-(\d{2})-(\d{2})T(\d{2}):(\d{2}):(\d{2})(?:\.(\d{1,7}))?(?:Z|([+-])(\d{2}):(\d{2}))$/;function mk(t){return t instanceof Date&&!isNaN(t.getTime())}function hk(t){const a=uk.exec(t);if(!a)return null;const[,r,o,l,d,u,m,p,x,b,y]=a,v=new Date(Date.UTC(parseInt(r,10),parseInt(o,10)-1,parseInt(l,10),parseInt(d,10),parseInt(u,10),parseInt(m,10),p?parseInt(p.padEnd(3,"0"),10):0));if(x){const w=(parseInt(b,10)*60+parseInt(y,10))*(x==="+"?-1:1);v.setUTCMinutes(v.getUTCMinutes()+w)}return mk(v)?v:null}function pk(t,a={}){const{strict:r=!1,warnings:o=!1,reviver:l,parseDates:d=!0}=a;if(typeof t!="string")return t;const u=t.trim(),m=u.toLowerCase();if(m.length<=9&&m in Y0)return Y0[m];if(!dk.test(u)){if(r)throw new SyntaxError("[better-json] Invalid JSON");return t}if(Object.entries(ck).some(([p,x])=>{const b=x.test(u);return b&&o&&console.warn(`[better-json] Detected potential prototype pollution attempt using ${p} pattern`),b})&&r)throw new Error("[better-json] Potential prototype pollution attempt detected");try{return JSON.parse(u,(x,b)=>{if(x==="__proto__"||x==="constructor"&&b&&typeof b=="object"&&"prototype"in b){o&&console.warn(`[better-json] Dropping "${x}" key to prevent prototype pollution`);return}if(d&&typeof b=="string"){const y=hk(b);if(y)return y}return l?l(x,b):b})}catch(p){if(r)throw p;return t}}function fk(t,a={strict:!0}){return pk(t,a)}const xk=["javascript:","data:","vbscript:"];function gk(t){let a;try{a=new URL(t)}catch{return!0}return!xk.includes(a.protocol)}const bk={id:"redirect",name:"Redirect",hooks:{onSuccess(t){var a,r;if((a=t.data)!=null&&a.url&&((r=t.data)!=null&&r.redirect)&&gk(t.data.url)&&typeof window<"u"&&window.location&&window.location)try{window.location.href=t.data.url}catch{}}}};let Nn=[],gc=0;const tx=4,yk=globalThis.nanostoresGlobal||(globalThis.nanostoresGlobal={epoch:0});let vk=()=>{let t,a;for(;gc<Nn.length;){a=gc,gc+=tx;try{Nn[a](Nn[a+1].value,Nn[a+2],Nn[a+3])}catch(r){t=r}}if(Nn.length=gc=0,t)throw t};const G0=t=>{let a=[],r={eq:Object.is,get(){return r.lc||r.listen(()=>{})(),r.value},init:t,lc:0,listen(o){return r.lc=a.push(o),()=>{for(let d=gc;d<Nn.length;)Nn[d]===o?Nn.splice(d,tx):d+=tx;let l=a.indexOf(o);~l&&(a.splice(l,1),--r.lc||r.off())}},notify(o,l){yk.epoch++;let d=!Nn.length&&!0;for(let u of a)Nn.push(u,r,o,l);d&&vk()},off(){},set(o){let l=r.value;r.eq(l,o)||(r.value=o,r.notify(l))},subscribe(o){let l=r.listen(o);return o(r.value),l},value:t};return r},jk=2,wk=5,vu=6,ju=10;let c2=(t,a,r,o)=>(t.events=t.events||{},t.events[r+ju]||(t.events[r+ju]=o(l=>{t.events[r].reduceRight((d,u)=>(u(d),d),{shared:{},...l})})),t.events[r]=t.events[r]||[],t.events[r].push(a),()=>{let l=t.events[r],d=l.indexOf(a);~d&&(l.splice(d,1),l.length||(t.events[r+ju](),delete t.events[r+ju]))}),Nk=(t,a)=>c2(t,a,jk,r=>{let o=t.set,l=t.setKey;return t.setKey&&(t.setKey=(d,u)=>{let m;if(r({abort:()=>{m=!0},changed:d,newValue:{...t.value,[d]:u}}),!m)return l(d,u)}),t.set=d=>{let u;if(r({abort:()=>{u=!0},newValue:d}),!u)return o(d)},()=>{t.set=o,t.setKey=l}});const Sk=1e3;let Ck=(t,a)=>c2(t,o=>{let l=a(o);l&&t.events[vu].push(l)},wk,o=>{let l=t.listen;t.listen=(...u)=>(!t.lc&&!t.active&&(t.active=!0,o()),l(...u));let d=t.off;return t.events[vu]=[],t.off=()=>{d(),setTimeout(()=>{if(t.active&&!t.lc){t.active=!1;for(let u of t.events[vu])u();t.events[vu]=[]}},Sk)},()=>{t.listen=l,t.off=d}});function Z0(t,a){let r=kk(a),o=t;for(let l of r){if(o==null)return;o=o[l]}return o}const J0=/(.*)\[(\d+)\]/;function kk(t){return t.split(".").flatMap(a=>d2(a))}function d2(t){if(J0.test(t)){let[,a,r]=t.match(J0);return[...d2(a),r]}return[t]}
633function Tk(t,a,r){let o=new Set(a);return t.listen((l,d,u)=>{(u===void 0?a.some(m=>d===void 0||l[m]!==d[m]||Z0(l,m)!==Z0(d,m)):o.has(u)||o.has(u.split(/\.|\[/)[0]))&&r(l,d,u)})}function X0(t){if(typeof t!="object"||t===null)return!1;const a=Object.getPrototypeOf(t);return a===Object.prototype||a===null}function Bu(t,a){if(t===a)return!0;if(Array.isArray(t)&&Array.isArray(a)){if(t.length!==a.length)return!1;for(let r=0;r<t.length;r++)if(!Bu(t[r],a[r]))return!1;return!0}if(X0(t)&&X0(a)){const r=Object.keys(t),o=Object.keys(a);if(r.length!==o.length)return!1;for(const l of r)if(!(l in a)||!Bu(t[l],a[l]))return!1;return!0}return!1}function Ak(t,a){return Nk(t,({newValue:r,abort:o})=>{a(t.value,r)&&o()})}const mf=Symbol.for("better-auth:broadcast-channel"),Ek=()=>Math.floor(Date.now()/1e3);var Hk=class{constructor(t="better-auth.message"){ma(this,"listeners",new Set);ma(this,"name");this.name=t}subscribe(t){return this.listeners.add(t),()=>{this.listeners.delete(t)}}post(t){if(!(typeof window>"u"))try{localStorage.setItem(this.name,JSON.stringify({...t,timestamp:Ek()}))}catch{}}setup(){if(typeof window>"u"||typeof window.addEventListener>"u")return()=>{};const t=a=>{if(a.key!==this.name)return;const r=JSON.parse(a.newValue??"{}");(r==null?void 0:r.event)!=="session"||!(r!=null&&r.data)||this.listeners.forEach(o=>o(r))};return window.addEventListener("storage",t),()=>{window.removeEventListener("storage",t)}}};function hf(t="better-auth.message"){return globalThis[mf]||(globalThis[mf]=new Hk(t)),globalThis[mf]}const pf=Symbol.for("better-auth:focus-manager");var zk=class{constructor(){ma(this,"listeners",new Set)}subscribe(t){return this.listeners.add(t),()=>{this.listeners.delete(t)}}setFocused(t){this.listeners.forEach(a=>a(t))}setup(){if(typeof window>"u"||typeof document>"u"||typeof window.addEventListener>"u")return()=>{};const t=()=>{document.visibilityState==="visible"&&this.setFocused(!0)};return document.addEventListener("visibilitychange",t,!1),()=>{document.removeEventListener("visibilitychange",t,!1)}}};function Q0(){return globalThis[pf]||(globalThis[pf]=new zk),globalThis[pf]}const ff=Symbol.for("better-auth:online-manager");var Rk=class{constructor(){ma(this,"listeners",new Set);ma(this,"isOnline",typeof navigator<"u"?navigator.onLine:!0)}subscribe(t){return this.listeners.add(t),()=>{this.listeners.delete(t)}}setOnline(t){this.isOnline=t,this.listeners.forEach(a=>a(t))}setup(){if(typeof window>"u"||typeof window.addEventListener>"u")return()=>{};const t=()=>this.setOnline(!0),a=()=>this.setOnline(!1);return window.addEventListener("online",t,!1),window.addEventListener("offline",a,!1),()=>{window.removeEventListener("online",t,!1),window.removeEventListener("offline",a,!1)}}};function xf(){return globalThis[ff]||(globalThis[ff]=new Rk),globalThis[ff]}const gf=()=>Math.floor(Date.now()/1e3),_k=5;function Lk(t){var M,P,E;const{fetchSession:a,shouldPollSession:r=()=>!0,sessionSignal:o,options:l={}}=t,d=((M=l.sessionOptions)==null?void 0:M.refetchInterval)??0,u=((P=l.sessionOptions)==null?void 0:P.refetchOnWindowFocus)??!0,m=((E=l.sessionOptions)==null?void 0:E.refetchWhenOffline)??!1,p={isInitialized:!1,lastSessionRequest:0},x=()=>m||xf().isOnline,b=U=>{if(x()){if((U==null?void 0:U.event)==="storage"){a();return}if((U==null?void 0:U.event)==="poll"){p.lastSessionRequest=gf(),a();return}if((U==null?void 0:U.event)==="visibilitychange"){if(gf()-p.lastSessionRequest<_k)return;p.lastSessionRequest=gf(),a();return}a()}},y=U=>{hf().post({event:"session",data:{trigger:U},clientId:Math.random().toString(36).substring(7)})},v=()=>{d&&d>0&&(p.pollInterval=setInterval(()=>{r()&&b({event:"poll"})},d*1e3))},w=()=>{p.unsubscribeBroadcast=hf().subscribe(()=>{b({event:"storage"})})},C=()=>{u&&(p.unsubscribeFocus=Q0().subscribe(()=>{b({event:"visibilitychange"})}))},A=()=>{p.unsubscribeOnline=xf().subscribe(U=>{U&&b({event:"visibilitychange"})})},S=()=>{p.unsubscribeSignal=o.listen(()=>{a()})};return{init:()=>{p.isInitialized||(p.isInitialized=!0,v(),w(),C(),A(),S(),p.cleanupBroadcastSetup=hf().setup(),p.cleanupFocusSetup=Q0().setup(),p.cleanupOnlineSetup=xf().setup())},cleanup:()=>{p.isInitialized&&(p.pollInterval&&(clearInterval(p.pollInterval),p.pollInterval=void 0),p.unsubscribeBroadcast&&(p.unsubscribeBroadcast(),p.unsubscribeBroadcast=void 0),p.unsubscribeFocus&&(p.unsubscribeFocus(),p.unsubscribeFocus=void 0),p.unsubscribeOnline&&(p.unsubscribeOnline(),p.unsubscribeOnline=void 0),p.unsubscribeSignal&&(p.unsubscribeSignal(),p.unsubscribeSignal=void 0),p.cleanupBroadcastSetup&&(p.cleanupBroadcastSetup(),p.cleanupBroadcastSetup=void 0),p.cleanupFocusSetup&&(p.cleanupFocusSetup(),p.cleanupFocusSetup=void 0),p.cleanupOnlineSetup&&(p.cleanupOnlineSetup(),p.cleanupOnlineSetup=void 0),p.isInitialized=!1,p.lastSessionRequest=0)},triggerRefetch:b,broadcastSessionUpdate:y}}const Dk=()=>typeof window>"u";function ej(t){return typeof t=="object"&&t!==null&&"data"in t&&"error"in t?t:{data:t,error:null}}function Ok(t){return!t||t.session===null&&t.user===null?null:t}function Mk(t,a){return Bu(t.data,a.data)&&t.error===a.error&&t.isPending===a.isPending&&t.isRefetching===a.isRefetching&&t.refetch===a.refetch}function Uk(t,a){const r=G0(!1);let o;const l=x=>m(x),d=G0({data:null,error:null,isPending:!0,isRefetching:!1,refetch:l});Ak(d,Mk);const u=x=>{if(o!==x)return;const b=d.get();o=void 0,!(!b.isPending&&!b.isRefetching)&&d.set({...b,isPending:!1,isRefetching:!1,refetch:l})},m=async x=>{o==null||o.abort();const b=new AbortController;o=b;const y=d.get();d.set({...y,isPending:y.data===null,isRefetching:!0,error:null,refetch:l});try{const v=await t("/get-session",{method:"GET",query:x==null?void 0:x.query,signal:b.signal});if(b.signal.aborted){u(b);return}let{data:w,error:C}=ej(v);if(w!=null&&w.needsRefresh)try{const T=await t("/get-session",{method:"POST",signal:b.signal});if(b.signal.aborted){u(b);return}({data:w,error:C}=ej(T))}catch{if(b.signal.aborted){u(b);return}}if(C){const T=d.get(),M=(C==null?void 0:C.status)===401;d.set({data:M?null:T.data,error:C,isPending:!1,isRefetching:!1,refetch:l});return}const A=Ok(w),S=d.get(),z=S.data!=null&&A!=null&&Bu(S.data,A)?S.data:A;d.set({data:z,error:null,isPending:!1,isRefetching:!1,refetch:l})}catch(v){if(b.signal.aborted){u(b);return}const w=d.get();d.set({data:w.data,error:v,isPending:!1,isRefetching:!1,refetch:l})}};let p=()=>{};return Ck(d,()=>{let x;Dk()||(x=setTimeout(()=>{m()},0));const b=Lk({fetchSession:m,shouldPollSession:()=>d.get().data!=null,sessionSignal:r,options:a});return b.init(),p=b.broadcastSessionUpdate,()=>{x&&clearTimeout(x);const y=o;y==null||y.abort(),y&&u(y),b.cleanup()}}),{session:d,$sessionSignal:r,broadcastSessionUpdate:x=>p(x)}}function bf(t){if(t===null||typeof t!="object")return!1;const a=Object.getPrototypeOf(t);return a!==null&&a!==Object.prototype&&Object.getPrototypeOf(a)!==null||Symbol.iterator in t?!1:Symbol.toStringTag in t?Object.prototype.toString.call(t)==="[object Module]":!0}function sx(t,a,r=".",o){if(!bf(a))return sx(t,{},r,o);const l={...a};for(const d of Object.keys(t)){if(d==="__proto__"||d==="constructor")continue;const u=t[d];u!=null&&(o&&o(l,d,u,r)||(Array.isArray(u)&&Array.isArray(l[d])?l[d]=[...u,...l[d]]:bf(u)&&bf(l[d])?l[d]=sx(u,l[d],(r?`${r}.`:"")+d.toString(),o):l[d]=u))}return l}function Pk(t){return(...a)=>a.reduce((r,o)=>sx(r,o,"",t),{})}const Kk=Pk();var Ik=Object.defineProperty,Bk=Object.defineProperties,$k=Object.getOwnPropertyDescriptors,tj=Object.getOwnPropertySymbols,Vk=Object.prototype.hasOwnProperty,Fk=Object.prototype.propertyIsEnumerable,sj=(t,a,r)=>a in t?Ik(t,a,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[a]=r,wn=(t,a)=>{for(var r in a||(a={}))Vk.call(a,r)&&sj(t,r,a[r]);if(tj)for(var r of tj(a))Fk.call(a,r)&&sj(t,r,a[r]);return t},Bn=(t,a)=>
633Bk(t,$k(a)),Wk=class extends Error{constructor(t,a,r){super(a||t.toString(),{cause:r}),this.status=t,this.statusText=a,this.error=r,Error.captureStackTrace(this,this.constructor)}},qk=async(t,a)=>{var r,o,l,d,u,m;let p=a||{};const x={onRequest:[a==null?void 0:a.onRequest],onResponse:[a==null?void 0:a.onResponse],onSuccess:[a==null?void 0:a.onSuccess],onError:[a==null?void 0:a.onError],onRetry:[a==null?void 0:a.onRetry]};if(!a||!(a!=null&&a.plugins))return{url:t,options:p,hooks:x};for(const b of(a==null?void 0:a.plugins)||[]){if(b.init){const y=await((r=b.init)==null?void 0:r.call(b,t.toString(),a));p=y.options||p,t=y.url}x.onRequest.push((o=b.hooks)==null?void 0:o.onRequest),x.onResponse.push((l=b.hooks)==null?void 0:l.onResponse),x.onSuccess.push((d=b.hooks)==null?void 0:d.onSuccess),x.onError.push((u=b.hooks)==null?void 0:u.onError),x.onRetry.push((m=b.hooks)==null?void 0:m.onRetry)}return{url:t,options:p,hooks:x}},aj=class{constructor(t){this.options=t}shouldAttemptRetry(t,a){return this.options.shouldRetry?Promise.resolve(t<this.options.attempts&&this.options.shouldRetry(a)):Promise.resolve(t<this.options.attempts)}getDelay(){return this.options.delay}},Yk=class{constructor(t){this.options=t}shouldAttemptRetry(t,a){return this.options.shouldRetry?Promise.resolve(t<this.options.attempts&&this.options.shouldRetry(a)):Promise.resolve(t<this.options.attempts)}getDelay(t){return Math.min(this.options.maxDelay,this.options.baseDelay*2**t)}};function Gk(t){if(typeof t=="number")return new aj({type:"linear",attempts:t,delay:1e3});switch(t.type){case"linear":return new aj(t);case"exponential":return new Yk(t);default:throw new Error("Invalid retry strategy")}}var Zk=async t=>{const a={},r=async o=>typeof o=="function"?await o():o;if(t!=null&&t.auth){if(t.auth.type==="Bearer"){const o=await r(t.auth.token);if(!o)return a;a.authorization=`Bearer ${o}`}else if(t.auth.type==="Basic"){const[o,l]=await Promise.all([r(t.auth.username),r(t.auth.password)]);if(!o||!l)return a;a.authorization=`Basic ${btoa(`${o}:${l}`)}`}else if(t.auth.type==="Custom"){const[o,l]=await Promise.all([r(t.auth.prefix),r(t.auth.value)]);if(!l)return a;a.authorization=`${o??""} ${l}`}}return a},Jk=/^application\/(?:[\w!#$%&*.^`~-]*\+)?json(;.+)?$/i;function Xk(t){const a=t.headers.get("content-type"),r=new Set(["image/svg","application/xml","application/xhtml","application/html"]);if(!a)return"json";const o=a.split(";").shift()||"";return Jk.test(o)?"json":r.has(o)||o.startsWith("text/")?"text":"blob"}function Qk(t){try{return JSON.parse(t),!0}catch{return!1}}function u2(t){if(t===void 0)return!1;const a=typeof t;return a==="string"||a==="number"||a==="boolean"||a===null?!0:a!=="object"?!1:Array.isArray(t)?!0:t.buffer?!1:t.constructor&&t.constructor.name==="Object"||typeof t.toJSON=="function"}function nj(t){try{return JSON.parse(t)}catch{return t}}function rj(t){return typeof t=="function"}function eT(t){if(t!=null&&t.customFetchImpl)return t.customFetchImpl;if(typeof globalThis<"u"&&rj(globalThis.fetch))return globalThis.fetch;if(typeof window<"u"&&rj(window.fetch))return window.fetch;throw new Error("No fetch implementation found")}function m2(...t){const a={};for(const r of t)if(r)if(r instanceof Headers)r.forEach((o,l)=>{a[l]=o});else{const o=Array.isArray(r)?r:Object.entries(r);for(const[l,d]of o)d!=null&&(a[l]=d)}return a}async function tT(t){const a=new Headers(m2(t==null?void 0:t.headers,await Zk(t)));if(!a.has("content-type")){const r=sT(t==null?void 0:t.body);r&&a.set("content-type",r)}return a}function sT(t){return u2(t)?"application/json":null}function aT(t){const a=t.get("content-type");return a?a.split(";")[0].trim().toLowerCase():null}function nT(t,a){const{body:r}=t;return r?!u2(r)||typeof r=="string"?r:aT(a)==="application/x-www-form-urlencoded"?new URLSearchParams(r).toString():JSON.stringify(r):null}function rT(t,a){var r;if(a!=null&&a.method)return a.method.toUpperCase();if(t.startsWith("@")){const o=(r=t.split("@")[1])==null?void 0:r.split("/")[0];return p2.includes(o)?o.toUpperCase():a!=null&&a.body?"POST":"GET"}return a!=null&&a.body?"POST":"GET"}function iT(t,a){let r;return!(t!=null&&t.signal)&&(t!=null&&t.timeout)&&(r=setTimeout(()=>
633a==null?void 0:a.abort(),t==null?void 0:t.timeout)),{abortTimeout:r,clearTimeout:()=>{r&&clearTimeout(r)}}}var oT=class h2 extends Error{constructor(a,r){super(r||JSON.stringify(a,null,2)),this.issues=a,Object.setPrototypeOf(this,h2.prototype)}};async function bc(t,a){const r=await t["~standard"].validate(a);if(r.issues)throw new oT(r.issues);return r.value}var p2=["get","post","put","patch","delete"],lT=t=>({id:"apply-schema",name:"Apply Schema",version:"1.0.0",async init(a,r){var o,l,d,u;const m=((l=(o=t.plugins)==null?void 0:o.find(p=>{var x;return(x=p.schema)!=null&&x.config?a.startsWith(p.schema.config.baseURL||"")||a.startsWith(p.schema.config.prefix||""):!1}))==null?void 0:l.schema)||t.schema;if(m){let p=a;(d=m.config)!=null&&d.prefix&&p.startsWith(m.config.prefix)&&(p=p.replace(m.config.prefix,""),m.config.baseURL&&(a=a.replace(m.config.prefix,m.config.baseURL))),(u=m.config)!=null&&u.baseURL&&p.startsWith(m.config.baseURL)&&(p=p.replace(m.config.baseURL,"")),p.startsWith("/")&&p.charAt(1)==="@"&&(p=p.substring(1));const x=m.schema[p];if(x){let b=r==null?void 0:r.headers;if(x.headers&&!(r!=null&&r.disableValidation)){const v={};if(r!=null&&r.headers){if(r.headers instanceof Headers)r.headers.forEach((A,S)=>{v[S.toLowerCase()]=A});else if(typeof r.headers=="object")for(const[A,S]of Object.entries(r.headers))S!=null&&(v[A.toLowerCase()]=S)}const w=await bc(x.headers,v),C={};for(const[A,S]of Object.entries(w))C[A.toLowerCase()]=S;b=C}let y=Bn(wn({},r),{method:x.method,output:x.output,headers:b});return r!=null&&r.disableValidation||(y=Bn(wn({},y),{body:x.input?await bc(x.input,r==null?void 0:r.body):r==null?void 0:r.body,params:x.params?await bc(x.params,r==null?void 0:r.params):r==null?void 0:r.params,query:x.query?await bc(x.query,r==null?void 0:r.query):r==null?void 0:r.query})),{url:a,options:y}}}return{url:a,options:r}}}),cT=t=>{async function a(r,o){const l=Bn(wn(wn({},t),o),{headers:m2(t==null?void 0:t.headers,o==null?void 0:o.headers),plugins:[...(t==null?void 0:t.plugins)||[],lT(t||{}),...(o==null?void 0:o.plugins)||[]]});if(t!=null&&t.catchAllError)try{return await ax(r,l)}catch(d){return{data:null,error:{status:500,statusText:"Fetch Error",message:"Fetch related error. Captured by catchAllError option. See error property for more details.",error:d}}}return await ax(r,l)}return a},dT=t=>t==="."||t==="..";function uT(t,a){let r=t;for(const[o,l]of a)r=r.replace(o,l);if(dT(r))throw new TypeError("Path parameters cannot be reserved path segments");return encodeURIComponent(r)}function mT(t,a){const{baseURL:r,params:o,query:l}=a||{query:{},params:{},baseURL:""};let d=t.startsWith("http")?t.split("/").slice(0,3).join("/"):r||"";if(t.startsWith("@")){const v=t.toString().split("@")[1].split("/")[0];p2.includes(v)&&(t=t.replace(`@${v}/`,"/"))}d.endsWith("/")||(d+="/");let[u,m]=t.replace(d,"").split("?");const p=new URLSearchParams(m);for(const[v,w]of Object.entries(l||{})){if(w==null)continue;let C;if(typeof w=="string")C=w;else if(Array.isArray(w)){for(const A of w)p.append(v,A);continue}else C=JSON.stringify(w);p.set(v,C)}const x=new Map;if(o)if(Array.isArray(o)){const v=u.split("/").filter(w=>w.startsWith(":"));for(const[w,C]of v.entries()){const A=o[w];x.set(C,String(A))}}else for(const[v,w]of Object.entries(o))x.set(`:${v}`,String(w));u=u.split("/").map(v=>uT(v,x)).join("/"),u=u.replace(/^\/+/,"");let b=p.toString();return b=b.length>0?`?${b}`.replace(/\+/g,"%20"):"",d.startsWith("http")?new URL(`${u}${b}`,d):`${d}${u}${b}`}var ax=async(t,a)=>{var r,o,l,d,u,m,p,x;const{hooks:b,url:y,options:v}=await qk(t,a),w=eT(v),C=new AbortController,A=(r=v.signal)!=null?r:C.signal,S=mT(y,v),z=await tT(v),T=nT(v,z),M=rT(y,v),P=Bn(wn({},v),{url:S,headers:z,body:T,method:M,signal:A});for(const D of b.onRequest)if(D){const W=await D(P);typeof W=="object"&&W!==null&&Object.assign(P,W)}("pipeTo"in P&&typeof P.pipeTo=="function"||typeof((o=a==null?void 0:a.body)==null?void 0:o.pipe)=="function")&&("duplex"in P||(P.duplex="half"));const{clearTimeout:E}=iT(v,C);let U=await w(P.url,P);E();const q={response:U,request:P};for(const D of b.onResponse)if(D){const W=await D(Bn(wn({},q),{response:(l=a==null?void 0:a.hookOptions)!=null&&l.cloneResponse?U.clone():U}));W instanceof Response?U=W:typeof W=="object"&&W!==null&&(U=W.response)}if(U.ok){if(!(P.method!=="HEAD"))return{data:"",error:null};const W=Xk(U),I={data:null,response:U,request:P};if(W==="json"||W==="text"){const k=await U.text(),K=(d=P.jsonParser)!=null?d:nj;I.data=await K(k)}else I.data=await U[W]();P!=null&&P.output&&P.output&&!P.disableValidation&&(I.data=await bc(P.output,I.data));for(const k of b.onSuccess)k&&await k(Bn(wn({},I),{response:(u=a==null?void 0:a.hookOptions)!=null&&u.cloneResponse?U.clone():U}));return a!=null&&a.throw?I.data:{data:I.data,error:null}}const H=(m=a==null?void 0:a.jsonParser)!=null?m:nj,J=await U.text(),B=Qk(J),Y=B?await H(J):null,$={response:U,responseText:J,request:P,error:Bn(wn({},Y),{status:U.status,statusText:U.statusText})};for(const D of b.onError)D&&await D(Bn(wn({},$),{response:(p=a==null?void 0:a.hookOptions)!=null&&p.cloneResponse?U.clone():U}));if(a!=null&&a.retry){const D=Gk(a.retry),W=(x=a.retryAttempt)!=null?x:0;if(await D.shouldAttemptRetry(W,U)){for(const k of b.onRetry)k&&await k(q);const I=D.getDelay(W);return await new Promise(k=>setTimeout(k,I)),await ax(t,Bn(wn({},a),{retryAttempt:W+1}))}}if(a!=null&&a.throw)throw new Wk(U.status,U.statusText,B?Y:J);return{data:null,error:Bn(wn({},Y),{status:U.status,statusText:U.statusText})}},Ii={};const hT=t=>{if(typeof process>"u")return;const a=t??"/api/auth";if(Ii.NEXT_PUBLIC_AUTH_URL)return Ii.NEXT_PUBLIC_AUTH_URL;if(typeof window>"u"){if(Ii.NEXTAUTH_URL)try{return Ii.NEXTAUTH_URL}catch{}if(Ii.VERCEL_URL)try{const r=Ii.VERCEL_URL.startsWith("http")?"":"https://";return`${new URL(`${r}${Ii.VERCEL_URL}`).origin}${a}`}catch{}}},pT=(t,a)=>{var E,U,q,H,J,B,Y;const r="credentials"in Request.prototype,o=lk(t==null?void 0:t.baseURL,t==null?void 0:t.basePath)??hT(t==null?void 0:t.basePath)??"/api/auth",l=((E=t==null?void 0:t.plugins)==null?void 0:E.flatMap($=>$.fetchPlugins).filter($=>$!==void 0))||[],d={id:"lifecycle-hooks",name:"lifecycle-hooks",hooks:{onSuccess:(U=t==null?void 0:t.fetchOptions)==null?void 0:U.onSuccess,onError:(q=t==null?void 0:t.fetchOptions)==null?void 0:q.onError,onRequest:(H=t==null?void 0:t.fetchOptions)==null?void 0:H.onRequest,onResponse:(J=t==null?void 0:t.fetchOptions)==null?void 0:J.onResponse}},{onSuccess:u,onError:m,onRequest:p,onResponse:x,...b}=(t==null?void 0:t.fetchOptions)||{},y=cT({baseURL:o,...r?{credentials:"include"}:{}
633,method:"GET",jsonParser($){return $?fk($,{strict:!1}):null},customFetchImpl:fetch,...b,plugins:[d,...b.plugins||[],...t!=null&&t.disableDefaultFetchPlugins?[]:[bk],...l]}),{$sessionSignal:v,session:w,broadcastSessionUpdate:C}=Uk(y,t),A=(t==null?void 0:t.plugins)||[];let S={};const z={$sessionSignal:v,session:w},T={"/sign-out":"POST","/revoke-sessions":"POST","/revoke-other-sessions":"POST","/delete-user":"POST"},M=[{signal:"$sessionSignal",matcher($){return $==="/sign-out"||$==="/update-user"||$==="/update-session"||$==="/sign-up/email"||$==="/sign-in/email"||$==="/delete-user"||$==="/verify-email"||$==="/revoke-sessions"||$==="/revoke-session"||$==="/revoke-other-sessions"||$==="/change-email"||$==="/change-password"},callback($){$==="/sign-out"?C("signout"):($==="/update-user"||$==="/update-session")&&C("updateUser")}}];for(const $ of A)$.getAtoms&&Object.assign(z,(B=$.getAtoms)==null?void 0:B.call($,y)),$.pathMethods&&Object.assign(T,$.pathMethods),$.atomListeners&&M.push(...$.atomListeners);const P={notify:$=>{z[$].set(!z[$].get())},listen:($,D)=>{z[$].subscribe(D)},atoms:z};for(const $ of A)$.getActions&&(S=Kk(((Y=$.getActions)==null?void 0:Y.call($,y,P,t))??{},S));return{get baseURL(){return o},pluginsActions:S,pluginsAtoms:z,pluginPathMethods:T,atomListeners:M,$fetch:y,$store:P}};function fT(t){return typeof t=="object"&&t!==null&&"get"in t&&typeof t.get=="function"&&"lc"in t&&typeof t.lc=="number"}function xT(t){return t.charAt(0).toUpperCase()+t.slice(1)}const gT=new RegExp("[\\p{Ll}\\d]+|\\p{Lu}+(?!\\p{Ll})|\\p{Lu}[\\p{Ll}\\d]+|\\p{Lo}+","gu"),bT=/['\u2019]/g;function yT(t){return t.replace(bT,"").match(gT)??[]}function vT(t){return yT(t).map(a=>a.toLowerCase()).join("-")}function jT(t,a,r){const o=a[t],{fetchOptions:l,query:d,...u}=r||{};return o||(l!=null&&l.method?l.method:u&&Object.keys(u).length>0?"POST":"GET")}function wT(t,a,r,o,l){function d(u=[]){return new Proxy(function(){},{get(m,p){if(typeof p!="string"||p==="then"||p==="catch"||p==="finally")return;const x=[...u,p];let b=t;for(const y of x)if(b&&typeof b=="object"&&y in b)b=b[y];else{b=void 0;break}return typeof b=="function"||fT(b)?b:d(x)},apply:async(m,p,x)=>{const b="/"+u.map(vT).join("/"),y=x[0]||{},v=x[1]||{},{query:w,fetchOptions:C,...A}=y,S={...v,...C},z=jT(b,r,y);return await a(b,{...S,body:z==="GET"?void 0:{...A,...(S==null?void 0:S.body)||{}},query:w||(S==null?void 0:S.query),method:z,async onSuccess(T){var E,U;if(await((E=S==null?void 0:S.onSuccess)==null?void 0:E.call(S,T)),!l||S.disableSignal)return;const M=l.filter(q=>q.matcher(b));if(!M.length)return;const P=new Set;for(const q of M){const H=o[q.signal];if(!H)return;if(P.has(q.signal))continue;P.add(q.signal);const J=H.get();setTimeout(()=>{H.set(!J)},10),(U=q.callback)==null||U.call(q,b)}}})}})}return d()}function NT(t,a={}){const r=g.useRef(t.get()),{keys:o,deps:l=[t,o]}=a,d=g.useCallback(m=>{const p=x=>{r.current!==x&&(r.current=x,m())};return p(t.value),o!=null&&o.length?Tk(t,o,p):t.listen(p)},l),u=()=>r.current;return g.useSyncExternalStore(d,u,u)}function ST(t){return`use${xT(t)}`}function CT(t){const{pluginPathMethods:a,pluginsActions:r,pluginsAtoms:o,$fetch:l,$store:d,atomListeners:u}=pT(t),m={};for(const[p,x]of Object.entries(o))m[ST(p)]=()=>NT(x);return wT({...r,...m,$fetch:l,$store:d},l,a,o,u)}const nx="better-auth.session-recovery-attempted",kT="/api/auth/get-session?clearCookies=1";function TT(t){try{return t.getItem(nx)==="1"?!1:(t.setItem(nx,"1"),!0)}catch{return!1}}function AT(t){try{t.removeItem(nx)}catch{}}const ug=CT({baseURL:typeof window<"u"?window.location.origin:""}),ET=8e3;function ij(){typeof window>"u"||TT(window.sessionStorage)&&fetch(kT,{cache:"no-store",credentials:"include"}).catch(()=>{}).finally(()=>{console.info(JSON.stringify({event:"auth.session.recovery.reloading"})),window.location.reload()})}function HT(t,a,r){g.useEffect(function(){if(typeof window>"u")return;if(t){ij();return}if(r){AT(window.sessionStorage);return}if(!a)return;const l=setTimeout(ij,ET);return()=>clearTimeout(l)},[t,a,r])}const zT=ug,{signIn:RT,signUp:_T,signOut:LT}=ug;function Us(){const{data:t,isPending:a,error:r}=ug.useSession(),o=!a&&!!(t!=null&&t.user);return HT(r,a,o),{session:t,user:(t==null?void 0:t.user)??null,isPending:a,error:r,isAuthenticated:o}}function DT({size:t}){return e.jsx("svg",{width:t,height:t,viewBox:"0 0 24 24",fill:"
633currentColor","aria-hidden":"true",children:e.jsx("path",{d:"M18.244 2.25h3.308l-7.227 8.26 8.502 11.24H16.17l-4.714-6.231-5.401 6.231H2.746l7.73-8.835L1.254 2.25H8.08l4.253 5.622 5.911-5.622Zm-1.161 17.52h1.833L7.084 4.126H5.117z"})})}function OT({size:t}){return e.jsx("svg",{width:t,height:t,viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":"true",children:e.jsx("path",{d:"M12 2C6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10S17.523 2 12 2zm3.84 10.933-5.372 3.097A1.07 1.07 0 0 1 8.93 15V9a1.07 1.07 0 0 1 1.538-.93l5.372 3.003a1.07 1.07 0 0 1 0 1.86z"})})}function MT(){const{pathname:t}=la();return t.startsWith("/home/wdaa")||t.startsWith("/wdaa")||t.startsWith("/video/wdaa")?{src:"/airo-assets/images/header/banner-wdaa-sponsorship",alt:"2026 WDAA Western Dressage World Championship Show – Sponsorship Opportunities",href:"https://www.wdaaworldshow.org",bannerId:"header-wdaa-sponsorship"}:t.startsWith("/shop")||t.startsWith("/sponsors-partners")||t.startsWith("/advertise")?{src:"/airo-assets/images/header/banner-debbie-brooks",alt:"Debbie Brooks Equestrian Collection – Handbags, Cuffs, Cases",href:"https://totalhorsechannel.com/shop/debbie-brooks-equestrian-collection/",bannerId:"header-debbie-brooks"}:t==="/"?{src:"/airo-assets/images/homepage/leaderboard-thc",alt:"Total Horse Channel – Horse Videos & Live Events",href:"/advertise",bannerId:"header-thc-homepage"}:{src:"/airo-assets/images/header/banner-wdaa-sponsorship",alt:"2026 WDAA Western Dressage World Championship Show – Sponsorship Opportunities",href:"https://www.wdaaworldshow.org",bannerId:"header-wdaa-sponsorship"}}const UT=[{label:"Home",href:"/",dropdown:[{label:"Categories",href:"/breedsdisciplines"},{label:"Games",href:"/games",submenu:[{label:"Horse Eden",href:"/games/horse-eden"},{label:"Horse World Online",href:"/games/horse-world-online"},{label:"Puzzles",href:"/puzzles"}]},{label:"Rumble",href:"/rumble"},{label:"Youtube",href:"/youtube"},{label:"Instagram",href:"/instagram"}]},{label:"Shop",href:"#",dropdown:[{label:"Debbie Brooks Equestrian Collection",href:"/shop/debbie-brooks-equestrian-collection"},{label:"The Horse Capital Tours",href:"/shop/the-horse-capital-tours"}]},{label:"LIVE",href:"/watch-live-events",isLive:!0,dropdown:[{label:"Current Live Events",href:"/watch-live-events"},{label:"Upcoming Live Events",href:"/live/upcoming"},{label:"Live Archives",href:"/live/archives"},{label:"Videos",href:"/videos"}]},{label:"Videos",href:"/videos"},{label:"Low Roller",href:"/home/low-roller/",isLowRoller:!0},{label:"Community",href:"/community",isCommunity:!0},{label:"Contests",href:"/contests"},{label:"News",href:"/news"},{label:"WDAA",href:"/home/wdaa",isHighlight:!0,isWdaa:!0,dropdown:[{label:"Ring 1",href:"/video/wdaa-world-championship-show-live"},{label:"Ring 2",href:"/video/wdaa-world-championship-show-live-ring-2"},{label:"Ring 3",href:"/video/wdaa-world-championship-show-live-ring-3"},{label:"Ring 4",href:"/video/wdaa-world-championship-show-live-ring-4"},{label:"Order Videos",href:"/wdaa-video-orders"},{label:"Past World Shows",href:"/wdaa-replays"},{label:"Sponsorships",href:"/wdaa-sponsorships"}]},{label:"Partners",href:"/sponsors-partners"},{label:"Advertise",href:"/advertise"},{label:"Help",href:"/help",dropdown:[{label:"Our Mission",href:"/mission"},{label:"Membership tiers",href:"/membership"},{label:"Donate",href:"/donations"},{label:"Community Guidelines",href:"/community-guidelines"},{label:"Terms of Service",href:"/terms-of-service"},{label:"Privacy Policy",href:"/privacy-policy"},{label:"Tech Support",href:"/tech-support"}]}];function PT({item:t}){const[a,r]=g.useState(!1),[o,l]=g.useState(null),d=g.useRef(null);function u(){d.current&&clearTimeout(d.current),r(!0)}function m(){d.current=setTimeout(()=>{r(!1),l(null)},80)}return g.useEffect(()=>()=>{d.current&&clearTimeout(d.current)},[]),t.isLive?e.jsxs("div",{className:"relative",onMouseEnter:u,onMouseLeave:m,children:[e.jsxs(O,{to:t.href,className:"flex items-center gap-1 px-3 py-2 text-white text-sm font-semibold rounded bg-primary hover:bg-primary/90 transition-colors",children:[e.jsx(Fn,{size:14}),"LIVE",e.jsx($n,{size:12})]}),a&&t.dropdown&&e.jsx("div",{className:"absolute top-full left-0 z-50 min-w-[220px] py-1 shadow-lg",style:{background:"hsl(var(--thc-navbar))"},onMouseEnter:u,onMouseLeave:m,children:t.dropdown.map(p=>e.jsx(O,{to:p.href,className:"block px-4 py-2 text-sm text-white hover:bg-primary transition-colors",children:p.label},p.href))})]}
633):t.dropdown?e.jsxs("div",{className:"relative",onMouseEnter:u,onMouseLeave:m,children:[e.jsxs(O,{to:t.href,className:`flex items-center gap-1 px-3 py-2 text-sm font-semibold transition-colors whitespace-nowrap${t.isHighlight?" text-white rounded bg-primary hover:bg-primary/90":" text-white hover:text-gray-300"}`,children:[t.label,e.jsx($n,{size:12})]}),a&&e.jsx("div",{className:"absolute top-full left-0 z-50 min-w-[220px] py-1 shadow-lg",style:{background:"hsl(var(--thc-navbar))"},onMouseEnter:u,onMouseLeave:m,children:t.dropdown.map(p=>{const x="submenu"in p&&Array.isArray(p.submenu)&&p.submenu.length>0;return e.jsxs("div",{className:"relative",onMouseEnter:()=>{x&&l(p.href)},onMouseLeave:()=>{x&&l(null)},children:[e.jsxs(O,{to:p.href,className:"flex items-center justify-between px-4 py-2 text-sm text-white hover:bg-primary transition-colors",children:[e.jsx("span",{children:p.label}),x&&e.jsx($n,{size:11,className:"-rotate-90 ml-2 shrink-0"})]}),x&&o===p.href&&e.jsx("div",{className:"absolute left-full top-0 z-50 min-w-[200px] py-1 shadow-lg",style:{background:"hsl(var(--thc-navbar))"},children:p.submenu.map(b=>e.jsx(O,{to:b.href,className:"block px-4 py-2 text-sm text-white hover:bg-primary transition-colors",children:b.label},b.href))})]},p.href)})})]}):t.isLowRoller?e.jsx(O,{to:t.href,className:"px-3 py-2 text-white text-sm font-semibold rounded bg-primary hover:bg-primary/90 transition-colors whitespace-nowrap",children:t.label}):t.isCommunity?e.jsx(O,{to:t.href,className:"px-3 py-2 text-sm font-medium text-gray-900 bg-gray-200 hover:bg-gray-300 rounded transition-colors whitespace-nowrap",children:t.label}):e.jsx(O,{to:t.href,className:"px-3 py-2 text-white text-sm hover:text-gray-300 transition-colors whitespace-nowrap",children:t.label})}function KT(){const[t,a]=g.useState(!1),r=g.useRef(null);function o(){r.current&&clearTimeout(r.current),a(!0)}function l(){r.current=setTimeout(()=>a(!1),80)}return g.useEffect(()=>()=>{r.current&&clearTimeout(r.current)},[]),e.jsxs("div",{className:"relative",onMouseEnter:o,onMouseLeave:l,children:[e.jsxs(O,{to:"/become-member",className:"flex items-center gap-1 px-3 py-2 text-white text-sm hover:text-gray-300 transition-colors whitespace-nowrap",children:["Register",e.jsx($n,{size:12})]}),t&&e.jsxs("div",{className:"absolute top-full right-0 z-50 min-w-[180px] py-1 shadow-lg",style:{background:"hsl(var(--thc-navbar))"},onMouseEnter:o,onMouseLeave:l,children:[e.jsx(O,{to:"/become-member",className:"block px-4 py-2 text-sm text-white hover:bg-primary transition-colors",children:"Create account"}),e.jsx(O,{to:"/membership",className:"block px-4 py-2 text-sm text-white hover:bg-primary transition-colors",children:"Membership tiers"})]})]})}function IT(){const t=MT(),{session:a,isAuthenticated:r}=Us(),o=ga();async function l(){await LT(),o("/")}return e.jsxs("header",{children:[e.jsx("div",{className:"w-full",style:{background:"hsl(var(--thc-topbar))"},children:e.jsxs("div",{className:"max-w-[1280px] mx-auto px-4 flex items-center justify-between h-9",children:[e.jsxs("div",{className:"flex items-center gap-3",children:[e.jsx("a",{href:"https://www.facebook.com/THCNetwork1",target:"_blank",rel:"noopener noreferrer",className:"text-gray-400 hover:text-white transition-colors",children:e.jsx(Vm,{size:16})}),e.jsx("a",{href:"https://x.com/TotalHorseChann",target:"_blank",rel:"noopener noreferrer",className:"text-gray-400 hover:text-white transition-colors",children:e.jsx(DT,{size:16})}),e.jsx("a",{href:"https://www.instagram.com/totalhorsechannel/",target:"_blank",rel:"noopener noreferrer",className:"text-gray-400 hover:text-white transition-colors",children:e.jsx(a2,{size:16})}),e.jsx("a",{href:"https://www.youtube.com/user/Prowinda",target:"_blank",rel:"noopener noreferrer",className:"text-gray-400 hover:text-white transition-colors",children:e.jsx(Fm,{size:16})}),e.jsx("a",{href:"https://rumble.com/c/TotalHorseChannel",target:"_blank",rel:"noopener noreferrer",className:"text-gray-400 hover:text-white transition-colors",children:e.jsx(OT,{size:16})})]}),e.jsx("div",{className:"text-gray-400 text-xs",children:"Total Horse Channel – Discover the Industry"})]})}),e.jsx("div",{className:"w-full border-b border-border",style:{background:"hsl(var(--thc-header-row))"},children:e.jsxs("div",{className:"max-w-[1280px] mx-auto px-4 flex items-center justify-between gap-4 py-2",children:[e.jsx(O,{to:"/",className:"shrink-0",children:e.jsx("img",{src:"/airo-assets/images/logo/horizontal",alt:"Total Horse Channel – Discover the Industry",className:"h-auto w-auto object-contain",style:{maxHeight:"160px",maxWidth:"380px"}})}),e.jsx(ak,{}),e.jsx("div",{className:"shrink-0 hidden md:block",children:e.jsx(Jc,{bannerId:t.bannerId,placement:"header",href:t.href,children:e.jsx("img",{src:t.src,alt:t.alt,width:540,height:192,className:"object-contain",style:{width:"540px",height:"192px"}})})})]})}),e.jsx("nav",{className:"w-full",style:{background:"hsl(var(--thc-navbar))"},"aria-label":"Main navigation",children:e.jsx("div",{className:"max-w-[1280px] mx-auto px-4",children:e.jsxs("div",{className:"flex items-center flex-wrap gap-0",children:[UT.map(d=>e.jsx(PT,{item:d},d.label)),r&&a?e.jsxs(e.Fragment,{children:[e.jsxs(O,{to:`/u/${a.user.username??""}`,className:"flex items-center gap-1 px-3 py-2 text-gray-400 text-sm whitespace-nowrap hover:text-white transition-colors",children:[e.jsx(Ha,{size:13}
vendor: 9,113 bytes, line 633
633),a.user.name||a.user.email]}),e.jsxs("button",{onClick:l,className:"flex items-center gap-1 px-3 py-2 text-white text-sm hover:text-gray-300 transition-colors whitespace-nowrap",children:[e.jsx(HC,{size:13}),"Log Out"]})]}):e.jsxs(e.Fragment,{children:[e.jsx(KT,{}),e.jsx(O,{to:"/login",className:"px-3 py-2 text-white text-sm hover:text-gray-300 transition-colors whitespace-nowrap",children:"Login"})]})]})})})]})}const BT=[],oj={urls:BT};function $T(){return(Array.isArray(oj.urls)?oj.urls:[]).filter(a=>typeof a=="string"&&a.length>0)}function VT(t){const r={"@type":t.businessType??"Organization","@id":`${t.siteUrl}/#organization`,name:t.name,url:`${t.siteUrl}/`};t.logo&&(r.logo=t.logo);const o=$T();return o.length>0&&(r.sameAs=o),r}function FT(t){return{"@context":"https://schema.org",...VT({siteUrl:t.siteUrl,name:t.organizationName})}}const WT=g.createContext(void 0);function qT(){const t=g.useContext(WT);return t||(typeof window<"u"?window.location.origin:"")}const YT={name:""};function GT(){const t=la(),a=qT();if(t.pathname!=="/"||!a)return null;const r=FT({siteUrl:a,organizationName:YT.name.trim()||new globalThis.URL(a).hostname});return e.jsx(we,{children:e.jsx("script",{type:"application/ld+json",children:JSON.stringify(r).replace(/</g,"\\u003c")})})}function f2(t){var a,r,o="";if(typeof t=="string"||typeof t=="number")o+=t;else if(typeof t=="object")if(Array.isArray(t)){var l=t.length;for(a=0;a<l;a++)t[a]&&(r=f2(t[a]))&&(o&&(o+=" "),o+=r)}else for(r in t)t[r]&&(o&&(o+=" "),o+=r);return o}function x2(){for(var t,a,r=0,o="",l=arguments.length;r<l;r++)(t=arguments[r])&&(a=f2(t))&&(o&&(o+=" "),o+=a);return o}const mg="-",ZT=t=>{const a=XT(t),{conflictingClassGroups:r,conflictingClassGroupModifiers:o}=t;return{getClassGroupId:u=>{const m=u.split(mg);return m[0]===""&&m.length!==1&&m.shift(),g2(m,a)||JT(u)},getConflictingClassGroupIds:(u,m)=>{const p=r[u]||[];return m&&o[u]?[...p,...o[u]]:p}}},g2=(t,a)=>{var u;if(t.length===0)return a.classGroupId;const r=t[0],o=a.nextPart.get(r),l=o?g2(t.slice(1),o):void 0;if(l)return l;if(a.validators.length===0)return;const d=t.join(mg);return(u=a.validators.find(({validator:m})=>m(d)))==null?void 0:u.classGroupId},lj=/^\[(.+)\]$/,JT=t=>{if(lj.test(t)){const a=lj.exec(t)[1],r=a==null?void 0:a.substring(0,a.indexOf(":"));if(r)return"arbitrary.."+r}},XT=t=>{const{theme:a,prefix:r}=t,o={nextPart:new Map,validators:[]};return e6(Object.entries(t.classGroups),r).forEach(([d,u])=>{rx(u,o,d,a)}),o},rx=(t,a,r,o)=>{t.forEach(l=>{if(typeof l=="string"){const d=l===""?a:cj(a,l);d.classGroupId=r;return}if(typeof l=="function"){if(QT(l)){rx(l(o),a,r,o);return}a.validators.push({validator:l,classGroupId:r});return}Object.entries(l).forEach(([d,u])=>{rx(u,cj(a,d),r,o)})})},cj=(t,a)=>{let r=t;return a.split(mg).forEach(o=>{r.nextPart.has(o)||r.nextPart.set(o,{nextPart:new Map,validators:[]}),r=r.nextPart.get(o)}),r},QT=t=>t.isThemeGetter,e6=(t,a)=>a?t.map(([r,o])=>{const l=o.map(d=>typeof d=="string"?a+d:typeof d=="object"?Object.fromEntries(Object.entries(d).map(([u,m])=>[a+u,m])):d);return[r,l]}):t,t6=t=>{if(t<1)return{get:()=>{},set:()=>{}};let a=0,r=new Map,o=new Map;const l=(d,u)=>{r.set(d,u),a++,a>t&&(a=0,o=r,r=new Map)};return{get(d){let u=r.get(d);if(u!==void 0)return u;if((u=o.get(d))!==void 0)return l(d,u),u},set(d,u){r.has(d)?r.set(d,u):l(d,u)}}},b2="!",s6=t=>{const{separator:a,experimentalParseClassName:r}=t,o=a.length===1,l=a[0],d=a.length,u=m=>{const p=[];let x=0,b=0,y;for(let S=0;S<m.length;S++){let z=m[S];if(x===0){if(z===l&&(o||m.slice(S,S+d)===a)){p.push(m.slice(b,S)),b=S+d;continue}if(z==="/"){y=S;continue}}z==="["?x++:z==="]"&&x--}const v=p.length===0?m:m.substring(b),w=v.startsWith(b2),C=w?v.substring(1):v,A=y&&y>b?y-b:void 0;return{modifiers:p,hasImportantModifier:w,baseClassName:C,maybePostfixModifierPosition:A}};return r?m=>r({className:m,parseClassName:u}):u},a6=t=>{if(t.length<=1)return t;const a=[];let r=[];return t.forEach(o=>{o[0]==="["?(a.push(...r.sort(),o),r=[]):r.push(o)}),a.push(...r.sort()),a},n6=t=>({cache:t6(t.cacheSize),parseClassName:s6(t),...ZT(t)}),r6=/\s+/,i6=(t,a)=>{const{parseClassName:r,getClassGroupId:o,getConflictingClassGroupIds:l}=a,d=[],u=t.trim().split(r6);let m="";for(let p=u.length-1;p>=0;p-=1){const x=u[p],{modifiers:b,hasImportantModifier:y,baseClassName:v,maybePostfixModifierPosition:w}=r(x);let C=!!w,A=o(C?v.substring(0,w):v);if(!A){if(!C){m=x+(m.length>0?" "+m:m);continue}if(A=o(v),!A){m=x+(m.length>0?" "+m:m);continue}C=!1}const S=a6(b).join(":"),z=y?S+b2:S,T=z+A;if(d.includes(T))continue;d.push(T);const M=l(A,C);for(let P=0;P<M.length;++P){const E=M[P];d.push(z+E)}m=x+(m.length>0?" "+m:m)}return m};function o6(){let t=0,a,r,o="";for(;t<arguments.length;)(a=arguments[t++])&&(r=y2(a))&&(o&&(o+=" "),o+=r);return o}const y2=t=>{if(typeof t=="string")return t;let a,r="";for(let o=0;o<t.length;o++)t[o]&&(a=y2(t[o]))&&(r&&(r+=" "),r+=a);return r};function l6(t,...a){let r,o,l,d=u;function u(p){const x=a.reduce((b,y)=>y(b),t());return r=n6(x),o=r.cache.get,l=r.cache.set,d=m,m(p)}function m(p){const x=o(p);if(x)return x;const b=i6(p,r);return l(p,b),b}return function(){return d(o6.apply(null,arguments))}}const ms=t=>{const a=r=>r[t]||[];return a.isThemeGetter=!0,a},v2=/^\[(?:([a-z-]+):)?(.+)\]$/i,c6=/^\d+\/\d+$/,d6=new Set(["px","full","screen"]),u6=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,m6=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,h6=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,p6=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,f6=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,fr=t=>el(t)||d6.has(t)||c6.test(t),Qr=t=>hl(t,"length",N6),el=t=>!!t&&!Number.isNaN(Number(t)),yf=t=>hl(t,"number",el),uc=t=>!!t&&Number.isInteger(Number(t)),x6=t=>t.endsWith("%")&&el(t.slice(0,-1)),ht=t=>v2.test(t),ei=t=>u6.test(t),g6=new Set(["length","size","percentage"]),b6=t=>hl(t,g6,j2),y6=t=>hl(t,"position",j2),v6=new Set(["image","url"]),j6=t=>hl(t,v6,C6),w6=t=>hl(t,"",S6),mc=()=>!0,hl=(t,a,r)=>{const o=v2.exec(t);return o?o[1]?typeof a=="string"?o[1]===a:a.has(o[1]):r(o[2]):!1},N6=t=>m6.test(t)&&!h6.test(t),j2=()=>!1,S6=t=>p6.test(t),C6=t=>f6.test(t),k6=()=>{const t=ms("colors"),a=ms("spacing"),r=ms("blur"),o=ms("brightness"),l=ms("borderColor"),d=ms("borderRadius"),u=ms("borderSpacing"),m=ms("borderWidth"),p=ms("contrast"),x=ms("grayscale"),b=ms("hueRotate"),y=ms("invert"),v=ms("gap"),w=ms("gradientColorStops"),C=ms("gradientColorStopPositions"),A=ms("inset"),S=ms("margin"),z=ms("opacity"),T=ms("padding"),M=ms("saturate"),P=ms("scale"),E=ms("sepia"),U=ms("skew"),q=ms("space"),H=ms("translate"),J=()=>["auto","contain","none"],B=()=>["auto","hidden","clip","visible","scroll"],Y=()=>["auto",ht,a],$=()=>[ht,a],D=()=>["",fr,Qr],W=()=>["auto",el,ht],I=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],k=()=>["solid","dashed","dotted","double","none"],K=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],L=()=>["start","end","center","between","around","evenly","stretch"],se=()=>["","0",ht],X=()=>["auto","avoid","all","avoid-page","page","left","right","column"],le=()=>[el,ht];return{cacheSize:500,separator:":",theme:{colors:[mc],spacing:[fr,Qr],blur:["none","",ei,ht],brightness:le(),borderColor:[t],borderRadius:["none","","full",ei,ht],borderSpacing:$(),borderWidth:D(),contrast:le(),grayscale:se(),hueRotate:le(),invert:se(),gap:$(),gradientColorStops:[t],gradientColorStopPositions:[x6,Qr],inset:Y(),margin:Y(),opacity:le(),padding:$(),saturate:le(),scale:le(),sepia:se(),skew:le(),space:$(),translate:$()},classGroups:{aspect:[{aspect:["auto","square","video",ht]}],container:["container"],columns:[{columns:[ei]}],"break-after":[{"break-after":X()}],"break-before":[{"break-before":X()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:[...I(),ht]}],overflow:[{overflow:B()}],"overflow-x":[{"overflow-x":B()}],"overflow-y":[{"overflow-y":B()}],overscroll:[{overscroll:J()}],"overscroll-x":[{"overscroll-x":J()}],"overscroll-y":[{"overscroll-y":J()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[A]}],"inset-x":[{"inset-x":[A]}],"inset-y":[{"inset-y":[A]}],start:[{start:[A]}],end:[{end:[A]}],top:[{top:[A]}
vendor: 9,951 bytes, line 633
633],right:[{right:[A]}],bottom:[{bottom:[A]}],left:[{left:[A]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",uc,ht]}],basis:[{basis:Y()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",ht]}],grow:[{grow:se()}],shrink:[{shrink:se()}],order:[{order:["first","last","none",uc,ht]}],"grid-cols":[{"grid-cols":[mc]}],"col-start-end":[{col:["auto",{span:["full",uc,ht]},ht]}],"col-start":[{"col-start":W()}],"col-end":[{"col-end":W()}],"grid-rows":[{"grid-rows":[mc]}],"row-start-end":[{row:["auto",{span:[uc,ht]},ht]}],"row-start":[{"row-start":W()}],"row-end":[{"row-end":W()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",ht]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",ht]}],gap:[{gap:[v]}],"gap-x":[{"gap-x":[v]}],"gap-y":[{"gap-y":[v]}],"justify-content":[{justify:["normal",...L()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...L(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...L(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[T]}],px:[{px:[T]}],py:[{py:[T]}],ps:[{ps:[T]}],pe:[{pe:[T]}],pt:[{pt:[T]}],pr:[{pr:[T]}],pb:[{pb:[T]}],pl:[{pl:[T]}],m:[{m:[S]}],mx:[{mx:[S]}],my:[{my:[S]}],ms:[{ms:[S]}],me:[{me:[S]}],mt:[{mt:[S]}],mr:[{mr:[S]}],mb:[{mb:[S]}],ml:[{ml:[S]}],"space-x":[{"space-x":[q]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[q]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",ht,a]}],"min-w":[{"min-w":[ht,a,"min","max","fit"]}],"max-w":[{"max-w":[ht,a,"none","full","min","max","fit","prose",{screen:[ei]},ei]}],h:[{h:[ht,a,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[ht,a,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[ht,a,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[ht,a,"auto","min","max","fit"]}],"font-size":[{text:["base",ei,Qr]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",yf]}],"font-family":[{font:[mc]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",ht]}],"line-clamp":[{"line-clamp":["none",el,yf]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",fr,ht]}],"list-image":[{"list-image":["none",ht]}],"list-style-type":[{list:["none","disc","decimal",ht]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[t]}],"placeholder-opacity":[{"placeholder-opacity":[z]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[t]}],"text-opacity":[{"text-opacity":[z]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...k(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",fr,Qr]}],"underline-offset":[{"underline-offset":["auto",fr,ht]}],"text-decoration-color":[{decoration:[t]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:$()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",ht]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",ht]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[z]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...I(),y6]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",b6]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},j6]}],"bg-color":[{bg:[t]}],"gradient-from-pos":[{from:[C]}],"gradient-via-pos":[{via:[C]}],"gradient-to-pos":[{to:[C]}],"gradient-from":[{from:[w]}],"gradient-via":[{via:[w]}],"gradient-to":[{to:[w]}],rounded:[{rounded:[d]}],"rounded-s":[{"rounded-s":[d]}],"rounded-e":[{"rounded-e":[d]}],"rounded-t":[{"rounded-t":[d]}],"rounded-r":[{"rounded-r":[d]}],"rounded-b":[{"rounded-b":[d]}],"rounded-l":[{"rounded-l":[d]}],"rounded-ss":[{"rounded-ss":[d]}],"rounded-se":[{"rounded-se":[d]}],"rounded-ee":[{"rounded-ee":[d]}],"rounded-es":[{"rounded-es":[d]}],"rounded-tl":[{"rounded-tl":[d]}],"rounded-tr":[{"rounded-tr":[d]}],"rounded-br":[{"rounded-br":[d]}],"rounded-bl":[{"rounded-bl":[d]}],"border-w":[{border:[m]}],"border-w-x":[{"border-x":[m]}],"border-w-y":[{"border-y":[m]}],"border-w-s":[{"border-s":[m]}],"border-w-e":[{"border-e":[m]}],"border-w-t":[{"border-t":[m]}],"border-w-r":[{"border-r":[m]}],"border-w-b":[{"border-b":[m]}],"border-w-l":[{"border-l":[m]}],"border-opacity":[{"border-opacity":[z]}],"border-style":[{border:[...k(),"hidden"]}],"divide-x":[{"divide-x":[m]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[m]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[z]}],"divide-style":[{divide:k()}],"border-color":[{border:[l]}],"border-color-x":[{"border-x":[l]}],"border-color-y":[{"border-y":[l]}],"border-color-s":[{"border-s":[l]}],"border-color-e":[{"border-e":[l]}],"border-color-t":[{"border-t":[l]}],"border-color-r":[{"border-r":[l]}],"border-color-b":[{"border-b":[l]}],"border-color-l":[{"border-l":[l]}],"divide-color":[{divide:[l]}],"outline-style":[{outline:["",...k()]}],"outline-offset":[{"outline-offset":[fr,ht]}],"outline-w":[{outline:[fr,Qr]}],"outline-color":[{outline:[t]}],"ring-w":[{ring:D()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[t]}],"ring-opacity":[{"ring-opacity":[z]}],"ring-offset-w":[{"ring-offset":[fr,Qr]}],"ring-offset-color":[{"ring-offset":[t]}],shadow:[{shadow:["","inner","none",ei,w6]}],"shadow-color":[{shadow:[mc]}],opacity:[{opacity:[z]}],"mix-blend":[{"mix-blend":[...K(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":K()}],filter:[{filter:["","none"]}],blur:[{blur:[r]}],brightness:[{brightness:[o]}],contrast:[{contrast:[p]}],"drop-shadow":[{"drop-shadow":["","none",ei,ht]}],grayscale:[{grayscale:[x]}],"hue-rotate":[{"hue-rotate":[b]}],invert:[{invert:[y]}],saturate:[{saturate:[M]}],sepia:[{sepia:[E]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[r]}],"backdrop-brightness":[{"backdrop-brightness":[o]}],"backdrop-contrast":[{"backdrop-contrast":[p]}],"backdrop-grayscale":[{"backdrop-grayscale":[x]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[b]}],"backdrop-invert":[{"backdrop-invert":[y]}],"backdrop-opacity":[{"backdrop-opacity":[z]}],"backdrop-saturate":[{"backdrop-saturate":[M]}],"backdrop-sepia":[{"backdrop-sepia":[E]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[u]}],"border-spacing-x":[{"border-spacing-x":[u]}],"border-spacing-y":[{"border-spacing-y":[u]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",ht]}],duration:[{duration:le()}],ease:[{ease:["linear","in","out","in-out",ht]}],delay:[{delay:le()}],animate:[{animate:["none","spin","ping","pulse","bounce",ht]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[P]}],"scale-x":[{"scale-x":[P]}],"scale-y":[{"scale-y":[P]}],rotate:[{rotate:[uc,ht]}],"translate-x":[{"translate-x":[H]}],"translate-y":[{"translate-y":[H]}],"skew-x":[{"skew-x":[U]}],"skew-y":[{"skew-y":[U]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",ht]}],accent:[{accent:["auto",t]}],appearance:[{appearance:["none","auto"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",ht]}],"caret-color":[{caret:[t]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":$()}],"scroll-mx":[{"scroll-mx":$()}],"scroll-my":[{"scroll-my":$()}],"scroll-ms":[{"scroll-ms":$()}],"scroll-me":[{"scroll-me":$()}],"scroll-mt":[{"scroll-mt":$()}],"scroll-mr":[{"scroll-mr":$()}],"scroll-mb":[{"scroll-mb":$()}],"scroll-ml":[{"scroll-ml":$()}],"scroll-p":[{"scroll-p":$()}],"scroll-px":[{"scroll-px":$()}],"scroll-py":[{"scroll-py":$()}],"scroll-ps":[{"scroll-ps":$()}],"scroll-pe":[{"scroll-pe":$()}],"scroll-pt":[{"scroll-pt":$()}],"scroll-pr":[{"scroll-pr":$()}],"scroll-pb":[{"scroll-pb":$()}],"scroll-pl":[{"scroll-pl":$()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}
633],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",ht]}],fill:[{fill:[t,"none"]}],"stroke-w":[{stroke:[fr,Qr,yf]}],stroke:[{stroke:[t,"none"]}],sr:["sr-only","not-sr-only"],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}},T6=l6(k6);function io(...t){return T6(x2(t))}function A6({children:t,config:a={},className:r}){const{layout:o={maxWidth:"full",padding:"md",background:"default",minHeight:!0}}=a,l=()=>{switch(o.background){case"muted":return"bg-muted";case"gradient":return"bg-gradient-to-b from-background to-muted/20";default:return"bg-background"}};return e.jsx("div",{className:io(o.minHeight!==!1&&"min-h-screen",l(),"flex flex-col",r),children:t})}function E6(t){typeof window.gtag=="function"&&window.gtag("event","page_view",{page_path:t,page_title:document.title,page_location:window.location.href})}function H6(){const t=la(),a=g.useRef(!0);return g.useEffect(()=>{if(a.current){a.current=!1;return}const r=setTimeout(()=>E6(t.pathname+t.search),200);return()=>clearTimeout(r)},[t.pathname,t.search]),null}const dj="thc-notice-dismissed-v1";function z6(){const[t,a]=g.useState(()=>{try{return typeof window<"u"&&localStorage.getItem(dj)==="1"}catch{return!1}});if(t)return null;function r(){try{localStorage.setItem(dj,"1")}catch{}a(!0)}return e.jsxs("div",{className:"w-full bg-secondary text-secondary-foreground text-xs sm:text-sm py-1.5 px-4 flex items-center justify-between gap-3",children:[e.jsx("span",{className:"flex-1 text-center leading-snug",children:"We’re moving 16 years of Total Horse Channel archives onto this new site. New videos and lives are going up every day — check back often."}),e.jsx("button",{onClick:r,"aria-label":"Dismiss notice",className:"shrink-0 opacity-70 hover:opacity-100 transition-opacity",children:e.jsx(Vt,{size:14})})]})}function R6({children:t}){return e.jsxs(A6,{children:[e.jsx(H6,{}),e.jsxs(we,{children:[e.jsx("title",{children:"Total Horse Channel – Horse Videos & Live Events"}),e.jsx("meta",{name:"description",content:"Total Horse Channel is an online television network showcasing horses and all things equine. Watch horse care, clinics, live shows, racing, and more."}),e.jsx("link",{rel:"icon",href:"/assets/other/86c25006f86dbf9a389b3df691cad93a.png",sizes:"192x192"})]}),e.jsx(GT,{}),e.jsx(G1,{}),e.jsx(IT,{}),e.jsx(z6,{}),t,e.jsx(KC,{})]})}function _6({className:t}){return e.jsx("div",{className:`inline-block ${t||""}`,children:e.jsxs("svg",{className:"animate-spin h-8 w-8 text-gray-600",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",children:[e.jsx("circle",{className:"opacity-10",cx:"12",cy:"12",r:"10",stroke:"currentColor",strokeWidth:"4"}),e.jsx("path",{className:"opacity-20",fill:"currentColor",d:"m4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"})]})})}var It;(function(t){t.assertEqual=l=>{};function a(l){}t.assertIs=a;function r(l){throw new Error}t.assertNever=r,t.arrayToEnum=l=>{const d={};for(const u of l)d[u]=u;return d},t.getValidEnumValues=l=>{const d=t.objectKeys(l).filter(m=>typeof l[l[m]]!="number"),u={};for(const m of d)u[m]=l[m];return t.objectValues(u)},t.objectValues=l=>t.objectKeys(l).map(function(d){return l[d]}),t.objectKeys=typeof Object.keys=="function"?l=>Object.keys(l):l=>{const d=[];for(const u in l)Object.prototype.hasOwnProperty.call(l,u)&&d.push(u);return d},t.find=(l,d)=>{for(const u of l)if(d(u))return u},t.isInteger=typeof Number.isInteger=="function"?l=>Number.isInteger(l):l=>typeof l=="number"&&Number.isFinite(l)&&Math.floor(l)===l;function o(l,d=" | "){return l.map(u=>typeof u=="string"?`'${u}'`:u).join(d)}t.joinValues=o,t.jsonStringifyReplacer=(l,d)=>typeof d=="bigint"?d.toString():d})(It||(It={}));var uj;(function(t){t.mergeShapes=(a,r)=>({...a,...r})})(uj||(uj={}));const Ke=It.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]),oi=t=>{switch(typeof t){case"undefined":return Ke.undefined;case"string":return Ke.string;case"number":return Number.isNaN(t)?Ke.nan:Ke.number;case"boolean":return Ke.boolean;case"function":return Ke.function;case"bigint":return Ke.bigint;case"symbol":return Ke.symbol;case"object":return Array.isArray(t)?Ke.array:t===null?Ke.null:t.then&&typeof t.then=="function"&&t.catch&&typeof t.catch=="function"?Ke.promise:typeof Map<"u"&&t instanceof Map?Ke.map:typeof Set<"u"&&t instanceof Set?Ke.set:typeof Date<"u"&&t instanceof Date?Ke.date:Ke.object;default:return Ke.unknown}}
vendor: 4,988 bytes, line 633
633,Ce=It.arrayToEnum(["invalid_type","invalid_literal","custom","invalid_union","invalid_union_discriminator","invalid_enum_value","unrecognized_keys","invalid_arguments","invalid_return_type","invalid_date","invalid_string","too_small","too_big","invalid_intersection_types","not_multiple_of","not_finite"]);class Sr extends Error{get errors(){return this.issues}constructor(a){super(),this.issues=[],this.addIssue=o=>{this.issues=[...this.issues,o]},this.addIssues=(o=[])=>{this.issues=[...this.issues,...o]};const r=new.target.prototype;Object.setPrototypeOf?Object.setPrototypeOf(this,r):this.__proto__=r,this.name="ZodError",this.issues=a}format(a){const r=a||function(d){return d.message},o={_errors:[]},l=d=>{for(const u of d.issues)if(u.code==="invalid_union")u.unionErrors.map(l);else if(u.code==="invalid_return_type")l(u.returnTypeError);else if(u.code==="invalid_arguments")l(u.argumentsError);else if(u.path.length===0)o._errors.push(r(u));else{let m=o,p=0;for(;p<u.path.length;){const x=u.path[p];p===u.path.length-1?(m[x]=m[x]||{_errors:[]},m[x]._errors.push(r(u))):m[x]=m[x]||{_errors:[]},m=m[x],p++}}};return l(this),o}static assert(a){if(!(a instanceof Sr))throw new Error(`Not a ZodError: ${a}`)}toString(){return this.message}get message(){return JSON.stringify(this.issues,It.jsonStringifyReplacer,2)}get isEmpty(){return this.issues.length===0}flatten(a=r=>r.message){const r={},o=[];for(const l of this.issues)if(l.path.length>0){const d=l.path[0];r[d]=r[d]||[],r[d].push(a(l))}else o.push(a(l));return{formErrors:o,fieldErrors:r}}get formErrors(){return this.flatten()}}Sr.create=t=>new Sr(t);const ix=(t,a)=>{let r;switch(t.code){case Ce.invalid_type:t.received===Ke.undefined?r="Required":r=`Expected ${t.expected}, received ${t.received}`;break;case Ce.invalid_literal:r=`Invalid literal value, expected ${JSON.stringify(t.expected,It.jsonStringifyReplacer)}`;break;case Ce.unrecognized_keys:r=`Unrecognized key(s) in object: ${It.joinValues(t.keys,", ")}`;break;case Ce.invalid_union:r="Invalid input";break;case Ce.invalid_union_discriminator:r=`Invalid discriminator value. Expected ${It.joinValues(t.options)}`;break;case Ce.invalid_enum_value:r=`Invalid enum value. Expected ${It.joinValues(t.options)}, received '${t.received}'`;break;case Ce.invalid_arguments:r="Invalid function arguments";break;case Ce.invalid_return_type:r="Invalid function return type";break;case Ce.invalid_date:r="Invalid date";break;case Ce.invalid_string:typeof t.validation=="object"?"includes"in t.validation?(r=`Invalid input: must include "${t.validation.includes}"`,typeof t.validation.position=="number"&&(r=`${r} at one or more positions greater than or equal to ${t.validation.position}`)):"startsWith"in t.validation?r=`Invalid input: must start with "${t.validation.startsWith}"`:"endsWith"in t.validation?r=`Invalid input: must end with "${t.validation.endsWith}"`:It.assertNever(t.validation):t.validation!=="regex"?r=`Invalid ${t.validation}`:r="Invalid";break;case Ce.too_small:t.type==="array"?r=`Array must contain ${t.exact?"exactly":t.inclusive?"at least":"more than"} ${t.minimum} element(s)`:t.type==="string"?r=`String must contain ${t.exact?"exactly":t.inclusive?"at least":"over"} ${t.minimum} character(s)`:t.type==="number"?r=`Number must be ${t.exact?"exactly equal to ":t.inclusive?"greater than or equal to ":"greater than "}${t.minimum}`:t.type==="bigint"?r=`Number must be ${t.exact?"exactly equal to ":t.inclusive?"greater than or equal to ":"greater than "}${t.minimum}`:t.type==="date"?r=`Date must be ${t.exact?"exactly equal to ":t.inclusive?"greater than or equal to ":"greater than "}${new Date(Number(t.minimum))}`:r="Invalid input";break;case Ce.too_big:t.type==="array"?r=`Array must contain ${t.exact?"exactly":t.inclusive?"at most":"less than"} ${t.maximum} element(s)`:t.type==="string"?r=`String must contain ${t.exact?"exactly":t.inclusive?"at most":"under"} ${t.maximum} character(s)`:t.type==="number"?r=`Number must be ${t.exact?"exactly":t.inclusive?"less than or equal to":"less than"} ${t.maximum}`:t.type==="bigint"?r=`BigInt must be ${t.exact?"exactly":t.inclusive?"less than or equal to":"less than"} ${t.maximum}`:t.type==="date"?r=`Date must be ${t.exact?"exactly":t.inclusive?"smaller than or equal to":"smaller than"} ${new Date(Number(t.maximum))}`:r="Invalid input";break;case Ce.custom:r="Invalid input";break;case Ce.invalid_intersection_types:r="Intersection results could not be merged";break;case Ce.not_multiple_of:r=`Number must be a multiple of ${t.multipleOf}`;break;case Ce.not_finite:r="Number must be finite";break;default:r=a.defaultError,It.assertNever(t)}return{message:r}};let L6=ix;function D6(){return L6}const O6=t=>{const{data:a,path:r,errorMaps:o,issueData:l}=t,d=[...r,...l.path||[]],u={...l,path:d};if(l.message!==void 0)return{...l,path:d,message:l.message};let m="";const p=o.filter(x=>!!x).slice().reverse();for(const x of p)m=x(u,{data:a,defaultError:m}).message;return{...l,path:d,message:m}}
vendor: 6,925 bytes, line 633
633;function _e(t,a){const r=D6(),o=O6({issueData:a,data:t.data,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,r,r===ix?void 0:ix].filter(l=>!!l)});t.common.issues.push(o)}class Fa{constructor(){this.value="valid"}dirty(){this.value==="valid"&&(this.value="dirty")}abort(){this.value!=="aborted"&&(this.value="aborted")}static mergeArray(a,r){const o=[];for(const l of r){if(l.status==="aborted")return it;l.status==="dirty"&&a.dirty(),o.push(l.value)}return{status:a.value,value:o}}static async mergeObjectAsync(a,r){const o=[];for(const l of r){const d=await l.key,u=await l.value;o.push({key:d,value:u})}return Fa.mergeObjectSync(a,o)}static mergeObjectSync(a,r){const o={};for(const l of r){const{key:d,value:u}=l;if(d.status==="aborted"||u.status==="aborted")return it;d.status==="dirty"&&a.dirty(),u.status==="dirty"&&a.dirty(),d.value!=="__proto__"&&(typeof u.value<"u"||l.alwaysSet)&&(o[d.value]=u.value)}return{status:a.value,value:o}}}const it=Object.freeze({status:"aborted"}),yc=t=>({status:"dirty",value:t}),dn=t=>({status:"valid",value:t}),mj=t=>t.status==="aborted",hj=t=>t.status==="dirty",al=t=>t.status==="valid",$u=t=>typeof Promise<"u"&&t instanceof Promise;var Fe;(function(t){t.errToObj=a=>typeof a=="string"?{message:a}:a||{},t.toString=a=>typeof a=="string"?a:a==null?void 0:a.message})(Fe||(Fe={}));class xi{constructor(a,r,o,l){this._cachedPath=[],this.parent=a,this.data=r,this._path=o,this._key=l}get path(){return this._cachedPath.length||(Array.isArray(this._key)?this._cachedPath.push(...this._path,...this._key):this._cachedPath.push(...this._path,this._key)),this._cachedPath}}const pj=(t,a)=>{if(al(a))return{success:!0,data:a.value};if(!t.common.issues.length)throw new Error("Validation failed but no issues detected.");return{success:!1,get error(){if(this._error)return this._error;const r=new Sr(t.common.issues);return this._error=r,this._error}}};function xt(t){if(!t)return{};const{errorMap:a,invalid_type_error:r,required_error:o,description:l}=t;if(a&&(r||o))throw new Error(`Can't use "invalid_type_error" or "required_error" in conjunction with custom error map.`);return a?{errorMap:a,description:l}:{errorMap:(u,m)=>{const{message:p}=t;return u.code==="invalid_enum_value"?{message:p??m.defaultError}:typeof m.data>"u"?{message:p??o??m.defaultError}:u.code!=="invalid_type"?{message:m.defaultError}:{message:p??r??m.defaultError}},description:l}}class Dt{get description(){return this._def.description}_getType(a){return oi(a.data)}_getOrReturnCtx(a,r){return r||{common:a.parent.common,data:a.data,parsedType:oi(a.data),schemaErrorMap:this._def.errorMap,path:a.path,parent:a.parent}}_processInputParams(a){return{status:new Fa,ctx:{common:a.parent.common,data:a.data,parsedType:oi(a.data),schemaErrorMap:this._def.errorMap,path:a.path,parent:a.parent}}}_parseSync(a){const r=this._parse(a);if($u(r))throw new Error("Synchronous parse encountered promise.");return r}_parseAsync(a){const r=this._parse(a);return Promise.resolve(r)}parse(a,r){const o=this.safeParse(a,r);if(o.success)return o.data;throw o.error}safeParse(a,r){const o={common:{issues:[],async:(r==null?void 0:r.async)??!1,contextualErrorMap:r==null?void 0:r.errorMap},path:(r==null?void 0:r.path)||[],schemaErrorMap:this._def.errorMap,parent:null,data:a,parsedType:oi(a)},l=this._parseSync({data:a,path:o.path,parent:o});return pj(o,l)}"~validate"(a){var o,l;const r={common:{issues:[],async:!!this["~standard"].async},path:[],schemaErrorMap:this._def.errorMap,parent:null,data:a,parsedType:oi(a)};if(!this["~standard"].async)try{const d=this._parseSync({data:a,path:[],parent:r});return al(d)?{value:d.value}:{issues:r.common.issues}}catch(d){(l=(o=d==null?void 0:d.message)==null?void 0:o.toLowerCase())!=null&&l.includes("encountered")&&(this["~standard"].async=!0),r.common={issues:[],async:!0}}return this._parseAsync({data:a,path:[],parent:r}).then(d=>al(d)?{value:d.value}:{issues:r.common.issues})}async parseAsync(a,r){const o=await this.safeParseAsync(a,r);if(o.success)return o.data;throw o.error}async safeParseAsync(a,r){const o={common:{issues:[],contextualErrorMap:r==null?void 0:r.errorMap,async:!0},path:(r==null?void 0:r.path)||[],schemaErrorMap:this._def.errorMap,parent:null,data:a,parsedType:oi(a)},l=this._parse({data:a,path:o.path,parent:o}),d=await($u(l)?l:Promise.resolve(l));return pj(o,d)}refine(a,r){const o=l=>typeof r=="string"||typeof r>"u"?{message:r}:typeof r=="function"?r(l):r;return this._refinement((l,d)=>{const u=a(l),m=()=>d.addIssue({code:Ce.custom,...o(l)});return typeof Promise<"u"&&u instanceof Promise?u.then(p=>p?!0:(m(),!1)):u?!0:(m(),!1)})}refinement(a,r){return this._refinement((o,l)=>a(o)?!0:(l.addIssue(typeof r=="function"?r(o,l):r),!1))}_refinement(a){return new il({schema:this,typeName:ot.ZodEffects,effect:{type:"refinement",refinement:a}})}superRefine(a){return this._refinement(a)}constructor(a){this.spa=this.safeParseAsync,this._def=a,this.parse=this.parse.bind(this),this.safeParse=this.safeParse.bind(this),this.parseAsync=this.parseAsync.bind(this),this.safeParseAsync=this.safeParseAsync.bind(this),this.spa=this.spa.bind(this),this.refine=this.refine.bind(this),this.refinement=this.refinement.bind(this),this.superRefine=this.superRefine.bind(this),this.optional=this.optional.bind(this),this.nullable=this.nullable.bind(this),this.nullish=this.nullish.bind(this),this.array=this.array.bind(this),this.promise=this.promise.bind(this),this.or=this.or.bind(this),this.and=this.and.bind(this),this.transform=this.transform.bind(this),this.brand=this.brand.bind(this),this.default=this.default.bind(this),this.catch=this.catch.bind(this),this.describe=this.describe.bind(this),this.pipe=this.pipe.bind(this),this.readonly=this.readonly.bind(this),this.isNullable=this.isNullable.bind(this),this.isOptional=this.isOptional.bind(this),this["~standard"]={version:1,vendor:"zod",validate:r=>this["~validate"](r)}}optional(){return mi.create(this,this._def)}nullable(){return ol.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return Wn.create(this)}promise(){return qu.create(this,this._def)}or(a){return Fu.create([this,a],this._def)}and(a){return Wu.create(this,a,this._def)}transform(a){return new il({...xt(this._def),schema:this,typeName:ot.ZodEffects,effect:{type:"transform",transform:a}})}default(a){const r=typeof a=="function"?a:()=>a;return new dx({...xt(this._def),innerType:this,defaultValue:r,typeName:ot.ZodDefault})}brand(){return new rA({typeName:ot.ZodBranded,type:this,...xt(this._def)})}catch(a){const r=typeof a=="function"?a:()=>a;return new ux({...xt(this._def),innerType:this,catchValue:r,typeName:ot.ZodCatch})}describe(a){const r=this.constructor;return new r({...this._def,description:a})}pipe(a){return hg.create(this,a)}readonly(){return mx.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}}const M6=/^c[^\s-]{8,}
vendor: 8,951 bytes, line 633
633$/i,U6=/^[0-9a-z]+$/,P6=/^[0-9A-HJKMNP-TV-Z]{26}$/i,K6=/^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12}$/i,I6=/^[a-z0-9_-]{21}$/i,B6=/^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/,$6=/^[-+]?P(?!$)(?:(?:[-+]?\d+Y)|(?:[-+]?\d+[.,]\d+Y$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:(?:[-+]?\d+W)|(?:[-+]?\d+[.,]\d+W$))?(?:(?:[-+]?\d+D)|(?:[-+]?\d+[.,]\d+D$))?(?:T(?=[\d+-])(?:(?:[-+]?\d+H)|(?:[-+]?\d+[.,]\d+H$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:[-+]?\d+(?:[.,]\d+)?S)?)??$/,V6=/^(?!\.)(?!.*\.\.)([A-Z0-9_'+\-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i,F6="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$";let vf;const W6=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,q6=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\/(3[0-2]|[12]?[0-9])$/,Y6=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))$/,G6=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,Z6=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,J6=/^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/,w2="((\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-((0[13578]|1[02])-(0[1-9]|[12]\\d|3[01])|(0[469]|11)-(0[1-9]|[12]\\d|30)|(02)-(0[1-9]|1\\d|2[0-8])))",X6=new RegExp(`^${w2}$`);function N2(t){let a="[0-5]\\d";t.precision?a=`${a}\\.\\d{${t.precision}}`:t.precision==null&&(a=`${a}(\\.\\d+)?`);const r=t.precision?"+":"?";return`([01]\\d|2[0-3]):[0-5]\\d(:${a})${r}`}function Q6(t){return new RegExp(`^${N2(t)}$`)}function eA(t){let a=`${w2}T${N2(t)}`;const r=[];return r.push(t.local?"Z?":"Z"),t.offset&&r.push("([+-]\\d{2}:?\\d{2})"),a=`${a}(${r.join("|")})`,new RegExp(`^${a}$`)}function tA(t,a){return!!((a==="v4"||!a)&&W6.test(t)||(a==="v6"||!a)&&Y6.test(t))}function sA(t,a){if(!B6.test(t))return!1;try{const[r]=t.split(".");if(!r)return!1;const o=r.replace(/-/g,"+").replace(/_/g,"/").padEnd(r.length+(4-r.length%4)%4,"="),l=JSON.parse(atob(o));return!(typeof l!="object"||l===null||"typ"in l&&(l==null?void 0:l.typ)!=="JWT"||!l.alg||a&&l.alg!==a)}catch{return!1}}function aA(t,a){return!!((a==="v4"||!a)&&q6.test(t)||(a==="v6"||!a)&&G6.test(t))}class ui extends Dt{_parse(a){if(this._def.coerce&&(a.data=String(a.data)),this._getType(a)!==Ke.string){const d=this._getOrReturnCtx(a);return _e(d,{code:Ce.invalid_type,expected:Ke.string,received:d.parsedType}),it}const o=new Fa;let l;for(const d of this._def.checks)if(d.kind==="min")a.data.length<d.value&&(l=this._getOrReturnCtx(a,l),_e(l,{code:Ce.too_small,minimum:d.value,type:"string",inclusive:!0,exact:!1,message:d.message}),o.dirty());else if(d.kind==="max")a.data.length>d.value&&(l=this._getOrReturnCtx(a,l),_e(l,{code:Ce.too_big,maximum:d.value,type:"string",inclusive:!0,exact:!1,message:d.message}),o.dirty());else if(d.kind==="length"){const u=a.data.length>d.value,m=a.data.length<d.value;(u||m)&&(l=this._getOrReturnCtx(a,l),u?_e(l,{code:Ce.too_big,maximum:d.value,type:"string",inclusive:!0,exact:!0,message:d.message}):m&&_e(l,{code:Ce.too_small,minimum:d.value,type:"string",inclusive:!0,exact:!0,message:d.message}),o.dirty())}else if(d.kind==="email")V6.test(a.data)||(l=this._getOrReturnCtx(a,l),_e(l,{validation:"email",code:Ce.invalid_string,message:d.message}),o.dirty());else if(d.kind==="emoji")vf||(vf=new RegExp(F6,"u")),vf.test(a.data)||(l=this._getOrReturnCtx(a,l),_e(l,{validation:"emoji",code:Ce.invalid_string,message:d.message}),o.dirty());else if(d.kind==="uuid")K6.test(a.data)||(l=this._getOrReturnCtx(a,l),_e(l,{validation:"uuid",code:Ce.invalid_string,message:d.message}),o.dirty());else if(d.kind==="nanoid")I6.test(a.data)||(l=this._getOrReturnCtx(a,l),_e(l,{validation:"nanoid",code:Ce.invalid_string,message:d.message}),o.dirty());else if(d.kind==="cuid")M6.test(a.data)||(l=this._getOrReturnCtx(a,l),_e(l,{validation:"cuid",code:Ce.invalid_string,message:d.message}),o.dirty());else if(d.kind==="cuid2")U6.test(a.data)||(l=this._getOrReturnCtx(a,l),_e(l,{validation:"cuid2",code:Ce.invalid_string,message:d.message}),o.dirty());else if(d.kind==="ulid")P6.test(a.data)||(l=this._getOrReturnCtx(a,l),_e(l,{validation:"ulid",code:Ce.invalid_string,message:d.message}),o.dirty());else if(d.kind==="url")try{new URL(a.data)}catch{l=this._getOrReturnCtx(a,l),_e(l,{validation:"url",code:Ce.invalid_string,message:d.message}),o.dirty()}else d.kind==="regex"?(d.regex.lastIndex=0,d.regex.test(a.data)||(l=this._getOrReturnCtx(a,l),_e(l,{validation:"regex",code:Ce.invalid_string,message:d.message}),o.dirty())):d.kind==="trim"?a.data=a.data.trim():d.kind==="includes"?a.data.includes(d.value,d.position)||(l=this._getOrReturnCtx(a,l),_e(l,{code:Ce.invalid_string,validation:{includes:d.value,position:d.position},message:d.message}),o.dirty()):d.kind==="toLowerCase"?a.data=a.data.toLowerCase():d.kind==="toUpperCase"?a.data=a.data.toUpperCase():d.kind==="startsWith"?a.data.startsWith(d.value)||(l=this._getOrReturnCtx(a,l),_e(l,{code:Ce.invalid_string,validation:{startsWith:d.value},message:d.message}),o.dirty()):d.kind==="endsWith"?a.data.endsWith(d.value)||(l=this._getOrReturnCtx(a,l),_e(l,{code:Ce.invalid_string,validation:{endsWith:d.value},message:d.message}),o.dirty()):d.kind==="datetime"?eA(d).test(a.data)||(l=this._getOrReturnCtx(a,l),_e(l,{code:Ce.invalid_string,validation:"datetime",message:d.message}),o.dirty()):d.kind==="date"?X6.test(a.data)||(l=this._getOrReturnCtx(a,l),_e(l,{code:Ce.invalid_string,validation:"date",message:d.message}),o.dirty()):d.kind==="time"?Q6(d).test(a.data)||(l=this._getOrReturnCtx(a,l),_e(l,{code:Ce.invalid_string,validation:"time",message:d.message}),o.dirty()):d.kind==="duration"?$6.test(a.data)||(l=this._getOrReturnCtx(a,l),_e(l,{validation:"duration",code:Ce.invalid_string,message:d.message}),o.dirty()):d.kind==="ip"?tA(a.data,d.version)||(l=this._getOrReturnCtx(a,l),_e(l,{validation:"ip",code:Ce.invalid_string,message:d.message}),o.dirty()):d.kind==="jwt"?sA(a.data,d.alg)||(l=this._getOrReturnCtx(a,l),_e(l,{validation:"jwt",code:Ce.invalid_string,message:d.message}),o.dirty()):d.kind==="cidr"?aA(a.data,d.version)||(l=this._getOrReturnCtx(a,l),_e(l,{validation:"cidr",code:Ce.invalid_string,message:d.message}),o.dirty()):d.kind==="base64"?Z6.test(a.data)||(l=this._getOrReturnCtx(a,l),_e(l,{validation:"base64",code:Ce.invalid_string,message:d.message}),o.dirty()):d.kind==="base64url"?J6.test(a.data)||(l=this._getOrReturnCtx(a,l),_e(l,{validation:"base64url",code:Ce.invalid_string,message:d.message}),o.dirty()):It.assertNever(d);return{status:o.value,value:a.data}}_regex(a,r,o){return this.refinement(l=>a.test(l),{validation:r,code:Ce.invalid_string,...Fe.errToObj(o)})}_addCheck(a){return new ui({...this._def,checks:[...this._def.checks,a]})}email(a){return this._addCheck({kind:"email",...Fe.errToObj(a)})}url(a){return this._addCheck({kind:"url",...Fe.errToObj(a)})}emoji(a){return this._addCheck({kind:"emoji",...Fe.errToObj(a)})}uuid(a){return this._addCheck({kind:"uuid",...Fe.errToObj(a)})}nanoid(a){return this._addCheck({kind:"nanoid",...Fe.errToObj(a)})}cuid(a){return this._addCheck({kind:"cuid",...Fe.errToObj(a)})}cuid2(a){return this._addCheck({kind:"cuid2",...Fe.errToObj(a)})}ulid(a){return this._addCheck({kind:"ulid",...Fe.errToObj(a)})}base64(a){return this._addCheck({kind:"base64",...Fe.errToObj(a)})}base64url(a){return this._addCheck({kind:"base64url",...Fe.errToObj(a)})}jwt(a){return this._addCheck({kind:"jwt",...Fe.errToObj(a)})}ip(a){return this._addCheck({kind:"ip",...Fe.errToObj(a)})}cidr(a){return this._addCheck({kind:"cidr",...Fe.errToObj(a)})}
vendor: 14,060 bytes, line 633
633datetime(a){return typeof a=="string"?this._addCheck({kind:"datetime",precision:null,offset:!1,local:!1,message:a}):this._addCheck({kind:"datetime",precision:typeof(a==null?void 0:a.precision)>"u"?null:a==null?void 0:a.precision,offset:(a==null?void 0:a.offset)??!1,local:(a==null?void 0:a.local)??!1,...Fe.errToObj(a==null?void 0:a.message)})}date(a){return this._addCheck({kind:"date",message:a})}time(a){return typeof a=="string"?this._addCheck({kind:"time",precision:null,message:a}):this._addCheck({kind:"time",precision:typeof(a==null?void 0:a.precision)>"u"?null:a==null?void 0:a.precision,...Fe.errToObj(a==null?void 0:a.message)})}duration(a){return this._addCheck({kind:"duration",...Fe.errToObj(a)})}regex(a,r){return this._addCheck({kind:"regex",regex:a,...Fe.errToObj(r)})}includes(a,r){return this._addCheck({kind:"includes",value:a,position:r==null?void 0:r.position,...Fe.errToObj(r==null?void 0:r.message)})}startsWith(a,r){return this._addCheck({kind:"startsWith",value:a,...Fe.errToObj(r)})}endsWith(a,r){return this._addCheck({kind:"endsWith",value:a,...Fe.errToObj(r)})}min(a,r){return this._addCheck({kind:"min",value:a,...Fe.errToObj(r)})}max(a,r){return this._addCheck({kind:"max",value:a,...Fe.errToObj(r)})}length(a,r){return this._addCheck({kind:"length",value:a,...Fe.errToObj(r)})}nonempty(a){return this.min(1,Fe.errToObj(a))}trim(){return new ui({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}toLowerCase(){return new ui({...this._def,checks:[...this._def.checks,{kind:"toLowerCase"}]})}toUpperCase(){return new ui({...this._def,checks:[...this._def.checks,{kind:"toUpperCase"}]})}get isDatetime(){return!!this._def.checks.find(a=>a.kind==="datetime")}get isDate(){return!!this._def.checks.find(a=>a.kind==="date")}get isTime(){return!!this._def.checks.find(a=>a.kind==="time")}get isDuration(){return!!this._def.checks.find(a=>a.kind==="duration")}get isEmail(){return!!this._def.checks.find(a=>a.kind==="email")}get isURL(){return!!this._def.checks.find(a=>a.kind==="url")}get isEmoji(){return!!this._def.checks.find(a=>a.kind==="emoji")}get isUUID(){return!!this._def.checks.find(a=>a.kind==="uuid")}get isNANOID(){return!!this._def.checks.find(a=>a.kind==="nanoid")}get isCUID(){return!!this._def.checks.find(a=>a.kind==="cuid")}get isCUID2(){return!!this._def.checks.find(a=>a.kind==="cuid2")}get isULID(){return!!this._def.checks.find(a=>a.kind==="ulid")}get isIP(){return!!this._def.checks.find(a=>a.kind==="ip")}get isCIDR(){return!!this._def.checks.find(a=>a.kind==="cidr")}get isBase64(){return!!this._def.checks.find(a=>a.kind==="base64")}get isBase64url(){return!!this._def.checks.find(a=>a.kind==="base64url")}get minLength(){let a=null;for(const r of this._def.checks)r.kind==="min"&&(a===null||r.value>a)&&(a=r.value);return a}get maxLength(){let a=null;for(const r of this._def.checks)r.kind==="max"&&(a===null||r.value<a)&&(a=r.value);return a}}ui.create=t=>new ui({checks:[],typeName:ot.ZodString,coerce:(t==null?void 0:t.coerce)??!1,...xt(t)});function nA(t,a){const r=(t.toString().split(".")[1]||"").length,o=(a.toString().split(".")[1]||"").length,l=r>o?r:o,d=Number.parseInt(t.toFixed(l).replace(".","")),u=Number.parseInt(a.toFixed(l).replace(".",""));return d%u/10**l}class nl extends Dt{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse(a){if(this._def.coerce&&(a.data=Number(a.data)),this._getType(a)!==Ke.number){const d=this._getOrReturnCtx(a);return _e(d,{code:Ce.invalid_type,expected:Ke.number,received:d.parsedType}),it}let o;const l=new Fa;for(const d of this._def.checks)d.kind==="int"?It.isInteger(a.data)||(o=this._getOrReturnCtx(a,o),_e(o,{code:Ce.invalid_type,expected:"integer",received:"float",message:d.message}),l.dirty()):d.kind==="min"?(d.inclusive?a.data<d.value:a.data<=d.value)&&(o=this._getOrReturnCtx(a,o),_e(o,{code:Ce.too_small,minimum:d.value,type:"number",inclusive:d.inclusive,exact:!1,message:d.message}),l.dirty()):d.kind==="max"?(d.inclusive?a.data>d.value:a.data>=d.value)&&(o=this._getOrReturnCtx(a,o),_e(o,{code:Ce.too_big,maximum:d.value,type:"number",inclusive:d.inclusive,exact:!1,message:d.message}),l.dirty()):d.kind==="multipleOf"?nA(a.data,d.value)!==0&&(o=this._getOrReturnCtx(a,o),_e(o,{code:Ce.not_multiple_of,multipleOf:d.value,message:d.message}),l.dirty()):d.kind==="finite"?Number.isFinite(a.data)||(o=this._getOrReturnCtx(a,o),_e(o,{code:Ce.not_finite,message:d.message}),l.dirty()):It.assertNever(d);return{status:l.value,value:a.data}}gte(a,r){return this.setLimit("min",a,!0,Fe.toString(r))}gt(a,r){return this.setLimit("min",a,!1,Fe.toString(r))}lte(a,r){return this.setLimit("max",a,!0,Fe.toString(r))}lt(a,r){return this.setLimit("max",a,!1,Fe.toString(r))}setLimit(a,r,o,l){return new nl({...this._def,checks:[...this._def.checks,{kind:a,value:r,inclusive:o,message:Fe.toString(l)}]})}_addCheck(a){return new nl({...this._def,checks:[...this._def.checks,a]})}int(a){return this._addCheck({kind:"int",message:Fe.toString(a)})}positive(a){return this._addCheck({kind:"min",value:0,inclusive:!1,message:Fe.toString(a)})}negative(a){return this._addCheck({kind:"max",value:0,inclusive:!1,message:Fe.toString(a)})}nonpositive(a){return this._addCheck({kind:"max",value:0,inclusive:!0,message:Fe.toString(a)})}nonnegative(a){return this._addCheck({kind:"min",value:0,inclusive:!0,message:Fe.toString(a)})}multipleOf(a,r){return this._addCheck({kind:"multipleOf",value:a,message:Fe.toString(r)})}finite(a){return this._addCheck({kind:"finite",message:Fe.toString(a)})}safe(a){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:Fe.toString(a)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:Fe.toString(a)})}get minValue(){let a=null;for(const r of this._def.checks)r.kind==="min"&&(a===null||r.value>a)&&(a=r.value);return a}get maxValue(){let a=null;for(const r of this._def.checks)r.kind==="max"&&(a===null||r.value<a)&&(a=r.value);return a}get isInt(){return!!this._def.checks.find(a=>a.kind==="int"||a.kind==="multipleOf"&&It.isInteger(a.value))}get isFinite(){let a=null,r=null;for(const o of this._def.checks){if(o.kind==="finite"||o.kind==="int"||o.kind==="multipleOf")return!0;o.kind==="min"?(r===null||o.value>r)&&(r=o.value):o.kind==="max"&&(a===null||o.value<a)&&(a=o.value)}return Number.isFinite(r)&&Number.isFinite(a)}}nl.create=t=>new nl({checks:[],typeName:ot.ZodNumber,coerce:(t==null?void 0:t.coerce)||!1,...xt(t)});class Oc extends Dt{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte}_parse(a){if(this._def.coerce)try{a.data=BigInt(a.data)}catch{return this._getInvalidInput(a)}if(this._getType(a)!==Ke.bigint)return this._getInvalidInput(a);let o;const l=new Fa;for(const d of this._def.checks)d.kind==="min"?(d.inclusive?a.data<d.value:a.data<=d.value)&&(o=this._getOrReturnCtx(a,o),_e(o,{code:Ce.too_small,type:"bigint",minimum:d.value,inclusive:d.inclusive,message:d.message}),l.dirty()):d.kind==="max"?(d.inclusive?a.data>d.value:a.data>=d.value)&&(o=this._getOrReturnCtx(a,o),_e(o,{code:Ce.too_big,type:"bigint",maximum:d.value,inclusive:d.inclusive,message:d.message}),l.dirty()):d.kind==="multipleOf"?a.data%d.value!==BigInt(0)&&(o=this._getOrReturnCtx(a,o),_e(o,{code:Ce.not_multiple_of,multipleOf:d.value,message:d.message}),l.dirty()):It.assertNever(d);return{status:l.value,value:a.data}}_getInvalidInput(a){const r=this._getOrReturnCtx(a);return _e(r,{code:Ce.invalid_type,expected:Ke.bigint,received:r.parsedType}),it}gte(a,r){return this.setLimit("min",a,!0,Fe.toString(r))}gt(a,r){return this.setLimit("min",a,!1,Fe.toString(r))}lte(a,r){return this.setLimit("max",a,!0,Fe.toString(r))}lt(a,r){return this.setLimit("max",a,!1,Fe.toString(r))}setLimit(a,r,o,l){return new Oc({...this._def,checks:[...this._def.checks,{kind:a,value:r,inclusive:o,message:Fe.toString(l)}]})}_addCheck(a){return new Oc({...this._def,checks:[...this._def.checks,a]})}positive(a){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:Fe.toString(a)})}negative(a){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:Fe.toString(a)})}nonpositive(a){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:Fe.toString(a)})}nonnegative(a){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:Fe.toString(a)})}multipleOf(a,r){return this._addCheck({kind:"multipleOf",value:a,message:Fe.toString(r)})}get minValue(){let a=null;for(const r of this._def.checks)r.kind==="min"&&(a===null||r.value>a)&&(a=r.value);return a}get maxValue(){let a=null;for(const r of this._def.checks)r.kind==="max"&&(a===null||r.value<a)&&(a=r.value);return a}}Oc.create=t=>new Oc({checks:[],typeName:ot.ZodBigInt,coerce:(t==null?void 0:t.coerce)??!1,...xt(t)});class ox extends Dt{_parse(a){if(this._def.coerce&&(a.data=!!a.data),this._getType(a)!==Ke.boolean){const o=this._getOrReturnCtx(a);return _e(o,{code:Ce.invalid_type,expected:Ke.boolean,received:o.parsedType}),it}return dn(a.data)}}ox.create=t=>new ox({typeName:ot.ZodBoolean,coerce:(t==null?void 0:t.coerce)||!1,...xt(t)});class Vu extends Dt{_parse(a){if(this._def.coerce&&(a.data=new Date(a.data)),this._getType(a)!==Ke.date){const d=this._getOrReturnCtx(a);return _e(d,{code:Ce.invalid_type,expected:Ke.date,received:d.parsedType}),it}if(Number.isNaN(a.data.getTime())){const d=this._getOrReturnCtx(a);return _e(d,{code:Ce.invalid_date}),it}const o=new Fa;let l;for(const d of this._def.checks)d.kind==="min"?a.data.getTime()<d.value&&(l=this._getOrReturnCtx(a,l),_e(l,{code:Ce.too_small,message:d.message,inclusive:!0,exact:!1,minimum:d.value,type:"date"}),o.dirty()):d.kind==="max"?a.data.getTime()>d.value&&(l=this._getOrReturnCtx(a,l),_e(l,{code:Ce.too_big,message:d.message,inclusive:!0,exact:!1,maximum:d.value,type:"date"}),o.dirty()):It.assertNever(d);return{status:o.value,value:new Date(a.data.getTime())}}_addCheck(a){return new Vu({...this._def,checks:[...this._def.checks,a]})}min(a,r){return this._addCheck({kind:"min",value:a.getTime(),message:Fe.toString(r)})}max(a,r){return this._addCheck({kind:"max",value:a.getTime(),message:Fe.toString(r)})}get minDate(){let a=null;for(const r of this._def.checks)r.kind==="min"&&(a===null||r.value>a)&&(a=r.value);return a!=null?new Date(a):null}get maxDate(){let a=null;for(const r of this._def.checks)r.kind==="max"&&(a===null||r.value<a)&&(a=r.value);return a!=null?new Date(a):null}}Vu.create=t=>new Vu({checks:[],coerce:(t==null?void 0:t.coerce)||!1,typeName:ot.ZodDate,...xt(t)});class fj extends Dt{_parse(a){if(this._getType(a)!==Ke.symbol){const o=this._getOrReturnCtx(a);return _e(o,{code:Ce.invalid_type,expected:Ke.symbol,received:o.parsedType}),it}return dn(a.data)}}fj.create=t=>new fj({typeName:ot.ZodSymbol,...xt(t)});class xj extends Dt{_parse(a){if(this._getType(a)!==Ke.undefined){const o=this._getOrReturnCtx(a);return _e(o,{code:Ce.invalid_type,expected:Ke.undefined,received:o.parsedType}),it}return dn(a.data)}}xj.create=t=>new xj({typeName:ot.ZodUndefined,...xt(t)});class gj extends Dt{_parse(a){if(this._getType(a)!==Ke.null){const o=this._getOrReturnCtx(a);return _e(o,{code:Ce.invalid_type,expected:Ke.null,received:o.parsedType}),it}return dn(a.data)}}gj.create=t=>new gj({typeName:ot.ZodNull,...xt(t)});class bj extends Dt{constructor(){super(...arguments),this._any=!0}_parse(a){return dn(a.data)}}bj.create=t=>new bj({typeName:ot.ZodAny,...xt(t)});class lx extends Dt{constructor(){super(...arguments),this._unknown=!0}_parse(a){return dn(a.data)}}lx.create=t=>new lx({typeName:ot.ZodUnknown,...xt(t)});class gi extends Dt{_parse(a){const r=this._getOrReturnCtx(a);return _e(r,{code:Ce.invalid_type,expected:Ke.never,received:r.parsedType}),it}}gi.create=t=>new gi({typeName:ot.ZodNever,...xt(t)});class yj extends Dt{_parse(a){if(this._getType(a)!==Ke.undefined){const o=this._getOrReturnCtx(a);return _e(o,{code:Ce.invalid_type,expected:Ke.void,received:o.parsedType}),it}return dn(a.data)}}yj.create=t=>new yj({typeName:ot.ZodVoid,...xt(t)});class Wn extends Dt{_parse(a){const{ctx:r,status:o}=this._processInputParams(a),l=this._def;if(r.parsedType!==Ke.array)return _e(r,{code:Ce.invalid_type,expected:Ke.array,received:r.parsedType}),it;if(l.exactLength!==null){const u=r.data.length>l.exactLength.value,m=r.data.length<l.exactLength.value;(u||m)&&(_e(r,{code:u?Ce.too_big:Ce.too_small,minimum:m?l.exactLength.value:void 0,maximum:u?l.exactLength.value:void 0,type:"array",inclusive:!0,exact:!0,message:l.exactLength.message}),o.dirty())}if(l.minLength!==null&&r.data.length<l.minLength.value&&(_e(r,{code:Ce.too_small,minimum:l.minLength.value,type:"array",inclusive:!0,exact:!1,message:l.minLength.message}),o.dirty()),l.maxLength!==null&&r.data.length>l.maxLength.value&&(_e(r,{code:Ce.too_big,maximum:l.maxLength.value,type:"array",inclusive:!0,exact:!1,message:l.maxLength.message}),o.dirty()),r.common.async)return Promise.all([...r.data].map((u,m)=>l.type._parseAsync(new xi(r,u,r.path,m)))).then(u=>Fa.mergeArray(o,u));const d=[...r.data].map((u,m)=>l.type._parseSync(new xi(r,u,r.path,m)));return Fa.mergeArray(o,d)}get element(){return this._def.type}min(a,r){return new Wn({...this._def,minLength:{value:a,message:Fe.toString(r)}})}max(a,r){return new Wn({...this._def,maxLength:{value:a,message:Fe.toString(r)}})}length(a,r){return new Wn({...this._def,exactLength:{value:a,message:Fe.toString(r)}})}nonempty(a){return this.min(1,a)}}Wn.create=(t,a)=>new Wn({type:t,minLength:null,maxLength:null,exactLength:null,typeName:ot.ZodArray,...xt(a)});function Go(t){if(t instanceof Os){const a={};for(const r in t.shape){const o=t.shape[r];a[r]=mi.create(Go(o))}return new Os({...t._def,shape:()=>a})}else return t instanceof Wn?new Wn({...t._def,type:Go(t.element)}):t instanceof mi?mi.create(Go(t.unwrap())):t instanceof ol?ol.create(Go(t.unwrap())):t instanceof ao?ao.create(t.items.map(a=>Go(a))):t}class Os extends Dt{constructor(){super(...arguments),this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(this._cached!==null)return this._cached;
vendor: 4,819 bytes, line 633
633const a=this._def.shape(),r=It.objectKeys(a);return this._cached={shape:a,keys:r},this._cached}_parse(a){if(this._getType(a)!==Ke.object){const x=this._getOrReturnCtx(a);return _e(x,{code:Ce.invalid_type,expected:Ke.object,received:x.parsedType}),it}const{status:o,ctx:l}=this._processInputParams(a),{shape:d,keys:u}=this._getCached(),m=[];if(!(this._def.catchall instanceof gi&&this._def.unknownKeys==="strip"))for(const x in l.data)u.includes(x)||m.push(x);const p=[];for(const x of u){const b=d[x],y=l.data[x];p.push({key:{status:"valid",value:x},value:b._parse(new xi(l,y,l.path,x)),alwaysSet:x in l.data})}if(this._def.catchall instanceof gi){const x=this._def.unknownKeys;if(x==="passthrough")for(const b of m)p.push({key:{status:"valid",value:b},value:{status:"valid",value:l.data[b]}});else if(x==="strict")m.length>0&&(_e(l,{code:Ce.unrecognized_keys,keys:m}),o.dirty());else if(x!=="strip")throw new Error("Internal ZodObject error: invalid unknownKeys value.")}else{const x=this._def.catchall;for(const b of m){const y=l.data[b];p.push({key:{status:"valid",value:b},value:x._parse(new xi(l,y,l.path,b)),alwaysSet:b in l.data})}}return l.common.async?Promise.resolve().then(async()=>{const x=[];for(const b of p){const y=await b.key,v=await b.value;x.push({key:y,value:v,alwaysSet:b.alwaysSet})}return x}).then(x=>Fa.mergeObjectSync(o,x)):Fa.mergeObjectSync(o,p)}get shape(){return this._def.shape()}strict(a){return Fe.errToObj,new Os({...this._def,unknownKeys:"strict",...a!==void 0?{errorMap:(r,o)=>{var d,u;const l=((u=(d=this._def).errorMap)==null?void 0:u.call(d,r,o).message)??o.defaultError;return r.code==="unrecognized_keys"?{message:Fe.errToObj(a).message??l}:{message:l}}}:{}})}strip(){return new Os({...this._def,unknownKeys:"strip"})}passthrough(){return new Os({...this._def,unknownKeys:"passthrough"})}extend(a){return new Os({...this._def,shape:()=>({...this._def.shape(),...a})})}merge(a){return new Os({unknownKeys:a._def.unknownKeys,catchall:a._def.catchall,shape:()=>({...this._def.shape(),...a._def.shape()}),typeName:ot.ZodObject})}setKey(a,r){return this.augment({[a]:r})}catchall(a){return new Os({...this._def,catchall:a})}pick(a){const r={};for(const o of It.objectKeys(a))a[o]&&this.shape[o]&&(r[o]=this.shape[o]);return new Os({...this._def,shape:()=>r})}omit(a){const r={};for(const o of It.objectKeys(this.shape))a[o]||(r[o]=this.shape[o]);return new Os({...this._def,shape:()=>r})}deepPartial(){return Go(this)}partial(a){const r={};for(const o of It.objectKeys(this.shape)){const l=this.shape[o];a&&!a[o]?r[o]=l:r[o]=l.optional()}return new Os({...this._def,shape:()=>r})}required(a){const r={};for(const o of It.objectKeys(this.shape))if(a&&!a[o])r[o]=this.shape[o];else{let d=this.shape[o];for(;d instanceof mi;)d=d._def.innerType;r[o]=d}return new Os({...this._def,shape:()=>r})}keyof(){return S2(It.objectKeys(this.shape))}}Os.create=(t,a)=>new Os({shape:()=>t,unknownKeys:"strip",catchall:gi.create(),typeName:ot.ZodObject,...xt(a)});Os.strictCreate=(t,a)=>new Os({shape:()=>t,unknownKeys:"strict",catchall:gi.create(),typeName:ot.ZodObject,...xt(a)});Os.lazycreate=(t,a)=>new Os({shape:t,unknownKeys:"strip",catchall:gi.create(),typeName:ot.ZodObject,...xt(a)});class Fu extends Dt{_parse(a){const{ctx:r}=this._processInputParams(a),o=this._def.options;function l(d){for(const m of d)if(m.result.status==="valid")return m.result;for(const m of d)if(m.result.status==="dirty")return r.common.issues.push(...m.ctx.common.issues),m.result;const u=d.map(m=>new Sr(m.ctx.common.issues));return _e(r,{code:Ce.invalid_union,unionErrors:u}),it}if(r.common.async)return Promise.all(o.map(async d=>{const u={...r,common:{...r.common,issues:[]},parent:null};return{result:await d._parseAsync({data:r.data,path:r.path,parent:u}),ctx:u}})).then(l);{let d;const u=[];for(const p of o){const x={...r,common:{...r.common,issues:[]},parent:null},b=p._parseSync({data:r.data,path:r.path,parent:x});if(b.status==="valid")return b;b.status==="dirty"&&!d&&(d={result:b,ctx:x}),x.common.issues.length&&u.push(x.common.issues)}if(d)return r.common.issues.push(...d.ctx.common.issues),d.result;const m=u.map(p=>new Sr(p));return _e(r,{code:Ce.invalid_union,unionErrors:m}),it}}get options(){return this._def.options}}Fu.create=(t,a)=>new Fu({options:t,typeName:ot.ZodUnion,...xt(a)});function cx(t,a){const r=oi(t),o=oi(a);if(t===a)return{valid:!0,data:t};if(r===Ke.object&&o===Ke.object){const l=It.objectKeys(a),d=It.objectKeys(t).filter(m=>l.indexOf(m)!==-1),u={...t,...a};for(const m of d){const p=cx(t[m],a[m]);if(!p.valid)return{valid:!1};u[m]=p.data}return{valid:!0,data:u}}else if(r===Ke.array&&o===Ke.array){if(t.length!==a.length)return{valid:!1};const l=[];for(let d=0;d<t.length;d++){const u=t[d],m=a[d],p=cx(u,m);if(!p.valid)return{valid:!1};l.push(p.data)}return{valid:!0,data:l}}
vendor: 4,344 bytes, line 633
633else return r===Ke.date&&o===Ke.date&&+t==+a?{valid:!0,data:t}:{valid:!1}}class Wu extends Dt{_parse(a){const{status:r,ctx:o}=this._processInputParams(a),l=(d,u)=>{if(mj(d)||mj(u))return it;const m=cx(d.value,u.value);return m.valid?((hj(d)||hj(u))&&r.dirty(),{status:r.value,value:m.data}):(_e(o,{code:Ce.invalid_intersection_types}),it)};return o.common.async?Promise.all([this._def.left._parseAsync({data:o.data,path:o.path,parent:o}),this._def.right._parseAsync({data:o.data,path:o.path,parent:o})]).then(([d,u])=>l(d,u)):l(this._def.left._parseSync({data:o.data,path:o.path,parent:o}),this._def.right._parseSync({data:o.data,path:o.path,parent:o}))}}Wu.create=(t,a,r)=>new Wu({left:t,right:a,typeName:ot.ZodIntersection,...xt(r)});class ao extends Dt{_parse(a){const{status:r,ctx:o}=this._processInputParams(a);if(o.parsedType!==Ke.array)return _e(o,{code:Ce.invalid_type,expected:Ke.array,received:o.parsedType}),it;if(o.data.length<this._def.items.length)return _e(o,{code:Ce.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),it;!this._def.rest&&o.data.length>this._def.items.length&&(_e(o,{code:Ce.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),r.dirty());const d=[...o.data].map((u,m)=>{const p=this._def.items[m]||this._def.rest;return p?p._parse(new xi(o,u,o.path,m)):null}).filter(u=>!!u);return o.common.async?Promise.all(d).then(u=>Fa.mergeArray(r,u)):Fa.mergeArray(r,d)}get items(){return this._def.items}rest(a){return new ao({...this._def,rest:a})}}ao.create=(t,a)=>{if(!Array.isArray(t))throw new Error("You must pass an array of schemas to z.tuple([ ... ])");return new ao({items:t,typeName:ot.ZodTuple,rest:null,...xt(a)})};class vj extends Dt{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(a){const{status:r,ctx:o}=this._processInputParams(a);if(o.parsedType!==Ke.map)return _e(o,{code:Ce.invalid_type,expected:Ke.map,received:o.parsedType}),it;const l=this._def.keyType,d=this._def.valueType,u=[...o.data.entries()].map(([m,p],x)=>({key:l._parse(new xi(o,m,o.path,[x,"key"])),value:d._parse(new xi(o,p,o.path,[x,"value"]))}));if(o.common.async){const m=new Map;return Promise.resolve().then(async()=>{for(const p of u){const x=await p.key,b=await p.value;if(x.status==="aborted"||b.status==="aborted")return it;(x.status==="dirty"||b.status==="dirty")&&r.dirty(),m.set(x.value,b.value)}return{status:r.value,value:m}})}else{const m=new Map;for(const p of u){const x=p.key,b=p.value;if(x.status==="aborted"||b.status==="aborted")return it;(x.status==="dirty"||b.status==="dirty")&&r.dirty(),m.set(x.value,b.value)}return{status:r.value,value:m}}}}vj.create=(t,a,r)=>new vj({valueType:a,keyType:t,typeName:ot.ZodMap,...xt(r)});class Mc extends Dt{_parse(a){const{status:r,ctx:o}=this._processInputParams(a);if(o.parsedType!==Ke.set)return _e(o,{code:Ce.invalid_type,expected:Ke.set,received:o.parsedType}),it;const l=this._def;l.minSize!==null&&o.data.size<l.minSize.value&&(_e(o,{code:Ce.too_small,minimum:l.minSize.value,type:"set",inclusive:!0,exact:!1,message:l.minSize.message}),r.dirty()),l.maxSize!==null&&o.data.size>l.maxSize.value&&(_e(o,{code:Ce.too_big,maximum:l.maxSize.value,type:"set",inclusive:!0,exact:!1,message:l.maxSize.message}),r.dirty());const d=this._def.valueType;function u(p){const x=new Set;for(const b of p){if(b.status==="aborted")return it;b.status==="dirty"&&r.dirty(),x.add(b.value)}return{status:r.value,value:x}}const m=[...o.data.values()].map((p,x)=>d._parse(new xi(o,p,o.path,x)));return o.common.async?Promise.all(m).then(p=>u(p)):u(m)}min(a,r){return new Mc({...this._def,minSize:{value:a,message:Fe.toString(r)}})}max(a,r){return new Mc({...this._def,maxSize:{value:a,message:Fe.toString(r)}})}size(a,r){return this.min(a,r).max(a,r)}nonempty(a){return this.min(1,a)}}Mc.create=(t,a)=>new Mc({valueType:t,minSize:null,maxSize:null,typeName:ot.ZodSet,...xt(a)});class jj extends Dt{get schema(){return this._def.getter()}_parse(a){const{ctx:r}=this._processInputParams(a);return this._def.getter()._parse({data:r.data,path:r.path,parent:r})}}jj.create=(t,a)=>new jj({getter:t,typeName:ot.ZodLazy,...xt(a)});class wj extends Dt{_parse(a){if(a.data!==this._def.value){const r=this._getOrReturnCtx(a);return _e(r,{received:r.data,code:Ce.invalid_literal,expected:this._def.value}),it}
vendor: 5,385 bytes, line 633
633return{status:"valid",value:a.data}}get value(){return this._def.value}}wj.create=(t,a)=>new wj({value:t,typeName:ot.ZodLiteral,...xt(a)});function S2(t,a){return new rl({values:t,typeName:ot.ZodEnum,...xt(a)})}class rl extends Dt{_parse(a){if(typeof a.data!="string"){const r=this._getOrReturnCtx(a),o=this._def.values;return _e(r,{expected:It.joinValues(o),received:r.parsedType,code:Ce.invalid_type}),it}if(this._cache||(this._cache=new Set(this._def.values)),!this._cache.has(a.data)){const r=this._getOrReturnCtx(a),o=this._def.values;return _e(r,{received:r.data,code:Ce.invalid_enum_value,options:o}),it}return dn(a.data)}get options(){return this._def.values}get enum(){const a={};for(const r of this._def.values)a[r]=r;return a}get Values(){const a={};for(const r of this._def.values)a[r]=r;return a}get Enum(){const a={};for(const r of this._def.values)a[r]=r;return a}extract(a,r=this._def){return rl.create(a,{...this._def,...r})}exclude(a,r=this._def){return rl.create(this.options.filter(o=>!a.includes(o)),{...this._def,...r})}}rl.create=S2;class Nj extends Dt{_parse(a){const r=It.getValidEnumValues(this._def.values),o=this._getOrReturnCtx(a);if(o.parsedType!==Ke.string&&o.parsedType!==Ke.number){const l=It.objectValues(r);return _e(o,{expected:It.joinValues(l),received:o.parsedType,code:Ce.invalid_type}),it}if(this._cache||(this._cache=new Set(It.getValidEnumValues(this._def.values))),!this._cache.has(a.data)){const l=It.objectValues(r);return _e(o,{received:o.data,code:Ce.invalid_enum_value,options:l}),it}return dn(a.data)}get enum(){return this._def.values}}Nj.create=(t,a)=>new Nj({values:t,typeName:ot.ZodNativeEnum,...xt(a)});class qu extends Dt{unwrap(){return this._def.type}_parse(a){const{ctx:r}=this._processInputParams(a);if(r.parsedType!==Ke.promise&&r.common.async===!1)return _e(r,{code:Ce.invalid_type,expected:Ke.promise,received:r.parsedType}),it;const o=r.parsedType===Ke.promise?r.data:Promise.resolve(r.data);return dn(o.then(l=>this._def.type.parseAsync(l,{path:r.path,errorMap:r.common.contextualErrorMap})))}}qu.create=(t,a)=>new qu({type:t,typeName:ot.ZodPromise,...xt(a)});class il extends Dt{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===ot.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(a){const{status:r,ctx:o}=this._processInputParams(a),l=this._def.effect||null,d={addIssue:u=>{_e(o,u),u.fatal?r.abort():r.dirty()},get path(){return o.path}};if(d.addIssue=d.addIssue.bind(d),l.type==="preprocess"){const u=l.transform(o.data,d);if(o.common.async)return Promise.resolve(u).then(async m=>{if(r.value==="aborted")return it;const p=await this._def.schema._parseAsync({data:m,path:o.path,parent:o});return p.status==="aborted"?it:p.status==="dirty"||r.value==="dirty"?yc(p.value):p});{if(r.value==="aborted")return it;const m=this._def.schema._parseSync({data:u,path:o.path,parent:o});return m.status==="aborted"?it:m.status==="dirty"||r.value==="dirty"?yc(m.value):m}}if(l.type==="refinement"){const u=m=>{const p=l.refinement(m,d);if(o.common.async)return Promise.resolve(p);if(p instanceof Promise)throw new Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return m};if(o.common.async===!1){const m=this._def.schema._parseSync({data:o.data,path:o.path,parent:o});return m.status==="aborted"?it:(m.status==="dirty"&&r.dirty(),u(m.value),{status:r.value,value:m.value})}else return this._def.schema._parseAsync({data:o.data,path:o.path,parent:o}).then(m=>m.status==="aborted"?it:(m.status==="dirty"&&r.dirty(),u(m.value).then(()=>({status:r.value,value:m.value}))))}if(l.type==="transform")if(o.common.async===!1){const u=this._def.schema._parseSync({data:o.data,path:o.path,parent:o});if(!al(u))return it;const m=l.transform(u.value,d);if(m instanceof Promise)throw new Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:r.value,value:m}}else return this._def.schema._parseAsync({data:o.data,path:o.path,parent:o}).then(u=>al(u)?Promise.resolve(l.transform(u.value,d)).then(m=>({status:r.value,value:m})):it);It.assertNever(l)}}il.create=(t,a,r)=>new il({schema:t,typeName:ot.ZodEffects,effect:a,...xt(r)});il.createWithPreprocess=(t,a,r)=>new il({schema:a,effect:{type:"preprocess",transform:t},typeName:ot.ZodEffects,...xt(r)});class mi extends Dt{_parse(a){return this._getType(a)===Ke.undefined?dn(void 0):this._def.innerType._parse(a)}unwrap(){return this._def.innerType}}mi.create=(t,a)=>new mi({innerType:t,typeName:ot.ZodOptional,...xt(a)});class ol extends Dt{_parse(a){return this._getType(a)===Ke.null?dn(null):this._def.innerType._parse(a)}unwrap(){return this._def.innerType}}ol.create=(t,a)=>new ol({innerType:t,typeName:ot.ZodNullable,...xt(a)});class dx extends Dt{_parse(a){const{ctx:r}=this._processInputParams(a);let o=r.data;return r.parsedType===Ke.undefined&&(o=this._def.defaultValue()),this._def.innerType._parse({data:o,path:r.path,parent:r})}removeDefault(){return this._def.innerType}}dx.create=(t,a)=>new dx({innerType:t,typeName:ot.ZodDefault,defaultValue:typeof a.default=="function"?a.default:()=>a.default,...xt(a)});class ux extends Dt{_parse(a){const{ctx:r}=this._processInputParams(a),o={...r,common:{...r.common,issues:[]}},l=this._def.innerType._parse({data:o.data,path:o.path,parent:{...o}});return $u(l)?l.then(d=>
633({status:"valid",value:d.status==="valid"?d.value:this._def.catchValue({get error(){return new Sr(o.common.issues)},input:o.data})})):{status:"valid",value:l.status==="valid"?l.value:this._def.catchValue({get error(){return new Sr(o.common.issues)},input:o.data})}}removeCatch(){return this._def.innerType}}ux.create=(t,a)=>new ux({innerType:t,typeName:ot.ZodCatch,catchValue:typeof a.catch=="function"?a.catch:()=>a.catch,...xt(a)});class Sj extends Dt{_parse(a){if(this._getType(a)!==Ke.nan){const o=this._getOrReturnCtx(a);return _e(o,{code:Ce.invalid_type,expected:Ke.nan,received:o.parsedType}),it}return{status:"valid",value:a.data}}}Sj.create=t=>new Sj({typeName:ot.ZodNaN,...xt(t)});class rA extends Dt{_parse(a){const{ctx:r}=this._processInputParams(a),o=r.data;return this._def.type._parse({data:o,path:r.path,parent:r})}unwrap(){return this._def.type}}class hg extends Dt{_parse(a){const{status:r,ctx:o}=this._processInputParams(a);if(o.common.async)return(async()=>{const d=await this._def.in._parseAsync({data:o.data,path:o.path,parent:o});return d.status==="aborted"?it:d.status==="dirty"?(r.dirty(),yc(d.value)):this._def.out._parseAsync({data:d.value,path:o.path,parent:o})})();{const l=this._def.in._parseSync({data:o.data,path:o.path,parent:o});return l.status==="aborted"?it:l.status==="dirty"?(r.dirty(),{status:"dirty",value:l.value}):this._def.out._parseSync({data:l.value,path:o.path,parent:o})}}static create(a,r){return new hg({in:a,out:r,typeName:ot.ZodPipeline})}}class mx extends Dt{_parse(a){const r=this._def.innerType._parse(a),o=l=>(al(l)&&(l.value=Object.freeze(l.value)),l);return $u(r)?r.then(l=>o(l)):o(r)}unwrap(){return this._def.innerType}}mx.create=(t,a)=>new mx({innerType:t,typeName:ot.ZodReadonly,...xt(a)});var ot;(function(t){t.ZodString="ZodString",t.ZodNumber="ZodNumber",t.ZodNaN="ZodNaN",t.ZodBigInt="ZodBigInt",t.ZodBoolean="ZodBoolean",t.ZodDate="ZodDate",t.ZodSymbol="ZodSymbol",t.ZodUndefined="ZodUndefined",t.ZodNull="ZodNull",t.ZodAny="ZodAny",t.ZodUnknown="ZodUnknown",t.ZodNever="ZodNever",t.ZodVoid="ZodVoid",t.ZodArray="ZodArray",t.ZodObject="ZodObject",t.ZodUnion="ZodUnion",t.ZodDiscriminatedUnion="ZodDiscriminatedUnion",t.ZodIntersection="ZodIntersection",t.ZodTuple="ZodTuple",t.ZodRecord="ZodRecord",t.ZodMap="ZodMap",t.ZodSet="ZodSet",t.ZodFunction="ZodFunction",t.ZodLazy="ZodLazy",t.ZodLiteral="ZodLiteral",t.ZodEnum="ZodEnum",t.ZodEffects="ZodEffects",t.ZodNativeEnum="ZodNativeEnum",t.ZodOptional="ZodOptional",t.ZodNullable="ZodNullable",t.ZodDefault="ZodDefault",t.ZodCatch="ZodCatch",t.ZodPromise="ZodPromise",t.ZodBranded="ZodBranded",t.ZodPipeline="ZodPipeline",t.ZodReadonly="ZodReadonly"})(ot||(ot={}));const N=ui.create,hi=nl.create,vc=ox.create,iA=lx.create;gi.create;const Ve=Wn.create,de=Os.create,oA=Fu.create;Wu.create;ao.create;rl.create;qu.create;mi.create;ol.create;const lA=de({id:N(),src:N(),alt:N(),href:N()}),cA=de({id:N(),href:N(),thumbnail:N(),title:N(),date:N(),views:hi(),likes:hi(),comments:hi(),isLive:vc()}),dA=de({id:N(),href:N(),thumbnail:N(),title:N(),date:N(),views:hi(),likes:hi(),comments:hi()}),ye={pages:{home:de({featuredPlayerCaption:N(),featuredPlayerLinkText:N(),description:Ve(de({id:N(),text:N()})),contestTitle:N(),contestPrize:N(),contestDates:N(),contestVoting:N(),contestRegistered:N(),miniContestTitle:N(),miniContestPrize:N(),miniContestDates:N(),miniContestVoting:N(),hmvContestTitle:N(),hmvContestPrize:N(),hmvContestDeadline:N(),hmvContestVoting:N(),createAccountCta:N(),ourMissionLabel:N(),watchLiveLabel:N(),addVideoLabel:N(),sharePhotosLabel:N()}),watch_live_events:de({SIDEBAR_BANNERS:Ve(lA),pageTitle:N(),pageIntro:N(),currentLiveEvents:Ve(cA),archiveEvents:Ve(dA),recentNews:Ve(N())}),news:de({pageTitle:N(),articles:Ve(de({id:N(),title:N(),excerpt:N(),date:N(),href:N(),thumbnail:N().optional(),category:N().optional()})),recentNews:Ve(N()),SIDEBAR_BANNERS:Ve(de({id:N(),src:N(),alt:N(),href:N()}))}),wdaa_video_orders:de({SIDEBAR_BANNERS:Ve(de({id:N(),src:N(),alt:N(),href:N()})),pageTitle:N(),intro:N(),note:N(),pricePerVideo:hi(),helpfulLinks:Ve(de({id:N(),label:N(),href:N()}))}),wdaa_hub:de({pageTitle:N(),pageSubtitle:N(),intro:N(),rings:Ve(de({id:N(),label:N(),embedUrl:N(),isLive:vc()})),helpfulLinks:Ve(de({id:N(),label:N(),href:N()})),SIDEBAR_BANNERS:Ve(de({id:N(),src:N(),alt:N(),href:N()}))}),wdaa_ring1:de({pageTitle:N(),description:N(),videoUrl:N(),embedUrl:N(),replaysUrl:N(),embedNote:N()}),wdaa_ring2:de({pageTitle:N(),description:N(),videoUrl:N(),embedUrl:N(),replaysUrl:N(),embedNote:N()}),wdaa_ring3:de({pageTitle:N(),description:N(),videoUrl:N(),embedUrl:N(),replaysUrl:N(),embedNote:N()}),wdaa_ring4:de({pageTitle:N(),description:N(),videoUrl:N(),embedUrl:N(),replaysUrl:N(),embedNote:N()}),wdaa_replays:de({pageTitle:N(),description:N(),purchaseUrl:N(),intro:N(),years:Ve(de({id:N(),year:N(),logoSrc:N(),note:N(),days:Ve(de({id:N(),label:N(),href:N()}))}))}),wdaa_sponsorships:de({pageTitle:N(),description:N(),heading:N(),intro:N(),sponsorIntro:N(),sponsorLearnMoreLabel:N(),sponsorLearnMoreUrl:N(),sponsorLearnMoreText:N(),contactHeading:N(),contactEmail:N(),contactPhone:N(),contacts:Ve(de({id:N(),type:N(),contact:N(),email:N()})),sponsorVideoLabel:N(),sponsorVideoNote:N(),currentSponsorsHeading:N(),sponsors:Ve(de({id:N(),name:N(),href:N(),logoSrc:N(),tier:N()})),packagesHeading:N(),packages:Ve(de({id:N(),name:N(),price:N(),features:Ve(N())}))}),sponsors_partners:de({pageTitle:N(),metaDescription:N(),intro:de({heading:N(),body:Ve(de({id:N(),text:N()}))}),tiers:Ve(de({id:N(),name:N(),price:N(),benefits:Ve(N())})),cta:de({heading:N(),body:N(),contactLabel:N(),email:N(),phone:N()}),partnersHeading:N(),partners:Ve(de({id:N(),name:N(),logoSrc:N(),logoAlt:N(),website:N(),websiteLabel:N(),ctaLabel:N(),ctaHref:N(),body:Ve(de({id:N(),text:N()}))})),SIDEBAR_BANNERS:Ve(de({id:N(),src:N(),alt:N(),href:N()}))}),help:de({pageTitle:N(),metaDescription:N(),SIDEBAR_BANNERS:Ve(de({id:N(),src:N(),alt:N(),href:N()})),contactForm:de({heading:N(),inquiryOptions:Ve(de({id:N(),label:N()}))}),contactInfo:Ve(de({id:N(),heading:N(),body:N(),email:N(),mediaKitHref:N().optional(),phone:N(),fax:N()})),socialLinks:Ve(de({id:N(),label:N(),href:N()}))}),donations:de({pageTitle:N(),metaDescription:N(),intro:de({heading:N(),body:N()}),thankYou:N(),paymentMethods:Ve(de({id:N(),name:N(),handle:N(),href:N(),instructions:N()})),SIDEBAR_BANNERS:Ve(de({id:N(),src:N(),alt:N(),href:N()}))}),tech_support:de({pageTitle:N(),metaDescription:N(),intro:de({heading:N(),body:N()}),steps:Ve(de({id:N(),number:N(),title:N(),body:N(),tips:Ve(iA())})),SIDEBAR_BANNERS:Ve(de({id:N(),src:N(),alt:N(),href:N()}))}),advertise:de({RATES:Ve(de({id:N(),label:N(),price:N(),period:N(),description:N(),restriction:N().optional()}))}),breeds_disciplines:de({pageTitle:N(),pageSubhead:N(),breeds:Ve(de({id:N(),name:N(),slug:N()})),disciplines:Ve(de({id:N(),name:N(),slug:N()}))}),puzzles:de({pageTitle:N(),intro:N(),playAllUrl:N(),footerLinkText:N(),puzzles:Ve(de({id:N(),title:N(),image:N(),playUrl:N()}))}),become_member:de({pageTitle:N(),subhead:N(),ctaLabel:N(),loginPrompt:N(),loginHref:N(),loginLinkLabel:N(),ACCOUNT_TYPE_OPTIONS:Ve(de({value:N(),label:N(),helper:N().optional(),id:N()})),nextSteps:Ve(de({id:N(),icon:N(),title:N(),body:N()}))}),login:de({pageTitle:N(),ctaLabel:N(),registerPrompt:N(),registerLinkLabel:N(),registerHref:N(),forgotLabel:N(),forgotHref:N()}),user_profile:de({headerBar:N(),notFoundTitle:N(),notFoundBody:N(),planLabel:N(),memberSinceLabel:N(),upgradeTeaser:N(),upgradeTeaserBody:N(),planNames:de({rookie:N(),maiden:N(),grand_prix:N()}),accountTypeLabels:de({horse_lover:N(),farm_trainer_business:N(),event_show:N(),association_org:N(),business:N()})}),link_to:de({pageTitle:N(),metaDescription:N(),intro:N(),textLinkSection:de({heading:N(),description:N(),linkUrl:N(),linkLabel:N(),code:N()}),logoLinkSection:de({heading:N(),description:N(),lightVariantLabel:N(),darkVariantLabel:N(),lightCode:N(),darkCode:N()})}),aha_partner:de({pageTitle:N(),metaDescription:N(),headline:N(),body:N(),ctaLabel:N(),ctaHref:N()}),community_guidelines:de({SIDEBAR_BANNERS:Ve(de({id:N(),src:N(),alt:N(),href:N()}))}),terms_of_service:de({SIDEBAR_BANNERS:Ve(de({id:N(),src:N(),alt:N(),href:N()})),SECTIONS:Ve(de({num:N(),heading:N(),subsections:Ve(de({label:N(),body:N(),email:oA([N(),vc()]).optional(),list:Ve(N()).optional(),id:N()})),id:N()}))}),privacy_policy:de({SIDEBAR_BANNERS:Ve(de({id:N(),src:N(),alt:N(),href:N()})),SECTIONS:Ve(de({num:N(),heading:N(),subsections:Ve(de({body:N(),list:Ve(N()).optional(),id:N()})),id:N()}))}),youtube:de({headline:N(),subtext:N(),ctaLabel:N(),channelUrl:N(),latestVideosHeading:N(),latestVideosSubtext:N(),subscribeLabel:N(),embedNote:N()}),rumble:de({headline:N(),subtext:N(),ctaLabel:N(),channelUrl:N(),latestStreamsHeading:N(),latestStreamsSubtext:N(),followLabel:N(),watchHeading:N(),watchBody:N()}),instagram:de({headline:N(),subtext:N(),ctaLabel:N(),channelUrl:N()}),games:de({GAMES:Ve(de({title:N(),description:N(),href:N(),playUrl:N(),id:N()}))}),horse_capital_tours:de({metaDescription:N(),pageTitle:N(),intro:de({heading:N(),paragraphs:Ve(N())}),bookingButton:de({label:N(),href:N()}),SIDEBAR_BANNERS:Ve(de({id:N(),src:N(),alt:N(),href:N()}))}),debbie_brooks:de({metaDescription:N(),pageTitle:N(),intro:de({heading:N(),paragraph:N()}),shopButton:de({label:N(),href:N()}),categories:Ve(de({id:N(),label:N(),slug:N()})),SIDEBAR_BANNERS:Ve(de({id:N(),src:N(),alt:N(),href:N()}))}),videos:de({ALL_CATEGORIES:Ve(de({label:N(),value:N(),id:N()}))}),membership:de({TIERS:Ve(de({key:N(),name:N(),trophies:hi(),available:vc(),comingSoon:vc().optional(),tagline:N(),features:Ve(N()),cta:de({label:N(),href:N()}),note:N().optional(),id:N()}))}),add_video_live:de({pageTitle:N(),metaDescription:N(),intro:N(),loginGate:de({heading:N(),body:N(),cta:N()}),notApproved:de({heading:N(),body:N(),cta:N()}),success:de({heading:N(),body:N(),ctaView:N(),ctaAnother:N()})}),contests:de({pageHeading:N(),pageSubheading:N(),hmv:de({title:N(),description:N(),entryDeadline:N(),votingNote:N(),prize:N(),platformBoxHeading:N(),rumbleLabel:N(),youtubeLabel:N(),emailBackup:N(),rightsDisclaimer:N(),rules:Ve(de({id:N(),text:N()}))}),wdaa:de({title:N(),description:N(),submissionDates:N(),votingDates:N(),prize:N(),rules:Ve(de({id:N(),text:N()}))})}),category_reining:de({contestBanner:de({status:N(),title:N(),prize:N(),submissionDates:N(),votingDates:N(),contestAnchor:N(),opensLabel:N()})}),live_helper:de({SOURCE_OPTIONS:Ve(de({value:N(),label:N(),id:N()}))}),admin_live_events:de({pageTitle:N()}),live_event_page:de({renoSbfButtons:de({liveScoring:N(),schedule:N()})}),news_article:de({loadingText:N(),notFoundTitle:N(),notFoundBody:N(),backToNews:N(),imageCreditLabel:N(),relatedLinksHeading:N(),breadcrumbHome:N(),breadcrumbNews:N()}),admin_users:de({pageTitle:N(),heading:N(),totalLabel:N(),approvedLabel:N(),unapprovedLabel:N(),searchPlaceholder:N(),noResults:N(),colMember:N(),colType:N(),colTier:N(),colJoined:N(),colApproved:N(),colAdmin:N(),colLiveHelper:N(),colDelete:N()}),admin_wdaa_orders:de({pageTitle:N(),pageSubtitle:N(),refreshLabel:N(),statTotalOrders:N(),statPending:N(),statCompleted:N(),statRevenue:N()}),category_miniature_horse:de({contestBanner:de({status:N(),title:N(),prize:N(),submissionDates:N(),votingDates:N(),contestAnchor:N(),opensLabel:N()})}),category_western_dressage:de({contestBanner:de({status:N(),title:N(),winner:N(),winnerOwner:N(),prize:N(),submissionDates:N(),votingDates:N(),contestAnchor:N(),opensLabel:N()})}),low_roller:de({title:N(),dates:N(),venue:N(),credit:N(),arena1:de({name:N(),startTime:N(),embedSrc:N(),embedTitle:N()}),arena2:de({name:N(),startTime:N(),embedSrc:N(),embedTitle:N()}),buttons:de({officialSite:N(),arena1Scores:N(),arena2Scores:N(),schedule:N()}),scoresDisclaimer:N()})}},tt={parse:t=>t};var yw,vw,jw,ww,Nw,Sw,Cw,kw,Tw,Aw,Ew,Hw,zw,Rw,_w,Lw,Dw,Ow,Mw,Uw,Pw,Kw,Iw,Bw,$w,Vw,Fw,Ww,qw,Yw,Gw,Zw,Jw,Xw,Qw,e1,t1,s1,a1,n1,r1,i1,o1,l1,c1,d1,u1,m1;const lt={add_video_live:(((yw=ye.pages)==null?void 0:yw.add_video_live)??ye.add_video_live??tt).parse({pageTitle:"Add Video / Live",metaDescription:"Publish a horse video or livestream to Total Horse Channel.",intro:"Paste a video or livestream URL or iframe from YouTube, Rumble, Vimeo, Box, or another source. We do not host video files — links and embeds only. Approved members' submissions go live on the site. Total Horse Channel may remove content that breaks the rules.",loginGate:{heading:"Add Video / Live",body:"You need to be logged in to publish a video or livestream.",cta:"Log In to Continue"},notApproved:{heading:"Account not yet approved",body:"New accounts cannot publish videos until an admin marks them as Approved. Contact us to request approval.",cta:"Contact Us"},success:{heading:"Your video is live!",body:"It has been published and is now visible on the Watch Live Events page. Total Horse Channel may remove content that breaks the rules.",ctaView:"View Your Video",ctaAnother:"Publish Another"}}),admin_live_events:(((vw=ye.pages)==null?void 0:vw.admin_live_events)??ye.admin_live_events??tt).parse({pageTitle:"Admin – Live Events"}),admin_users:(((jw=ye.pages)==null?void 0:jw.admin_users)??ye.admin_users??tt).parse({pageTitle:"Admin – Users | Total Horse Channel",heading:"Admin – Users",totalLabel:"total members",approvedLabel:"approved",unapprovedLabel:"unapproved",searchPlaceholder:"Search name, username, email…",noResults:"No users match your search.",colMember:"Member",colType:"Type",colTier:"Tier",colJoined:"Joined",colApproved:"Approved",colAdmin:"Admin",colLiveHelper:"Live Helper",colDelete:"Delete"}),admin_wdaa_orders:(((ww=ye.pages)==null?void 0:ww.admin_wdaa_orders)??ye.admin_wdaa_orders??tt).parse({pageTitle:"WDAA Video Orders",pageSubtitle:"2026 World Championship Show — video order management",refreshLabel:"Refresh",statTotalOrders:"Total Orders",statPending:"Pending",statCompleted:"Completed",statRevenue:"Revenue"}),advertise:(((Nw=ye.pages)==null?void 0:Nw.advertise)??ye.advertise??tt).parse({RATES:[{id:"rate-header",label:"Header Banner",price:"$300",period:"per month",description:"A prominent leaderboard banner displayed in the site header — maximum visibility on every page load. Total Horse Channel sponsor banners always stay in the header rotation. Championship members may add up to 2 banners in that rotation; they do not replace THC sponsor headers."},{id:"rate-homepage-leaderboard",label:"Homepage Banner (728×90)",price:"$250",period:"per month",description:"A 728×90 leaderboard banner displayed beneath the homepage player — high-visibility placement seen by every homepage visitor. Note: Championship members may have a 728×90 on their own pages when that feature ships. This advertised slot is the homepage player placement."},{id:"rate-sidebar-500",label:"Sidebar Banner (500×500)",price:"$200",period:"per month",description:"Your 500×500 square banner rotates in the sidebar across the site, seen by visitors on every page.",restriction:"Higher-tier member pages may show that member's own banner on their profile and their own live/video pages. Sitewide advertiser rotation still applies elsewhere."},{id:"rate-sidebar-220",label:"Sidebar Banner (220×300)",price:"$100",period:"per month",description:"Your 220×300 banner rotates in the sidebar across the site.",restriction:"Higher-tier member pages may show that member's own banner on their profile and their own live/video pages. Sitewide advertiser rotation still applies elsewhere."},{id:"rate-article",label:"Article + Link",price:"$100",period:"per article",description:"A featured article about your business, product, or event published on Total Horse Channel with a link back to your site. Includes up to 4 do-follow links, authorized photos with credit links, and optional video embeds."},{id:"rate-partner",label:"Partner Page Listing",price:"$500",period:"per year",description:"A dedicated card on our Sponsors & Partners page with your logo, writeup, and website link."}]}),aha_partner:(((Sw=ye.pages)==null?void 0:Sw.aha_partner)??ye.aha_partner??tt).parse({pageTitle:"Official AHA Media Partner",metaDescription:"Total Horse Channel is an official media partner of the Arabian Horse Association, sharing Arabian horse news, events, and education with viewers worldwide.",headline:"Official AHA Media Partner",body:"Total Horse Channel is a
633 media partner of the Arabian Horse Association. We help share Arabian horse news, events, and education with viewers around the world.",ctaLabel:"Visit Arabian Horse Association",ctaHref:"https://www.arabianhorses.org"}),become_member:(((Cw=ye.pages)==null?void 0:Cw.become_member)??ye.become_member??tt).parse({pageTitle:"Create Your Free Total Horse Channel Account",subhead:"Join the Total Horse Channel community. Watch live events, enter contests, and connect with riders, owners, farms, and shows.",ctaLabel:"Create Free Account",loginPrompt:"Already have an account?",loginHref:"/login",loginLinkLabel:"Log in here",ACCOUNT_TYPE_OPTIONS:[{value:"horse_lover",label:"Horse Enthusiast",helper:"Riders, owners, and viewers",id:"c_nVm2x0VY7rsRMgmhgFB"},{value:"farm_trainer_business",label:"Farm, Trainer, or Business",id:"_XS_ZjdWJ_oCnKFPbtWXa"},{value:"event_show",label:"Event or Show",id:"a2Q0UjHMtDOpkbTX0uZ2E"},{value:"association_org",label:"Association or Organization",id:"ab5c85o0xkZSf3QRlPH2z"}],nextSteps:[{id:"ns1",icon:"bell",title:"Get notified about live events",body:"Never miss a live broadcast. We'll alert you when your favorite events go live."},{id:"ns2",icon:"video",title:"Watch exclusive video content",body:"Access member-only replays, behind-the-scenes footage, and full event coverage."},{id:"ns3",icon:"film",title:"Share your horse videos",body:"Upload and share your own videos with the Total Horse Channel community."}]}),breeds_disciplines:(((kw=ye.pages)==null?void 0:kw.breeds_disciplines)??ye.breeds_disciplines??tt).parse({pageTitle:"Breeds & Disciplines",pageSubhead:"Find videos by breed or riding discipline.",breeds:[{id:"b-31",name:"Akhal-Teke",slug:"akhal-teke"},{id:"b-1",name:"American Quarter Horse",slug:"american-quarter-horse"},{id:"b-2",name:"American Saddlebred",slug:"american-saddlebred"},{id:"b-3",name:"Andalusian",slug:"andalusian"},{id:"b-32",name:"Anglo-Arab",slug:"anglo-arab"},{id:"b-4",name:"Appaloosa",slug:"appaloosa"},{id:"b-53",name:"Barb (Barbe)",slug:"barb-barbe"},{id:"b-5",name:"Arabian",slug:"arabian"},{id:"b-33",name:"Belgian Draft",slug:"belgian-draft"},{id:"b-24",name:"Campolina",slug:"campolina"},{id:"b-25",name:"Cavalo Crioulo",slug:"cavalo-crioulo"},{id:"b-34",name:"Clydesdale",slug:"clydesdale"},{id:"b-35",name:"Connemara",slug:"connemara"},{id:"b-7",name:"Draft Horse",slug:"draft-horse"},{id:"b-36",name:"Fjord",slug:"fjord"},{id:"b-8",name:"Friesian",slug:"friesian"},{id:"b-9",name:"Gypsy Vanner",slug:"gypsy-vanner"},{id:"b-10",name:"Hackney",slug:"hackney"},{id:"b-37",name:"Haflinger",slug:"haflinger"}
633,{id:"b-38",name:"Hanoverian",slug:"hanoverian"},{id:"b-39",name:"Icelandic",slug:"icelandic"},{id:"b-40",name:"Irish Sport Horse",slug:"irish-sport-horse"},{id:"b-41",name:"Kentucky Mountain Saddle Horse",slug:"kentucky-mountain-saddle-horse"},{id:"b-42",name:"Lipizzan",slug:"lipizzan"},{id:"b-43",name:"Lusitano",slug:"lusitano"},{id:"b-44",name:"Mangalarga Marchador",slug:"mangalarga-marchador"},{id:"b-11",name:"Miniature Horse",slug:"miniature-horse"},{id:"b-45",name:"Missouri Fox Trotter",slug:"missouri-fox-trotter"},{id:"b-12",name:"Morgan",slug:"morgan"},{id:"b-13",name:"Mustang",slug:"mustang"},{id:"b-54",name:"National Show Horse",slug:"national-show-horse"},{id:"b-14",name:"Paint Horse",slug:"paint-horse"},{id:"b-15",name:"Paso Fino",slug:"paso-fino"},{id:"b-46",name:"Percheron",slug:"percheron"},{id:"b-47",name:"Peruvian Paso",slug:"peruvian-paso"},{id:"b-16",name:"Pinto",slug:"pinto"},{id:"b-17",name:"Pony",slug:"pony"},{id:"b-23",name:"Rocky Mountain Horse",slug:"rocky-mountain-horse"},{id:"b-48",name:"Shetland Pony",slug:"shetland-pony"},{id:"b-49",name:"Shire",slug:"shire"},{id:"b-50",name:"Standardbred",slug:"standardbred"},{id:"b-6",name:"Straight Egyptian Arabian",slug:"straight-egyptian-arabian"},{id:"b-18",name:"Tennessee Walking Horse",slug:"tennessee-walking-horse"},{id:"b-19",name:"Thoroughbred",slug:"thoroughbred"},{id:"b-51",name:"Trakehner",slug:"trakehner"},{id:"b-20",name:"Warmblood",slug:"warmblood"},{id:"b-52",name:"Welsh Pony",slug:"welsh-pony"}],disciplines:[{id:"d-1",name:"Barrel Racing",slug:"barrel-racing"},{id:"campdraft-disc-01",name:"Campdraft",slug:"campdraft"},{id:"d-25",name:"Cowboy Dressage",slug:"cowboy-dressage"},{id:"d-2",name:"Cross Country",slug:"cross-country"},{id:"d-3",name:"Cutting Horse",slug:"cutting"},{id:"d-4",name:"Dressage",slug:"dressage"},{id:"d-27",name:"Dressage to Music / Freestyle",slug:"dressage-to-music-freestyle"},{id:"d-6",name:"Driving",slug:"driving"},{id:"d-7",name:"Endurance",slug:"endurance"},{id:"d-8",name:"Eventing",slug:"eventing"},{id:"d-29",name:"Farms",slug:"farms"},{id:"d-30",name:"Foals",slug:"foals"},{id:"d-37",name:"4-H",slug:"4-h"},{id:"d-9",name:"Halter",slug:"halter"},{id:"d-24",name:"Harness Racing",slug:"harness-racing"},{id:"d-23",name:"Horse Racing",slug:"horse-racing"},{id:"d-35",name:"Horse Sale",slug:"horse-sale"},{id:"d-32",name:"Horse For Sale",slug:"horse-for-sale"},{id:"d-33",name:"Horse Show",slug:"horse-show"},{id:"d-10",name:"Hunter/Jumper",slug:"hunter"},{id:"d-11",name:"Mounted Archery",slug:"mounted-archery"},{id:"d-12",name:"Mounted Shooting",slug:"mounted-shooting"},{id:"d-28",name:"Horse Music Videos",slug:"horse-music-videos"},{id:"d-13",name:"Polo",slug:"polo"},{id:"d-14",name:"Ranch Riding",slug:"ranch-riding"},{id:"d-26",name:"Reined Cow Horse",slug:"reined-cow-horse"},{id:"d-15",name:"Reining",slug:"reining"},{id:"d-16",name:"Rodeo",slug:"rodeo"},{id:"d-17",name:"Roping",slug:"roping"},{id:"d-18",name:"Show Jumping",slug:"show-jumping"},{id:"d-34",name:"Sporthorse",slug:"sporthorse"},{id:"d-19",name:"Trail",slug:"trail"},{id:"d-20",name:"Vaulting",slug:"vaulting"},{id:"d-21",name:"Western Dressage",slug:"western-dressage"},{id:"d-22",name:"Western Pleasure",slug:"western-pleasure"},{id:"d-36",name:"Working Equitation",slug:"working-equitation"},{id:"d-31",name:"Other / General",slug:"other-general"}]}),category_horse_music_videos:(((Tw=ye.pages)==null?void 0:Tw.category_horse_music_videos)??ye.category_horse_music_videos??tt).parse({contestBanner:{status:"current",title:"Horse Music Video Contest",prize:"$300 Visa gift card",submissionDates:"Entries through October 31, 2026",votingDates:"November 1, 2026",contestAnchor:"#horse-music-video",opensLabel:""}}),category_miniature_horse:(((Aw=ye.pages)==null?void 0:Aw.category_miniature_horse)??ye.category_miniature_horse??tt).parse({contestBanner:{status:"current",title:"Miniature Horse Category Icon Photo Contest",prize:"$150 Visa gift card",submissionDates:"September 25 – October 3, 2026",votingDates:"week of October 4",contestAnchor:"#miniature-horse-icon",opensLabel:"September 25"}}),category_reined_cow_horse:(((Ew=ye.pages)==null?void 0:Ew.category_reined_cow_horse)??ye.category_reined_cow_horse??tt).parse({contestBanner:{status:"current",title:"Reined Cow Horse Category Icon Photo Contest",prize:"$150 Visa gift card",submissionDates:"September 11 – September 20, 2026",votingDates:"week of September 21",contestAnchor:"#reined-cow-horse-icon",opensLabel:""}}),category_reining:(((Hw=ye.pages)==null?void 0:Hw.category_reining)??ye.category_reining??tt).parse({contestBanner:{status:"upcoming",title:"Reining Category Icon Photo Contest",prize:"$150 Visa gift card",submissionDates:"October 2 – October 10, 2026",votingDates:"week of October 11",contestAnchor:"#reining-icon",opensLabel:"October 2"}}),category_western_dressage:(((zw=ye.pages)==null?void 0:zw.category_western_dressage)??ye.category_western_dressage??tt).parse({contestBanner:{status:"closed",title:"Western Dressage Category Icon Photo Contest",winner:"Alex Maximus",winnerOwner:"Pete Lichau",prize:"$150 Visa gift card",submissionDates:"September 14 – September 19, 2026",votingDates:"September 20–25",contestAnchor:"#western-dressage-icon",opensLabel:""}}),community_guidelines:(((Rw=ye.pages)==null?void 0:Rw.community_guidelines)??ye.community_guidelines??tt).parse({SIDEBAR_BANNERS:[{id:"wdaa",src:"/airo-assets/images/sidebar/wdaa-banner",alt:"WDAA Western Dressage Association",href:"/home/wdaa"},{id:"debbie-brooks",src:"/airo-assets/images/sidebar/debbie-brooks-custom-cuff",alt:"Debbie Brooks Custom Cuffs",href:"https://www.debbiebrooks.com"},{src:"/airo-assets/images/sidebar/banner-sale-500",alt:"Total Horse Channel – New Website Special Banner Sale",href:"/advertise",id:"cg-thc-banner-sale"}]}),contests:(((_w=ye.pages)==null?void 0:_w.contests)??ye.contests??tt).parse({pageHeading:"Contests",pageSubheading:"Win prizes and get your content featured on Total Horse Channel",hmv:{title:"Horse Music Video Contest",description:"Submit your best horse music video. Prize is a $300 Visa gift card.",entryDeadline:"October 31, 2026",votingNote:"Voting opens November 1 — logged-in THC members, one vote per video",prize:"$300 Visa gift card",platformBoxHeading:"Your video must be hosted on Rumble or YouTube before you submit.",rumbleLabel:"Create a free Rumble account (or sign in if you already have one)",youtubeLabel:"Sign in or create a YouTube account",emailBackup:"if the entry form is not ready.",rightsDisclaimer:"By submitting you confirm the music is yours, licensed to you, or made in a generator whose terms give you the rights. No uncleared commercial tracks.",rules:[{id:"r1",text:"Submit a Rumble link (preferred) or a YouTube link to a video you control."},{id:"r2",text:"Music must be yours, licensed to you, or made in a generator whose terms give you the rights. No uncleared commercial tracks."},{id:"r3",text:"Entry period: now through October 31, 2026."},{id:"r4",text:"Voting opens November 1, 2026. Logged-in Total Horse Channel members only. One vote per member per video."},{id:"r5",text:"By submitting, you confirm you have the right to share the video and its music."}]},wdaa:{title:"Western Dressage Category Icon Photo Contest",description:"Submit your best Western Dressage horse photo. The winning image becomes the Western Dressage category icon on TotalHorseChannel.com for one year. Winner also receives a $150 Visa gift card.",submissionDates:"Sep 14–19, 2026",votingDates:"Sep 20–25, 2026",prize:"$150 Visa gift card",rules:[{id:"r1",text:"Real photograph only. No AI-generated images."},{id:"r2",text:"Submitter must own the photo or have permission to use it."},{id:"r3",text:"A rider may appear in the photo."},{id:"r4",text:"By submitting, you grant Total Horse Channel the right to use the image on TotalHorseChannel.com."},{id:"r5",text:"One vote per logged-in account per photo during the voting window."},{id:"r6",text:"Votes may be changed or removed during the voting window."}]}}),debbie_brooks:(((Lw=ye.pages)==null?void 0:Lw.debbie_brooks)??ye.debbie_brooks??tt).parse({metaDescription:"Shop the Debbie Brooks Equestrian Collection — cuffs, handbags, accessories, and more. Available through Total Horse Channel.",pageTitle:"Debbie Brooks Equestrian Collection",intro:{heading:"Debbie Brooks Equestrian Collection",paragraph:"Shop the Debbie Brooks Equestrian Collection — cuffs, handbags, accessories, and more. Checkout is handled through Debbie Brooks' store on Total Horse Channel. Total Horse Channel may earn a commission from purchases."},shopButton:{label:"Shop the Collection",href:"https://totalhorsechannel.com/shop/debbie-brooks-equestrian-collection/?utm_source=thc&utm_medium=shop&utm_campaign=debbie-brooks"},categories:[{id:"cat-1",label:"Equestrian Collection",slug:"equestrian-collection"},{id:"cat-2",label:"Summer Collection",slug:"summer-collection"},{id:"cat-3",label:"Cuffs",slug:"cuffs"},{id:"cat-4",label:"Accessories",slug:"accessories"},{id:"cat-5",label:"Handbags",slug:"handbags"},{id:"cat-6",label:"Magnafabs",slug:"magnafabs"}],SIDEBAR_BANNERS:[{id:"sb-wdaa",src:"/airo-assets/images/sidebar/wdaa-banner",alt:"WDAA Western Dressage Association",href:"/home/wdaa"},{id:"sb-debbie-brooks-cuff",src:"/airo-assets/images/sidebar/debbie-brooks-custom-cuff",alt:"Debbie Brooks New York – Custom Horse Cuffs",href:"https://totalhorsechannel.com/shop/debbie-brooks-equestrian-collection/?utm_source=thc&utm_medium=shop&utm_campaign=debbie-brooks"},{src:"/airo-assets/images/sidebar/banner-sale-500",alt:"Total Horse Channel – New Website Special Banner Sale",href:"/advertise",id:"db-thc-banner-sale"}]}),donations:(((Dw=ye.pages)==null?void 0:Dw.donations)??ye.donations??tt).parse({pageTitle:"Support Total Horse Channel",metaDescription:"Support Total Horse Channel with a donation via PayPal, Venmo, or CashApp. Your gift helps keep live horse show coverage free and grow new programming.",intro:{heading:"Support Total Horse Channel",body:"Total Horse Channel brings live horse shows, racing, clinics, and equine education to fans around the world. Your gift helps keep that coverage free, grow new programming, and share the horse industry with the next generation of riders and viewers."},thankYou:"Every dollar goes toward production, equipment, and bringing more events to your screen — and toward building the features that make Total Horse Channel different: a horse-only place to watch, follow, and connect. We are grateful for your support.",paymentMethods:[{id:"pm-paypal",name:"PayPal",handle:"totalhorsechannel",href:"https://www.paypal.me/totalhorsechannel",instructions:"Click the button below or send directly to totalhorsechannel via PayPal."},{id:"pm-venmo",name:"Venmo",handle:"@TotalHorseChannel",href:"https://venmo.com/u/TotalHorseChannel",instructions:"Search @TotalHorseChannel in the Venmo app or tap the button below."},{id:"pm-zelle",name:"Zelle",handle:"[email protected]",href:"",instructions:"Open your bank's app and send to the email address below. No link needed — Zelle works directly through your bank."}],SIDEBAR_BANNERS:[{id:"sb-wdaa",src:"/airo-assets/images/sidebar/wdaa-banner",alt:"WDAA Western Dressage Association",href:"/home/wdaa"},{id:"sb-debbie-brooks",src:"/airo-assets/images/sidebar/debbie-brooks-custom-cuff",alt:"Debbie Brooks New York – Custom Horse Cuffs",href:"https://www.debbiebrooks.com/"},{src:"/airo-assets/images/sidebar/banner-sale-500",alt:"Total Horse Channel – New Website Special Banner Sale",href:"/advertise",id:"don-thc-banner-sale"}]}),games:(((Ow=ye.pages)==null?void 0:Ow.games)??ye.games??tt).parse({GAMES:[{title:"Horse Eden",description:"Free eventing horse sim. Breed, train, and show.",href:"/games/horse-eden",playUrl:"https://horseeden.com/",id:"horse-eden"},{title:"Horse World Online",description:"Free horse breeding and training game.",href:"/games/horse-world-online",playUrl:"https://www.horseworldonline.net/",id:"horse-world-online"}]}),help:(((Mw=ye.pages)==null?void 0:Mw.help)??ye.help??tt).parse({pageTitle:"Help / Tech Supp
633ort",metaDescription:"Get help with Total Horse Channel — contact customer service, technical support, or reach out about advertising and partnership opportunities.",SIDEBAR_BANNERS:[{id:"sb-wdaa",src:"/airo-assets/images/sidebar/wdaa-banner",alt:"WDAA Western Dressage Association",href:"/home/wdaa"},{id:"sb-debbie-brooks",src:"/airo-assets/images/sidebar/debbie-brooks-custom-cuff",alt:"Debbie Brooks New York – Custom Horse Cuffs",href:"https://www.debbiebrooks.com/"},{src:"/airo-assets/images/sidebar/banner-sale-500",alt:"Total Horse Channel – New Website Special Banner Sale",href:"/advertise",id:"help-thc-banner-sale"}],contactForm:{heading:"Got Questions? We Got Answers!",inquiryOptions:[{id:"iq-general",label:"General Question"},{id:"iq-tech",label:"Technical Support"},{id:"iq-billing",label:"Billing / Account"},{id:"iq-advertising",label:"Advertising & Partnerships"},{id:"iq-other",label:"Other"}]},contactInfo:[{id:"ci-customer-service",heading:"Customer Service",body:"Assistance with accounts and/or billing.",email:"[email protected]",phone:"404.827.8340",fax:""},{id:"ci-tech-support",heading:"Technical Support",email:"[email protected]",body:"",phone:"",fax:""},{id:"ci-advertising",heading:"Advertising & Partnership Opportunities",body:"We partner with companies and organizations to deliver effective multi-media campaigns. Request our Media Kit, or email us directly.",email:"[email protected]",mediaKitHref:"/advertise",phone:"",fax:""}],socialLinks:[{id:"sl-rumble",label:"Watch us on Rumble",href:"https://rumble.com/c/TotalHorseChannel?e9s=src_v1_sa%2Csrc_v4_sa_o"},{id:"sl-facebook",label:"Follow us on Facebook",href:"https://www.facebook.com/TotalHorseChannel"},{id:"sl-youtube",label:"Subscribe on YouTube",href:"https://www.youtube.com/@TotalHorseChannel"}]}),home:(((Uw=ye.pages)==null?void 0:Uw.home)??ye.home??tt).parse({featuredPlayerCaption:"Featured player — partners and booked events.",featuredPlayerLinkText:"Advertise this slot",description:[{id:"desc-1",text:"Total Horse Channel is an online television network that showcases horses and ALL things related to the equine industry. Browse interesting horse videos on horse care & health, education, clinics, special events, live horse shows, and other live equine events and more!"},{id:"desc-2",text:"The ultimate Grand National 2026 guide – Discover all the Runners, Riders and Odds with our easy to follow guide. Plus free bets & tips for the big race."}],contestTitle:"Western Dressage | Category Icon Photo Contest",contestPrize:"$150 Visa gift card + your photo as the Western Dressage category image on TotalHorseChannel.com for one year.",contestDates:"Sep 14–19",contestVoting:"Sep 20–25",contestRegistered:"You're registered — check back September 14",miniContestTitle:"Miniature Horse | Category Icon Photo Contest",miniContestPrize:"$150 Visa gift card + your photo as the Miniature Horse category image on TotalHorseChannel.com for one year.",miniContestDates:"Sep 25 – Oct 3",miniContestVoting:"Voting: week of Oct 4",hmvContestTitle:"Horse Music Video Contest",hmvContestPrize:"$300 Visa gift card",hmvContestDeadline:"Entries open through October 31, 2026",hmvContestVoting:"Voting opens November 1",createAccountCta:"Create your free account — follow riders, comment, and enter contests.",ourMissionLabel:"Our Mission",watchLiveLabel:"WATCH LIVE EVENTS",addVideoLabel:"+ ADD VIDEO / LIVE",sharePhotosLabel:"SHARE PHOTOS & UPDATES"}),horse_capital_tours:(((Pw=ye.pages)==null?void 0:Pw.horse_capital_tours)??ye.horse_capital_tours??tt).parse({metaDescription:"Experience the Horse Capital of the World with The Horse Capital Tours — exclusive guided tours of Ocala's top breeding farms, training facilities, and auction venues.",pageTitle:"The Horse Capital Tours",intro:{heading:"The Horse Capital Tours",paragraphs:["Inspired by what you see in this video? You can experience the Horse Capital of the World in person through professionally guided tours offered by The Horse Capital Tours.","These tours provide exclusive access to some of Ocala's most renowned equestr
633ian destinations, including breeding farms, training facilities, and historic auction venues. Each tour is designed to give visitors a deeper understanding of the horses, people, and traditions that define this world-class equine community.","To view current tour offerings, availability, and booking information, visit the official The Horse Capital Tours website. All tour bookings and inquiries are handled directly through The Horse Capital Tours."]},bookingButton:{label:"Book Your Tour Today",href:"https://thehorsecapitaltours.com"},SIDEBAR_BANNERS:[{id:"sb-wdaa",src:"/airo-assets/images/sidebar/wdaa-banner",alt:"WDAA Western Dressage Association",href:"/home/wdaa"},{id:"sb-debbie-brooks",src:"/airo-assets/images/sidebar/debbie-brooks-custom-cuff",alt:"Debbie Brooks New York – Custom Horse Cuffs",href:"https://www.debbiebrooks.com/"},{src:"/airo-assets/images/sidebar/banner-sale-500",alt:"Total Horse Channel – New Website Special Banner Sale",href:"/advertise",id:"hct-thc-banner-sale"}]}),instagram:(((Kw=ye.pages)==null?void 0:Kw.instagram)??ye.instagram??tt).parse({headline:"Total Horse Channel on Instagram",subtext:"Photos and short video from shows, lives, and the horse community.",ctaLabel:"Follow on Instagram",channelUrl:"https://www.instagram.com/totalhorsechannel/"}),link_to:(((Iw=ye.pages)==null?void 0:Iw.link_to)??ye.link_to??tt).parse({pageTitle:"Link to Total Horse Channel",metaDescription:"Share Total Horse Channel with your visitors. Copy a text link or add our logo to your website.",intro:"Share Total Horse Channel with your visitors. Copy a text link or add our logo.",textLinkSection:{heading:"Text Link",description:"Copy and paste this HTML to add a text link to Total Horse Channel on your website.",linkUrl:"https://totalhorsechannel.com/",linkLabel:"Total Horse Channel",code:'<a href="https://totalhorsechannel.com/">Total Horse Channel</a>'},logoLinkSection:{heading:"Logo Link",description:"Add the official Total Horse Channel logo to your website. Choose the version that works best with your site's background.",lightVariantLabel:"Color logo — for white or light backgrounds",darkVariantLabel:"White logo — for dark or colored backgrounds",lightCode:'<a href="https://totalhorsechannel.com/"><img src="https://totalhorsechannel.com/airo-assets/images/logo/horizontal/light" alt="Total Horse Channel" width="220" height="60" /></a>',darkCode:'<a href="https://totalhorsechannel.com/"><img src="https://totalhorsechannel.com/airo-assets/images/logo/horizontal/dark" alt="Total Horse Channel" width="220" height="60" /></a>'}}),live_event_page:(((Bw=ye.pages)==null?void 0:Bw.live_event_page)??ye.live_event_page??tt).parse({renoSbfButtons:{liveScoring:"Live Scoring",schedule:"Schedule"}}),live_helper:((($w=ye.pages)==null?void 0:$w.live_helper)??ye.live_helper??tt).parse({SOURCE_OPTIONS:[{value:"youtube",label:"YouTube",id:"X0uPegBPMakUBC5DMtOXc"},{value:"rumble",label:"Rumble",id:"DSr-wfp6L3xkFSY6qMyr3"},{value:"vimeo",label:"Vimeo",id:"2gppSMyXbaGUGLN0ayeaF"},{value:"box",label:"Box",id:"renBHMzkyrdxbJbd4SvLr"},{value:"other",label:"Other",id:"QJnOMmy8oJFWdEkDkki40"}]}),login:(((Vw=ye.pages)==null?void 0:Vw.login)??ye.login??tt).parse({pageTitle:"Log in to Total Horse Channel",ctaLabel:"Log In",registerPrompt:"Don't have an account?",registerLinkLabel:"Create a free account",registerHref:"/become-member",forgotLabel:"Forgot password?",forgotHref:"/forgot-password"}),low_roller:(((Fw=ye.pages)==null?void 0:Fw.low_roller)??ye.low_roller??tt).parse({title:"2026 Low Roller Reining Classic",dates:"October 2–10, 2026",venue:"Ford Idaho Horse Park • Nampa, Idaho",credit:"Livestreams provided by RainDancer Video on Total Horse Channel",arena1:{name:"Arena 1",startTime:"Start time: 8:00 a.m. Mountain / 10:00 a.m. Eastern",embedSrc:"https://rumble.com/embed/v7e45i8/?pub=mqmap",embedTitle:"2026 Low Roller Reining Classic — Arena 1"},arena2:{name:"Arena 2 (Coverall)",startTime:"Start time: 8:30 a.m. Mountain / 10:30 a.m. Eastern",embedSrc:"https://rumble.com/embed/v7e45so/?pub=mqmap",embedTitle:"2026 Low Roller Reining Classic — Arena 2 (Coverall)"},buttons:{officialSite:"Official Site",arena1Scores:"Arena 1 Scores & Draws",arena2Scores:"Arena 2 Scores & Draws",schedule:"Schedule (PDF)"},scoresDisclaimer:"Scores on the Low Roller site are unofficial."}),membership:(((Ww=ye.pages)==null?void 0:Ww.membership)??ye.membership??tt).parse({TIERS:[{key:"rookie",n
633ame:"Rookie",trophies:1,available:!0,tagline:"Your starting gate on Total Horse Channel.",features:["Watch videos and live events","Comment on videos and live events when logged in","Basic member profile","Add Video or Live (embed or URL — after account is approved)","View Events and Contests","Post photos and updates in Community","Enter the Western Dressage Icon contest during the free launch (submissions Sep 14–19)"],cta:{label:"Create free account",href:"/become-member"},note:"",id:"NvouMrNskZRlvkne19P4T"},{key:"maiden",name:"Maiden",trophies:2,available:!0,tagline:"More ways to participate and share.",features:["Everything in Rookie, plus:","Submit Events on the Events page","Enter contests and giveaways","Community posts (already included in Rookie)"],cta:{label:"Create account",href:"/become-member"},note:"",id:"C_kt93-80ypx--fz8WT0U"},{key:"grand_prix",name:"Grand Prix",trophies:3,available:!0,tagline:"Extra tools for active contributors.",features:["Everything in Maiden, plus:","Extra profile tools as we turn them on","Basic stats on your own videos when analytics ships"],cta:{label:"Create account",href:"/become-member"},note:"",id:"FTzWj64vxvGWg4BjzzQeh"},{key:"invitational",name:"Invitational",trophies:4,available:!1,comingSoon:!0,tagline:"Coming soon.",features:["Everything in Grand Prix, plus:","Details coming soon"],cta:{label:"",href:""},note:"",id:"tafYwXluyHj90d6Km0273"},{key:"championship",name:"Championship",trophies:5,available:!1,comingSoon:!0,tagline:"Coming soon.",features:["Everything in Invitational, plus:","Details coming soon"],cta:{label:"",href:""},note:"Partner accounts may be assigned Championship tier by Total Horse Channel.",id:"871I-znprXWFJCH-1NwCt"}]}),news:(((qw=ye.pages)==null?void 0:qw.news)??ye.news??tt).parse({pageTitle:"News",articles:[{id:"news-1",title:"How Different Horse Race Distances Impact Performance",excerpt:"It's race day, and fans are gathering in the stands excited to see their favourite runners charge towards victory. Understanding how different race distances impact performance can give bettors and fans a real edge.",date:"August 18, 2026",href:"https://totalhorsechannel.com/2026/08/18/how-different-horse-race-distances-impact-performance/",thumbnail:"https://totalhorsechannel.com/wp-content/uploads/gene-devine-U-yHjENTmMg-unsplash-2-360x240.jpg",category:"Horse Racing"},{id:"news-2",title:"2026 WDAA Western Dressage World Championship Show – Entries Close August 25th",excerpt:"2026 WDAA Western Dressage World Championship Show September 15th–19th, 2026 at Lazy E Arena, Guthrie, Oklahoma. Prize list and entry blank now available.",date:"August 5, 2026",href:"https://totalhorsechannel.com/2026/08/05/2026-wdaa-western-dressage-world-championship-show-entries-close-august-25th/",thumbnail:"https://totalhorsechannel.com/wp-content/uploads/WDAA-Entries-Close-500x500-3-360x240.png",category:"Horse Health"},{id:"news-3",title:"6 Summer Horse Racing Events Every Bettor Should Watch",excerpt:"Summer racing brings together many of the world's finest horses, trainers, and jockeys across a series of prestigious festivals. Here are six events you shouldn't miss.",date:"August 4, 2026",href:"https://totalhorsechannel.com/2026/08/04/6-summer-horse-racing-events-every-bettor-should-watch/",thumbnail:"https://totalhorsechannel.com/wp-content/uploads/mathew-schwartz-5qRWQEdK7Sg-unsplash-2-360x240.jpg",category:"Horse Racing"},{id:"news-4",title:"Common Mistakes in Horse Racing Betting and How to Avoid Them",excerpt:"Horse race betting is still one of those gaming activities that constantly encourages many players, especially those who are new to the sport. Learn how to avoid the most common pitfalls.",date:"July 24, 2026",href:"https://totalhorsechannel.com/2026/07/24/common-mistakes-in-horse-racing-betting-and-how-to-avoid-them/",thumbnail:"https://totalhorsechannel.com/wp-content/uploads/Screenshot-2026-07-06-150935-360x240.png",category:"Horse Racing"},{id:"news-5",title:"A Guide to Understanding Horse Racing Odds",excerpt:"Horse racing odds are one of the first things new bettors notice on a race card. They may look confusing at first, but understanding them is simpler than you think.",date:"July 3, 2026",href:"https://totalhorsechannel.com/2026/07/03/a-guide-to-understanding-horse-racing-odds/",thumbnail:"https://totalhorsechannel.com/wp-content/uploads/Screenshot-2026-06-19-151949-360x240.png",category:"Horse Racing"},{id:"news-6",title:"Why Good-Quality Hay Matters for Healthy, Happy Animals",excerpt:"Anyone who keeps horses, rabbits, guinea pigs, cattle, goats or other hay-loving animals knows there's hay, and then there's hay. Quality makes all the difference.",date:"June 22, 2026",href:"https://totalhorsechannel.com/2026/06/22/why-good-quality-hay-matters-for-healthy-happy-animals/",thumbnail:"",category:"Horse Health"},{id:"news-7",title:"The Horse Racing Events That Still Define Prestige",excerpt:"Horse racing has survived because its biggest days feel different from ordinary sport. The best events comb
633ine bloodlines, tactics, weather, and history into something unforgettable.",date:"June 19, 2026",href:"https://totalhorsechannel.com/2026/06/19/the-horse-racing-events-that-still-define-prestige/",thumbnail:"",category:"Horse Racing"},{id:"news-8",title:"Horse Racing Statistics for Beginners",excerpt:"Horse racing is one of the most thrilling sports to watch as each race unfolds a story through numbers, form guides, and speed figures. Here's how to start reading them.",date:"June 2, 2026",href:"https://totalhorsechannel.com/2026/06/02/horse-racing-statistics-for-beginners/",thumbnail:"https://totalhorsechannel.com/wp-content/uploads/jeff-griffith-PaIDqj8otls-unsplash-360x240.jpg",category:"Horse Racing"},{id:"news-9",title:"Key Storylines Shaping 2026 Belmont Stakes Betting Discussions",excerpt:"Horse racing conversations rarely stay focused on speed figures alone ahead of a Belmont Stakes this dramatic. Rivalries, form reversals, and track bias are all in play.",date:"June 2, 2026",href:"https://totalhorsechannel.com/2026/06/02/key-storylines-shaping-2026-belmont-stakes-betting-discussions/",thumbnail:"https://totalhorsechannel.com/wp-content/uploads/mathew-schwartz-5qRWQEdK7Sg-unsplash-1-1-360x240.jpg",category:"Horse Racing"},{id:"news-10",title:"The 2026 Equestrian Competition Calendar: FEI Finals, USEF Showcases, Triple Crown Trail and Welfare Advances",excerpt:"The 2026 equestr
633ian season has already produced a denser, more international competition calendar than any of the previous three years combined.",date:"May 25, 2026",href:"https://totalhorsechannel.com/2026/05/25/the-2026-equestrian-competition-calendar-fei-finals-usef-showcases-triple-crown-trail-and-welfare-advances/",thumbnail:"https://totalhorsechannel.com/wp-content/uploads/Screenshot-2026-05-25-124319-360x240.png",category:"Show Jumping"},{id:"news-11",title:"Why Horse Racing Continues to Be One of the Most Exciting Global Sports",excerpt:"The ground blurs. The horse explodes beneath the rider as the field straightens for the wire. Few sports deliver the same visceral thrill as horse racing.",date:"May 18, 2026",href:"https://totalhorsechannel.com/2026/05/18/why-horse-racing-continues-to-be-one-of-the-most-exciting-global-sports/",thumbnail:"https://totalhorsechannel.com/wp-content/uploads/Screenshot-2026-05-18-103057-360x240.png",category:"Horse Racing"},{id:"news-12",title:"Belmont Stakes 2026 Contenders and Early Odds Watch",excerpt:"As anticipation builds toward the 2026 Belmont Stakes, early futures markets are already offering insight into which horses could contend for the final jewel of the Triple Crown.",date:"May 4, 2026",href:"https://totalhorsechannel.com/2026/05/04/belmont-stakes-2026-contenders-and-early-odds-watch/",thumbnail:"https://totalhorsechannel.com/wp-content/uploads/joshua-adams-o86VhXH4P-o-unsplash-360x240.jpg",category:"Horse Racing"},{id:"news-13",title:"Santa Anita Derby Form Could Be the Key to the Kentucky Derby",excerpt:"The Kentucky Derby is traditionally one of the biggest betting races of the year in North America, and this year's Santa Anita Derby runners are drawing plenty of attention.",date:"April 22, 2026",href:"https://totalhorsechannel.com/2026/04/22/santa-anita-derby-form-could-be-the-key-to-the-kentucky-derby/",thumbnail:"",category:"Horse Racing"},{id:"news-14",title:"Meet the Kentucky Derby Contenders: Top Horses and Their Betting Outlook",excerpt:"The 2026 Kentucky Derby trail is already delivering standout performances from promising three-year-olds across major prep races. Here's a look at the top contenders.",date:"April 6, 2026",href:"https://totalhorsechannel.com/2026/04/06/meet-the-kentucky-derby-contenders-top-horses-and-their-betting-outlook/",thumbnail:"https://totalhorsechannel.com/wp-content/uploads/Screenshot-2026-04-06-142223-360x240.png",category:"Horse Racing"},{id:"news-15",title:"Join the Excitement: Sponsor the 2026 WDAA World Championship Show!",excerpt:"The WDAA World Championship Show is the ultimate celebration of Western Dressage, featuring top riders and horses from over 50 breeds. Sponsorship opportunities are now available.",date:"March 14, 2026",href:"https://totalhorsechannel.com/2026/03/14/join-the-excitement-sponsor-the-2026-wdaa-world-championship-show/",thumbnail:"https://totalhorsechannel.com/wp-content/uploads/Breeders-Crown-Race-3-Oct-1-2023-4224681798-360x240.jpg",category:"Horse Health"},{id:"news-16",title:"A Beginner's Guide to UAE Derby Betting in 2026",excerpt:"Every spring, the racing world turns its attention to Dubai as Meydan Racecourse hosts Dubai World Cup Night, and the UAE Derby draws some of the most exciting three-year-olds in training.",date:"March 10, 2026",href:"https://totalhorsechannel.com/2026/03/10/a-beginners-guide-to-uae-derby-betting-in-2026/",thumbnail:"",category:"Horse Racing"},{id:"news-17",title:"How Digital Platforms Are Reshaping the UK Horse Racing Betting Market",excerpt:"Generations of punters have taken joy in a quick flutter at the races, and this small joy isn't going to disappear — but the way people bet is changing fast.",date:"March 4, 2026",href:"https://totalhorsechannel.com/2026/03/04/how-digital-platforms-are-reshaping-the-uk-horse-racing-betting-market/",thumbnail:"https://totalhorsechannel.com/wp-content/uploads/Screenshot-2026-02-03-135744-360x240.png",category:"Horse Racing"},{id:"news-18",title:"How to Get Into Betting on Horse Racing in Canada",excerpt:"Horse racing has been part of Canadian sporting culture for well over a century, and the betting side of it has evolved dramatically in recent years.",date:"February 19, 2026",href:"https://totalhorsechannel.com/2026/02/19/how-to-get-into-betting-on-horse-racing-in-canada/",thumbnail:"",category:"Horse Racing"},{id:"news-19",title:"Home of Secretariat! Join Me as We Tour Claiborne Farm",excerpt:"On January 28, 2026, Total Horse Channel went live on Rumble to share a wonderful tour of Claiborne Farm — the historic Kentucky farm that was home to Secretariat.",date:"February 2, 2026",href:"https://totalhorsechannel.com/2026/02/02/home-of-secretariat-join-me-as-we-tour-claiborne-farm/",thumbnail:"https://totalhorsechannel.com/wp-content/uploads/Clairborne-Farm-Tour-1-360x240.png",category:"Quarter Horse"},{id:"news-20",title:"For Horse Racing Fans: An Analysis of the History Behind the Canadian Sports Betting Market",excerpt:"For many years, sports betting in Canada was heavily restricted with only parlay-style betting allowed. That has changed significantly in recent years.",date:"January 20, 2026",href:"https://totalhorsechannel.com/2026/01/20/for-horse-racing-fans-an-analysis-of-the-history-behind-the-canadian-sports-betting-market/",thumbnail:"",category:"Horse Racing"}],recentNews:["WDAA 2026 World Championship Show Kicks Off This Weekend","Saratoga Fall Meet Schedule Announced","Horse Park Masters Dressage - Entry List Released","CSI Horov
633ice Show Jumping - Preview","Gulfstream Park Fall Meet Begins September 26","Total Horse Channel Expands Live Coverage for 2026"],SIDEBAR_BANNERS:[{id:"sb-wdaa",src:"/airo-assets/images/sidebar/banner-wdaa-500",alt:"WDAA Western Dressage Association",href:"https://www.wdaa.us"},{id:"sb-di",src:"/airo-assets/images/sidebar/banner-di-logo",alt:"Dressage Illustrated",href:"#"},{id:"sb-skyline",src:"/airo-assets/images/sidebar/banner-skyline",alt:"Skyline Goldsmiths",href:"#"},{id:"sb-tioga",src:"/airo-assets/images/sidebar/banner-tioga-territory",alt:"Tioga Territory",href:"#"},{id:"sb-circa",src:"/airo-assets/images/sidebar/banner-4",alt:"Circa Resort & Casino",href:"#"},{id:"sb-wdaa-date",src:"/airo-assets/images/sidebar/wdaa-save-date",alt:"WDAA 2026 World Championship Show",href:"https://www.wdaa.us"},{id:"sb-thc-banner-sale",src:"/airo-assets/images/sidebar/banner-sale-500",alt:"Total Horse Channel – New Website Special Banner Sale",href:"/advertise"}]}),news_article:(((Yw=ye.pages)==null?void 0:Yw.news_article)??ye.news_article??tt).parse({loadingText:"Loading article…",notFoundTitle:"Article Not Found – Total Horse Channel",notFoundBody:"This article could not be found.",backToNews:"← Back to News",imageCreditLabel:"Image credit",relatedLinksHeading:"Related links",breadcrumbHome:"Home",breadcrumbNews:"News"}),privacy_policy:(((Gw=ye.pages)==null?void 0:Gw.privacy_policy)??ye.privacy_policy??tt).parse({SIDEBAR_BANNERS:[{id:"wdaa",src:"/airo-assets/images/sidebar/wdaa-banner",alt:"WDAA Western Dressage Association",href:"/home/wdaa"},{id:"debbie-brooks",src:"/airo-assets/images/sidebar/debbie-brooks-custom-cuff",alt:"Debbie Brooks Custom Cuffs",href:"https://www.debbiebrooks.com"},{src:"/airo-assets/images/sidebar/banner-sale-500",alt:"Total Horse Channel – New Website Special Banner Sale",href:"/advertise",id:"pp-thc-banner-sale"}],SECTIONS:[{num:"1",heading:"Introduction",subsections:[{body:'Total Horse Channel ("THC") takes your right to privacy seriously and wants you to feel comfortable using the THC website. This Privacy Policy describes the personally identifiable information (referred to as "data" below) that may be collected by this site and how it is used. This policy does not apply to other entities that are not owned or c
633ontrolled by THC, nor to persons who are not employees or agents of THC. Please also read our Terms of Service.',id:"sIx2IIxhmUGzCcwrFmEpX"}],id:"OcncSBYGmB-t-IdQEbw9U"},{num:"2",heading:"Collection of Data",subsections:[{body:"Creating a member account on THC requires a valid email address, a username, and a display name. You are not required to provide any other information if you do not wish to. Please be aware that the username and display name you choose, the email address you provide, and any other information you submit may render you personally identifiable and may be displayed on this website — intentionally (based on choices you make, such as your public profile at totalhorsechannel.com/u/username) or unintentionally (such as following a successful intrusion by a third party).",id:"PSKTcbgwM8a7jN9CZ3--E"},{body:"As with many websites, THC may also automatically receive general information contained in server log files, such as your IP address and cookie information. Information about how advertising may be served on this site is set forth in Section 4 below.",id:"rRi9yxUrTExCOzdWTTZZr"}],id:"YniH85junuEK7sx6cEH5I"},{num:"3",heading:"Use of Data",subsections:[{body:"Data may be used to customize and improve your user experience on this site. Efforts will be made to prevent your data from being made available to third parties unless:",list:["Provided for otherwise in this Privacy Policy;","Your consent is obtained, such as when you choose to opt in or opt out of data sharing;","A service provided on our site requires interaction with a third party or is provided by a third party, such as an application service provider;","Pursuant to legal action or law enforcement;","It is found that your use of this site violates this policy, the Terms of Service, or other usage guidelines, or if it is deemed reasonably necessary by THC to protect its legal rights and/or property; or","This site is purchased by a third party, in which case that third party will be able to use the data in the same manner as set forth in this policy."],id:"leH7cNd9uLHry0VtNYCIj"},{body:"If you use links on this website to visit other websites, you are advised to read the privacy policies of those sites.",id:"qhVDS8XWYZVcxa54KxZid"}],id:"CDYUImHzQJv6LrJpAxynj"},{num:"4",heading:"Cookies",subsections:[{body:"Like many websites, THC sets and uses cookies to enhance your user experience — for example, to retain your session and preferences. Advertisements may appear on this website and, if so, may set and access cookies on your computer; such cookies are subject to the privacy policy of the parties providing the advertisement. However, those advertising parties do not have access to THC's cookies. These parties usually use non-personally-identifiable or anonymous codes to obtain information about your visits to this site.",id:"dWbuzmaKmAwtSQtAIX6ge"}],id:"oZZuSGuACru_pJ8ZtD5tr"},{num:"5",heading:"Minors",subsections:[{body:"Children under the age of 13 are not permitted to become registered members of this site. Users between 13 and 17 must have a parent or legal guardian's permission to register and use the THC Service. For more information, see Section 2 of our Terms of Service or contact us at [email protected].",id:"_ZMU2k20phMi-BBFjfneM"}],id:"mJq71uXd8J181BUWqavQa"},{num:"6",heading:"Your Account — Editing and Deletion",subsections:[{body:"You may update your account information (including your display name and avatar) at any time by visiting your profile page at totalhorsechannel.com/u/username. You may also change your password from your profile page.",id:"K5oUfDoR6UlrO2hF60dK_"},{body:"You may request deletion of your account by contacting us at [email protected]. Content you have submitted — such as video links or comments — may remain on the site at THC's discretion after your account is deleted. Please see the Terms of Service for more information.",id:"qVC-LXkbu5XxWbdasY-Q1"}],id:"E1cESqvjVBd6VgGZRg-rc"},{num:"7",heading:"Content Submitted to THC",subsections:[{body:"THC does not host video files. Members submit watch URLs or iframe embeds from third-party platforms such as YouTube, Rumble, Vimeo, or similar services. By submitting a link or embed, you represent that you have the right to do so. THC may remove submitted content at any time for any reason, including violation of the Terms of Service or Community Guidelines.",id:"8fakFnCCtWjFmVDsH6NZO"}],id:"TJ9Ewt5vzjO38AC6YH_y7"},{num:"8",heading:"Donations",subsections:[{body:"Voluntary donations to THC may be made via PayPal, Venmo, or Zelle. THC does not collect or store payment card information. Donation transactions are processed entirely by the respective payment platforms and are subject to their privacy policies.",id:"fcKBObZDibVyAAb0Cnvs_"}],id:"_EXVaMG_dMTrftfaw5NRr"},{num:"9",heading:"Changes to This Privacy Policy",subsections:[{body:"THC may update this policy from time to time. You will be notified of substantial changes by a prominent announcement on the site and/or by a message sent to the email address associated with your account. Continued use of the THC Service after changes are posted constitutes your acceptance of the revised policy.",id:"GlglKXcaToG9hWbu6Uf_d"}],id:"lfyQ29heEU-5zSDRsCeOk"},{num:"10",heading:"No Guarantees",subsections:[{body:"While this Privacy Policy states standards for the maintenance of data, and while efforts will be made to meet those standards, THC cannot guarantee compliance in all circumstances. There may be factors beyond THC's control that result in disclosure of data. Consequently, THC offers no warranties or representations regarding the maintenance or non-disclosure of data.",id:"wLuAz6Qq9X96UUCm2Fves"}],id:"Mn6piefqIx_5YS5lnwe-3"},{num:"11",heading:"Contact Information",subsections:[{body:"If you have any questions about this Privacy Policy or the THC website, please contact us:",list:["Email: [email protected]","Mail: Total Horse Channel, PO Box 773011, Ocala, FL 34477-3011"],id:"fmehUn2CQOBkTUY-vAry7"}],id:"Wae68U05exs8FnlMVP8KE"}]}),puzzles:(((Zw=ye.pages)==null?void 0:Zw.puzzles)??ye.puzzles??tt).parse({pageTitle:"Horse Puzzles",intro:"Play free jigsaw puzzles made from Total Horse Channel photos and fan favorites. Pick a picture, choose your piece count, and play.",playAllUrl:"https://www.jspuzzles.com/en/gallery/users/U26110/",footerLinkText:"More puzzles on JSPuzzles",puzzles:[{id:"p-1",title:"Western Dressage World Championship Show",image:"https://www.jspuzzles.com/puzzlewebp400ratio268/userpic3-puzzle-890364.webp",playUrl:"https://www.jspuzzles.com/en/horse-puzzles?puzzleid=890364"},{id:"p-2",title:"2018 Western Dressage World Championship Show",image:"https://www.jspuzzles.com/puzzlewebp400ratio268/userpic3-puzzle-890361.webp",playUrl:"https://www.jspuzzles.com/en/horse-puzzles?puzzleid=890361"},{id:"p-3",title:"Wagon Wheel Ranch",image:"https://www.jspuzzles.com/puzzlewebp400ratio268/userpic3-puzzle-889388.webp",playUrl:"https://www.jspuzzles.com/en/horse-puzzles?puzzleid=889388"},{id:"p-4",title:"Bahamian Squall | Thoroughbred Stallion",image:"https://www.jspuzzles.com/puzzlewebp400ratio268/userpic3-puzzle-889385.webp",playUrl:"https://www.jspuzzles.com/en/horse-puzzles?puzzleid=889385"},{id:"p-5",title:"Native Costume",image:"https://www.jspuzzles.com/puzzlewebp400ratio268/userpic3-puzzle-816459.webp",playUrl:"https://www.jspuzzles.com/en/horse-puzzles?puzzleid=816459"},{id:"p-6",title:"Arabian Side-Saddle",image:"https://www.jspuzzles.com/puzzlewebp400ratio268/userpic3-puzzle-816458.webp",playUrl:"https://www.jspuzzles.com/en/horse-puzzles?puzzleid=816458"},{id:"p-7",title:"Region 12 Arabian",image:"https://www.jspuzzles.com/puzzlewebp400ratio268/userpic3-puzzle-816456.webp",playUrl:"https://www.jspuzzles.com/en/horse-puzzles?puzzleid=816456"},{id:"p-8",title:"Live Oak International",image:"https://www.jspuzzles.com/puzzlewebp400ratio268/userpic3-puzzle-666624.webp",playUrl:"https://www.jspuzzles.com/en/horse-puzzles?puzzleid=666624"}
633,{id:"p-9",title:"Horse Rider Live Oak International 2020",image:"https://www.jspuzzles.com/puzzlewebp400ratio268/userpic3-puzzle-666623.webp",playUrl:"https://www.jspuzzles.com/en/horse-puzzles?puzzleid=666623"},{id:"p-10",title:"2019 WDAA World Show",image:"https://www.jspuzzles.com/puzzlewebp400ratio268/userpic3-puzzle-665917.webp",playUrl:"https://www.jspuzzles.com/en/farm-puzzles?puzzleid=665917"},{id:"p-11",title:"Gypsy Vanner Horse",image:"https://www.jspuzzles.com/puzzlewebp400ratio268/userpic3-puzzle-665916.webp",playUrl:"https://www.jspuzzles.com/en/horse-puzzles?puzzleid=665916"},{id:"p-12",title:"Ribbon Garland",image:"https://www.jspuzzles.com/puzzlewebp400ratio268/userpic3-puzzle-665915.webp",playUrl:"https://www.jspuzzles.com/en/flower-puzzles?puzzleid=665915"}]}),rumble:(((Jw=ye.pages)==null?void 0:Jw.rumble)??ye.rumble??tt).parse({headline:"Total Horse Channel on Rumble",subtext:"Watch Total Horse Channel livestreams on Rumble. This is where we stream most often.",ctaLabel:"Open our Rumble channel",channelUrl:"https://rumble.com/c/TotalHorseChannel",latestStreamsHeading:"Latest Streams",latestStreamsSubtext:"Live events, replays, and more — streamed regularly on Rumble.",followLabel:"Follow on Rumble",watchHeading:"Watch on Rumble",watchBody:"This is our primary streaming platform. Subscribe on Rumble to get notified every time we go live."}),sponsors_partners:(((Xw=ye.pages)==null?void 0:Xw.sponsors_partners)??ye.sponsors_partners??tt).parse({pageTitle:"Partners",metaDescription:"Meet the sponsors and partners of Total Horse Channel — the horse industry's premier livestream and video destination.",intro:{heading:"Total Horse Channel",body:[{id:"intro-p1",text:"Total Horse Channel has covered the horse industry since 2006. We started as The Arabian, brought Arabian show coverage to YouTube early, and became Total Horse Channel in 2010. Since then we have streamed hundreds of events and worked with associations, tracks, farms, and video producers across breeds and disciplines."},{id:"intro-p2",text:"This new site is where that coverage lives now: live events, replays, and the people who make them, in one horse-only place."},{id:"intro-p3",text:"If you want to reach that audience, advertise with us or join the partner list below."}]},tiers:[{id:"tier-bronze",name:"Bronze",price:"$600 / year",benefits:["Logo + link on Sponsors page","2 Article posts"]},{id:"tier-silver",name:"Silver",price:"$1,200 / year",benefits:["All Bronze benefits","Rotating 500x500 banner","4 Article posts"]},{id:"tier-gold",name:"Gold",price:"$2,500 / year",benefits:["All Silver benefits","1920x540 Header Banner","8 Article posts","6 Social Media Posts Across all Platforms"]},{id:"tier-platinum",name:"Platinum / Launch Partner",price:"$5,000+ or custom",benefits:["All Gold benefits","Free Championship Tier on the new platform","Dedicated sponsor page","12 Article Posts","Official Sponsor of Discover The Industry Livestreams"]}],cta:{heading:"Ready to Become a Sponsor or Partner?",body:"We offer flexible sponsorship packages and custom opportunities. Whether you want increased visibility, banner placement, article features, or premium positioning on the new platform, we can create a package that delivers real value for your business.",contactLabel:"Contact us today to discuss how we can work together.",email:"[email protected]",phone:"404 827-8340"},partnersHeading:"2026 Sponsors & Partners",partners:[{id:"partner-wdaa",name:"Western Dressage Association of America (WDAA)",logoSrc:"/airo-assets/images/sponsors/wdaa",logoAlt:"Western Dressage Association of America logo",website:"https://www.westerndressageassociation.org/",websiteLabel:"Western Dressage Association of America (WDAA)",ctaLabel:"",ctaHref:"",body:[{id:"wdaa-p1",text:"The Western Dressage Association of America (WDAA), founded in 2010, is dedicated to promoting and advancing Western Dressage by blending classical dressage principles with Western riding techniques. Through education, structured tests, competitions, and strong community support, WDAA continues to grow the sport and strengthen horse-and-rider partnerships."},{id:"wdaa-p2",text:"Total Horse Channel has proudly served as the Official Livestream Partner for the WDAA Western Dressage World Championship Show since 2018, helping bring this world-class event to a global audience."},{id:"wdaa-p3",text:"Watch the 2026 WDAA Western Dressage World Championship Show LIVE on Total Horse Channel September 15th – 19th, 2026"}]},{id:"partner-321-action-video",name:"321 Action Video",logoSrc:"/airo-assets/images/sponsors/321-action-video",logoAlt:"321 Action Video logo",website:"https://www.321actionvideo.com/",websiteLabel:"321actionvideo.com",ctaLabel:"",ctaHref:"",body:[{id:"av-p1",text:"321 Action Video, led by Michael Cloward, has been a trusted video partner of Total Horse Channel for more than a decade. Michael's team is known for clear, professional coverage of barrel racing and CMSA Cowboy Mounted Shooting events."},{id:"av-p2",text:"We are proud to share 321 Action Video's work with the horse community and grateful for more than ten years of covering these events together."}]},{id:"partner-debbie-brooks",name:"Debbie Brooks",logoSrc:"/airo-assets/images/sponsors/debbie-brooks-ny",logoAlt:"Debbie Brooks Equestrian Collection",website:"https://www.debbiebrooks.com/",websiteLabel:"Debbie Brooks",ctaLabel:"Shop Now",ctaHref:"https://www.debbiebrooks.com/",body:[{id:"db-p1",text:"New York-based designer and longtime partner of Total Horse Channel since 2019."},{id:"db-p2",text:"Debbie Brooks is a celebrated designer known for her unique wearable art, including handbags and accessories. She gained national recognition as a contestant on Shark Tank, where her creative vision and entrepreneurial spirit impressed viewers and investors alike."},{id:"db-p3",text:"Her equestrian collection features beautiful designs inspired by horse riding and the equestrian lifestyle, perfectly blending artistic flair with a deep passion for the sport."},{id:"db-p4",text:"We are proud to have Debbie Brooks as a valued partner and sponsor of Total Horse Channel."}]},{id:"partner-nsb",name:"National Sports Broadcasting",logoSrc:"/airo-assets/images/sponsors/national-sports-broadcasting",logoAlt:"National Sports Broadcasting logo",website:"https://www.nationalsportsbroadcasting.com/",websiteLabel:"National Sports Broadcasting",ctaLabel:"",ctaHref:"",body:[{id:"nsb-p1",text:"National Sports Broadcasting is a premier equine production company specializing in high-quality livestreaming and broadcast services for major horse shows and events."},{id:"nsb-p2",text:"Led by Bryan Morgan, the company has been a trusted partner of Total Horse Channel for over a decade. Bryan has worked closely with us to deliver professional coverage of numerous events, including the Quarter Horse Congress and AMHA World Miniature Horse Show. His deep technical expertise and understanding of equine sports have been instrumental in helping us bring world-class competition to a global audience."},{id:"nsb-p3",text:"We are proud to continue our long-standing partnership with National Sports Broadcasting as we build the future of equine media."}]},{id:"partner-raindancer",name:"RainDancer Video",logoSrc:"/airo-assets/images/sponsors/raindancer-video",logoAlt:"RainDancer Video logo",website:"https://www.raindancervideo.com/",websiteLabel:"RainDancer Video",ctaLabel:"",ctaHref:"",body:[{id:"rd-p1",text:"RainDancer Video, led by Dan Browning, has been a trusted production partner of Total Horse Channel for over a decade."},{id:"rd-p2",text:"Known for delivering high-quality, professional livestreams, RainDancer Video has captured some of the biggest events in the Western performance horse world, including The Best Little Derby in the West and the prestigious Reno Snaffle Bit Futurity."},{id:"rd-p3",text:"Their technical expertise and dedication to showcasing the sport at the highest level have been instrumental in helping Total Horse Channel bring world-class competition to audie
633nces worldwide."},{id:"rd-p4",text:"We are proud to have RainDancer Video as a longtime partner."}]},{id:"partner-seehorse",name:"Seehorse Video",logoSrc:"/airo-assets/images/sponsors/seehorse-video",logoAlt:"Seehorse Video logo",website:"https://www.seehorsevideos.com/",websiteLabel:"Seehorse Video",ctaLabel:"",ctaHref:"",body:[{id:"sh-p1",text:"Seehorse Video, owned by Scott Cooper, has been a valued production partner of Total Horse Channel for over 20 years — since the very beginning of our journey."},{id:"sh-p2",text:"Scott has played a key role in helping us share high-quality coverage of Arabian, Half-Arabian, National Show Horse, and American Saddlebred events. His work includes livestreaming and recording major shows such as the Region 12 Arabian & Half-Arabian Championship Show, National Show Horse Finals, and the River Ridge Charity Horse Show."},{id:"sh-p3",text:"We are deeply grateful for Scott's longtime dedication and expertise in bringing these beautiful breeds and disciplines to audiences worldwide."}]},{id:"partner-showtime",name:"Showtime Training Center",logoSrc:"/airo-assets/images/sponsors/showtime-training-center",logoAlt:"Showtime Training Center logo",website:"https://www.showtimetrainingcenter.com/",websiteLabel:"Showtime Training Center",ctaLabel:"",ctaHref:"",body:[{id:"st-p1",text:"Showtime Training Center, located in Newnan, Georgia, is a respected full-service training facility specializing in Arabian, Half-Arabian, National Show Horse, and American Saddlebred show horses."},{id:"st-p2",text:"Owned and operated by Tish Kondas (along with Margaret and Randy Hankins), Showtime Training Center is known for its quality training programs and successful show horses."},{id:"st-p3",text:'Tish Kondas was one of the very first people interviewed when Total Horse Channel began as "The Arabian" back in 2006. We are grateful for her early support and continued friendship over the years.'}]},{id:"partner-horse-capital",name:"The Horse Capital Tours",logoSrc:"/airo-assets/images/sponsors/horse-capital-tours",logoAlt:"The Horse Capital Tours logo",website:"https://www.thehorsecapitaltours.com/",websiteLabel:"thehorsecapitaltours.com",ctaLabel:"Book Your Tour Today",ctaHref:"https://www.thehorsecapitaltours.com/",body:[{id:"hct-p1",text:"The Horse Capital Tours, owned by Jann Fitzgerald, offers unique, behind-the-scenes experiences showcasing the very best of Ocala, Florida — the Horse Capital of the World."},{id:"hct-p2",text:"From world-class breeding farms and training centers to premier sales facilities, Jann's tours give visitors from around the globe an unforgettable look into the heart of the equine industry. Popular stops include Ocala Breeders' Sales Company (OBS) and Niall Brennan Stables, among many others."},{id:"hct-p3",text:"Colleen first met Jann at a meet-and-greet at Tamarian Farms shortly after they purchased the property. They instantly connected, and before long Colleen was proudly conducting tours for The Horse Capital Tours. This experience remains one of her greatest passions — sharing the beauty, dedication, and magic of Ocala's horse community with people from all walks of life."},{id:"hct-p4",text:"We are grateful for Jann's friendship and continued support over the years."}]}],SIDEBAR_BANNERS:[{id:"sp-sb-debbie",src:"/airo-assets/images/sidebar/debbie-brooks-custom-cuff",alt:"Debbie Brooks New York – Custom Horse Cuffs",href:"https://www.debbiebrooks.com/"},{id:"sp-sb-wdaa",src:"/airo-assets/images/sidebar/banner-wdaa-500",alt:"WDAA Western Dressage Association",href:"https://www.westerndressageassociation.org/"},{id:"sp-sb-circa",src:"/airo-assets/images/sidebar/banner-4",alt:"Circa Resort & Casino",href:"https://www.circalasvegas.com/"},{id:"sp-sb-tioga",src:"/airo-assets/images/sidebar/banner-tioga-territory",alt:"Tioga Territory",href:"https://www.tiogaterritory.com/store/WDAA.html"},{id:"sp-sb-di",src:"/airo-assets/images/sidebar/banner-di-logo",alt:"Dressage Illustrated",href:"https://dressageillustrated.com/collections/riders-wdaa-western-dressage-diagram-books"},{id:"sp-sb-skyline",src:"/airo-assets/images/sidebar/banner-skyline",alt:"Skyline Goldsmiths",href:"https://www.skylinevaquero.com/"},{src:"/airo-assets/images/sidebar/banner-sale-500",alt:"Total Horse Channel – New Website Special Banner Sale",href:"/advertise",id:"sp-thc-banner-sale"}]}),tech_support:(((Qw=ye.pages)==null?void 0:Qw.tech_support)??ye.tech_support??tt).parse({pageTitle:"Technical Support",metaDescription:"Get technical support for Total Horse Channel — troubleshooting tips for live streams and videos, browser requirements, connection speed guidance, and direct contact with our support team.",intro:{heading:"Having Trouble Viewing Live Streams or Videos?",body:"We want every viewer to have a smooth, high-quality experience on Total Horse Channel. If you are running into issues, the steps below resolve the vast majority of playback problems. If you still need help after working through these steps, our support team is standing by."},steps:[{id:"step-requirements",number:"1",title:"Minimum Technical Requirements",body:"Please confirm your device meets the minimum requirements to view our videos and live events. We support all modern browsers including Chrome, Firefox, Safari, and Edge — any version released in the last three years will work. Internet Explorer is no longer supported.",tips:[]},{id:"step-connection",number:"2",title:"Internet Connection Speed",body:"For a reliable viewing experience we recommend a download speed of at least 5 Mbps for standard video and 10 Mbps or higher for HD live streams. You can test your connection speed at SpeedTest.net.",tips:[{id:"tip-wifi",text:"If you are on a mobile device, connect to Wi-Fi whenever possible for the best experience."},{id:"tip-mobile",text:"If Wi-Fi is not available, a fast 4G LTE or 5G connection is recommended for live event viewing."},{id:"tip-close",text:"Close other applications or browser tabs that may be using bandwidth while you watch."}]},{id:"step-browser",number:"3",title:"Browser & Device Tips",body:"If your connection speed looks good but playback is still choppy or failing, try the following:",tips:[{id:"tip-refresh",text:"Refresh the page and allow the player to fully load before pressing play."},{id:"tip-restart-browser",text:"Quit and restart your web browser, then return to the video."},{id:"tip-different-browser",text:"Try a different browser — Chrome and Firefox tend to offer the most consistent playback."},{id:"tip-restart-device",text:"Restart your computer or mobile device to clear any temporary issues."},{id:"tip-clear-cache",text:"Clear your browser cache and cookies, then reload the page."}]},{id:"step-still-stuck",number:"4",title:"Still Not Working?",body:"If you have worked through the steps above and are still experiencing issues, please reach out to our technical support team directly. Include a brief description of the problem, the device and browser you are using, and the name of the video or event you were trying to watch — this helps us resolve your issue as quickly as possible.",tips:[]}],SIDEBAR_BANNERS:[{id:"sb-wdaa",src:"/airo-assets/images/sidebar/wdaa-banner",alt:"WDAA Western Dressage Association",href:"/home/wdaa"},{id:"sb-debbie-brooks",src:"/airo-assets/images/sidebar/debbie-brooks-custom-cuff",alt:"Debbie Brooks New York – Custom Horse Cuffs",href:"https://www.debbiebrooks.com/"},{src:"/airo-assets/images/sidebar/banner-sale-500",alt:"Total Horse Channel – New Website Special Banner Sale",href:"/advertise",id:"ts-thc-banner-sale"}]}),terms_of_service:(((e1=ye.pages)==null?void 0:e1.terms_of_service)??ye.terms_of_service??tt).parse({SIDEBAR_BANNERS:[{id:"wdaa",src:"/airo-assets/images/sidebar/wdaa-banner",alt:"WDAA Western Dressage Association",href:"/home/wdaa"},{id:"debbie-brooks",src:"/airo-assets/images/sidebar/debbie-brooks-custom-cuff",alt:"Debbie Brooks Custom Cuffs",href:"https://www.debbiebrooks.com"},{src:"/airo-assets/images/sidebar/banner-sale-500",alt:"Total Horse Channel – New Website Special Banner Sale",href:"/advertise",id:"tos-thc-banner-sale"}],SECTIONS:[{num:"1",heading:"Agreement",subsections:[{label:"A.",body:"By accessing the THC Site or using the THC Service, you acknowledge that you have read, understand and agree to be bound by these Terms, including the Privacy Policy incorporated herein, which form an agreement between you and THC that is effective as if you had signed it. YOUR ACCESS TO AND USE OF THE THC SERVICE, AND ITS CONTENT ARE SUBJECT TO ALL TERMS CONTAINED HEREIN AND ALL APPLICABLE LAWS AND REGULATIONS. IF YOU DO NOT AGREE TO THESE TERMS, YOUR PERMISSION TO ACCESS OR USE THE WEBSITE IS AUTOMATICALLY AND IMMEDIATELY REVOKED AND YOU MUST DISCONTINUE USE OF THE WEBSITE IMMEDIATELY.",id:"dHd9WakvY20_1ZIEi8p5S"},{label:"B.",body:'THC may revise the Terms at any time by posting the revised Terms on the THC Site, and you agree that your use of the THC Service after such changes will constitute your acceptance of such changes. You can determine when the Terms were last revised by referring to the "Last Revised" date under the title of the Terms. THC will not personally notify you when changes are made to these Terms. THC may make changes to the THC Site or Content, products, services or features of the THC Service at any time. Nothing in these Terms shall be deemed to confer any third-party rights or benef
633its. You understand and agree that THC may discontinue or restrict your use of the THC Service at any time for any reason or no reason with or without notice.',id:"uadKXKgI9mYAuv3C1qHn1"}],id:"e2XKqSBJi-hb-BgQYfzyi"},{num:"2",heading:"Permitted Users of the THC Service",subsections:[{label:"A.",body:"Persons 18 years of age or older, or emancipated minors who are fully able and competent to enter into the terms, conditions, obligations, affirmations, representations, and warranties set forth in these Terms of Service, and to abide by and comply with these Terms of Service, are permitted to agree to these Terms on their own behalf.",id:"u7_6QA_Z-QAPwwVzbbCdC"},{label:"B.",body:"You must be at least 13 years old to use the THC Service. If you are at least 13 but are still a minor (this depends on where you live), you must have your parent or legal guardian's permission to use the THC Service. Please have your parent(s) read this Agreement with you. Parents must be fully able and competent to enter into the terms, conditions, obligations, affirmations, representations, and warranties set forth in these Terms of Service, and to abide by and comply with these Terms of Service.",id:"FrOiJAtKGXXTydT0fTcV2"},{label:"C.",body:"Parent(s): by granting your child permission to use the THC Service, you agree to the terms of this Agreement on behalf of your child. You are responsible for monitoring and supervising your child's use of the THC Service. If your child is using the THC Service and is either under 13 or does not have your permission, please contact us immediately so that we can disable your child's access. Questions: [email protected]",email:!0,id:"LzW08wKwyNpDF93NE0t0r"}],id:"dh4iKZlcqeTVT1OxEGLf7"},{num:"3",heading:"Content — How THC Works",subsections:[{label:"A.",body:'"Content" includes text, scripts, graphics, photos, links, video embeds, watch URLs, images, audio, audiovisual combinations, interactive features, and other materials you may view on, access through, or contribute to the THC Site.',id:"EuZ_H12eZRvSTuZm7Ziwd"},{label:"B.",body:'Total Horse Channel does not host video files on its servers. Members submit watch URLs or iframe embeds from third-party platforms such as YouTube, Rumble, Vimeo, Box, or similar services. When these Terms refer to "uploading" or "submitting" Content, that means submitting a link or embed — not storing a video file on THC servers.',id:"t-hTX85nLXO-yGoCDh271"},{label:"C.",body:'The Content, and the trademarks, service marks and logos ("Marks") on the THC Service, are owned by or licensed to THC, subject to copyright and other intellectual property rights under the law.',id:"jiULF6AEXjWSCgO2mQsib"},{label:"D.",body:"The THC Site may contain links to third-party websites that are not owned or c
633ontrolled by THC. THC has no control over, and assumes no responsibility for, the content, privacy policies, or practices of any third-party websites. By using the THC Service you expressly relieve THC from any and all liability arising from your use of any third-party website. THC encourages you to read the terms and privacy policy of each other website you visit.",id:"aDpgT-JXsOWViuK83yV66"},{label:"E.",body:"Content is provided to you AS IS. You may access Content for your information and personal use solely as intended through the provided functionality of the THC Service and as permitted under these Terms. You shall not copy, reproduce, distribute, transmit, broadcast, display, sell, license, or otherwise exploit any Content for any other purposes without the prior written consent of THC or the respective licensors of the Content.",id:"MwvhCrrMkjpR4UiLtQmW3"},{label:"F.",body:"THC does not endorse any Content submitted to the THC Service by any user or other licensor, or any opinion, recommendation, or advice expressed therein, and THC expressly disclaims any and all liability in connection with Content. THC does not permit copyright infringing activities and will remove Content if properly notified that such Content infringes on another's intellectual property rights.",id:"oLZd0H86Yqy9DaAqMVexQ"},{label:"G.",body:"THC reserves the right to review Content to accept or deny placement on the THC Site, and to remove Content or close accounts without advance notice.",id:"ukmqo4Jh6wAxTMgOK6i_M"},{label:"H.",body:"You agree that Content you submit will not contain third-party copyrighted material or material subject to other proprietary rights, unless you have permission from the rightful owner or are otherwise legally entitled to submit it. You agree not to submit any Content that:",list:["Infringes any third party's copyrights or other rights (e.g., trademark, privacy rights, etc.);","Contains sexually explicit content or pornography;","Contains hateful, defamatory, or discriminatory content or incites hatred against any individual or group;","Exploits minors;","Depicts unlawful acts or extreme violence;","Depicts animal cruelty or extreme violence towards animals;","Promotes fraudulent schemes, MLM schemes, get-rich-quick schemes, online gambling, cash gifting, work-from-home ventures, or other dubious money-making ventures; or","Violates any law."],id:"yXvmFx29dv-JGUyuAZG0R"},{label:"I.",body:"You understand that THC does not guarantee any confidentiality with respect to any Content that you submit.",id:"EPOKjhLdw0dcqNUsytgN_"},{label:"J.",body:"You shall be solely responsible for your own Content and the consequences of submitting and publishing your Content on the THC Service. You affirm, represent, and warrant that you own or have the necessary licenses, rights, consents, and permissions to publish Content you submit; and you license to THC all patent, trademark, trade secret, copyright or other proprietary rights in and to such Content for publication on the THC Service pursuant to these Terms of Service.",id:"caCT9CRlz8-LSiUoWQYrc"},{label:"K.",body:"Even though you retain all of your ownership rights in your Content, by submitting Content to THC you hereby grant THC a worldwide, non-exclusive, royalty-free, sublicenseable and transferable license to use, reproduce, distribute, prepare derivative works of, display, and perform the Content in connection with the THC Service and THC's business. You also hereby grant each user of the THC Service a non-exclusive license to access your Content through the THC Service as permitted through the functionality of the Service and under these Terms. Licenses granted in video Content terminate within a commercially reasonable time after you remove or delete your submission. Licenses granted in user comments are perpetual and irrevocable.",id:"J7F4gGtbrt9gmh9nvd1Zc"},{label:"L.",body:"You understand that when using the THC Service you will be exposed to Content from a variety of sources, and that THC is not responsible for the accuracy, usefulness, safety, or intellectual property rights of or relating to such Content. To the extent permitted by applicable law, you agree to indemnify and hold harmless THC, its owners, operators, affiliates, licensors, and licensees regarding all matters related to your use of the THC Service.",id:"m-Fb9iq8qsoiu26EoZsgj"}],id:"09_WsnAHavZZiDVl5kmpQ"},{num:"4",heading:"Permissions and Restrictions",subsections:[{label:"A.",body:"THC grants you permission to access and use the THC Service as set forth in these Terms, provided that you agree not to distribute any part of the THC Service or Content without prior written authorization from THC, unless THC makes available the means for such distribution.",id:"Wy-dnnO3wdOC5W67TNe4x"},{label:"B.",body:"You agree not to alter or modify any part of the THC Service or THC Site.",id:"VC3J8TCuT-OhUiDR9V4Eh"},{label:"C.",body:"You agree not to use the THC Service for the following commercial uses without prior written approval from THC: (1) the sale of access to the Service; (2) the sale of advertising, sponsorships, or promotions placed on or within the THC Service or Content; or (3) the sale of advertising on any page containing Content delivered via the THC Service, unless other material not obtained from THC a
633ppears on the same page and is of sufficient value to be the basis for such sales.",id:"i-n0Xr1Kay4O8cVSP8rXM"},{label:"D.",body:"Permitted commercial uses include: submitting a link or embed to promote your own horse-related business or artistic enterprise; showing THC Site Content on an ad-enabled blog or website subject to the restrictions above; or any use THC expressly authorizes in writing.",id:"whjQ2HNHIZN8-M9yeYhmB"},{label:"E.",body:"You agree not to circumvent, disable or otherwise interfere with security-related features of the Service or features that prevent or restrict use or copying of any Content.",id:"tjI-XZ2WEg01CIiDze7aS"},{label:"F.",body:"You agree not to use or launch any automated system — including robots, bots, spiders, or offline readers — that accesses the THC Service in a manner that sends more requests to THC servers than a human can reasonably produce using a conventional web browser. THC grants public search engine operators permission to use spiders solely to create publicly available searchable indices of the materials. You agree not to collect or harvest any personally identifiable information from the THC Service, nor to use the communication systems provided by the Service for any commercial solicitation purposes.",id:"H5idpWLsvM_bJdF9mzNOD"},{label:"G.",body:"In your use of the THC Service, you will comply with all applicable laws. THC reserves the right to discontinue any aspect of the Service at any time.",id:"pfbTZhn1LXOfCzYnHzOLX"}],id:"WkHOkXLRu-u8ylxZkBovr"},{num:"5",heading:"Accounts",subsections:[{label:"A.",body:"To access features such as submitting Content, you must create a user account. Accounts include a username, display name, and a public profile at totalhorsechannel.com/u/username. You may never use another's account without permission. When creating your account, you must provide accurate and complete information. You are solely responsible for the activity that occurs on your account, and you must keep your account password secure. You must notify THC immediately of any breach of security or unauthorized use of your account.",id:"o5L2ZFsoxXNnER40xKS1t"},{label:"B.",body:"Although THC will not be liable for your losses caused by any unauthorized use of your account, you may be liable for the losses of THC or others due to such unauthorized use.",id:"pC9-mN4dyanpfHV1QNjb5"}],id:"WGXexBqETYpfHo__G-zme"},{num:"6",heading:"Code of Conduct",subsections:[{label:"",body:"In using the THC Service, you must behave in a civil and respectful manner at all times. You will not:",list:["Act in a deceptive manner by, among other things, impersonating any person;","Harass or stalk any other person;","Harm or exploit minors;","Distribute spam;","Collect information about others without their consent; or","Advertise or solicit others to purchase any product or service within the THC Site (unless you are an official THC partner or advertiser with a written agreement with THC)."],id:"ZvccAE3ysf9re0REPxe0w"},{label:"",body:"THC has the right, but not the obligation, to monitor all conduct on and Content submitted to the THC Service.",id:"Pbbaut9ueQtdAkQ4PE2y1"}],id:"Yk7TPktg9L9x18ulUMPvB"},{num:"7",heading:"Donations",subsections:[{label:"",body:"Voluntary donations to support Total Horse Channel may be made via PayPal, Venmo, or Zelle. Donations are not purchases of goods or services and are non-refundable. THC does not operate a paid membership checkout or auction service.",id:"pNZP52CYWIsY_oYBPGGGv"}],id:"Pc_9J35iWN6nmp_e63TIL"},{num:"8",heading:"WDAA Video Orders",subsections:[{label:"",body:"WDAA video orders are processed through the existing WDAA order process and are not a THC store or THC checkout. THC is not a party to WDAA video order transactions. For questions about WDAA video orders, contact WDAA directly.",id:"jVX_SMp25ocMvYTtq0C0v"}],id:"2xdzpMGsdOvy81WHgBybV"},{num:"9",heading:"Term, Termination, and Account Deletion",subsections:[{label:"A.",body:"TERM: This Agreement begins on the date you first use the THC Service and continues as long as you have an account with us.",id:"euOtVAxgyuoKMD1XafEqH"}
633,{label:"B.",body:"ACCOUNT DELETION: You may request deletion of your account at any time by contacting [email protected].",email:!0,id:"9-Vs1juzQVll-7v1P92ib"},{label:"C.",body:"THC will terminate a user's access to the Service if, under appropriate circumstances, the user is determined to be a repeat infringer.",id:"kcDfOOAD1o3lnpPNasxXU"},{label:"D.",body:"THC reserves the right to decide whether Content violates these Terms of Service for reasons other than copyright infringement, such as but not limited to pornography, obscenity, or excessive length. THC may at any time, without prior notice and in its sole discretion, remove such Content and/or terminate a user's account for submitting such material in violation of these Terms of Service.",id:"xkEDVfBLuqC2yYiImqPp0"}],id:"TvMGP7zV_uvOnb9GcfTq2"},{num:"10",heading:"Digital Millennium Copyright Act (DMCA)",subsections:[{label:"A.",body:"If you are a copyright owner or an agent thereof and believe that any Content infringes upon your copyrights, you may submit a notification pursuant to the DMCA (17 U.S.C. § 512(c)(3)) by providing our Copyright Agent with the following information in writing:",list:["A physical or electronic signature of a person authorized to act on behalf of the owner of an exclusive right that is allegedly infringed;","Identification of the copyrighted work claimed to have been infringed, or a representative list of such works;","Identification of the material that is claimed to be infringing and information reasonably sufficient to permit THC to locate the material;","Information reasonably sufficient to permit THC to contact you, such as an address, telephone number, and email;","A statement that you have a good faith belief that use of the material in the manner complained of is not authorized by the copyright owner, its agent, or the law; and","A statement that the information in the notification is accurate, and under penalty of perjury, that you are authorized to act on behalf of the owner of an exclusive right that is allegedly infringed."],id:"m1sFO-uVFFomRL4IWNpMo"},{label:"B.",body:"THC's designated Copyright Agent: PO Box 773011, Ocala, FL 34477-3011 | [email protected]. Only DMCA notices should go to the Copyright Agent. All other communications should be directed to [email protected].",email:!0,id:"Ufy5odwS4u4S5jPuVJg70"},{label:"C.",body:"Counter-Notice. If you believe that your Content that was removed is not infringing, or that you have authorization from the copyright owner to post the material, you may send a counter-notice to the Copyright Agent containing: (1) your physical or electronic signature; (2) identification of the Content that was removed and the location at which it appeared; (3) a statement that you have a good faith belief that the Content was removed as a result of mistake or misidentification; and (4) your name, address, telephone number, and email address, a statement that you consent to the jurisdiction of the federal court in Ocala, Florida, and a statement that you will accept service of process from the person who provided notification of the alleged infringement.",id:"9LsoUKEMroWvFXnKA8Ax2"},{label:"D.",body:"If a counter-notice is received by the Copyright Agent, THC may send a copy of the counter-notice to the original complaining party informing that person that it may replace the removed Content or cease disabling it in 10 business days. Unless the copyright owner files an action seeking a court order, the removed Content may be replaced or access to it restored in 10 to 14 business days or more after receipt of the counter-notice, at THC's sole discretion.",id:"qUFFpzdpiFKzr0tFMJbcn"},{label:"E.",body:"THC reserves the right to prohibit users who are subject to multiple DMCA notices.",id:"izXr2vvFHLmzPo51ez-e_"}],id:"g7aFBOscF9NwAv1LCUuTC"},{num:"11",heading:"Warranty Disclaimer",subsections:[{label:"",body:"YOU AGREE THAT YOUR USE OF THE THC SERVICE SHALL BE AT YOUR SOLE RISK. TO THE FULLEST EXTENT PERMITTED BY LAW, THC, ITS OFFICERS, DIRECTORS, EMPLOYEES, AND AGENTS DISCLAIM ALL WARRANTIES, EXPRESS OR IMPLIED, IN CONNECTION WITH THE SERVICES AND YOUR USE THEREOF. THC MAKES NO WARRANTIES OR REPRESENTATIONS ABOUT THE ACCURACY OR COMPLETENESS OF THIS SITE'S CONTENT OR THE CONTENT OF ANY SITES LINKED TO THIS SITE AND ASSUMES NO LIABILITY OR RESPONSIBILITY FOR ANY 
633(I) ERRORS, MISTAKES, OR INACCURACIES OF CONTENT, (II) PERSONAL INJURY OR PROPERTY DAMAGE OF ANY NATURE WHATSOEVER RESULTING FROM YOUR ACCESS TO AND USE OF OUR SERVICES, (III) ANY UNAUTHORIZED ACCESS TO OR USE OF OUR SECURE SERVERS AND/OR ANY PERSONAL INFORMATION STORED THEREIN, (IV) ANY INTERRUPTION OR CESSATION OF TRANSMISSION TO OR FROM OUR SERVICES, (V) ANY BUGS, VIRUSES, OR TROJAN HORSES WHICH MAY BE TRANSMITTED TO OR THROUGH OUR SERVICES BY ANY THIRD PARTY, AND/OR (VI) ANY ERRORS OR OMISSIONS IN ANY CONTENT OR FOR ANY LOSS OR DAMAGE OF ANY KIND INCURRED AS A RESULT OF THE USE OF ANY CONTENT POSTED, EMAILED, TRANSMITTED, OR OTHERWISE MADE AVAILABLE VIA THE SERVICES. THC DOES NOT WARRANT, ENDORSE, GUARANTEE, OR ASSUME RESPONSIBILITY FOR ANY PRODUCT OR SERVICE ADVERTISED OR OFFERED BY A THIRD PARTY THROUGH THE SERVICES.",id:"vU8WDXHDacuMnzVwzz4k-"}],id:"GxxEYXm5Gnq2UIFGCwZBY"},{num:"12",heading:"Limitation of Liability",subsections:[{label:"",body:"IN NO EVENT SHALL THC, ITS OFFICERS, DIRECTORS, EMPLOYEES, OR AGENTS BE LIABLE TO YOU FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, PUNITIVE, OR CONSEQUENTIAL DAMAGES WHATSOEVER RESULTING FROM ANY (I) ERRORS, MISTAKES, OR INACCURACIES OF CONTENT, (II) PERSONAL INJURY OR PROPERTY DAMAGE OF ANY NATURE WHATSOEVER RESULTING FROM YOUR ACCESS TO AND USE OF OUR SERVICES, (III) ANY UNAUTHORIZED ACCESS TO OR USE OF OUR SECURE SERVERS AND/OR ANY PERSONAL INFORMATION STORED THEREIN, (IV) ANY INTERRUPTION OR CESSATION OF TRANSMISSION TO OR FROM OUR SERVICES, (V) ANY BUGS, VIRUSES, OR TROJAN HORSES TRANSMITTED TO OR THROUGH OUR SERVICES BY ANY THIRD PARTY, AND/OR (VI) ANY ERRORS OR OMISSIONS IN ANY CONTENT OR FOR ANY LOSS OR DAMAGE OF ANY KIND INCURRED AS A RESULT OF YOUR USE OF ANY CONTENT POSTED, EMAILED, TRANSMITTED, OR OTHERWISE MADE AVAILABLE VIA THE SERVICES, WHETHER BASED ON WARRANTY, CONTRACT, TORT, OR ANY OTHER LEGAL THEORY, AND WHETHER OR NOT THE COMPANY IS ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. THE FOREGOING LIMITATION OF LIABILITY SHALL APPLY TO THE FULLEST EXTENT PERMITTED BY LAW. YOU SPECIFICALLY ACKNOWLEDGE THAT THC SHALL NOT BE LIABLE FOR CONTENT OR THE DEFAMATORY, OFFENSIVE, OR ILLEGAL CONDUCT OF ANY THIRD PARTY AND THAT THE RISK OF HARM OR DAMAGE FROM THE FOREGOING RESTS ENTIRELY WITH YOU.",id:"VpzcUBCrqQOKc8ADGQ9am"},{label:"",body:"The THC Service is controlled and offered by THC from its facilities in the United States of America. THC makes no representations that the Service is appropriate or available for use in other locations. Those who access or use the Service from other jurisdictions do so at their own volition and are responsible for compliance with local law.",id:"VS5GgvPNb4NphKuuz1NOZ"}],id:"qzIPtc5P5oAotoZUiLbf_"},{num:"13",heading:"Indemnity",subsections:[{label:"",body:"To the extent permitted by applicable law, you agree to defend, indemnify and hold harmless THC, its parent corporation, officers, directors, employees and agents, from and against any and all claims, damages, obligations, losses, liabilities, costs or debt, and expenses (including but not limited to attorney's fees) arising from: (i) your use of and access to the THC Service; (ii) your violation of any term of these Terms of Service; (iii) your violation of any third party right, including without limitation any copyright, property, or privacy right; or (iv) any claim that your Content caused damage to a third party. This defense and indemnification obligation will survive these Terms of Service and your use of the THC Service.",id:"-CW0aEwu_z8RzCHyajxxs"}],id:"XwAhX2ClDvK5eLSErdFQg"},{num:"14",heading:"Assignment",subsections:[{label:"",body:"These Terms of Service, and any rights and licenses granted hereunder, may not be transferred or assigned by you, but may be assigned by THC without restriction.",id:"wVm6OSQ1IchmMafg3lkun"}],id:"PqnNoKFdr3hvg2lhERg51"},{num:"15",heading:"General",subsections:[{label:"",body:"You agree that: (i) the THC Service shall be deemed solely based in Florida; and (ii) the Service shall be deemed a passive website that does not give rise to personal jurisdiction over THC, either specific or general, in jurisdictions other than Florida. These Terms of Service shall be governed by the internal substantive laws of the State of Florida, without respect to its conflict of laws principles. Any claim or dispute between you and THC that arises in whole or in part from the THC Service shall be decided exclusively by a court of competent jurisdiction located in Marion County, Florida. These Terms of Service, together with the Privacy Notice at PO Box 773011, Ocala, FL 34477-3011 and any other legal notices published by THC on the Service, shall constitute the entire agreement between you and THC concerning the Service. If any provision of these Terms is deemed invali
633d by a court of competent jurisdiction, the invalidity of such provision shall not affect the validity of the remaining provisions. No waiver of any term of these Terms of Service shall be deemed a further or continuing waiver of such term or any other term. THC reserves the right to amend these Terms of Service at any time and without notice, and it is your responsibility to review these Terms of Service for any changes. YOU AND THC AGREE THAT ANY CAUSE OF ACTION ARISING OUT OF OR RELATED TO THE SERVICES MUST COMMENCE WITHIN ONE (1) YEAR AFTER THE CAUSE OF ACTION ACCRUES. OTHERWISE, SUCH CAUSE OF ACTION IS PERMANENTLY BARRED.",id:"O1C8zF2xGJk1AfNbdsTXZ"}],id:"eEPaVBLHKcqiUmfb_Eb4N"}]}),user_profile:(((t1=ye.pages)==null?void 0:t1.user_profile)??ye.user_profile??tt).parse({headerBar:"Member Profile",notFoundTitle:"Profile not found",notFoundBody:"This username doesn't exist or may have been removed.",planLabel:"Plan",memberSinceLabel:"Member since",upgradeTeaser:"Profile features will expand with membership",upgradeTeaserBody:"Upgrade coming soon.",planNames:{rookie:"Rookie",maiden:"Maiden",grand_prix:"Grand Prix"},accountTypeLabels:{horse_lover:"Horse Enthusiast",farm_trainer_business:"Farm, Trainer, or Business",event_show:"Event or Show",association_org:"Association or Organization",business:"Business"}}),videos:(((s1=ye.pages)==null?void 0:s1.videos)??ye.videos??tt).parse({ALL_CATEGORIES:[{label:"All",value:"",id:"4tUQSu0nXgFfiH85r_iWL"},{label:"Horse Racing",value:"Horse Racing",id:"mXmHOHhBxsrNJcU2WbJJw"},{label:"Harness Racing",value:"Harness Racing",id:"5aCRuZ198C6dmpeZ05H9y"},{label:"Western Dressage",value:"Western Dressage",id:"4h2GWIJSDEtbWq1WfpHEe"},{label:"Show Jumping",value:"Show Jumping",id:"6ry2x7wct1zu2gaKvLDHJ"},{label:"Reining",value:"Reining",id:"NuBNXhtdVB6u2AZ-oDOv-"},{label:"Reined Cow Horse",value:"Reined Cow Horse",id:"OOkPZcPJdBmtkv9dUC34G"},{label:"Cow Horse",value:"Cow Horse",id:"CowHorse001THC"},{label:"Campdraft",value:"Campdraft",id:"campdraft-cat-01"},{label:"Cutting Horse",value:"Cutting Horse",id:"dlajNZ_3Eo3w4zH6Gtbrt"},{label:"Eventing",value:"Eventing",id:"CkVOnLs2ngzSeP2akQhtx"},{label:"Quarter Horse",value:"Quarter Horse",id:"C-_m4wvpibKdvSkVHwrqC"},{label:"How To Videos",value:"How To Videos",id:"bORsQEDpDxjBX25nQB-2x"},{label:"Working Equitation",value:"Working Equitation",id:"WorkingEquitation001THC"},{label:"Other / General",value:"Other / General",id:"Vo9Kkr8Ehkzn85WMocW1H"}]}),watch_live_events:(((a1=ye.pages)==null?void 0:a1.watch_live_events)??ye.watch_live_events??tt).parse({SIDEBAR_BANNERS:[{id:"live-sidebar-circa",src:"/airo-assets/images/sidebar/banner-4",alt:"Circa Resort & Casino",href:"https://www.circalasvegas.com/"},{id:"live-sidebar-tioga",src:"/airo-assets/images/sidebar/banner-tioga-territory",alt:"Tioga Territory",href:"https://www.tiogaterritory.com/store/WDAA.html"},{id:"live-sidebar-state-line",src:"/airo-assets/images/sponsors/state-line-tack",alt:"State Line Tack",href:"https://www.statelinetack.com/"},{id:"live-sidebar-di",src:"/airo-assets/images/sidebar/banner-di-logo",alt:"Dressage Illustrated",href:"https://dressageillustrated.com/collections/riders-wdaa-western-dressage-diagram-books"},{id:"live-sidebar-debbie-brooks",src:"/airo-assets/images/sidebar/debbie-brooks-custom-cuff",alt:"Debbie Brooks New York – Custom Horse Cuffs",href:"https://www.debbiebrooks.com/"},{id:"live-sidebar-skyline",src:"/airo-assets/images/sidebar/banner-skyline",alt:"Skyline Goldsmiths & Silversmiths",href:"https://www.skylinevaquero.com/"},{id:"live-sidebar-wdaa-sponsor",src:"/airo-assets/images/sponsors/wdaa",alt:"WDAA THC Sponsorship",href:"https://www.wdaaworldshow.org"},{id:"live-sidebar-purina",src:"/airo-assets/images/sponsors/purina",alt:"Purina Horse Feed",href:"https://www.purina.com/"},{id:"live-sidebar-wdaa",src:"/airo-assets/images/sidebar/banner-wdaa-500",alt:"WDAA Western Dressage Association",href:"https://wdaa.org/"},{id:"live-sidebar-absorbine",src:"/airo-assets/images/sponsors/absorbine",alt:"Absorbine",href:"https://absorbine.com/"},{id:"live-sidebar-killian",src:"/airo-assets/images/sponsors/killian-insurance",alt:"Killian Insurance",href:"https://farmequine
633insurance.com/"},{src:"/airo-assets/images/sidebar/banner-sale-500",alt:"Total Horse Channel – New Website Special Banner Sale",href:"/advertise",id:"live-thc-banner-sale"}],pageTitle:"Watch Live Events",pageIntro:"Watch Live Events from around the world! Register today to share your LIVE Events for FREE.",currentLiveEvents:[{id:"cle-1",href:"https://www.youtube.com/watch?v=jfKfPfyJRdk",thumbnail:"/airo-assets/images/videos/torrelavega-pre",title:"XXVI Concurso Morfologico de PRE 3* - Ciudad de Torrelavega FECAB 2026",date:"August 28, 2026",views:19,likes:0,comments:0,isLive:!0},{id:"cle-2",href:"https://www.youtube.com/watch?v=5qap5aO4i9A",thumbnail:"/airo-assets/images/videos/hippodrome-casablanca",title:"Hippodrome CASABLANCA du 28/08/2026",date:"August 28, 2026",views:22,likes:0,comments:0,isLive:!0},{id:"cle-3",href:"https://rumble.com/c/UtahReinedCowHorse",thumbnail:"/airo-assets/images/videos/utah-reined-cow",title:"2026 Utah Reined Cow Horse Futurity - Friday",date:"August 28, 2026",views:37,likes:1,comments:0,isLive:!0},{id:"cle-4",href:"https://www.youtube.com/watch?v=DWcJFNfaw9c",thumbnail:"/airo-assets/images/videos/handicappers-report",title:"Handicappers Report - August 28, 2026",date:"August 28, 2026",views:20,likes:0,comments:0,isLive:!0},{id:"cle-5",href:"https://www.youtube.com/watch?v=M7lc1UVf-VE",thumbnail:"/airo-assets/images/videos/race-day-las-vegas",title:"Race Day Las Vegas - August 28, 2026",date:"August 28, 2026",views:21,likes:0,comments:0,isLive:!0},{id:"cle-6",href:"https://www.youtube.com/watch?v=oTJRivZTMLs",thumbnail:"/airo-assets/images/videos/ici-on-parie-cabourg",title:"ICI On Parie ! Cabourg, Quinte+ et pronostics en live, Vendredi 28 Aout 2026",date:"August 28, 2026",views:39,likes:0,comments:0,isLive:!0},{id:"cle-7",href:"https://www.youtube.com/watch?v=kJQP7kiw5Fk",thumbnail:"/airo-assets/images/videos/trofeo-coca-cola-jumping",title:"Trofeo COCA-COLA - CSIYH1* 6yo/7yo - Special Two-Phase - 1.30m/1.35m",date:"August 28, 2026",views:21,likes:0,comments:0,isLive:!0},{id:"cle-8",href:"https://www.youtube.com/watch?v=9bZkp7q19f0",thumbnail:"/airo-assets/images/videos/csi-horovice",title:"LIVE | skoky CSI Horovice (CZE) - 28. 8. 2026",date:"August 28, 2026",views:23,likes:0,comments:0,isLive:!0},{id:"cle-9",href:"https://www.youtube.com/watch?v=YQHsXMglC9A",thumbnail:"/airo-assets/images/videos/red-shores-racetrack",title:"Red Shores Racetrack | LIVE",date:"August 27, 2026",views:11390,likes:64,comments:1,isLive:!1},{id:"cle-10",href:"https://www.youtube.com/watch?v=hT_nvWreIhg",thumbnail:"/airo-assets/images/videos/hipodromo-camarero",title:"Hipodromo Camarero | Horse Racing | LIVE",date:"August 27, 2026",views:67120,likes:404,comments:0,isLive:!1},{id:"cle-11",href:"https://www.youtube.com/watch?v=RgKAFK5djSk",thumbnail:"/airo-assets/images/videos/saratoga-live",title:"Saratoga Live | August 27th",date:"August 27, 2026",views:24930,likes:220,comments:0,isLive:!1},{id:"cle-12",href:"https://www.youtube.com/watch?v=JGwWNGJdvx8",thumbnail:"/airo-assets/images/videos/gulfstream-park",title:"America's Day at the Races | LIVE",date:"August 27, 2026",views:104697,likes:858,comments:9,isLive:!1}],archiveEvents:[{id:"arc-1",href:"https://www.youtube.com/watch?v=fJ9rUzIMcZQ",thumbnail:"/airo-assets/images/videos/woodbine-mohawk-park",title:"Woodbine Mohawk Park Racetrack Thursday, August 27, 2026",date:"August 27, 2026",views:39,likes:0,comments:0},{id:"arc-2",href:"https://www.youtube.com/watch?v=CevxZvSJLk8",thumbnail:"/airo-assets/images/videos/horseshoe-indianapolis",title:"Horseshoe Indianapolis 08/27/2026",date:"August 27, 2026",views:31,likes:0,comments:0},{id:"arc-3",href:"https://www.youtube.com/watch?v=dQw4w9WgXcQ",thumbnail:"/airo-assets/images/videos/woodbine-mohawk-park",title:"Woodbine Racetrack - Thursday, August 27th, 2026",date:"August 27, 2026",views:36,likes:0,comments:0},{id:"arc-4",href:"https://www.youtube.com/watch?v=2Vv-BfVoq4g",thumbnail:"/airo-assets/images/videos/racing-across-america",title:"Racing Across America - August 27, 2026",date:"August 27, 2026",views:35,likes:0,comments:0}
633,{id:"arc-5",href:"https://www.youtube.com/watch?v=DWcJFNfaw9c",thumbnail:"/airo-assets/images/videos/handicappers-report",title:"Handicappers Report - August 27, 2026",date:"August 27, 2026",views:28,likes:1,comments:0},{id:"arc-6",href:"https://www.youtube.com/watch?v=M7lc1UVf-VE",thumbnail:"/airo-assets/images/videos/race-day-las-vegas-aug27",title:"Race Day Las Vegas - August 27, 2026",date:"August 27, 2026",views:31,likes:1,comments:0},{id:"arc-7",href:"https://rumble.com/c/UtahReinedCowHorse",thumbnail:"/airo-assets/images/videos/utah-reined-cow",title:"2026 Utah Reined Cow Horse Futurity - Thursday",date:"August 27, 2026",views:96,likes:1,comments:0},{id:"arc-8",href:"https://www.youtube.com/watch?v=oTJRivZTMLs",thumbnail:"/airo-assets/images/videos/ici-on-parie-cabourg",title:"ICI on Parie ! Deauville - August 27, 2026",date:"August 27, 2026",views:30,likes:1,comments:0}],recentNews:["WDAA 2026 World Championship Show Kicks Off This Weekend","Saratoga Fall Meet Schedule Announced","Horse Park Masters Dressage - Entry List Released","CSI Horovice Show Jumping - Preview","Gulfstream Park Fall Meet Begins September 26","Total Horse Channel Expands Live Coverage for 2026"]}),wdaa_hub:(((n1=ye.pages)==null?void 0:n1.wdaa_hub)??ye.wdaa_hub??tt).parse({pageTitle:"2026 Western Dressage World Championship Show",pageSubtitle:"Live Coverage & Replays",intro:"Watch the 2026 WDAA World Championship Horse Show live from all four rings. Select a ring below to tune in, or browse replays and order your personal competition videos.",rings:[{id:"ring-1",label:"Ring 1",embedUrl:"https://totalhorsechannel.com/video/wdaa-world-championship-show-live/",isLive:!0},{id:"ring-2",label:"Ring 2",embedUrl:"https://totalhorsechannel.com/video/wdaa-world-championship-show-live-ring-2/",isLive:!0},{id:"ring-3",label:"Ring 3",embedUrl:"https://totalhorsechannel.com/video/wdaa-world-championship-show-live-ring-3/",isLive:!0},{id:"ring-4",label:"Ring 4",embedUrl:"https://totalhorsechannel.com/video/wdaa-world-championship-show-live-ring-4/",isLive:!0}],helpfulLinks:[{id:"hl-1",label:"Technical Support",href:"/help"},{id:"hl-2",label:"Link to Us",href:"/link-to-us"},{id:"hl-3",label:"Official AHA Media Partner",href:"https://www.arabianhorses.org/"},{id:"hl-4",label:"Upload Videos",href:"/upload"},{id:"hl-5",label:"Advertising Options",href:"/advertise"},{id:"hl-6",label:"Community Guidelines",href:"/community-guidelines"},{id:"hl-7",label:"Terms of Service",href:"/terms"},{id:"hl-8",label:"Privacy Policy",href:"/privacy"}],SIDEBAR_BANNERS:[{id:"sb-2",src:"/airo-assets/images/sidebar/banner-4",alt:"Circa Resort & Casino",href:"https://www.circalasvegas.com/"},{id:"sb-3",src:"/airo-assets/images/sidebar/banner-tioga-territory",alt:"Tioga Territory",href:"https://www.tiogaterritory.com/store/WDAA.html"},{id:"sb-4",src:"/airo-assets/images/sponsors/state-line-tack",alt:"State Line Tack",href:"https://www.statelinetack.com/"},{id:"sb-5",src:"/airo-assets/images/sidebar/banner-di-logo",alt:"Dressage Illustrated",href:"https://dressageillustrated.com/collections/riders-wdaa-western-dressage-diagram-books"},{id:"sb-6",src:"/airo-assets/images/sidebar/banner-wdaa-500",alt:"WDAA Western Dressage Association",href:"https://www.westerndressageassociation.org/"},{src:"/airo-assets/images/sidebar/banner-sale-500",alt:"Total Horse Channel – New Website Special Banner Sale",href:"/advertise",id:"wdaa-thc-banner-sale"}]}),wdaa_replays:(((r1=ye.pages)==null?void 0:r1.wdaa_replays)??ye.wdaa_replays??tt).parse({pageTitle:"WDAA Replays",description:"Watch replays of the LIVESTREAMS from the WDAA Western Dressage World Championship Show. Individual rides and classes available for purchase from 2018 through 2025.",purchaseUrl:"https://totalhorsechannel.com/wdaa-video-orders",intro:"Watch replays of the LIVESTREAMS from the WDAA Western Dressage World Championship Show. Individual rides and classes are available for purchase from 2018 through 2025.",years:[{id:"y2025",year:"2025",logoSrc:"/airo-assets/images/wdaa-replays/logo-2025",note:"",days:[{id:"d2025-tue",label:"Tuesday",href:"https://rumble.com/playlists/IjzdnnYm4BM"},{id:"d2025-wed",label:"Wednesday",href:"https://rumble.com/playlists/Y4oy3K4hZdk"},{id:"d2025-thu",label:"Thursday",href:"https://rumble.com/playlists/FChY9Gef7O8"},{id:"d2025-fri",label:"Friday",href:"https://rumble.com/playlists/Gf51XKKa8O4"},{id:"d2025-sat",label:"Saturday",href:"https://rumble.com/playlists/ZhpxNkoIt4c"}]},{id:"y2024",year:"2024",logoSrc:"/airo-assets/images/wdaa-replays/logo-2024",note:"",days:[{id:"d2024-wed",label:"Wednesday",href:"https://rumble.com/playlists/E95nqpZPGvQ"},{id:"d2024-thu",label:"Thursday",href:"https://rumble.com/playlists/CXMUG4XUbvA"},{id:"d2024-fri",label:"Friday",href:"https://rumble.com/playlists/Hk6iNaSHFPE"},{id:"d2024-sat",label:"Saturday",href:"https://rumble.com/playlists/DpE6dBhPTeE"},{id:"d2024-sun",label:"Sunday",href:"https://rumble.com/playlists/MDcfwiy7a4c"}]},{id:"y2023",year:"2023",logoSrc:"/airo-assets/images/wdaa-replays/logo-2023",note:"",days:[{id:"d2023-tue",label:"Tuesday",href:"https://rumble.com/playlists/aH-KoRk_F7Y"},{id:"d2023-wed",label:"Wednesday",href:"https://rumble.com/playlists/Irxra_kNjVo"},{id:"d2023-thu",label:"Thursday",href:"https://rumble.com/playlists/Ehdh7bjTfAw"},{id:"d2023-fri",label:"Friday",href:"https://rumble.com/playlists/d3KYDmSp1UU"},{id:"d2023-sat",label:"Saturday",href:"https://rumble.com/playlists/UpXKU3gFK74"}]},{id:"y2019",year:"2019",logoSrc:"/airo-assets/images/wdaa-replays/logo-2019",note:"2019 was streamed through YouTube. Some of the show is no longer available on YouTube but you can still purchase an individual ride.",days:[{id:"d2019-wed",label:"Wednesday",href:"https://youtube.com/playlist?list=PL_LdBy8uhKHT0VltB6lTtEaAPtcX1BZad&si=QO_sYEVMcf9NxE5c"},{id:"d2019-thu",label:"Thursday",href:"https://youtube.com/playlist?list=PL_LdBy8uhKHTIzsXwfTGJTHYZ8AuzBBVf&si=qEHCLK7SRDtZbz11"},{id:"d2019-fri",label:"Friday",href:"https://youtube.com/playlist?list=PL_LdBy8uhKHRVgO4HY2yzBThPdUuOrgAq&si=n_GmM99hau2uglTp"}]}]}),wdaa_ring1:(((i1=ye.pages)==null?void 0:i1.wdaa_ring1)??ye.wdaa_ring1??tt).parse({pageTitle:"WDAA World Championship Show — Ring 1 Live",description:"Watch Ring 1 of the 2026 WDAA Western Dressage World Championship Show live. September 15–19, 2026 at Lazy E Arena, Guthrie, Oklahoma.",videoUrl:"https://totalhorsechannel.com/video/wdaa-world-championship-show-live/",embedUrl:"https://rumble.com/embed/v7dfsau/?pub=mqmap",replaysUrl:"/wdaa-replays",embedNote:"Live stream — Ring 1"}
633),wdaa_ring2:(((o1=ye.pages)==null?void 0:o1.wdaa_ring2)??ye.wdaa_ring2??tt).parse({pageTitle:"WDAA World Championship Show — Ring 2 Live",description:"Watch Ring 2 of the 2026 WDAA Western Dressage World Championship Show live. September 15–19, 2026 at Lazy E Arena, Guthrie, Oklahoma.",videoUrl:"https://totalhorsechannel.com/video/wdaa-world-championship-show-live-ring-2/",embedUrl:"https://rumble.com/embed/v7disrk/?pub=mqmap",replaysUrl:"/wdaa-replays",embedNote:"Live stream — Ring 2"}),wdaa_ring3:(((l1=ye.pages)==null?void 0:l1.wdaa_ring3)??ye.wdaa_ring3??tt).parse({pageTitle:"WDAA World Championship Show — Ring 3 Live",description:"Watch Ring 3 of the 2026 WDAA Western Dressage World Championship Show live. September 15–19, 2026 at Lazy E Arena, Guthrie, Oklahoma.",videoUrl:"https://totalhorsechannel.com/video/wdaa-world-championship-show-live-ring-3/",embedUrl:"https://rumble.com/embed/v7disve/?pub=mqmap",replaysUrl:"/wdaa-replays",embedNote:"Live stream — Ring 3"}),wdaa_ring4:(((c1=ye.pages)==null?void 0:c1.wdaa_ring4)??ye.wdaa_ring4??tt).parse({pageTitle:"WDAA World Championship Show — Ring 4 Live",description:"Watch Ring 4 of the 2026 WDAA Western Dressage World Championship Show live. September 15–19, 2026 at Lazy E Arena, Guthrie, Oklahoma.",videoUrl:"https://totalhorsechannel.com/video/wdaa-world-championship-show-live-ring-4/",embedUrl:"https://rumble.com/embed/v7dit0s/?pub=mqmap",replaysUrl:"/wdaa-replays",embedNote:"Live stream — Ring 4"}),wdaa_sponsorships:(((d1=ye.pages)==null?void 0:d1.wdaa_sponsorships)??ye.wdaa_sponsorships??tt).parse({pageTitle:"WDAA World Championship Show – Sponsorships",description:"Become a sponsor of the WDAA Western Dressage World Championship Show on Total Horse Channel. Reach thousands of passionate equestrian fans with your brand.",heading:"2026 WDAA World Championship Show Sponsorships",intro:"The WDAA Western Dressage World Championship Show showcases the very best in Western Dressage. Featuring over 50 breeds of horses showing for 5 days in 4 separate arenas, a non-stop presentation of superior horsemanship, happy horses and exhibitor comradery.",sponsorIntro:"If you would like to sponsor the WDAA World Championship Show, there are a few ways to do so. Become a Corporate Sponsor, Party Sponsor, Awards Sponsor or even a show vendor! Many sponsorship opportunities available.",sponsorLearnMoreLabel:"Learn more:",sponsorLearnMoreUrl:"https://wdaaworldshow.org/sponsor",sponsorLearnMoreText:"wdaaworldshow.org/sponsor",contactHeading:"Sponsorship Contacts",contactEmail:"[email protected]",contactPhone:"",contacts:[{id:"c-corporate",type:"Corporate Sponsorship",contact:"Candy",email:"[email protected]"},{id:"c-party",type:"Party Sponsorship",contact:"Dini",email:"[email protected]"},{id:"c-award",type:"Award Sponsorship",contact:"Kim",email:"[email protected]"}],sponsorVideoLabel:"2026 Sponsor Highlight Video",sponsorVideoNote:"This sponsor video will air during the 2026 WDAA World Championship Show livestream.",currentSponsorsHeading:"Thank You to Our 2026 Sponsors",sponsors:[{id:"sp-wdaa",name:"WDAA Western Dressage Association",href:"https://www.westerndressageassociation.org/",logoSrc:"/airo-assets/images/sponsors/wdaa",tier:"title"},{id:"sp-purina",name:"Purina Animal Nutrition",href:"https://www.purina.com/",logoSrc:"/airo-assets/images/sponsors/purina",tier:"gold"},{id:"sp-absorbine",name:"Absorbine",href:"https://www.absorbine.com/",logoSrc:"/airo-assets/images/sponsors/absorbine",tier:"gold"},{id:"sp-circa",name:"Circa Resort & Casino",href:"https://www.circalasvegas.com/",logoSrc:"/airo-assets/images/sponsors/circa-resort-casino",tier:"gold"},{id:"sp-killian",name:"Killian Insurance Agency",href:"https://farmequineinsurance.com/",logoSrc:"/airo-assets/images/sponsors/killian-insurance",tier:"silver"},{id:"sp-state-line",name:"State Line Tack",href:"https://www.statelinetack.com/",logoSrc:"/airo-assets/images/sponsors/state-line-tack",tier:"silver"},{id:"sp-dressage-illustrated",name:"Dressage Illustrated",href:"https://dressageillustrated.com/collections/riders-wdaa-western-dressage-diagram-books",logoSrc:"/airo-assets/images/sponsors/dressage-illustrated",tier:"silver"}
633,{id:"sp-skyline",name:"Skyline Gold & Silversmiths",href:"https://skylinevaquero.com/",logoSrc:"/airo-assets/images/sponsors/skyline-gold-silversmiths",tier:"silver"},{id:"sp-tioga",name:"Tioga Territory Ltd",href:"https://www.tiogaterritory.com/store/WDAA.html",logoSrc:"/airo-assets/images/sponsors/tioga-territory",tier:"silver"},{id:"sp-100x",name:"100X Equine",href:"https://100xequine.com/",logoSrc:"/airo-assets/images/sponsors/100x-equine",tier:"silver"},{id:"sp-spotlight",name:"Spotlight Horse Shows",href:"https://www.spotlighthorseshows.com/",logoSrc:"/airo-assets/images/sponsors/spotlight-horse-shows",tier:"silver"},{id:"sp-us-equestrian",name:"US Equestrian",href:"https://www.usef.org/",logoSrc:"/airo-assets/images/sponsors/us-equestrian",tier:"silver"}],packagesHeading:"Sponsorship Packages",packages:[{id:"pkg-title",name:"Title Sponsor",price:"Contact for Pricing",features:["Prominent logo placement on all livestream overlays","Featured sponsor video aired during broadcast","Logo on WDAA Replays page","Social media mentions across all platforms","Banner ad on Total Horse Channel website","Verbal recognition during broadcast"]},{id:"pkg-gold",name:"Gold Sponsor",price:"Contact for Pricing",features:["Logo placement on livestream overlays","Logo on WDAA Replays page","Social media mentions","Banner ad on Total Horse Channel website"]},{id:"pkg-silver",name:"Silver Sponsor",price:"Contact for Pricing",features:["Logo on WDAA Replays page","Social media mention","Logo on sponsorships page"]}]}),wdaa_video_orders:(((u1=ye.pages)==null?void 0:u1.wdaa_video_orders)??ye.wdaa_video_orders??tt).parse({SIDEBAR_BANNERS:[{id:"wdaa-sidebar-circa",src:"/airo-assets/images/sidebar/banner-4",alt:"Circa Resort & Casino",href:"https://www.circalasvegas.com/"},{id:"wdaa-sidebar-tioga",src:"/airo-assets/images/sidebar/banner-tioga-territory",alt:"Tioga Territory",href:"https://www.tiogaterritory.com/store/WDAA.html"},{id:"wdaa-sidebar-state-line",src:"/airo-assets/images/sponsors/state-line-tack",alt:"State Line Tack",href:"https://www.statelinetack.com/"},{id:"wdaa-sidebar-di",src:"/airo-assets/images/sidebar/banner-di-logo",alt:"Dressage Illustrated",href:"https://dressageillustrated.com/collections/riders-wdaa-western-dressage-diagram-books"},{id:"wdaa-sidebar-wdaa",src:"/airo-assets/images/sidebar/banner-wdaa-500",alt:"WDAA Western Dressage Association",href:"https://www.westerndressageassociation.org/"},{src:"/airo-assets/images/sidebar/banner-sale-500",alt:"Total Horse Channel – New Website Special Banner Sale",href:"/advertise",id:"wvo-thc-banner-sale"}],pageTitle:"WDAA Video Orders",intro:"Order now and receive your very own copy of your ride. Your video will be sent to your email via a downloadable link.",note:"For multiple videos please enter all required info.",pricePerVideo:35,helpfulLinks:[{id:"hl1",label:"Technical Support",href:"/help"},{id:"hl2",label:"Link to Us",href:"/link-to-us"},{id:"hl3",label:"Official AHA Media Partner",href:"#"},{id:"hl4",label:"Upload Videos",href:"#"},{id:"hl5",label:"Advertising Options",href:"/advertise"},{id:"hl6",label:"Community Guidelines",href:"#"},{id:"hl7",label:"Terms of Service",href:"#"},{id:"hl8",label:"Privacy Policy",href:"#"}]}),youtube:(((m1=ye.pages)==null?void 0:m1.youtube)??ye.youtube??tt).parse({headline:"Total Horse Channel on YouTube",subtext:"Watch lives, replays, and Shorts on our YouTube channel.",ctaLabel:"Open our YouTube channel",channelUrl:"https://www.youtube.com/user/Prowinda",latestVideosHeading:"Latest Videos",latestVideosSubtext:"Live events, replays, how-to guides, and more — updated regularly.",subscribeLabel:"Subscribe on YouTube",embedNote:"Video player provided by YouTube. Some videos may require visiting youtube.com/user/Prowinda directly."})},Cs=lt.add_video_live,Cj=lt.admin_live_events,Aa=lt.admin_users,Bi=lt.admin_wdaa_orders,uA=lt.advertise,Mn=lt.aha_partner,ti=lt.become_member,jf=lt.breeds_disciplines,$i=lt.category_horse_music_videos,si=lt.category_miniature_horse,ai=lt.category_reining,vn=lt.category_western_dressage,$s=lt.contests,Vi=lt.debbie_brooks,Fi=lt.donations,mA=lt.games,Dn=lt.help,ha=lt.home,ni=lt.horse_capital_tours,Bo=lt.instagram,Hs=lt.link_to,kj=lt.live_event_page,hA=lt.live_helper,Wi=lt.login,Zs=lt.low_roller,pA=lt.membership,Ps=lt.news,xr=lt.news_article,fA=lt.privacy_policy,$o=lt.puzzles,tn=lt.rumble,ri=lt.sponsors_partners,Vo=lt.tech_support,xA=lt.terms_of_service,hc=lt.user_profile,Nr=lt.wdaa_hub,vr=lt.wdaa_replays,li=lt.wdaa_ring1,Un=lt.wdaa_ring2,Pn=lt.wdaa_ring3,Kn=lt.wdaa_ring4,gs=lt.wdaa_sponsorships,pc=lt.wdaa_video_orders,Fo=lt.youtube;function wf(t){return t>
633=1e3?t.toLocaleString():String(t)}function Tj({thumbnail:t,title:a,date:r,views:o,likes:l,comments:d}){return e.jsxs("div",{className:"flex flex-col gap-2 cursor-pointer group",children:[e.jsxs("div",{className:"relative w-full overflow-hidden bg-muted",style:{aspectRatio:"16/9"},children:[t?e.jsx("img",{src:t,alt:a,className:"w-full h-full object-cover group-hover:opacity-90 transition-opacity",loading:"lazy"}):e.jsx("div",{className:"w-full h-full bg-gray-800 flex items-center justify-center",children:e.jsx("svg",{className:"w-8 h-8 text-gray-600",fill:"currentColor",viewBox:"0 0 20 20",children:e.jsx("path",{d:"M2 6a2 2 0 012-2h6a2 2 0 012 2v8a2 2 0 01-2 2H4a2 2 0 01-2-2V6zm12.553 1.106A1 1 0 0014 8v4a1 1 0 00.553.894l2 1A1 1 0 0018 13V7a1 1 0 00-1.447-.894l-2 1z"})})}),e.jsx("div",{className:"absolute inset-0 flex items-center justify-center opacity-0 group-hover:opacity-100 transition-opacity pointer-events-none",children:e.jsx("div",{className:"w-10 h-10 rounded-full bg-primary/80 flex items-center justify-center",children:e.jsx("svg",{className:"w-4 h-4 text-white ml-0.5",fill:"currentColor",viewBox:"0 0 20 20",children:e.jsx("path",{d:"M6.3 2.841A1.5 1.5 0 004 4.11V15.89a1.5 1.5 0 002.3 1.269l9.344-5.89a1.5 1.5 0 000-2.538L6.3 2.84z"})})})})]}),e.jsxs("div",{className:"flex flex-col gap-1",children:[e.jsx("p",{className:"text-foreground font-bold leading-tight line-clamp-2 hover:text-accent transition-colors",style:{fontSize:"14px",lineHeight:"16.8px"},children:e.jsx(_,{devId:"96f9d5",guard:{file:"src/components/VideoCard.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:aaf2320646108059a87ab5017a86aee454f5378ed95003dbb2e12f4ca5266e0e"},children:a})}),e.jsx("p",{className:"text-muted-foreground",style:{fontSize:"13px"},children:e.jsx(_,{devId:"96f9d6",guard:{file:"src/components/VideoCard.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:0e87632cd46bd4907c516317eb6d81fe0f921a23c7643018f21292894b470681"},children:r})}),e.jsxs("div",{className:"flex items-center gap-3 text-muted-foreground",style:{fontSize:"12px"},children:[e.jsxs("span",{className:"flex items-center gap-1",children:[e.jsx(xa,{size:12}),wf(o)]}),l!==void 0&&e.jsxs("span",{className:"flex items-center gap-1",children:[e.jsx(Gn,{size:12}),wf(l)]}),d!==void 0&&e.jsxs("span",{className:"flex items-center gap-1",children:[e.jsx(zC,{size:12}),wf(d)]})]})]})]})}function gA({href:t,...a}){return t?e.jsx(O,{to:t,className:"block no-underline",children:e.jsx(Tj,{...a})}):e.jsx(Tj,{...a})}function wu({title:t,videos:a,totalPages:r,seeAllHref:o}){return e.jsxs("section",{className:"mb-8",children:[e.jsxs("div",{className:"border-b-2 border-border mb-4 pb-2 flex items-end justify-between gap-3",children:[o?e.jsx(O,{to:o,className:"font-semibold uppercase text-foreground hover:text-primary transition-colors",style:{fontSize:"25.6px",lineHeight:"30.72px",fontWeight:500},children:t}):e.jsx("h2",{className:"font-semibold uppercase text-foreground",style:{fontSize:"25.6px",lineHeight:"30.72px",fontWeight:500},children:e.jsx(_,{devId:"d0568b",guard:{file:"src/components/VideoSection.tsx",tagName:"h2",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:aaf2320646108059a87ab5017a86aee454f5378ed95003dbb2e12f4ca5266e0e"},children:t})}),o&&e.jsx(O,{to:o,className:"text-accent text-sm hover:underline whitespace-nowrap shrink-0 mb-0.5",children:"See all →"})]}),e.jsx("div",{className:"grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-4 gap-4",children:a.map((l,d)=>e.jsx(gA,{...l},d))}),e.jsxs("div",{className:"flex items-center gap-1 mt-4 flex-wrap",style:{fontSize:"14px"},children:[e.jsx("span",{className:"inline-flex items-center justify-center w-7 h-7 text-white text-sm font-semibold bg-primary",children:"1"}),[2,3,4].map(l=>e.jsx("a",{href:"#",className:"inline-flex items-center justify-center w-7 h-7 text-accent hover:underline text-sm",children:l},l)),e.jsx("span",{className:"text-muted-foreground text-sm px-1",children:"…"}),o?e.jsx(O,{to:o,className:"text-accent hover:underline text-sm",children:r.toLocaleStr
vendor: 4,294 bytes, line 633
633ing()}):e.jsx("a",{href:"#",className:"text-accent hover:underline text-sm",children:e.jsx(_,{devId:"c58855",guard:{file:"src/components/VideoSection.tsx",tagName:"a",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:c9ffe19ab5fd2ad4e8d715274d886d83985e3f39419ba8672d11f30db8fcfbb8"},children:r.toLocaleString()})}),o?e.jsx(O,{to:o,className:"text-accent hover:underline text-sm ml-1",children:"Next →"}):e.jsx("a",{href:"#",className:"text-accent hover:underline text-sm ml-1",children:"Next →"})]})]})}const bA={active:!0,breakpoints:{},delay:4e3,jump:!1,playOnInit:!0,stopOnFocusIn:!0,stopOnInteraction:!0,stopOnMouseEnter:!1,stopOnLastSnap:!1,rootNode:null};function yA(t,a){const r=t.scrollSnapList();return typeof a=="number"?r.map(()=>a):a(r,t)}function vA(t,a){const r=t.rootNode();return a&&a(r)||r}function Wm(t={}){let a,r,o,l,d=null,u=0,m=!1,p=!1,x=!1,b=!1;function y(W,I){r=W;const{mergeOptions:k,optionsAtMedia:K}=I,L=k(bA,Wm.globalOptions),se=k(L,t);if(a=K(se),r.scrollSnapList().length<=1)return;b=a.jump,o=!1,l=yA(r,a.delay);const{eventStore:X,ownerDocument:le}=r.internalEngine(),ge=!!r.internalEngine().options.watchDrag,Se=vA(r,a.rootNode);X.add(le,"visibilitychange",z),ge&&r.on("pointerDown",M),ge&&!a.stopOnInteraction&&r.on("pointerUp",P),a.stopOnMouseEnter&&X.add(Se,"mouseenter",E),a.stopOnMouseEnter&&!a.stopOnInteraction&&X.add(Se,"mouseleave",U),a.stopOnFocusIn&&r.on("slideFocusStart",S),a.stopOnFocusIn&&!a.stopOnInteraction&&X.add(r.containerNode(),"focusout",A),a.playOnInit&&A()}function v(){r.off("pointerDown",M).off("pointerUp",P).off("slideFocusStart",S),S(),o=!0,m=!1}function w(){const{ownerWindow:W}=r.internalEngine();W.clearTimeout(u),u=W.setTimeout(Y,l[r.selectedScrollSnap()]),d=new Date().getTime(),r.emit("autoplay:timerset")}function C(){const{ownerWindow:W}=r.internalEngine();W.clearTimeout(u),u=0,d=null,r.emit("autoplay:timerstopped")}function A(){if(!o){if(T()){x=!0;return}m||r.emit("autoplay:play"),w(),m=!0}}function S(){o||(m&&r.emit("autoplay:stop"),C(),m=!1)}function z(){if(T())return x=m,S();x&&A()}function T(){const{ownerDocument:W}=r.internalEngine();return W.visibilityState==="hidden"}function M(){p||S()}function P(){p||A()}function E(){p=!0,S()}function U(){p=!1,A()}function q(W){typeof W<"u"&&(b=W),A()}function H(){m&&S()}function J(){m&&A()}function B(){return m}function Y(){const{index:W}=r.internalEngine(),I=W.clone().add(1).get(),k=r.scrollSnapList().length-1,K=a.stopOnLastSnap&&I===k;if(r.canScrollNext()?r.scrollNext(b):r.scrollTo(0,b),r.emit("autoplay:select"),K)return S();A()}function $(){if(!d)return null;const W=l[r.selectedScrollSnap()],I=new Date().getTime()-d;return W-I}return{name:"autoplay",options:t,init:y,destroy:v,play:q,stop:H,reset:J,isPlaying:B,timeUntilNext:$}}Wm.globalOptions=void 0;function jA(t){return Object.prototype.toString.call(t)==="[object Object]"}function Aj(t){return jA(t)||Array.isArray(t)}function wA(){return!!(typeof window<"u"&&window.document&&window.document.createElement)}function pg(t,a){const r=Object.keys(t),o=Object.keys(a);if(r.length!==o.length)return!1;const l=JSON.stringify(Object.keys(t.breakpoints||{})),d=JSON.stringify(Object.keys(a.breakpoints||{}));return l!==d?!1:r.every(u=>{const m=t[u],p=a[u];return typeof m=="function"?`${m}`==`${p}`:!Aj(m)||!Aj(p)?m===p:pg(m,p)})}function Ej(t){return t.concat().sort((a,r)=>a.name>r.name?1:-1).map(a=>a.options)}function NA(t,a){if(t.length!==a.length)return!1;const r=Ej(t),o=Ej(a);return r.every((l,d)=>{const u=o[d];return pg(l,u)})}function fg(t){return typeof t=="number"}function hx(t){return typeof t=="string"}function qm(t){return typeof t=="boolean"}function Hj(t){return Object.prototype.toString.call(t)==="[object Object]"}function bs(t){return Math.abs(t)}function xg(t){return Math.sign(t)}function kc(t,a){return bs(t-a)}function SA(t,a){if(t===0||a===0||bs(t)<=bs(a))return 0;const r=kc(bs(t),bs(a));return bs(r/t)}function CA(t){return Math.round(t*100)/100}function Uc(t){return Pc(t).map(Number)}function Cn(t){return t[Xc(t)]}function Xc(t){return Math.max(0,t.length-1)}function gg(t,a){return a===Xc(t)}function zj(t,a=0){return Array.from(Array(t),(r,o)=>a+o)}function Pc(t){return Object.keys(t)}function C2(t,a){return[t,a].reduce((r,o)=>
vendor: 16,920 bytes, line 633
633(Pc(o).forEach(l=>{const d=r[l],u=o[l],m=Hj(d)&&Hj(u);r[l]=m?C2(d,u):u}),r),{})}function px(t,a){return typeof a.MouseEvent<"u"&&t instanceof a.MouseEvent}function kA(t,a){const r={start:o,center:l,end:d};function o(){return 0}function l(p){return d(p)/2}function d(p){return a-p}function u(p,x){return hx(t)?r[t](p):t(a,p,x)}return{measure:u}}function Kc(){let t=[];function a(l,d,u,m={passive:!0}){let p;if("addEventListener"in l)l.addEventListener(d,u,m),p=()=>l.removeEventListener(d,u,m);else{const x=l;x.addListener(u),p=()=>x.removeListener(u)}return t.push(p),o}function r(){t=t.filter(l=>l())}const o={add:a,clear:r};return o}function TA(t,a,r,o){const l=Kc(),d=1e3/60;let u=null,m=0,p=0;function x(){l.add(t,"visibilitychange",()=>{t.hidden&&C()})}function b(){w(),l.clear()}function y(S){if(!p)return;u||(u=S,r(),r());const z=S-u;for(u=S,m+=z;m>=d;)r(),m-=d;const T=m/d;o(T),p&&(p=a.requestAnimationFrame(y))}function v(){p||(p=a.requestAnimationFrame(y))}function w(){a.cancelAnimationFrame(p),u=null,m=0,p=0}function C(){u=null,m=0}return{init:x,destroy:b,start:v,stop:w,update:r,render:o}}function AA(t,a){const r=a==="rtl",o=t==="y",l=o?"y":"x",d=o?"x":"y",u=!o&&r?-1:1,m=b(),p=y();function x(C){const{height:A,width:S}=C;return o?A:S}function b(){return o?"top":r?"right":"left"}function y(){return o?"bottom":r?"left":"right"}function v(C){return C*u}return{scroll:l,cross:d,startEdge:m,endEdge:p,measureSize:x,direction:v}}function no(t=0,a=0){const r=bs(t-a);function o(x){return x<t}function l(x){return x>a}function d(x){return o(x)||l(x)}function u(x){return d(x)?o(x)?t:a:x}function m(x){return r?x-r*Math.ceil((x-a)/r):x}return{length:r,max:a,min:t,constrain:u,reachedAny:d,reachedMax:l,reachedMin:o,removeOffset:m}}function k2(t,a,r){const{constrain:o}=no(0,t),l=t+1;let d=u(a);function u(v){return r?bs((l+v)%l):o(v)}function m(){return d}function p(v){return d=u(v),y}function x(v){return b().set(m()+v)}function b(){return k2(t,m(),r)}const y={get:m,set:p,add:x,clone:b};return y}function EA(t,a,r,o,l,d,u,m,p,x,b,y,v,w,C,A,S,z,T){const{cross:M,direction:P}=t,E=["INPUT","SELECT","TEXTAREA"],U={passive:!1},q=Kc(),H=Kc(),J=no(50,225).constrain(w.measure(20)),B={mouse:300,touch:400},Y={mouse:500,touch:600},$=C?43:25;let D=!1,W=0,I=0,k=!1,K=!1,L=!1,se=!1;function X(ve){if(!T)return;function ze(ct){(qm(T)||T(ve,ct))&&We(ct)}const Ue=a;q.add(Ue,"dragstart",ct=>ct.preventDefault(),U).add(Ue,"touchmove",()=>{},U).add(Ue,"touchend",()=>{}).add(Ue,"touchstart",ze).add(Ue,"mousedown",ze).add(Ue,"touchcancel",te).add(Ue,"contextmenu",te).add(Ue,"click",me,!0)}function le(){q.clear(),H.clear()}function ge(){const ve=se?r:a;H.add(ve,"touchmove",Ye,U).add(ve,"touchend",te).add(ve,"mousemove",Ye,U).add(ve,"mouseup",te)}function Se(ve){const ze=ve.nodeName||"";return E.includes(ze)}function Me(){return(C?Y:B)[se?"mouse":"touch"]}function st(ve,ze){const Ue=y.add(xg(ve)*-1),ct=b.byDistance(ve,!C).distance;return C||bs(ve)<J?ct:S&&ze?ct*.5:b.byIndex(Ue.get(),0).distance}function We(ve){const ze=px(ve,o);se=ze,L=C&&ze&&!ve.buttons&&D,D=kc(l.get(),u.get())>=2,!(ze&&ve.button!==0)&&(Se(ve.target)||(k=!0,d.pointerDown(ve),x.useFriction(0).useDuration(0),l.set(u),ge(),W=d.readPoint(ve),I=d.readPoint(ve,M),v.emit("pointerDown")))}function Ye(ve){if(!px(ve,o)&&ve.touches.length>=2)return te(ve);const Ue=d.readPoint(ve),ct=d.readPoint(ve,M),Ot=kc(Ue,W),Et=kc(ct,I);if(!K&&!se&&(!ve.cancelable||(K=Ot>Et,!K)))return te(ve);const Zt=d.pointerMove(ve);Ot>A&&(L=!0),x.useFriction(.3).useDuration(.75),m.start(),l.add(P(Zt)),ve.preventDefault()}function te(ve){const Ue=b.byDistance(0,!1).index!==y.get(),ct=d.pointerUp(ve)*Me(),Ot=st(P(ct),Ue),Et=SA(ct,Ot),Zt=$-10*Et,as=z+Et/50;K=!1,k=!1,H.clear(),x.useDuration(Zt).useFriction(as),p.distance(Ot,!C),se=!1,v.emit("pointerUp")}function me(ve){L&&(ve.stopPropagation(),ve.preventDefault(),L=!1)}function Le(){return k}return{init:X,destroy:le,pointerDown:Le}}function HA(t,a){let o,l;function d(y){return y.timeStamp}function u(y,v){const C=`client${(v||t.scroll)==="x"?"X":"Y"}`;return(px(y,a)?y:y.touches[0])[C]}function m(y){return o=y,l=y,u(y)}function p(y){const v=u(y)-u(l),w=d(y)-d(o)>170;return l=y,w&&(o=y),v}function x(y){if(!o||!l)return 0;const v=u(l)-u(o),w=d(y)-d(o),C=d(y)-d(l)>170,A=v/w;return w&&!C&&bs(A)>.1?A:0}return{pointerDown:m,pointerMove:p,pointerUp:x,readPoint:u}}function zA(){function t(r){const{offsetTop:o,offsetLeft:l,offsetWidth:d,offsetHeight:u}=r;return{top:o,right:l+d,bottom:o+u,left:l,width:d,height:u}}return{measure:t}}function RA(t){function a(o){return t*(o/100)}return{measure:a}}function _A(t,a,r,o,l,d,u){const m=[t].concat(o);let p,x,b=[],y=!1;function v(S){return l.measureSize(u.measure(S))}function w(S){if(!d)return;x=v(t),b=o.map(v);function z(T){for(const M of T){if(y)return;const P=M.target===t,E=o.indexOf(M.target),U=P?x:b[E],q=v(P?t:o[E]);if(bs(q-U)>=.5){S.reInit(),a.emit("resize");break}}}p=new ResizeObserver(T=>{(qm(d)||d(S,T))&&z(T)}),r.requestAnimationFrame(()=>{m.forEach(T=>p.observe(T))})}function C(){y=!0,p&&p.disconnect()}return{init:w,destroy:C}}function LA(t,a,r,o,l,d){let u=0,m=0,p=l,x=d,b=t.get(),y=0;function v(){const U=o.get()-t.get(),q=!p;let H=0;return q?(u=0,r.set(o),t.set(o),H=U):(r.set(t),u+=U/p,u*=x,b+=u,t.add(u),H=b-y),m=xg(H),y=b,E}function w(){const U=o.get()-a.get();return bs(U)<.001}function C(){return p}function A(){return m}function S(){return u}function z(){return M(l)}function T(){return P(d)}function M(U){return p=U,E}function P(U){return x=U,E}const E={direction:A,duration:C,velocity:S,seek:v,settled:w,useBaseFriction:T,useBaseDuration:z,useFriction:P,useDuration:M};return E}function DA(t,a,r,o,l){const d=l.measure(10),u=l.measure(50),m=no(.1,.99);let p=!1;function x(){return!(p||!t.reachedAny(r.get())||!t.reachedAny(a.get()))}function b(w){if(!x())return;const C=t.reachedMin(a.get())?"min":"max",A=bs(t[C]-a.get()),S=r.get()-a.get(),z=m.constrain(A/u);r.subtract(S*z),!w&&bs(S)<d&&(r.set(t.constrain(r.get())),o.useDuration(25).useBaseFriction())}function y(w){p=!w}return{shouldConstrain:x,constrain:b,toggleActive:y}}function OA(t,a,r,o,l){const d=no(-a+t,0),u=y(),m=b(),p=v();function x(C,A){return kc(C,A)<=1}function b(){const C=u[0],A=Cn(u),S=u.lastIndexOf(C),z=u.indexOf(A)+1;return no(S,z)}function y(){return r.map((C,A)=>{const{min:S,max:z}=d,T=d.constrain(C),M=!A,P=gg(r,A);return M?z:P||x(S,T)?S:x(z,T)?z:T}).map(C=>parseFloat(C.toFixed(3)))}function v(){if(a<=t+l)return[d.max];if(o==="keepSnaps")return u;const{min:C,max:A}=m;return u.slice(C,A)}return{snapsContained:p,scrollContainLimit:m}}function MA(t,a,r){const o=a[0],l=r?o-t:Cn(a);return{limit:no(l,o)}}function UA(t,a,r,o){const d=a.min+.1,u=a.max+.1,{reachedMin:m,reachedMax:p}=no(d,u);function x(v){return v===1?p(r.get()):v===-1?m(r.get()):!1}function b(v){if(!x(v))return;const w=t*(v*-1);o.forEach(C=>C.add(w))}return{loop:b}}function PA(t){const{max:a,length:r}=t;function o(d){const u=d-a;return r?u/-r:0}return{get:o}}function KA(t,a,r,o,l){const{startEdge:d,endEdge:u}=t,{groupSlides:m}=l,p=y().map(a.measure),x=v(),b=w();function y(){return m(o).map(A=>Cn(A)[u]-A[0][d]).map(bs)}function v(){return o.map(A=>r[d]-A[d]).map(A=>-bs(A))}function w(){return m(x).map(A=>A[0]).map((A,S)=>A+p[S])}return{snaps:x,snapsAligned:b}}function IA(t,a,r,o,l,d){const{groupSlides:u}=l,{min:m,max:p}=o,x=b();function b(){const v=u(d),w=!t||a==="keepSnaps";return r.length===1?[d]:w?v:v.slice(m,p).map((C,A,S)=>{const z=!A,T=gg(S,A);if(z){const M=Cn(S[0])+1;return zj(M)}if(T){const M=Xc(d)-Cn(S)[0]+1;return zj(M,Cn(S)[0])}return C})}return{slideRegistry:x}}function BA(t,a,r,o,l){const{reachedAny:d,removeOffset:u,constrain:m}=o;function p(C){return C.concat().sort((A,S)=>bs(A)-bs(S))[0]}function x(C){const A=t?u(C):m(C),S=a.map((T,M)=>({diff:b(T-A,0),index:M})).sort((T,M)=>bs(T.diff)-bs(M.diff)),{index:z}=S[0];return{index:z,distance:A}}function b(C,A){const S=[C,C+r,C-r];if(!t)return C;if(!A)return p(S);const z=S.filter(T=>xg(T)===A);return z.length?p(z):Cn(S)-r}function y(C,A){const S=a[C]-l.get(),z=b(S,A);return{index:C,distance:z}}function v(C,A){const S=l.get()+C,{index:z,distance:T}=x(S),M=!t&&d(S);if(!A||M)return{index:z,distance:C};const P=a[z]-T,E=C+b(P,0);return{index:z,distance:E}}return{byDistance:v,byIndex:y,shortcut:b}}function $A(t,a,r,o,l,d,u){function m(y){const v=y.distance,w=y.index!==a.get();d.add(v),v&&(o.duration()?t.start():(t.update(),t.render(1),t.update())),w&&(r.set(a.get()),a.set(y.index),u.emit("select"))}function p(y,v){const w=l.byDistance(y,v);m(w)}function x(y,v){const w=a.clone().set(y),C=l.byIndex(w.get(),v);m(C)}return{distance:p,index:x}}function VA(t,a,r,o,l,d,u,m){const p={passive:!0,capture:!0};let x=0;function b(w){if(!m)return;function C(A){if(new Date().getTime()-x>10)return;u.emit("slideFocusStart"),t.scrollLeft=0;const T=r.findIndex(M=>M.includes(A));fg(T)&&(l.useDuration(0),o.index(T,0),u.emit("slideFocus"))}d.add(document,"keydown",y,!1),a.forEach((A,S)=>{d.add(A,"focus",z=>{(qm(m)||m(w,z))&&C(S)},p)})}function y(w){w.code==="Tab"&&(x=new Date().getTime())}return{init:b}}function jc(t){let a=t;function r(){return a}function o(p){a=u(p)}function l(p){a+=u(p)}function d(p){a-=u(p)}function u(p){return fg(p)?p:p.get()}return{get:r,set:o,add:l,subtract:d}}function T2(t,a){const r=t.scroll==="x"?u:m,o=a.style;let l=null,d=!1;function u(v){return`translate3d(${v}px,0px,0px)`}function m(v){return`translate3d(0px,${v}px,0px)`}function p(v){if(d)return;const w=CA(t.direction(v));w!==l&&(o.transform=r(w),l=w)}function x(v){d=!v}function b(){d||(o.transform="",a.getAttribute("style")||a.removeAttribute("style"))}return{clear:b,to:p,toggleActive:x}}function FA(t,a,r,o,l,d,u,m,p){const b=Uc(l),y=Uc(l).reverse(),v=z().concat(T());function w(q,H){return q.reduce((J,B)=>J-l[B],H)}function C(q,H){return q.reduce((J,B)=>w(J,H)>0?J.concat([B]):J,[])}function A(q){return d.map((H,J)=>({start:H-o[J]+.5+q,end:H+a-.5+q}))}function S(q,H,J){const B=A(H);return q.map(Y=>{const $=J?0:-r,D=J?r:0,W=J?"end":"start",I=B[Y][W];return{index:Y,loopPoint:I,slideLocation:jc(-1),translate:T2(t,p[Y]),target:()=>m.get()>I?$:D}})}function z(){const q=u[0],H=C(y,q);return S(H,r,!1)}function T(){const q=a-u[0]-1,H=C(b,q);return S(H,-r,!0)}function M(){return v.every(({index:q})=>{const H=b.filter(J=>J!==q);return w(H,a)<=.1})}function P(){v.forEach(q=>{const{target:H,translate:J,slideLocation:B}=q,Y=H();Y!==B.get()&&(J.to(Y),B.set(Y))})}function E(){v.forEach(q=>q.translate.clear())}return{canLoop:M,clear:E,loop:P,loopPoints:v}}function WA(t,a,r){let o,l=!1;function d(p){if(!r)return;function x(b){for(const y of b)if(y.type==="childList"){p.reInit(),a.emit("slidesChanged");break}}o=new MutationObserver(b=>{l||(qm(r)||r(p,b))&&x(b)}),o.observe(t,{childList:!0})}function u(){o&&o.disconnect(),l=!0}return{init:d,destroy:u}}function qA(t,a,r,o){const l={};let d=null,u=null,m,p=!1;function x(){m=new IntersectionObserver(C=>{p||(C.forEach(A=>{const S=a.indexOf(A.target);l[S]=A}),d=null,u=null,r.emit("slidesInView"))},{root:t.parentElement,threshold:o}),a.forEach(C=>m.observe(C))}function b(){m&&m.disconnect(),p=!0}function y(C){return Pc(l).reduce((A,S)=>{const z=parseInt(S),{isIntersecting:T}=l[z];return(C&&T||!C&&!T)&&A.push(z),A},[])}function v(C=!0){if(C&&d)return d;if(!C&&u)return u;const A=y(C);return C&&(d=A),C||(u=A),A}return{init:x,destroy:b,get:v}}function YA(t,a,r,o,l,d){const{measureSize:u,startEdge:m,endEdge:p}=t,x=r[0]&&l,b=C(),y=A(),v=r.map(u),w=S();function C(){if(!x)return 0;const T=r[0];return bs(a[m]-T[m])}function A(){if(!x)return 0;const T=d.getComputedStyle(Cn(o));return parseFloat(T.getPropertyValue(`margin-${p}`))}function S(){return r.map((T,M,P)=>{const E=!M,U=gg(P,M);return E?v[M]+b:U?v[M]+y:P[M+1][m]-T[m]}).map(bs)}return{slideSizes:v,slideSizesWithGaps:w,startGap:b,endGap:y}}function GA(t,a,r,o,l,d,u,m,p){const{startEdge:x,endEdge:b,direction:y}=t,v=fg(r);function w(z,T){return Uc(z).filter(M=>M%T===0).map(M=>z.slice(M,M+T))}function C(z){return z.length?Uc(z).reduce((T,M,P)=>{const E=Cn(T)||0,U=E===0,q=M===Xc(z),H=l[x]-d[E][x],J=l[x]-d[M][b],B=!o&&U?y(u):0,Y=!o&&q?y(m):0,$=bs(J-Y-(H+B));return P&&$>a+p&&T.push(M),q&&T.push(z.length),T},[]).map((T,M,P)=>{const E=Math.max(P[M-1]||0);return z.slice(E,T)}):[]}function A(z){return v?w(z,r):C(z)}return{groupSlides:A}}function ZA(t,a,r,o,l,d,u){const{align:m,axis:p,direction:x,startIndex:b,loop:y,duration:v,dragFree:w,dragThreshold:C,inViewThreshold:A,slidesToScroll:S,skipSnaps:z,containScroll:T,watchResize:M,watchSlides:P,watchDrag:E,watchFocus:U}=d,q=2,H=zA(),J=H.measure(a),B=r.map(H.measure),Y=AA(p,x),$=Y.measureSize(J),D=RA($),W=kA(m,$),I=!y&&!!T,k=y||!!T,{slideSizes:K,slideSizesWithGaps:L,startGap:se,endGap:X}=YA(Y,J,B,r,k,l),le=GA(Y,$,S,y,J,B,se,X,q),{snaps:ge,snapsAligned:Se}=KA(Y,W,J,B,le),Me=-Cn(ge)+Cn(L),{snapsContained:st,scrollContainLimit:We}=OA($,Me,Se,T,q),Ye=I?st:Se,{limit:te}=MA(Me,Ye,y),me=k2(Xc(Ye),b,y),Le=me.clone(),Ie=Uc(r),ve=({dragHandler:qt,scrollBody:je,scrollBounds:gt,options:{loop:et}})=>{et||gt.constrain(qt.pointerDown()),je.seek()},ze=({scrollBody:qt,translate:je,location:gt,offsetLocation:et,previousLocation:Xe,scrollLooper:Ae,slideLooper:De,dragHandler:ft,animation:Yt,eventHandler:ls,scrollBounds:qs,options:{loop:ue}},be)=>{const _t=qt.settled(),ns=!qs.shouldConstrain(),Ct=ue?_t:_t&&ns,Ut=Ct&&!ft.pointerDown();Ut&&Yt.stop();const Qs=gt.get()*be+Xe.get()*(1-be);et.set(Qs),ue&&(Ae.loop(qt.direction()),De.loop()),je.to(et.get()),Ut&&ls.emit("settle"),Ct||ls.emit("scroll")},Ue=TA(o,l,()=>ve(os),qt=>ze(os,qt)),ct=.68,Ot=Ye[me.get()],Et=jc(Ot),Zt=jc(Ot),as=jc(Ot),Jt=jc(Ot),vs=LA(Et,as,Zt,Jt,v,ct),js=BA(y,Ye,Me,te,Jt),Ws=$A(Ue,me,Le,vs,js,Jt,u),Mt=PA(te),jt=Kc(),ps=qA(a,r,u,A),{slideRegistry:Wt}=IA(I,T,Ye,We,le,Ie),ws=VA(t,r,Wt,Ws,vs,jt,u,U),os={ownerDocument:o,ownerWindow:l,eventHandler:u,containerRect:J,slideRects:B,animation:Ue,axis:Y,dragHandler:EA(Y,t,o,l,Jt,HA(Y,l),Et,Ue,Ws,vs,js,me,u,D,w,C,z,ct,E),eventStore:jt,percentOfView:D,index:me,indexPrevious:Le,limit:te,location:Et,offsetLocation:as,previousLocation:Zt,options:d,resizeHandler:_A(a,u,l,r,Y,M,H),scrollBody:vs,scrollBounds:DA(te,as,Jt,vs,D),scrollLooper:UA(Me,te,as,[Et,as,Zt,Jt]),scrollProgress:Mt,scrollSnapList:Ye.map(Mt.get),scrollSnaps:Ye,scrollTarget:js,scrollTo:Ws,slideLooper:FA(Y,$,Me,K,L,ge,Ye,as,r),slideFocus:ws,slidesHandler:WA(a,u,P),slidesInView:ps,slideIndexes:Ie,slideRegistry:Wt,slidesToScroll:le,target:Jt,translate:T2(Y,a)};return os}function JA(){let t={},a;function r(x){a=x}function o(x){return t[x]||[]}function l(x){return o(x).forEach(b=>b(a,x)),p}function d(x,b){return t[x]=o(x).concat([b]),p}function u(x,b){return t[x]=o(x).filter(y=>y!==b),p}function m(){t={}}const p={init:r,emit:l,off:u,on:d,clear:m};return p}const XA={align:"center",axis:"x",container:null,slides:null,containScroll:"trimSnaps",direction:"ltr",slidesToScroll:1,inViewThreshold:0,breakpoints:{},dragFree:!1,dragThreshold:10,loop:!1,skipSnaps:!1,duration:25,startIndex:0,active:!0,watchDrag:!0,watchResize:!0,watchSlides:!0,watchFocus:!0};function QA(t){function a(d,u){return C2(d,u||{})}function r(d){const u=d.breakpoints||{},m=Pc(u).filter(p=>t.matchMedia(p).matches).map(p=>u[p]).reduce((p,x)=>a(p,x),{});return a(d,m)}function o(d){return d.map(u=>Pc(u.breakpoints||{})).reduce((u,m)=>u.concat(m),[]).map(t.matchMedia)}return{mergeOptions:a,optionsAtMedia:r,optionsMediaQueries:o}}function eE(t){let a=[];function r(d,u){return a=u.filter(({options:m})=>t.optionsAtMedia(m).active!==!1),a.forEach(m=>m.init(d,t)),u.reduce((m,p)=>Object.assign(m,{[p.name]:p}),{})}function o(){a=a.filter(d=>d.destroy())}return{init:r,destroy:o}}function Yu(t,a,r){const o=t.ownerDocument,l=o.defaultView,d=QA(l),u=eE(d),m=Kc(),p=JA(),{mergeOptions:x,optionsAtMedia:b,optionsMediaQueries:y}=d,{on:v,off:w,emit:C}=p,A=Y;let S=!1,z,T=x(XA,Yu.globalOptions),M=x(T),P=[],E,U,q;function H(){const{container:Ie,slides:ve}=M;U=(hx(Ie)?t.querySelector(Ie):Ie)||t.children[0];const Ue=hx(ve)?U.querySelectorAll(ve):ve;q=[].slice.call(Ue||U.children)}function J(Ie){const ve=ZA(t,U,q,o,l,Ie,p);if(Ie.loop&&!ve.slideLooper.canLoop()){const ze=Object.assign({},Ie,{loop:!1});return J(ze)}return ve}function B(Ie,ve){S||(T=x(T,Ie),M=b(T),P=ve||P,H(),z=J(M),y([T,...P.map(({options:ze})=>ze)]).forEach(ze=>m.add(ze,"change",Y)),M.active&&(z.translate.to(z.location.get()),z.animation.init(),z.slidesInView.init(),z.slideFocus.init(Le),z.eventHandler.init(Le),z.resizeHandler.init(Le),z.slidesHandler.init(Le),z.options.loop&&z.slideLooper.loop(),U.offsetParent&&q.length&&z.dragHandler.init(Le),E=u.init(Le,P)))}function Y(Ie,ve){const ze=le();$(),B(x({startIndex:ze},Ie),ve),p.emit("reInit")}function $(){z.dragHandler.destroy(),z.eventStore.clear(),z.translate.clear(),z.slideLooper.clear(),z.resizeHandler.destroy(),z.slidesHandler.destroy(),z.slidesInView.destroy(),z.animation.destroy(),u.destroy(),m.clear()}
633function D(){S||(S=!0,m.clear(),$(),p.emit("destroy"),p.clear())}function W(Ie,ve,ze){!M.active||S||(z.scrollBody.useBaseFriction().useDuration(ve===!0?0:M.duration),z.scrollTo.index(Ie,ze||0))}function I(Ie){const ve=z.index.add(1).get();W(ve,Ie,-1)}function k(Ie){const ve=z.index.add(-1).get();W(ve,Ie,1)}function K(){return z.index.add(1).get()!==le()}function L(){return z.index.add(-1).get()!==le()}function se(){return z.scrollSnapList}function X(){return z.scrollProgress.get(z.offsetLocation.get())}function le(){return z.index.get()}function ge(){return z.indexPrevious.get()}function Se(){return z.slidesInView.get()}function Me(){return z.slidesInView.get(!1)}function st(){return E}function We(){return z}function Ye(){return t}function te(){return U}function me(){return q}const Le={canScrollNext:K,canScrollPrev:L,containerNode:te,internalEngine:We,destroy:D,off:w,on:v,emit:C,plugins:st,previousScrollSnap:ge,reInit:A,rootNode:Ye,scrollNext:I,scrollPrev:k,scrollProgress:X,scrollSnapList:se,scrollTo:W,selectedScrollSnap:le,slideNodes:me,slidesInView:Se,slidesNotInView:Me};return B(a,r),setTimeout(()=>p.emit("init"),0),Le}Yu.globalOptions=void 0;function bg(t={},a=[]){const r=g.useRef(t),o=g.useRef(a),[l,d]=g.useState(),[u,m]=g.useState(),p=g.useCallback(()=>{l&&l.reInit(r.current,o.current)},[l]);return g.useEffect(()=>{pg(r.current,t)||(r.current=t,p())},[t,p]),g.useEffect(()=>{NA(o.current,a)||(o.current=a,p())},[a,p]),g.useEffect(()=>{if(wA()&&u){Yu.globalOptions=bg.globalOptions;const x=Yu(u,r.current,o.current);return d(x),()=>x.destroy()}else d(void 0)},[u,d]),[m,l]}bg.globalOptions=void 0;const Rj=t=>typeof t=="boolean"?`${t}`:t===0?"0":t,_j=x2,tE=(t,a)=>r=>{var o;if((a==null?void 0:a.variants)==null)return _j(t,r==null?void 0:r.class,r==null?void 0:r.className);const{variants:l,defaultVariants:d}=a,u=Object.keys(l).map(x=>{const b=r==null?void 0:r[x],y=d==null?void 0:d[x];if(b===null)return null;const v=Rj(b)||Rj(y);return l[x][v]}),m=r&&Object.entries(r).reduce((x,b)=>{let[y,v]=b;return v===void 0||(x[y]=v),x},{}),p=a==null||(o=a.compoundVariants)===null||o===void 0?void 0:o.reduce((x,b)=>{let{class:y,className:v,...w}=b;return Object.entries(w).every(C=>{let[A,S]=C;return Array.isArray(S)?S.includes({...d,...m}[A]):{...d,...m}[A]===S})?[...x,y,v]:x},[]);return _j(t,u,p,r==null?void 0:r.class,r==null?void 0:r.className)},sE=tE("inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-[var(--radius-button)] text-sm font-medium ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",{variants:{variant:{default:"bg-primary text-primary-foreground hover:bg-primary/90",destructive:"bg-destructive text-destructive-foreground hover:bg-destructive/90",outline:"border border-input bg-transparent text-foreground hover:bg-accent hover:text-accent-foreground",secondary:"bg-secondary text-secondary-foreground hover:bg-secondary/80",ghost:"hover:bg-accent hover:text-accent-foreground",link:"text-primary underline-offset-4 hover:underline"},size:{default:"h-10 px-4 py-2",sm:"h-9 rounded-[var(--radius-button)] px-3",lg:"h-11 rounded-[var(--radius-button)] px-8",icon:"h-10 w-10"}},defaultVariants:{variant:"default",size:"default"}}),Qc=g.forwardRef(({className:t,variant:a,size:r,asChild:o=!1,...l},d)=>{const u=o?j4:"button";return e.jsx(u,{className:io(sE({variant:a,size:r,className:t})),ref:d,...l})});Qc.displayName="Button";const A2=g.createContext(null);function Ym(){const t=g.useContext(A2);if(!t)throw new Error("useCarousel must be used within a <Carousel />");return t}const yg=g.forwardRef(({orientation:t="horizontal",opts:a,setApi:r,plugins:o,className:l,children:d,...u},m)=>{const[p,x]=bg({...a,axis:t==="horizontal"?"x":"y"},o),[b,y]=g.useState(!1),[v,w]=g.useState(!1),C=g.useRef(null),A=g.useCallback(U=>{C.current=U,typeof m=="function"?m(U):m&&(m.current=U)},[m]),S=g.useCallback(U=>{U&&(y(U.canScrollPrev()),w(U.canScrollNext()))},[]),z=g.useCallback(()=>{x==null||x.scrollPrev()},[x]),T=g.useCallback(()=>{x==null||x.scrollNext()},[x]),M=g.useCallback(U=>{U.key==="ArrowLeft"?(U.preventDefault(),z()):U.key==="ArrowRight"&&(U.preventDefault(),T())},[z,T]);g.useEffect(()=>{!x||!r||r(x)},[x,r]),g.useEffect(()=>{if(x)return S(x),x.on("reInit",S),x.on("select",S),()=>{x==null||x.off("select",S)}},[x,S]);const[P,E]=g.useState(!1);return g.useEffect(()=>{const U=()=>{const q=!!window.__airoCarouselSlotEditActive,H=window.__airoCarouselSlotEditRoot;E(!!(q&&C.current&&H===C.current))};return U(),window.addEventListener("airo:carousel-slot-edit",U),()=>{window.removeEventListener("airo:carousel-slot-edit",U)}},[]),g.useEffect(()=>{const U=()=>{!C.current||!window.__airoCarouselSlotEditActive||window.__airoCarouselSlotEditRoot===C.current&&window.dispatchEvent(new CustomEvent("airo:carousel-slot-nav-state",{detail:{canScrollPrev:b,canScrollNext:v,carouselRoot:C.current}}))};return U(),window.addEventListener("airo:carousel-slot-edit",U),()=>{window.removeEventListener("airo:carousel-slot-edit",U)}},[b,v,P]),g.useEffect(()=>{const U=q=>{const H=q.detail;!C.current||window.__airoCarouselSlotEditRoot!==C.current||((H==null?void 0:H.direction)==="prev"&&b?z():(H==null?void 0:H.direction)==="next"&&v&&T())};return window.addEventListener("airo:carousel-slot-nav",U),()=>{window.removeEventListener("airo:carousel-slot-nav",U)}},[z,T,b,v]),g.useEffect(()=>{if(!x||!P)return;const U=()=>{C.current&&window.__airoCarouselSlotEditRoot===C.current&&window.dispatchEvent(new CustomEvent("airo:carousel-slot-select",{detail:{carouselRoot:C.current,selectedIndex:x.selectedScrollSnap()}}))};return x.on("select",U),()=>{x.off("select",U)}},[x,P]),g.useEffect(()=>{if(!x)return;const U=()=>{const W=x.plugins().autoplay;
633if(W&&typeof W.stop=="function"&&typeof W.play=="function")return W},q=()=>{const W=C.current;if(!W)return!1;if(window.__airoCarouselSlotEditActive){const I=window.__airoCarouselSlotEditRoot;if(I==null||I===W)return!0}return window.__airoCarouselToolbarPauseRoot===W},H=W=>{const I=U();I&&(W?I.stop():I.play())},J=()=>{H(q())};J();const B=()=>{J()},Y=()=>{q()&&queueMicrotask(()=>{var W;q()&&((W=U())==null||W.stop())})};window.addEventListener("airo:carousel-slot-edit",B),window.addEventListener("airo:carousel-toolbar-pause",B);const $=x.on,D=x.off;return $("autoplay:play",Y),()=>{window.removeEventListener("airo:carousel-slot-edit",B),window.removeEventListener("airo:carousel-toolbar-pause",B),D("autoplay:play",Y)}},[x]),e.jsx(A2.Provider,{value:{carouselRef:p,api:x,opts:a,orientation:t||((a==null?void 0:a.axis)==="y"?"vertical":"horizontal"),scrollPrev:z,scrollNext:T,canScrollPrev:b,canScrollNext:v,carouselSlotEditActive:P},children:e.jsx("div",{ref:A,onKeyDownCapture:M,className:io("relative",l),role:"region","aria-roledescription":"carousel",...u,children:d})})});yg.displayName="Carousel";const vg=g.forwardRef(({className:t,...a},r)=>{const{carouselRef:o,orientation:l}=Ym();return e.jsx("div",{ref:o,className:"overflow-hidden",children:e.jsx("div",{ref:r,className:io("flex",l==="horizontal"?"-ml-4":"-mt-4 flex-col",t),...a})})});vg.displayName="CarouselContent";const Gu=g.forwardRef(({className:t,...a},r)=>{const{orientation:o}=Ym();return e.jsx("div",{ref:r,role:"group","aria-roledescription":"slide",className:io("min-w-0 shrink-0 grow-0 basis-full",o==="horizontal"?"pl-4":"pt-4",t),...a})});Gu.displayName="CarouselItem";const E2=g.forwardRef(({className:t,variant:a="outline",size:r="icon",...o},l)=>{const{orientation:d,scrollPrev:u,canScrollPrev:m,carouselSlotEditActive:p}=Ym();return p?null:e.jsxs(Qc,{ref:l,variant:a,size:r,className:io("absolute  h-8 w-8 rounded-full",d==="horizontal"?"-left-12 top-1/2 -translate-y-1/2":"-top-12 left-1/2 -translate-x-1/2 rotate-90",t),disabled:!m,onClick:u,...o,children:[e.jsx(wC,{className:"h-4 w-4"}),e.jsx("span",{className:"sr-only",children:"Previous slide"})]})});E2.displayName="CarouselPrevious";const H2=g.forwardRef(({className:t,variant:a="outline",size:r="icon",...o},l)=>{const{orientation:d,scrollNext:u,canScrollNext:m,carouselSlotEditActive:p}=Ym();return p?null:e.jsxs(Qc,{ref:l,variant:a,size:r,className:io("absolute h-8 w-8 rounded-full",d==="horizontal"?"-right-12 top-1/2 -translate-y-1/2":"-bottom-12 left-1/2 -translate-x-1/2 rotate-90",t),disabled:!m,onClick:u,...o,children:[e.jsx(NC,{className:"h-4 w-4"}),e.jsx("span",{className:"sr-only",children:"Next slide"})]})});H2.displayName="CarouselNext";const aE=[{src:"/airo-assets/images/sponsors/wdaa",alt:"Western Dressage Association of America (WDAA)",href:"https://www.westerndressageassociation.org/"},{src:"/airo-assets/images/sponsors/321-action-video",alt:"321 Action Video",href:"https://www.321actionvideo.com/"},{src:"/airo-assets/images/sponsors/debbie-brooks-ny",alt:"Debbie Brooks Equestrian Collection",href:"https://www.debbiebrooks.com/"},{src:"/airo-assets/images/sponsors/national-sports-broadcasting",alt:"National Sports Broadcasting",href:"https://www.nationalsportsbroadcasting.com/"},{src:"/airo-assets/images/sponsors/raindancer-video",alt:"RainDancer Video",href:"https://www.raindancervideo.com/"},{src:"/airo-assets/images/sponsors/seehorse-video",alt:"Seehorse Video",href:"https://www.seehorsevideos.com/"},{src:"/airo-assets/images/sponsors/showtime-training-center",alt:"Showtime Training Center",href:"https://www.showtimetrainingcenter.com/"},{src:"/airo-assets/images/sponsors/horse-capital-tours",alt:"The Horse Capital Tours",href:"https://www.thehorsecapitaltours.com/"}];function nE(){const t=g.useRef(Wm({delay:4e3,stopOnInteraction:!1}));return e.jsx("section",{className:"py-6 border-t border-border",children:e.jsxs("div",{className:"max-w-[1280px] mx-auto px-4",children:[e.jsx("h2",{className:"font-semibold uppercase text-foreground mb-4 border-b-2 border-border pb-2",style:{fontSize:"25.6px",lineHeight:"30.72px",fontWeight:500},children:"Partners"}),e.jsx("div",{className:"relative",children:e.jsxs(yg,{opts:{loop:!0},plugins:[t.current],children:[e.jsx(vg,{children:aE.map(a=>e.jsx(Gu,{className:"basis-1/2 md:basis-1/3 lg:basis-1/4",children:e.jsx("a",{href:a.href,target:"_blank",rel:"noopener noreferrer",className:"flex items-center justify-center p-4 h-32 bg-muted rounded hover:bg-muted/70 transition-colors","aria-label":a.alt,children:e.jsx("img",{src:a.src,alt:a.alt,className:"max-h-24 max-w-full object-contain",loading:"lazy"})})},a.alt))}),e.jsx(E2,{className:"-left-4"}),e.jsx(H2,{className:"-right-4"})]})})]})})}const rE=[{src:"/airo-assets/images/uploads/hero-bzx9g6wwjr-1788277492637-file-d9xx-yg8cv",alt:"Total Horse Channel – Discover the Industry. Create a free account.",href:"/register",bannerId:"wdaa-thc-welcome"},{src:"/airo-assets/images/sidebar/wdaa-banner",alt:"WDAA – It's About the Journey",href:"https://www.wdaaworldshow.org",bannerId:"wdaa-journey"},{src:"/airo-assets/images/sponsors/purina",alt:"Purina – Horse Feed & Nutrition",href:"https://www.purinamills.com/horse-feed",bannerId:"wdaa-purina"},{src:"/airo-assets/images/sponsors/state-line-tack",alt:"State Line Tack – Equestrian Supplies",href:"https://www.statelinetack.com",bannerId:"wdaa-state-line-tack"},{src:"/airo-assets/images/sponsors/circa-resort-casino",alt:"Circa Resort & Casino",href:"https://circalasvegas.com",bannerId:"wdaa-circa"},{src:"/airo-assets/images/sponsors/tioga-territory",alt:"Tioga Territory – Western Apparel & Awards",href:"https://www.tiogaterritory.com/store/WDAA.html",bannerId:"wdaa-tioga"},{src:"/airo-assets/images/sponsors/dressage-illustrated",alt:"Dressage Illustrated",href:"https://dressageillustrated.com/collections/riders-wdaa-western-dressage-diagram-books",bannerId:"wdaa-dressage-illustrated"},{src:"/airo-assets/images/sponsors/killian-insurance",alt:"Killian Insurance Agency",href:"https://www.killianinsurance.com",bannerId:"wdaa-killian"},{src:"/airo-assets/images/sponsors/absorbine",alt:"Absorbine – Horse Care Products",href:"https://www.absorbine.com",bannerId:"wdaa-absorbine"},{src:"/airo-assets/images/sponsors/skyline-gold-silversmiths",alt:"Skyline Gold & Silver
633smiths",href:"https://www.skylinevaquero.com/",bannerId:"wdaa-skyline"},{src:"/airo-assets/images/sponsors/spotlight-horse-shows",alt:"Spotlight Horse Shows",href:"https://www.spotlighthorseshows.com",bannerId:"wdaa-spotlight"},{src:"/airo-assets/images/sponsors/100x-equine",alt:"100x Equine",href:"https://www.100xequine.com",bannerId:"wdaa-100x-equine"},{src:"/airo-assets/images/sponsors/us-equestrian",alt:"US Equestrian – United States Equestrian Federation",href:"https://www.usef.org/",bannerId:"wdaa-us-equestrian"}],iE=[{src:"/airo-assets/images/uploads/hero-bzx9g6wwjr-1788277492637-file-d9xx-yg8cv",alt:"Total Horse Channel – Discover the Industry. Create a free account.",href:"/register",bannerId:"thc-welcome-banner"},{src:"/airo-assets/images/sponsors/debbie-brooks",alt:"Debbie Brooks Equestrian Collection",href:"https://www.debbiebrooks.com/",bannerId:"thc-debbie-brooks"},{src:"/airo-assets/images/sidebar/horse-capital-tours-500",alt:"The Horse Capital Tours – Book Your Tour Today",href:"https://www.thehorsecapitaltours.com/",bannerId:"thc-horse-capital-tours"}],oE=5e3;function z2({slides:t,placement:a}){const[r,o]=g.useState(0),l=g.useRef(null);g.useEffect(()=>(l.current=setInterval(()=>{o(u=>(u+1)%t.length)},oE),()=>{l.current&&clearInterval(l.current)}),[t.length]);const d=t[r];return e.jsxs("aside",{className:"w-full","aria-label":"Sponsor advertisement",children:[e.jsx(Jc,{bannerId:d.bannerId,placement:a,href:d.href,className:"block w-full",children:e.jsx("div",{className:"w-full aspect-square overflow-hidden",children:e.jsx("img",{src:d.src,alt:d.alt,className:"w-full h-full object-contain",loading:"lazy"})})}),e.jsx("div",{className:"flex justify-center gap-1.5 mt-2","aria-hidden":"true",children:t.map((u,m)=>e.jsx("button",{onClick:()=>o(m),className:["w-2 h-2 rounded-full transition-colors",m===r?"bg-primary":"bg-gray-300 hover:bg-gray-400"].join(" "),"aria-label":`Go to banner ${m+1}`},m))})]})}function vi({placement:t="sidebar-wdaa"}){return e.jsx(z2,{slides:rE,placement:t})}function zs({placement:t="sidebar-thc"}){return e.jsx(z2,{slides:iE,placement:t})}function Cr({placement:t="sidebar-promo-220"}){return e.jsxs("div",{className:"flex flex-col items-center gap-2",children:[e.jsxs("div",{className:"w-full flex items-center gap-2",children:[e.jsx("div",{className:"flex-1 border-t border-border"}),e.jsx(O,{to:"/advertise",className:"shrink-0 text-xs font-semibold uppercase tracking-wide text-muted-foreground hover:text-primary transition-colors px-2 py-1 border border-border rounded hover:border-primary",children:"Advertise With Us"}),e.jsx("div",{className:"flex-1 border-t border-border"})]}),e.jsx("aside",{"aria-label":"Advertisement",children:e.jsx(Jc,{bannerId:"thc-promo-220x300",placement:t,href:"/advertise",className:"block",children:e.jsx("div",{className:"overflow-hidden",style:{width:"220px",height:"300px"},children:e.jsx("img",{src:"/airo-assets/images/sidebar/news-promo-banner",alt:"Total Horse Channel – Advertise With Us",width:220,height:300,className:"w-full h-full object-contain",loading:"lazy"})})})})]})}function lE(t,a){const r=t.startAt?new Date(t.startAt).getTime():-1/0;return(a.startAt?new Date(a.startAt).getTime():-1/0)-r}function cE(t,a){const r=t.startAt?new Date(t.startAt).getTime():-1/0;return(a.startAt?new Date(a.startAt).getTime():-1/0)-r}function Lj(t,a){return new Date(a.createdAt).getTime()-new Date(t.createdAt).getTime()}function dE(t,a){const r=t.startAt?new Date(t.startAt).getTime():1/0,o=a.startAt?new Date(a.startAt).getTime():1/0;return r-o}function uE(t,a){if(t.category===a)return!0;if(t.extraCategories)try{const r=JSON.parse(t.extraCategories);if(Array.isArray(r)&&r.includes(a))return!0}catch{}return!1}function ed(){const[t,a]=g.useState([]),[r,o]=g.useState([]),[l,d]=g.useState([]),[u,m]=g.useState(!0);g.useEffect(()=>{fetch("/api/live-events").then(C=>C.json()).then(C=>{a(C.events??[]),o(C.upcomingEvents??[]),d(C.archivedEvents??[])}).catch(()=>{a([]),o([]),d([])}).finally(()=>m(!1))},[]);const p=t.filter(C=>!C.isArchived&&C.videoType!=="upcoming"&&C.videoType!=="video").sort(lE),x=t.filter(C=>!C.isArchived&&C.videoType==="video").sort(Lj),b=l.sort(cE),y=r.sort(dE),v=[...x,...b].sort(Lj),w=v.filter(C=>uE(C,"Horse Racing"));return{events:t,liveEvents:p,videoEvents:x,archivedEvents:b,upcomingEvents:y,allVideos:v,horseRacingVideos:w,loading:u}}const mE=new Date("2000-01-02T00:00:00Z").getTime();function Va(t){if(!t)return!0;const a=typeof t=="string"?new Date(t).getTime():t.getTime();return isNaN(a)?!0:a<mE}const Nf={january:1,jan:1,february:2,feb:2,march:3,mar:3,april:4,apr:4,may:5,june:6,jun:6,july:7,jul:7,august:8,aug:8,september:9,sep:9,sept:9,october:10,oct:10,november:11,nov:11,december:12,dec:12};function td(t){if(!t)return null;const a=t.match(/\b(\d{4})-(\d{2})-(\d{2})\b/);if(a){const u=new Date(`${a[1]}-${a[2]}-${a[3]}T12:00:00Z`);
633if(!isNaN(u.getTime())&&!Va(u))return u}const r=t.match(/\b(\d{1,2})\/(\d{1,2})\/(\d{4})\b/);if(r){const u=new Date(`${r[3]}-${r[1].padStart(2,"0")}-${r[2].padStart(2,"0")}T12:00:00Z`);if(!isNaN(u.getTime())&&!Va(u))return u}const o=t.match(/\b(january|february|march|april|may|june|july|august|september|october|november|december|jan|feb|mar|apr|jun|jul|aug|sep|sept|oct|nov|dec)\b\.?\s+(\d{1,2})(?:st|nd|rd|th)?,?\s+(\d{4})\b/i);if(o){const u=Nf[o[1].toLowerCase()],m=parseInt(o[2],10),p=parseInt(o[3],10);if(u&&m&&p){const x=new Date(`${p}-${String(u).padStart(2,"0")}-${String(m).padStart(2,"0")}T12:00:00Z`);if(!isNaN(x.getTime())&&!Va(x))return x}}const l=t.match(/\b(\d{1,2})(?:st|nd|rd|th)?\s+(january|february|march|april|may|june|july|august|september|october|november|december|jan|feb|mar|apr|jun|jul|aug|sep|sept|oct|nov|dec)\.?\s+(\d{4})\b/i);if(l){const u=parseInt(l[1],10),m=Nf[l[2].toLowerCase()],p=parseInt(l[3],10);if(m&&u&&p){const x=new Date(`${p}-${String(m).padStart(2,"0")}-${String(u).padStart(2,"0")}T12:00:00Z`);if(!isNaN(x.getTime())&&!Va(x))return x}}const d=t.match(/\b(january|february|march|april|may|june|july|august|september|october|november|december|jan|feb|mar|apr|jun|jul|aug|sep|sept|oct|nov|dec)\.?\s+(\d{4})\b/i);if(d){const u=Nf[d[1].toLowerCase()],m=parseInt(d[2],10);if(u&&m){const p=new Date(`${m}-${String(u).padStart(2,"0")}-01T12:00:00Z`);if(!isNaN(p.getTime())&&!Va(p))return p}}return null}function An(t,a,r){const o=l=>l.toLocaleDateString("en-US",{month:"short",day:"numeric",year:"numeric"});if(t){const l=new Date(t);if(!isNaN(l.getTime())&&!Va(l))return o(l)}if(a){const l=td(a);if(l)return o(l)}return""}const Nu=43200,Dj=1440,Oj=Symbol.for("constructDateFrom");function jg(t,a){return typeof t=="function"?t(a):t&&typeof t=="object"&&Oj in t?t[Oj](a):t instanceof Date?new t.constructor(a):new Date(a)}function bi(t,a){return jg(t,t)}let hE={};function pE(){return hE}function Mj(t){const a=bi(t),r=new Date(Date.UTC(a.getFullYear(),a.getMonth(),a.getDate(),a.getHours(),a.getMinutes(),a.getSeconds(),a.getMilliseconds()));return r.setUTCFullYear(a.getFullYear()),+t-+r}function wg(t,...a){const r=jg.bind(null,t||a.find(o=>typeof o=="object"));return a.map(r)}function _u(t,a){const r=+bi(t)-+bi(a);return r<0?-1:r>0?1:r}function fE(t){return jg(t,Date.now())}function xE(t,a,r){const[o,l]=wg(r==null?void 0:r.in,t,a),d=o.getFullYear()-l.getFullYear(),u=o.getMonth()-l.getMonth();return d*12+u}function gE(t){return a=>{const o=(t?Math[t]:Math.trunc)(a);return o===0?0:o}}function bE(t,a){return+bi(t)-+bi(a)}function yE(t,a){const r=bi(t);return r.setHours(23,59,59,999),r}function vE(t,a){const r=bi(t),o=r.getMonth();return r.setFullYear(r.getFullYear(),o+1,0),r.setHours(23,59,59,999),r}function jE(t,a){const r=bi(t);return+yE(r)==+vE(r)}function wE(t,a,r){const[o,l,d]=wg(r==null?void 0:r.in,t,t,a),u=_u(l,d),m=Math.abs(xE(l,d));if(m<1)return 0;l.getMonth()===1&&l.getDate()>27&&l.setDate(30),l.setMonth(l.getMonth()-u*m);let p=_u(l,d)===-u;jE(o)&&m===1&&_u(o,d)===1&&(p=!1);const x=u*(m-+p);return x===0?0:x}function NE(t,a,r){const o=bE(t,a)/1e3;return gE(r==null?void 0:r.roundingMethod)(o)}const SE={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},CE=(t,a,r)=>{let o;const l=SE[t];return typeof l=="string"?o=l:a===1?o=l.one:o=l.other.replace("{{count}}",a.toString()),r!=null&&r.addSuffix?r.comparison&&r.comparison>0?"in "+o:o+" ago":o};function Sf(t){return(a={})=>{const r=a.width?String(a.width):t.defaultWidth;return t.formats[r]||t.formats[t.defaultWidth]}}const kE={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},TE={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},AE={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},EE={date:Sf({formats:kE,defaultWidth:"full"}),time:Sf({formats:TE,defaultWidth:"full"}),dateTime:Sf({formats:AE,defaultWidth:"full"})},HE={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},zE=(t,a,r,o)=>HE[t];function fc(t){return(a,r)=>{const o=r!=null&&r.context?String(r.context):"standalone";let l;if(o==="formatting"&&t.formattingValues){const u=t.defaultFormattingWidth||t.defaultWidth,m=r!=null&&r.width?String(r.width):u;l=t.formattingValues[m]||t.formattingValues[u]}else{const u=t.defaultWidth,m=r!=null&&r.width?String(r.width):t.defaultWidth;l=t.values[m]||t.values[u]}const d=t.argumentCallback?t.argumentCallback(a):a;return l[d]}}const RE={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},_E={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},LE={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},DE={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Frid
633ay","Saturday"]},OE={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},ME={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},UE=(t,a)=>{const r=Number(t),o=r%100;if(o>20||o<10)switch(o%10){case 1:return r+"st";case 2:return r+"nd";case 3:return r+"rd"}return r+"th"},PE={ordinalNumber:UE,era:fc({values:RE,defaultWidth:"wide"}),quarter:fc({values:_E,defaultWidth:"wide",argumentCallback:t=>t-1}),month:fc({values:LE,defaultWidth:"wide"}),day:fc({values:DE,defaultWidth:"wide"}),dayPeriod:fc({values:OE,defaultWidth:"wide",formattingValues:ME,defaultFormattingWidth:"wide"})};function xc(t){return(a,r={})=>{const o=r.width,l=o&&t.matchPatterns[o]||t.matchPatterns[t.defaultMatchWidth],d=a.match(l);if(!d)return null;const u=d[0],m=o&&t.parsePatterns[o]||t.parsePatterns[t.defaultParseWidth],p=Array.isArray(m)?IE(m,y=>y.test(u)):KE(m,y=>y.test(u));let x;x=t.valueCallback?t.valueCallback(p):p,x=r.valueCallback?r.valueCallback(x):x;const b=a.slice(u.length);return{value:x,rest:b}}}function KE(t,a){for(const r in t)if(Object.prototype.hasOwnProperty.call(t,r)&&a(t[r]))return r}function IE(t,a){for(let r=0;r<t.length;r++)if(a(t[r]))return r}function BE(t){return(a,r={})=>{const o=a.match(t.matchPattern);if(!o)return null;const l=o[0],d=a.match(t.parsePattern);if(!d)return null;let u=t.valueCallback?t.valueCallback(d[0]):d[0];u=r.valueCallback?r.valueCallback(u):u;const m=a.slice(l.length);return{value:u,rest:m}}}const $E=/^(\d+)(th|st|nd|rd)?/i,VE=/\d+/i,FE={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},WE={any:[/^b/i,/^(a|c)/i]},qE={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},YE={any:[/1/i,/2/i,/3/i,/4/i]},GE={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},ZE={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},JE={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},XE={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},QE={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},e8={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},t8={ordinalNumber:BE({matchPattern:$E,parsePattern:VE,valueCallback:t=>parseInt(t,10)}),era:xc({matchPatterns:FE,defaultMatchWidth:"wide",parsePatterns:WE,defaultParseWidth:"any"}),quarter:xc({matchPatterns:qE,defaultMatchWidth:"wide",parsePatterns:YE,defaultParseWidth:"any",valueCallback:t=>t+1}),month:xc({matchPatterns:GE,defaultMatchWidth:"wide",parsePatterns:ZE,defaultParseWidth:"any"}),day:xc({matchPatterns:JE,defaultMatchWidth:"wide",parsePatterns:XE,defaultParseWidth:"any"}),dayPeriod:xc({matchPatterns:QE,defaultMatchWidth:"any",parsePatterns:e8,defaultParseWidth:"any"})},s8={code:"en-US",formatDistance:CE,formatLong:EE,formatRelative:zE,localize:PE,match:t8,options:{weekStartsOn:0,firstWeekContainsDate:1}};function a8(t,a,r){const o=pE(),l=(r==null?void 0:r.locale)??o.locale??s8,d=2520,u=_u(t,a);if(isNaN(u))throw new RangeError("Invalid time value");const m=Object.assign({},r,{addSuffix:r==null?void 0:r.addSuffix,comparison:u}),[p,x]=wg(r==null?void 0:r.in,...u>0?[a,t]:[t,a]),b=NE(x,p),y=(Mj(x)-Mj(p))/1e3,v=Math.round((b-y)/60);let w;if(v<2)return r!=null&&r.includeSeconds?b<5?l.formatDistance("lessThanXSeconds",5,m):b<10?l.formatDistance("lessThanXSeconds",10,m):b<20?l.formatDistance("lessThanXSeconds",20,m):b<40?l.formatDistance("halfAMinute",0,m):b<60?l.formatDistance("lessThanXMinutes",1,m):l.formatDistance("xMinutes",1,m):v===0?l.formatDistance("lessThanXMinutes",1,m):l.formatDistance("xMinutes",v,m);if(v<45)return l.formatDistance("xMinutes",v,m);if(v<90)return l.formatDistance("aboutXHours",1,m);if(v<Dj){const C=Math.round(v/60);return l.formatDistance("aboutXHours",C,m)}else{if(v<d)return l.formatDistance("xDays",1,m);if(v<Nu){const C=Math.round(v/Dj);return l.formatDistance("xDays",C,m)}else if(v<Nu*2)return w=Math.round(v/Nu),l.formatDistance("aboutXMonths",w,m)}if(w=wE(x,p),w<12){const C=Math.round(v/Nu);return l.formatDistance("xMonths",C,m)}else{const C=w%12,A=Math.trunc(w/12);return C<3?l.formatDistance("aboutXYears",A,m):C<9?l.formatDistance("overXYears",A,m):l.formatDistance("almostXYears",A+1,m)}}function R2(t,a){return a8(t,fE(t),a)}const Uj=[{label:"Horses & Animals",emojis:["🐴","🐎","🦄","🤠","🐄","🐂","🐕","🐈","🦅","🌾","🏇","🎠"]},{label:"Reactions",emojis:["😀","😂","🤣","😍","🥰","😎","🤩","😮","😲","🥺","😢","😭"]},{label:"Hands & Hearts",emojis:["❤️","🧡","💛","💚","💙","💜","🖤","🤍","👍","👎","👏","🙌"]},{label:"Symbols",emojis:["🔥","⭐","🌟","✨","🏆","🥇","🎉","🎊","💪","🙏","✅","❌"]}];function n8({onSelect:t,onClose:a}){const r=g.useRef(null),[o,l]=g.useState(0);return g.useEffect(()=>{function d(u){r.current&&!r.current.contains(u.target)&&a()}return document.addEventListener("mousedown",d),()=>document.removeEventListener("mousedown",d)},[a]),e.jsxs("div",{ref:r,className:"absolute bottom-full right-0 mb-1 z-50 bg-card border border-border rounded-lg shadow-lg w-64 p-2","aria-label":"Emoji picker",children:[e.jsx("div",{className:"flex gap-1 mb-2 border-b border-border pb-1",children:Uj.map((d,u)=>e.jsx("button",{type:"button",onClick:()=>l(u),className:`flex-1 text-center text-base py-0.5 rounded transition-colors ${o===u?"bg-primary/10":"hover:bg-muted"}`,title:d.label,children:d.emojis[0]},u))}),e.jsx("div",{className:"grid grid-cols-6 gap-0.5",children:Uj[o].emojis.map(d=>e.jsx("button",{type:"button",onClick:()=>{t(d),a()},className:"text-xl p-1 rounded hover:bg-muted transition-colors","aria-label":d,title:d,children:d},d))})]})}function r8(t){try{return R2(new Date(t),{addSuffix:!0})}catch{return""}}function i8(t){try{const a=new Date(t);return a.toLocaleDateString("en-US",{month:"short",day:"numeric",year:"numeric"})+" at "+a.toLocaleTimeString("en-US",{hour:"numeric",minute:"2-digit",hour12:!0})}catch{return t}}function Pj({text:t}){const a=new RegExp(`https?:\\/\\/[^\\s<>"']+|(?<![/@\\w])(?:[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?\\.)+(?:com|net|org|io|co|tv|us|info|biz|horse)(?:\\/[^\\s<>"']*)?`,"g"),r=[];let o=0,l;for(;(l=a.exec(t))!==null;){l.index>o&&r.push(t.slice(o,l.index));const d=l[0],u=/^https?:\/\//i.test(d)?d:`https://${d}`;r.push(e.jsx("a",{href:u,target:"_blank",rel:"noopener noreferrer",className:"text-primary underline break-all",children:e.jsx(_,{devId:"1824e5",guard:{file:"src/components/community/CommunityPostCard.tsx",tagName:"a",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionH
633ash:"sha256:d7439bee24773bcbfa2d0a97947ee36227b10d1022b1a55847e928965bb6bfde"},children:d})},l.index)),o=l.index+d.length}return o<t.length&&r.push(t.slice(o)),e.jsx(e.Fragment,{children:r})}function o8({images:t,startIndex:a,onClose:r}){const[o,l]=g.useState(a);return g.useEffect(()=>{function d(u){u.key==="Escape"&&r(),u.key==="ArrowLeft"&&l(m=>Math.max(0,m-1)),u.key==="ArrowRight"&&l(m=>Math.min(t.length-1,m+1))}return document.addEventListener("keydown",d),()=>document.removeEventListener("keydown",d)},[t.length,r]),e.jsxs("div",{className:"fixed inset-0 z-[9999] flex items-center justify-center bg-black/90",onClick:r,role:"dialog","aria-modal":"true","aria-label":"Photo viewer",children:[e.jsx("button",{type:"button",onClick:r,className:"absolute top-4 right-4 text-white/80 hover:text-white p-2 rounded-full bg-black/40 hover:bg-black/60 transition-colors z-10","aria-label":"Close",children:e.jsx(Vt,{className:"w-5 h-5"})}),t.length>1&&o>0&&e.jsx("button",{type:"button",onClick:d=>{d.stopPropagation(),l(u=>u-1)},className:"absolute left-3 top-1/2 -translate-y-1/2 text-white/80 hover:text-white p-2 rounded-full bg-black/40 hover:bg-black/60 transition-colors z-10","aria-label":"Previous photo",children:e.jsx(En,{className:"w-6 h-6"})}
633),e.jsx("img",{src:t[o],alt:`Photo ${o+1} of ${t.length}`,className:"max-w-[90vw] max-h-[90vh] object-contain rounded shadow-2xl",onClick:d=>d.stopPropagation(),loading:"lazy"}),t.length>1&&o<t.length-1&&e.jsx("button",{type:"button",onClick:d=>{d.stopPropagation(),l(u=>u+1)},className:"absolute right-3 top-1/2 -translate-y-1/2 text-white/80 hover:text-white p-2 rounded-full bg-black/40 hover:bg-black/60 transition-colors z-10","aria-label":"Next photo",children:e.jsx(Lt,{className:"w-6 h-6"})}),t.length>1&&e.jsxs("div",{className:"absolute bottom-4 left-1/2 -translate-x-1/2 text-white/70 text-sm bg-black/40 px-3 py-1 rounded-full",children:[o+1," / ",t.length]})]})}function l8({images:t,onOpen:a}){const r=t.length;if(r===1)return e.jsx("div",{className:"w-full bg-muted cursor-pointer",onClick:()=>a(0),children:e.jsx("img",{src:t[0],alt:"Community post photo",className:"w-full h-auto max-h-[600px] object-contain",loading:"lazy"})});if(r===2)return e.jsx("div",{className:"grid grid-cols-2 gap-0.5 bg-muted",children:t.map((d,u)=>e.jsx("div",{className:"aspect-square overflow-hidden cursor-pointer",onClick:()=>a(u),children:e.jsx("img",{src:d,alt:`Photo ${u+1}`,className:"w-full h-full object-cover hover:opacity-95 transition-opacity",loading:"lazy"})},u))});if(r===3)return e.jsxs("div",{className:"grid grid-cols-2 gap-0.5 bg-muted",children:[e.jsx("div",{className:"row-span-2 aspect-[3/4] overflow-hidden cursor-pointer",onClick:()=>a(0),children:e.jsx("img",{src:t[0],alt:"Photo 1",className:"w-full h-full object-cover hover:opacity-95 transition-opacity",loading:"lazy"})}),t.slice(1).map((d,u)=>e.jsx("div",{className:"aspect-[3/2] overflow-hidden cursor-pointer",onClick:()=>a(u+1),children:e.jsx("img",{src:d,alt:`Photo ${u+2}`,className:"w-full h-full object-cover hover:opacity-95 transition-opacity",loading:"lazy"})},u))]});const o=t.slice(0,4),l=r-4;return e.jsx("div",{className:"grid grid-cols-2 gap-0.5 bg-muted",children:o.map((d,u)=>{const m=u===3&&l>0;return e.jsxs("div",{className:"relative aspect-square overflow-hidden cursor-pointer",onClick:()=>a(u),children:[e.jsx("img",{src:d,alt:`Photo ${u+1}`,className:`w-full h-full object-cover hover:opacity-95 transition-opacity ${m?"brightness-50":""}`,loading:"lazy"}),m&&e.jsx("div",{className:"absolute inset-0 flex items-center justify-center pointer-events-none",children:e.jsxs("span",{className:"text-white text-2xl font-bold drop-shadow",children:["+",l]})})]},u)})})}function _2({post:t,currentUserId:a,isAdmin:r,onDeleted:o,onEdited:l}){var Xe;const d=ga(),u=t.username?`/u/${t.username}`:"#",m=t.name||t.username||"Member",p=a!=null&&a===t.userId,x=a!=null,b=t.images&&t.images.length>0?t.images:t.imageUrl?[t.imageUrl]:[],[y,v]=g.useState(null),[w,C]=g.useState(!1),[A,S]=g.useState(!1),[z,T]=g.useState(!1),[M,P]=g.useState(""),[E,U]=g.useState(!1);function q(){const Ae=`${window.location.origin}/community/p/${t.id}`;navigator.share?navigator.share({title:"Total Horse Channel",url:Ae}).catch(()=>{}):navigator.clipboard.writeText(Ae).then(()=>{U(!0),setTimeout(()=>U(!1),2e3)}).catch(()=>{})}const[H,J]=g.useState(!1),[B,Y]=g.useState(""),[$,D]=g.useState(!1),[W,I]=g.useState(""),[k,K]=g.useState(t.likeCount??0),[L,se]=g.useState(t.isLiked??!1),[X,le]=g.useState(!1),[ge,Se]=g.useState(t.isFollowing??!1),[Me,st]=g.useState(!1),[We,Ye]=g.useState(!1),[te,me]=g.useState([]),[Le,Ie]=g.useState(!1),[ve,ze]=g.useState(t.commentCount??0),[Ue,ct]=g.useState(""),[Ot,Et]=g.useState(!1),[Zt,as]=g.useState(""),[Jt,vs]=g.useState(!1),js=g.useRef(null);g.useEffect(()=>{K(t.likeCount??0)},[t.likeCount]),g.useEffect(()=>{se(t.isLiked??!1)},[t.isLiked]),g.useEffect(()=>{Se(t.isFollowing??!1)},[t.isFollowing]),g.useEffect(()=>{ze(t.commentCount??0)},[t.commentCount]);const Ws=g.useCallback(async()=>{Ie(!0);try{const Ae=await fetch(`/api/community/posts/${t.id}/comments`);if(!Ae.ok)throw new Error("Failed");const De=await Ae.json();me(De.comments)}catch{}finally{Ie(!1)}},[t.id]);g.useEffect(()=>{We&&Ws()},[We,Ws]);async function Mt(){if(!(A||w)){C(!0),P("");try{if(!(await fetch(`/api/community/posts/${t.id}/report`,{method:"POST",credentials:"include"})).ok)throw new Error("Failed");S(!0)}catch{P("Could not send report. Please try again.")}finally{C(!1)}}}async function jt(){if(!z&&window.confirm("Delete this post? This cannot be undone.")){T(!0),P("");try{if(!(await fetch(`/api/community/posts/${t.id}`,{method:"DELETE",credentials:"include"})).ok)throw new Error("Failed");o==null||o(t.id)}catch{P("Could not delete post. Please try again."),T(!1)}}}function ps(){Y(t.body??""),I(""),J(!0)}async function Wt(){D(!0),I("");try{const Ae=await fetch(`/api/community/posts/${t.id}`,{method:"PATCH",headers:{"Content-Type":"application/json"},credentials:"include",body:JSON.stringify({body:B})});
633if(!Ae.ok){const ft=await Ae.json().catch(()=>({}));I(ft.error??"Save failed.");return}const{body:De}=await Ae.json();l==null||l(t.id,De),J(!1)}catch{I("Network error. Please try again.")}finally{D(!1)}}async function ws(){if(!X){if(!x){d("/login");return}le(!0);try{const Ae=await fetch(`/api/community/posts/${t.id}/like`,{method:"POST",credentials:"include"});if(!Ae.ok)throw new Error("Failed");const De=await Ae.json();se(De.liked),K(De.likeCount)}catch{}finally{le(!1)}}}async function os(){if(!(Me||!t.username)){if(!x){d("/login");return}st(!0);try{const Ae=await fetch(`/api/users/${t.username}/follow`,{method:"POST",credentials:"include"});if(!Ae.ok)throw new Error("Failed");const De=await Ae.json();Se(De.following)}catch{}finally{st(!1)}}}async function qt(Ae){Ae.preventDefault();const De=Ue.trim();if(!(!De||Ot)){Et(!0),as("");try{const ft=await fetch(`/api/community/posts/${t.id}/comments`,{method:"POST",headers:{"Content-Type":"application/json"},credentials:"include",body:JSON.stringify({body:De})});if(!ft.ok){const ls=await ft.json().catch(()=>({}));as(ls.error??"Failed.");return}const Yt=await ft.json();me(ls=>[Yt.comment,...ls]),ze(ls=>ls+1),ct("")}catch{as("Network error. Please try again.")}finally{Et(!1)}}}async function je(Ae){if(window.confirm("Delete this comment?"))try{if(!(await fetch(`/api/community/posts/${t.id}/comments/${Ae}`,{method:"DELETE",credentials:"include"})).ok)throw new Error("Failed");me(ft=>ft.filter(Yt=>Yt.id!==Ae)),ze(ft=>Math.max(0,ft-1))}catch{}}function gt(Ae){const De=js.current;if(!De){ct(qs=>qs+Ae);return}const ft=De.selectionStart??Ue.length,Yt=De.selectionEnd??Ue.length,ls=Ue.slice(0,ft)+Ae+Ue.slice(Yt);ct(ls),requestAnimationFrame(()=>{De.focus();const qs=ft+Ae.length;De.setSelectionRange(qs,qs)})}const et=x&&!p&&!ge&&t.username;return e.jsxs("article",{id:`post-${t.id}`,className:"bg-card border border-border rounded-lg flex flex-col gap-0 overflow-hidden",children:[e.jsxs("div",{className:"flex items-start gap-3 p-4 pb-3",children:[e.jsx(O,{to:u,className:"shrink-0",children:t.avatarUrl?e.jsx("img",{src:t.avatarUrl,alt:m,className:"w-10 h-10 rounded-full object-cover border border-border",loading:"lazy"}):e.jsx("span",{className:"w-10 h-10 rounded-full bg-muted flex items-center justify-center border border-border",children:e.jsx(Ha,{className:"w-5 h-5 text-muted-foreground"})})}),e.jsxs("div",{className:"min-w-0 flex-1",children:[e.jsx(O,{to:u,className:"font-semibold text-sm text-foreground hover:text-primary truncate block",children:m}),e.jsx("span",{className:"text-xs text-muted-foreground",children:e.jsx(_,{devId:"6c2e13",guard:{file:"src/components/community/CommunityPostCard.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:9af5ae0c39cfe639d43edb860d0d781f1151c62e73df756d4e4f1339f7ed1baf"},children:r8(t.createdAt)})}),((Xe=t.username)==null?void 0:Xe.toLowerCase())==="vlemaster"&&e.jsxs("span",{className:"inline-flex items-center gap-1 mt-1 text-xs font-semibold px-1.5 py-0.5 rounded bg-primary text-white",children:[e.jsx(zc,{size:10,className:"shrink-0"}),"Official 2026 WDAA Photographer"]})]}),e.jsxs("div",{className:"flex items-center gap-1 shrink-0",children:[x&&!p&&!r&&e.jsx("button",{type:"button",onClick:Mt,disabled:w||A,title:A?"Reported":"Report this post",className:`p-1.5 rounded transition-colors ${A?"text-muted-foreground cursor-default":"text-muted-foreground hover:text-destructive"}`,"aria-label":"Report post",children:e.jsx(_,{devId:"a7ecfe",guard:{file:"src/components/community/CommunityPostCard.tsx",tagName:"button",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:949bcd6b0036630846ff99230c55005fe7cf5e0bf9be6bff3fc6a6c81abd8213"},children:w?e.jsx(Rt,{className:"w-3.5 h-3.5 animate-spin"}):e.jsx(t2,{className:"w-3.5 h-3.5"})})}),(p||r)&&e.jsx("button",{type:"button",onClick:jt,disabled:z,title:"Delete post",className:"p-1.5 rounded text-muted-foreground hover:text-destructive transition-colors","aria-label":"Delete post",children:e.jsx(_,{devId:"a7ecff",guard:{file:"src/components/community/CommunityPostCard.tsx",tagName:"button",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionH
633ash:"sha256:3667a1001ac649f0d1d6e5589a5e4c5a0f2a9fa8f07bb5121164e9c50c4d2dd9"},children:z?e.jsx(Rt,{className:"w-3.5 h-3.5 animate-spin"}):e.jsx(Tn,{className:"w-3.5 h-3.5"})})}),p&&!H&&e.jsx("button",{type:"button",onClick:ps,title:"Edit post",className:"p-1.5 rounded text-muted-foreground hover:text-primary transition-colors","aria-label":"Edit post",children:e.jsx(Vn,{className:"w-3.5 h-3.5"})})]})]}),M&&e.jsx("p",{className:"px-4 text-xs text-destructive",children:e.jsx(_,{devId:"5f4529",guard:{file:"src/components/community/CommunityPostCard.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:4d9e0fe975d50fdc3911dcc307a7eca299d09ef5984d1d7d410e80f7e7f5bffe"},children:M})}),A&&e.jsx("p",{className:"px-4 text-xs text-muted-foreground",children:"Thank you — this post has been reported to our team."}),t.contestSourceType&&t.contestSourceType!=="thc-promo"&&e.jsx("div",{className:"px-4 pt-2",children:e.jsx("span",{className:"inline-flex items-center gap-1 text-xs font-semibold px-2 py-0.5 rounded border bg-yellow-50 text-yellow-800 border-yellow-300",children:"🏆 Contest Entry"})}),b.length>0&&e.jsx(l8,{images:b,onOpen:Ae=>v(Ae)}),y!==null&&e.jsx(o8,{images:b,startIndex:y,onClose:()=>v(null)}),e.jsx("div",{className:"px-4 pt-3",children:H?e.jsxs("div",{className:"flex flex-col gap-2",children:[e.jsx("textarea",{value:B,onChange:Ae=>Y(Ae.target.value.slice(0,2e3)),rows:4,maxLength:2e3,className:"w-full resize-none rounded border border-input bg-background px-3 py-2 text-sm focus:outline-none focus:ring-2 focus:ring-primary",autoFocus:!0}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsxs("button",{type:"button",onClick:Wt,disabled:$,className:"flex items-center gap-1 px-3 py-1 text-xs font-semibold bg-primary text-white rounded hover:opacity-90 disabled:opacity-60",children:[e.jsx(Ea,{className:"w-3 h-3"}),$?"Saving…":"Save"]}),e.jsxs("button",{type:"button",onClick:()=>J(!1),className:"flex items-center gap-1 px-3 py-1 text-xs border border-border rounded hover:bg-muted transition-colors",children:[e.jsx(Vt,{className:"w-3 h-3"}),"Cancel"]}),e.jsxs("span",{className:"text-xs text-muted-foreground ml-auto",children:[B.length,"/2000"]})]}),W&&e.jsx("p",{className:"text-xs text-destructive",children:e.jsx(_,{devId:"ec4e53",guard:{file:"src/components/community/CommunityPostCard.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:5785b36dd0c5a5124cce80e2bd895bae76cb9dad02391ef79355b159d31c2fe6"},children:W})})]}):t.body&&e.jsx("p",{className:"text-sm text-foreground whitespace-pre-wrap break-words",children:e.jsx(Pj,{text:t.body})})}),e.jsxs("div",{className:"flex items-center gap-3 px-4 py-3 mt-1",children:[e.jsxs("button",{type:"button",onClick:ws,disabled:X,className:`flex items-center gap-1.5 text-sm transition-colors ${L?"text-primary":"text-muted-foreground hover:text-primary"}`,"aria-label":L?"Unlike":"Like",children:[e.jsx(_c,{className:`w-4 h-4 ${L?"fill-primary":""}`}),e.jsx("span",{className:"tabular-nums",children:e.jsx(_,{devId:"e8ab4f",guard:{file:"src/components/community/CommunityPostCard.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:5d0ab9f68eb7273d9991d7606aa884cfefb7ffeca86168d77d169636d0e760b1"},children:k>0?k:""})})]}),e.jsxs("button",{type:"button",onClick:()=>Ye(Ae=>!Ae),className:"flex items-center gap-1.5 text-sm text-muted-foreground hover:text-primary transition-colors","aria-label":"Comments",children:[e.jsx(ig,{className:"w-4 h-4"}),e.jsx("span",{className:"tabular-nums",children:e.jsx(_,{devId:"2a8030",guard:{file:"src/components/community/CommunityPostCard.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:90918705ef34f65fdf8969a25c2c3ee541dade903a9556d7e9d29d465e8d7f4c"},children:ve>0?ve:""})})]}),e.jsx("button",{type:"button",onClick:q,className:"flex items-center gap-1.5 text-sm text-muted-foreground hover:text-primary transition-colors","aria-label":"Share post",title:E?"Link copied!":"Share",children:e.jsx(_,{devId:"2e13ee",guard:{file:"src/components/community/CommunityPostCard.tsx",tagName:"button",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionH
633ash:"sha256:3d2bbf23e49157daff66beb3cca95849ee20a266f032cb71f138c23a964e1932"},children:E?e.jsx(Ea,{className:"w-4 h-4 text-primary"}):e.jsx(LC,{className:"w-4 h-4"})})}),et&&e.jsxs("button",{type:"button",onClick:os,disabled:Me,className:"ml-auto flex items-center gap-1 text-xs font-semibold text-primary hover:opacity-80 transition-opacity","aria-label":`Follow ${m}`,children:[Me?e.jsx(Rt,{className:"w-3.5 h-3.5 animate-spin"}):e.jsx(Dc,{className:"w-3.5 h-3.5"}),"Follow"]})]}),We&&e.jsxs("div",{className:"border-t border-border bg-muted/30 px-4 py-3 flex flex-col gap-3",children:[x?e.jsxs("form",{onSubmit:qt,className:"flex flex-col gap-2",children:[e.jsxs("div",{className:"relative flex items-end gap-2",children:[e.jsx("textarea",{ref:js,value:Ue,onChange:Ae=>ct(Ae.target.value.slice(0,1e3)),placeholder:"Write a comment…",rows:2,maxLength:1e3,className:"flex-1 resize-none rounded border border-input bg-background px-3 py-2 text-sm focus:outline-none focus:ring-2 focus:ring-primary"}),e.jsxs("div",{className:"flex flex-col gap-1 shrink-0",children:[e.jsxs("div",{className:"relative",children:[e.jsx("button",{type:"button",onClick:()=>vs(Ae=>!Ae),className:"p-1.5 rounded text-muted-foreground hover:text-primary transition-colors","aria-label":"Insert emoji",children:e.jsx(i2,{className:"w-4 h-4"})}),Jt&&e.jsx(n8,{onSelect:gt,onClose:()=>vs(!1)})]}),e.jsx("button",{type:"submit",disabled:!Ue.trim()||Ot,className:"p-1.5 rounded bg-primary text-white hover:opacity-90 disabled:opacity-40 transition-opacity","aria-label":"Post comment",children:e.jsx(_,{devId:"c2543a",guard:{file:"src/components/community/CommunityPostCard.tsx",tagName:"button",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:bc9242e86412c48d7c5db9a3d9a9d0d9c0d7f34324e917491b051003a344bd19"},children:Ot?e.jsx(Rt,{className:"w-4 h-4 animate-spin"}):e.jsx(fi,{className:"w-4 h-4"})})})]})]}),Zt&&e.jsx("p",{className:"text-xs text-destructive",children:e.jsx(_,{devId:"404be6",guard:{file:"src/components/community/CommunityPostCard.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:5038e18da51609eb1727befb9ed9dc4df516d59946bd24fb69af21d814372664"},children:Zt})})]}):e.jsxs("p",{className:"text-xs text-muted-foreground",children:[e.jsx(O,{to:"/login",className:"text-primary hover:underline font-medium",children:"Log in"})," or"," ",e.jsx(O,{to:"/signup",className:"text-primary hover:underline font-medium",children:"create an account"})," to comment."]}),Le&&e.jsx("div",{className:"flex justify-center py-2",children:e.jsx(Rt,{className:"w-4 h-4 animate-spin text-muted-foreground"})}),!Le&&te.length===0&&e.jsx("p",{className:"text-xs text-muted-foreground text-center py-1",children:"No comments yet."}),!Le&&te.map(Ae=>{const De=Ae.name||Ae.username||"Member",ft=Ae.username?`/u/${Ae.username}`:"#",Yt=a===Ae.userId;return e.jsxs("div",{className:"flex gap-2 items-start",children:[e.jsx(O,{to:ft,className:"shrink-0",children:Ae.avatarUrl?e.jsx("img",{src:Ae.avatarUrl,alt:De,className:"w-7 h-7 rounded-full object-cover border border-border",loading:"lazy"}):e.jsx("span",{className:"w-7 h-7 rounded-full bg-muted flex items-center justify-center border border-border",children:e.jsx(Ha,{className:"w-3.5 h-3.5 text-muted-foreground"})})}),e.jsxs("div",{className:"flex-1 min-w-0 bg-card rounded-lg px-3 py-2 border border-border",children:[e.jsxs("div",{className:"flex items-center justify-between gap-2 mb-0.5",children:[e.jsx(O,{to:ft,className:"text-xs font-semibold text-foreground hover:text-primary truncate",children:De}),e.jsxs("div",{className:"flex items-center gap-1 shrink-0",children:[e.jsx("span",{className:"text-xs text-muted-foreground",children:i8(Ae.createdAt)}),(Yt||r)&&e.jsx("button",{type:"button",onClick:()=>je(Ae.id),className:"p-0.5 text-muted-foreground hover:text-destructive transition-colors","aria-label":"Delete comment",children:e.jsx(Tn,{className:"w-3 h-3"})})]})]}),e.jsx("p",{className:"text-sm text-foreground whitespace-pre-wrap break-words",children:e.jsx(Pj,{text:Ae.body})})]})]},Ae.id)})]})]})}const Wo=10,c8=5*1024*1024;
633async function d8(t){const a=await t.arrayBuffer(),r=new Uint8Array(a);let o="";const l=8192;for(let d=0;d<r.length;d+=l)o+=String.fromCharCode(...r.subarray(d,d+l));return btoa(o)}function u8({onPosted:t}){const[a,r]=g.useState(""),[o,l]=g.useState([]),[d,u]=g.useState(!1),[m,p]=g.useState(""),[x,b]=g.useState(null),[y,v]=g.useState(!1),[w,C]=g.useState(""),A=g.useRef(null);g.useEffect(()=>{fetch("/api/community/guidelines-status",{credentials:"include"}).then(E=>E.json()).then(E=>b(E.agreed)).catch(()=>b(!1))},[]);function S(E){const U=Array.from(E.target.files??[]);if(!U.length)return;const q=Wo-o.length;if(q<=0){p(`You can add up to ${Wo} photos per post.`);return}const H=U.slice(0,q),J=[];let B="";for(const Y of H){if(Y.size>c8){B=`${Y.name} is over 5 MB — skipped.`;continue}const $=URL.createObjectURL(Y);J.push({file:Y,preview:$})}J.length&&(l(Y=>[...Y,...J]),p("")),B&&p(B),A.current&&(A.current.value="")}function z(E){l(U=>{const q=[...U];return URL.revokeObjectURL(q[E].preview),q.splice(E,1),q})}async function T(E){if(E.preventDefault(),!x&&!y){C("Please agree to the Community Guidelines and Terms of Service to post.");return}if(!a.trim()&&o.length===0){p("Add some text or a photo to post.");return}u(!0),p(""),C("");try{!x&&y&&(await fetch("/api/community/agree-guidelines",{method:"PATCH",credentials:"include"}),b(!0));const U=[];for(const J of o){const B=await d8(J.file);U.push({base64:B,mime:J.file.type})}const q=await fetch("/api/community/posts",{method:"POST",credentials:"include",headers:{"Content-Type":"application/json"},body:JSON.stringify({body:a.trim(),images:U})});if(!q.ok){const J=await q.json().catch(()=>({}));throw new Error(J.error||"Failed to post")}const{post:H}=await q.json();t(H),r(""),o.forEach(J=>URL.revokeObjectURL(J.preview)),l([])}catch(U){p(U instanceof Error?U.message:"Failed to post")}finally{u(!1)}}const M=x===!1,P=o.length<Wo;return e.jsxs("form",{onSubmit:T,className:"bg-card border border-border rounded-lg p-4 flex flex-col gap-3",children:[e.jsx("textarea",{value:a,onChange:E=>r(E.target.value),placeholder:"Share a photo or update with the horse industry…",rows:3,maxLength:2e3,className:"w-full resize-none rounded-md border border-input bg-background px-3 py-2 text-sm placeholder:text-muted-foreground focus:outline-none focus:ring-2 focus:ring-primary"}),o.length>0&&e.jsx("div",{className:`grid gap-2 ${o.length===1?"grid-cols-1":o.length===2?"grid-cols-2":"grid-cols-3"}`,children:o.map((E,U)=>e.jsxs("div",{className:"relative group aspect-square",children:[e.jsx("img",{src:E.preview,alt:`Photo ${U+1}`,className:"w-full h-full object-cover rounded-md border border-border"}),e.jsx("button",{type:"button",onClick:()=>z(U),className:"absolute top-1 right-1 bg-black/60 text-white rounded-full p-0.5 hover:bg-black/80 opacity-0 group-hover:opacity-100 transition-opacity","aria-label":`Remove photo ${U+1}`,children:e.jsx(Vt,{className:"w-3.5 h-3.5"})})]},U))}),M&&e.jsxs("label",{className:"flex items-start gap-2 cursor-pointer select-none",children:[e.jsx("input",{type:"checkbox",checked:y,onChange:E=>{v(E.target.checked),E.target.checked&&C("")},className:"mt-0.5 h-4 w-4 rounded border-input accent-primary shrink-0"}),e.jsxs("span",{className:"text-xs text-muted-foreground leading-snug",children:["I agree to the"," ",e.jsx(O,{to:"/community-guidelines",className:"underline text-foreground hover:text-primary",target:"_blank",rel:"noopener noreferrer",children:"Community Guidelines"})," ","and"," ",e.jsx(O,{to:"/terms-of-service",className:"underline text-foreground hover:text-primary",target:"_blank",rel:"noopener noreferrer",children:"Terms of Service"}),"."]})]}),w&&e.jsx("p",{className:"text-xs text-destructive",children:e.jsx(_,{devId:"b86ac8",guard:{file:"src/components/community/CommunityPostBox.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:1946c4b7068f26925de58fd8784b3f78f777eaea4439c841e18b5f33c98c7673"},children:w})}),m&&e.jsx("p",{className:"text-sm text-destructive",children:e.jsx(_,{devId:"b86ac9",guard:{file:"src/components/community/CommunityPostBox.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionH
633ash:"sha256:ca00fccfb408989eddc401062c4d1219a6aceb6b9b55412357f1790862e8f178"},children:m})}),e.jsxs("div",{className:"flex items-center justify-between gap-2",children:[e.jsxs("div",{className:"flex items-center gap-3",children:[P&&e.jsxs("button",{type:"button",onClick:()=>{var E;return(E=A.current)==null?void 0:E.click()},className:"flex items-center gap-1.5 text-sm text-muted-foreground hover:text-primary transition-colors","aria-label":"Add photo",children:[e.jsx(Jf,{className:"w-4 h-4"}),e.jsxs("span",{children:["Photo",o.length>0?` (${o.length}/${Wo})`:""]})]}),!P&&e.jsxs("span",{className:"text-xs text-muted-foreground",children:[Wo,"/",Wo," photos"]})]}),e.jsx("input",{ref:A,type:"file",accept:"image/jpeg,image/png,image/gif,image/webp",multiple:!0,className:"hidden",onChange:S}),e.jsxs(Qc,{type:"submit",size:"sm",disabled:d||x===null,children:[d?e.jsx(Rt,{className:"w-4 h-4 animate-spin mr-1"}):null,"Post"]})]}),e.jsx("p",{className:"text-xs text-muted-foreground border-t border-border pt-2 leading-snug",children:"Horse industry only. No nudity, harassment, or photos you do not have the right to use. Total Horse Channel may remove posts and accounts."})]})}const m8=20;function L2({username:t,limit:a,hidePostBox:r}){var H,J;const l=Us().session,d=!!(l!=null&&l.user),u=((H=l==null?void 0:l.user)==null?void 0:H.id)??null,m=!!((J=l==null?void 0:l.user)!=null&&J.isAdmin),[p,x]=g.useState([]),[b,y]=g.useState(!0),[v,w]=g.useState(!1),[C,A]=g.useState(""),[S,z]=g.useState(!1),[T,M]=g.useState(null),P=g.useCallback(async(B,Y)=>{Y?y(!0):w(!0),A("");try{const $=a??m8;let D=t?`/api/community/posts/user/${encodeURIComponent(t)}?limit=${$}`:`/api/community/posts?limit=${$}`;B&&(D+=`&before=${encodeURIComponent(B)}`);const W=await fetch(D);if(!W.ok)throw new Error("Failed to load");const k=(await W.json()).posts;x(Y?k:L=>[...L,...k]);const K=!a&&k.length>=$;z(K),M(k.length>0?k[k.length-1].id:null)}catch{A("Could not load community posts.")}finally{y(!1),w(!1)}},[t,a]);g.useEffect(()=>{x([]),M(null),z(!1),P(null,!0)},[P]);function E(B){x(Y=>[B,...Y])}function U(B){x(Y=>Y.filter($=>$.id!==B))}function q(B,Y){x($=>$.map(D=>D.id===B?{...D,body:Y}:D))}return e.jsxs("div",{className:"flex flex-col gap-4",children:[d&&!r&&e.jsx(u8,{onPosted:E}),!d&&!r&&e.jsxs("div",{className:"bg-muted/50 border border-border rounded-lg p-4 text-center flex flex-col items-center gap-2",children:[e.jsx(o2,{className:"w-6 h-6 text-muted-foreground"}),e.jsx("p",{className:"text-sm text-muted-foreground",children:"Share photos and updates with the horse industry."}),e.jsx(O,{to:"/signup",children:e.jsx(Qc,{size:"sm",variant:"default",children:"Create free account"})})]}),b&&e.jsx("div",{className:"flex justify-center py-8",children:e.jsx(Rt,{className:"w-6 h-6 animate-spin text-muted-foreground"})}),!b&&C&&e.jsx("p",{className:"text-sm text-destructive text-center py-4",children:e.jsx(_,{devId:"13da7c",guard:{file:"src/components/community/CommunityFeed.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:ca00fccfb408989eddc401062c4d1219a6aceb6b9b55412357f1790862e8f178"},children:C})}),!b&&!C&&p.length===0&&e.jsx("p",{className:"text-sm text-muted-foreground text-center py-8",children:"No posts yet. Be the first to share something!"}),!b&&p.map(B=>e.jsx(_2,{post:B,currentUserId:u,isAdmin:m,onDeleted:U,onEdited:q},B.id)),!b&&S&&e.jsx("div",{className:"flex justify-center pt-2 pb-4",children:e.jsx("button",{onClick:()=>P(T,!1),disabled:v,className:"flex items-center gap-2 px-6 py-2 border border-border text-sm font-semibold text-foreground hover:bg-muted transition-colors disabled:opacity-60",children:e.jsx(_,{devId:"983e3e",guard:{file:"src/components/community/CommunityFeed.tsx",tagName:"button",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:e0d07c4a097c9dea71d00e79802510b4a164d324fe818e617365e0c118ef9b98"},children:v?e.jsxs(e.Fragment,{children:[e.jsx(Rt,{size:14,className:"animate-spin"})," Loading…"]}):"Load more posts"})})})]})}function Ng({placement:t="player-leaderboard"}){return e.jsx("div",{className:"w-full overflow-hidden",style:{height:"90px"},children:e.jsx(Jc,{bannerId:"player-lb-thc",placement:t,href:"/#register",target:"_self",rel:"",className:"block w-full h-full",children:e.jsx("img",{src:"/airo-assets/images/homepage/leaderboard-thc",alt:"Total Horse Channel – Watch Live Horse Events – TotalHorseChannel.com",width:728,height:90,loading:"eager",fetchPriority:"high",className:"w-full h-full object-cover"})})})}function h8(t=3){const[a,r]=g.useState([]);return g.useEffect(()=>{fetch("/api/events").then(o=>o.json()).then(o=>{const l=new Date().toISOString().slice(0,10),d=o.filter(u=>(u.endDate??u.startDate)>=l).slice(0,t);r(d)}).catch(()=>r([]))},[t]),a}function p8(t,a){const r=d=>{const[,u,m]=d.split("-");return`${["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"][parseInt(u,10)-1]} ${parseInt(m,10)}`};if(!a||a===t)return r(t);const[o]=t.split("-"),[l]=a.split("-");return o!==l?`${r(t)}, ${o} – ${r(a)}, ${l}`:`${r(t)} – ${r(a)}`}function f8({trackId:t}){const a=g.useCallback(r=>{const o=document.getElementById(t);o&&o.scrollBy({left:r==="left"?-460:460,behavior:"smooth"})},[t]);return e.jsxs("div",{className:"flex items-center gap-1",children:[e.jsx("button",{onClick:()=>a("left"),"aria-label":"Scroll left",className:"flex items-center justify-center w-6 h-6 border border-border bg-card hover:bg-muted transition-colors rounded-sm",children:e.jsx(En,{size:14,className:"text-foreground"})}),e.jsx("button",{onClick:()=>a("right"),"aria-label":"Scroll right",className:"flex items-center justify-center w-6 h-6 border border-border bg-card hover:bg-muted transition-colors rounded-sm",children:e.jsx(Lt,{size:14,className:"text-foreground"})})]})}function x8(t=6){const[a,r]=g.useState([]);return g.useEffect(()=>{fetch(`/api/news?limit=${t}`).then(o=>o.json()).then(o=>r((o.articles??[]).slice(0,t))).catch(()=>{})},[t]),a}const an="https://totalhorsechannel.com";function Cf(t){return{thumbnail:t.thumbnailUrl??"",title:t.title,date:An(t.createdAt,t.title)||An(t.startAt,t.title),views:t.viewCount??0,likes:t.likeCount??void 0,href:`/live/${t.slug}`}}const g8=[{thumbnail:"/assets/images/cecd7c477f3af7a9cb65e2631deb22c0.jpg",title:"When is the right time to feed my horse? | Tips by Cavalor",date:"January 16, 2024",views:2552,likes:1},{thumbnail:"/assets/images/8fa881187af0d30654bfb914ac5e8e67.jpg",title:"500 Miles – The Story of Ranchers and Horses",date:"December 15, 2017",views:8138,likes:9},{thumbnail:"/assets/images/595a406831c75c5aa39509c0688ec505.png",title:"Horse Park Masters 2021 | Dressage | LIVE",date:"June 3, 2021",views:2538,likes:4},{thumbnail:"/assets/images/3ee9c6772cda5405e4bb353b959e811b.jpg",title:"Homemade Bath Bomb Tutorial",date:"May 10, 2017",views:4672,likes:2}],b8={"@context":"https://schema.org","@graph":[{"@type":"WebSite","@id":`${an}/#website`,name:"Total Horse Channel",url:`${an}/`},{"@type":"Organization","@id":`${an}/#organization`,name:"Total Horse Channel",url:`${an}/`},{"@type":"WebPage","@id":`${an}/#webpage`,url:`${an}/`,isPartOf:{"@id":`${an}/#website`},about:{"@id":`${an}/#organization`},datePublished:"2018-01-01",dateModified:"2026-08-28"}]};
633function y8(){const{liveEvents:t,allVideos:a,horseRacingVideos:r}=ed(),o=(y,v)=>An(y,v),l=x8(6),{isAuthenticated:d,isPending:u}=Us(),m=h8(12),p=g.useMemo(()=>a.slice(0,8).map(Cf),[a]),x=g.useMemo(()=>[...a].sort((y,v)=>(v.viewCount??0)-(y.viewCount??0)).slice(0,4).map(Cf),[a]),b=g.useMemo(()=>r.slice(0,4).map(Cf),[r]);return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Total Horse Channel – Horse Videos & Live Events"}),e.jsx("meta",{name:"description",content:"Total Horse Channel is an online television network showcasing horses and all things equine. Watch horse care, clinics, live shows, racing, and more."}),e.jsx("link",{rel:"canonical",href:an}),e.jsx("meta",{property:"og:title",content:"Total Horse Channel – Horse Videos & Live Events"}),e.jsx("meta",{property:"og:description",content:"Total Horse Channel is an online television network showcasing horses and all things equine."}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{property:"og:url",content:an}),e.jsx("meta",{property:"og:image",content:`${an}/assets/images/03d4cc3463b5f931df4f08c7c706f416.png`}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("meta",{name:"twitter:title",content:"Total Horse Channel – Horse Videos & Live Events"}),e.jsx("meta",{name:"twitter:description",content:"Total Horse Channel is an online television network showcasing horses and all things equine."}),e.jsx("meta",{name:"twitter:image",content:`${an}/assets/images/03d4cc3463b5f931df4f08c7c706f416.png`}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify(b8)})]}),e.jsxs("main",{children:[e.jsx("h1",{className:"sr-only",children:"Total Horse Channel – Horse Videos & Live Equine Events"}),e.jsx("div",{className:"max-w-[1280px] mx-auto px-4 py-4",children:e.jsxs("div",{className:"flex flex-col lg:flex-row gap-6",children:[e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsxs("div",{className:"relative w-full mb-4 bg-black",style:{aspectRatio:"16/9"},children:[e.jsx("iframe",{src:"https://rumble.com/embed/v7e3mzc/?pub=mqmap",title:"2026 AMHA World Show - Day 8",className:"w-full h-full",frameBorder:"0",allowFullScreen:!0}),e.jsx("div",{className:"absolute bottom-0 left-0 right-0 px-3 py-2 pointer-events-none",style:{background:"hsl(var(--thc-overlay))"},children:e.jsx("p",{className:"text-white text-sm font-semibold",children:"2026 AMHA World Show - Day 8"})})]}),e.jsxs("a",{href:"https://totalhorsechannel.com/home/low-roller/",className:"flex items-center justify-center gap-2 w-full px-4 py-2 mb-3 rounded text-white font-semibold text-sm text-center hover:opacity-90 transition-opacity",style:{background:"hsl(var(--primary))"},children:[e.jsx("span",{children:"Low Roller Reining Classic — Arena 1 at 10:00 a.m. Eastern, Arena 2 at 10:30 a.m. Eastern."}),e.jsx("span",{className:"underline whitespace-nowrap",children:"Watch both."})]}),e.jsxs("p",{className:"text-muted-foreground mb-3",style:{fontSize:"14px",lineHeight:"21px"},children:[e.jsx("span",{style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"fde732",guard:{file:"src/pages/index.tsx",tagName:"span",sourceKind:"content-key",contentKey:"home.featuredPlayerCaption",contentKeyTemplate:null,expressionHash:null},children:ha.featuredPlayerCaption})})," ",e.jsx(O,{to:"/advertise#featured-player",className:"text-accent hover:underline",children:e.jsx("span",{style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"c0d471",guard:{file:"src/pages/index.tsx",tagName:"span",sourceKind:"content-key",contentKey:"home.featuredPlayerLinkText",contentKeyTemplate:null,expressionHash:null},children:ha.featuredPlayerLinkText})})})]}),e.jsx(Ng,{placement:"homepage-player-leaderboard"}),e.jsxs("div",{className:"mb-4 text-foreground flex flex-col gap-3",style:{fontSize:"16px",lineHeight:"24px"},children:[e.jsx("p",{children:e.jsx("span",{style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"bd1267",guard:{file:"src/pages/index.tsx",tagName:"span",sourceKind:"content-key",contentKey:"home.description[0].text",contentKeyTemplate:null,expressionHash:null},children:ha.description[0].text})})}),e.jsxs("p",{children:["The ultimate"," ",e.jsx("a",{href:"https://www.grandnational.org.uk/",target:"_blank",rel:"noopener noreferrer",className:"text-accent hover:underline",children:"Grand National 2026 guide"})," ","– Discover all the Runners, Riders and Odds with our easy to follow guide. Plus free bets & tips for the big race."]})]}),m.length>0&&e.jsxs("div",{className:"mb-4",children:[e.jsxs("div",{className:"flex items-center justify-between mb-2",children:[e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(ys,{size:14,className:"text-primary shrink-0"}),e.jsx("span",{className:"font-bold text-foreground text-sm uppercase tracking-wide",children:"Upcoming Events"})]}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(O,{to:"/events",className:"text-accent hover:underline text-xs font-semibold",children:"View all →"}),e.jsx(f8,{trackId:"upcoming-events-track"})]})]}),e.jsx("div",{id:"upcoming-events-track",className:"flex gap-2 overflow-x-auto pb-2",style:{scrollbarWidth:"thin",scrollSnapType:"x mandatory"},children:m.map(y=>{var v,w;return e.jsxs("div",{className:"border border-border bg-card flex flex-col gap-1.5 px-3 py-2.5 shrink-0",style:{width:"220px",scrollSnapAlign:"start"},children:[y.logoUrl&&e.jsx("img",{src:y.logoUrl,alt:y.title,className:"h-8 w-auto object-contain mb-0.5",loading:"lazy"}),e.jsx("p",{className:"font-semibold text-foreground leading-snug line-clamp-2",style:{fontSize:"13px"},children:y.title}),e.jsxs("p",{className:"text-muted-foreground",style:{fontSize:"12px"},children:[p8(y.startDate,y.endDate),y.cityVenue?` · ${y.cityVenue}`:""]}),e.jsx(O,{to:(v=y.linkLabel)!=null&&v.startsWith("/")?y.linkLabel:"/events",...!((w=y.linkLabel)!=null&&w.startsWith("/"))&&y.linkLabel?{target:"_blank",rel:"noopener noreferrer"}:{},className:"mt-auto self-start bg-primary text-white text-xs font-bold uppercase px-2.5 py-1 hover:opacity-90 transition-opacity",children:y.buttonLabel||"Learn More"})]},y.id)})})]}),e.jsxs("div",{className:"border border-border bg-card flex flex-col sm:flex-row items-stretch gap-0 mb-4 overflow-hidden",children:[e.jsx("div",{className:"sm:w-1.5 w-full h-1.5 
633sm:h-auto bg-primary shrink-0"}),e.jsxs("div",{className:"flex-1 px-4 py-3 flex flex-col gap-1.5",children:[e.jsxs("div",{className:"flex items-center gap-2 flex-wrap",children:[e.jsx(Xs,{size:14,className:"text-primary shrink-0"}),e.jsx("span",{className:"font-bold text-foreground text-sm uppercase tracking-wide leading-tight",children:"Reining Category Icon Photo Contest"}),e.jsx("span",{className:"text-xs font-semibold px-1.5 py-0.5 rounded border bg-green-100 text-green-800 border-green-300",children:"Entries Open"})]}),e.jsxs("p",{className:"text-muted-foreground text-xs leading-snug",children:[e.jsx("span",{className:"font-semibold text-foreground",children:"Prize:"})," ",e.jsx("span",{children:"$150 Visa gift card + Reining category icon for one year"})]}),e.jsxs("p",{className:"text-muted-foreground text-xs",children:[e.jsx("span",{className:"font-semibold text-foreground",children:"Submissions:"})," October 2–10, 2026  · ",e.jsx("span",{children:"Voting: week of October 11"})]}),e.jsxs("div",{className:"flex items-center gap-3 flex-wrap mt-0.5",children:[e.jsx(O,{to:"/contests#reining-icon",className:"bg-primary text-white text-xs font-bold uppercase px-3 py-1.5 hover:opacity-90 transition-opacity shrink-0",children:"Enter Contest"}),e.jsx(O,{to:"/contests#reining-icon",className:"text-accent hover:underline text-xs shrink-0",children:"Contest Rules"})]}),e.jsxs("p",{className:"text-xs text-muted-foreground mt-1",children:["Sponsored by ",e.jsx("span",{className:"font-semibold text-foreground",children:"Total Horse Channel"})]})]})]}),e.jsxs("div",{className:"border border-border bg-card flex flex-col sm:flex-row items-stretch gap-0 mb-4 overflow-hidden",children:[e.jsx("div",{className:"sm:w-1.5 w-full h-1.5 sm:h-auto bg-primary shrink-0"}),e.jsxs("div",{className:"flex-1 px-4 py-3 flex flex-col gap-1.5",children:[e.jsxs("div",{className:"flex items-center gap-2 flex-wrap",children:[e.jsx(Xs,{size:14,className:"text-primary shrink-0"}),e.jsx("span",{className:"font-bold text-foreground text-sm uppercase tracking-wide leading-tight",children:e.jsx("span",{style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"f782f5",guard:{file:"src/pages/index.tsx",tagName:"span",sourceKind:"content-key",contentKey:"home.miniContestTitle",contentKeyTemplate:null,expressionHash:null},children:ha.miniContestTitle})})}),e.jsx("span",{className:"text-xs font-semibold px-1.5 py-0.5 rounded border bg-green-100 text-green-800 border-green-300",children:"Entries Open"})]}),e.jsxs("p",{className:"text-muted-foreground text-xs leading-snug",children:[e.jsx("span",{className:"font-semibold text-foreground",children:"Prize:"})," ",e.jsx("span",{style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"0177c0",guard:{file:"src/pages/index.tsx",tagName:"span",sourceKind:"content-key",contentKey:"home.miniContestPrize",contentKeyTemplate:null,expressionHash:null},children:ha.miniContestPrize})})]}),e.jsxs("p",{className:"text-muted-foreground text-xs",children:[e.jsx("span",{className:"font-semibold text-foreground",children:"Submissions:"})," ",e.jsx("span",{style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"434ca1",guard:{file:"src/pages/index.tsx",tagName:"span",sourceKind:"content-key",contentKey:"home.miniContestDates",contentKeyTemplate:null,expressionHash:null},children:ha.miniContestDates})}),"  · ",e.jsx("span",{style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"434ca2",guard:{file:"src/pages/index.tsx",tagName:"span",sourceKind:"content-key",contentKey:"home.miniContestVoting",contentKeyTemplate:null,expressionHash:null},children:ha.miniContestVoting})})]}),e.jsxs("div",{className:"flex items-center gap-3 flex-wrap mt-0.5",children:[e.jsx(O,{to:"/contests#miniature-horse-icon",className:"bg-primary text-white text-xs font-bold uppercase px-3 py-1.5 hover:opacity-90 transition-opacity shrink-0",children:"Enter Contest"}),e.jsx(O,{to:"/contests#miniature-horse-icon",className:"text-accent hover:underline text-xs shrink-0",children:"Contest Rules"})]}),e.jsxs("p",{className:"text-xs text-muted-foreground mt-1",children:["Sponsored by ",e.jsx("span",{className:"font-semibold text-foreground",children:"Total Horse Channel"})]})]})]}),e.jsxs("div",{className:"border border-border bg-card flex flex-col sm:flex-row items-stretch gap-0 mb-4 overflow-hidden",children:[e.jsx("div",{className:"sm:w-1.5 w-full h-1.5 
633sm:h-auto bg-primary shrink-0"}),e.jsxs("div",{className:"flex-1 px-4 py-3 flex flex-col gap-1.5",children:[e.jsxs("div",{className:"flex items-center gap-2 flex-wrap",children:[e.jsx(og,{size:14,className:"text-primary shrink-0"}),e.jsx("span",{className:"font-bold text-foreground text-sm uppercase tracking-wide leading-tight",children:e.jsx("span",{style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"709a36",guard:{file:"src/pages/index.tsx",tagName:"span",sourceKind:"content-key",contentKey:"home.hmvContestTitle",contentKeyTemplate:null,expressionHash:null},children:ha.hmvContestTitle})})})]}),e.jsxs("p",{className:"text-muted-foreground text-xs leading-snug",children:[e.jsx("span",{className:"font-semibold text-foreground",children:"Prize:"})," ",e.jsx("span",{style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"1799e1",guard:{file:"src/pages/index.tsx",tagName:"span",sourceKind:"content-key",contentKey:"home.hmvContestPrize",contentKeyTemplate:null,expressionHash:null},children:ha.hmvContestPrize})})]}),e.jsxs("p",{className:"text-muted-foreground text-xs",children:[e.jsx("span",{style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"596ec1",guard:{file:"src/pages/index.tsx",tagName:"span",sourceKind:"content-key",contentKey:"home.hmvContestDeadline",contentKeyTemplate:null,expressionHash:null},children:ha.hmvContestDeadline})}),e.jsx("span",{className:"mx-1.5 opacity-40",children:"·"}),e.jsx("span",{style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"596ec3",guard:{file:"src/pages/index.tsx",tagName:"span",sourceKind:"content-key",contentKey:"home.hmvContestVoting",contentKeyTemplate:null,expressionHash:null},children:ha.hmvContestVoting})})]}),e.jsxs("div",{className:"flex items-center gap-3 flex-wrap mt-0.5",children:[e.jsx(O,{to:"/contests#horse-music-video",className:"bg-primary text-white text-xs font-bold uppercase px-3 py-1.5 hover:opacity-90 transition-opacity shrink-0",children:"Enter Contest"}),e.jsx(O,{to:"/contests#horse-music-video",className:"text-accent hover:underline text-xs shrink-0",children:"Contest Rules"}),e.jsx(O,{to:"/advertise#sponsor-a-contest",className:"text-accent hover:underline text-xs shrink-0",children:"Sponsor this contest"})]})]})]}),(!d||u)&&e.jsxs("div",{className:"flex flex-col sm:flex-row items-center justify-between gap-3 bg-primary px-4 py-3 mb-4",children:[e.jsx("span",{className:"text-white font-semibold text-sm text-center sm:text-left",children:e.jsx("span",{style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"cc964e",guard:{file:"src/pages/index.tsx",tagName:"span",sourceKind:"content-key",contentKey:"home.createAccountCta",contentKeyTemplate:null,expressionHash:null},children:ha.createAccountCta})})}),e.jsx(O,{to:"/become-member",className:"shrink-0 bg-white text-primary text-sm font-bold uppercase px-5 py-2 hover:bg-white/90 transition-opacity",children:"Create Account"})]}),e.jsx(O,{to:"/mission",className:"block w-full text-center font-bold uppercase py-2 text-sm bg-gray-200 text-gray-800 hover:bg-gray-300 transition-colors mb-4",children:e.jsx("span",{style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"ca9710",guard:{file:"src/pages/index.tsx",tagName:"span",sourceKind:"content-key",contentKey:"home.ourMissionLabel",contentKeyTemplate:null,expressionHash:null},children:ha.ourMissionLabel})})})]}),e.jsxs("div",{className:"w-full lg:w-[350px] shrink-0 flex flex-col gap-4",children:[e.jsx(zs,{placement:"sidebar-homepage"}),e.jsx(O,{to:"/watch-live-events",className:"block w-full text-center text-white font-bold uppercase py-3 text-base bg-primary hover:bg-primary/90 transition-colors",children:e.jsx("span",{style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"1204d1",guard:{file:"src/pages/index.tsx",tagName:"span",sourceKind:"content-key",contentKey:"home.watchLiveLabel",contentKeyTemplate:null,expressionHash:null},children:ha.watchLiveLabel})})}),e.jsx(O,{to:"/add-video-live",className:"block w-full text-center text-white font-bold uppercase py-3 text-base bg-secondary hover:bg-secondary/80 transition-colors",children:e.jsx("span",{style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"53d9b2",guard:{file:"src/pages/index.tsx",tagName:"span",sourceKind:"content-key",contentKey:"home.addVideoLabel",contentKeyTemplate:null,expressionH
633ash:null},children:ha.addVideoLabel})})}),e.jsx(O,{to:"/community",className:"block w-full text-center text-white font-bold uppercase py-3 text-base bg-primary hover:bg-primary/90 transition-colors",children:e.jsx("span",{style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"95ae93",guard:{file:"src/pages/index.tsx",tagName:"span",sourceKind:"content-key",contentKey:"home.sharePhotosLabel",contentKeyTemplate:null,expressionHash:null},children:ha.sharePhotosLabel})})}),e.jsx(Cr,{placement:"sidebar-homepage-220"}),e.jsxs("div",{children:[e.jsxs("div",{className:"bg-primary px-3 py-2 flex items-center justify-between",children:[e.jsx("h2",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Recent News"}),e.jsx(O,{to:"/news",className:"text-white/80 hover:text-white text-xs",children:"All news →"})]}),e.jsx("ul",{className:"border border-border divide-y divide-border",children:l.length===0?e.jsx("li",{children:e.jsx(O,{to:"/news",className:"block px-3 py-2 text-accent hover:underline",style:{fontSize:"14px",lineHeight:"21px"},children:"View all news →"})}):l.map(y=>e.jsx("li",{children:e.jsxs(O,{to:`/news/${y.slug}`,className:"flex gap-2 px-3 py-2 hover:bg-muted transition-colors",children:[y.imageUrl&&e.jsx("div",{className:"shrink-0 w-[60px] h-[40px] overflow-hidden bg-muted mt-0.5",children:e.jsx("img",{src:y.imageUrl,alt:y.title,width:60,height:40,className:"w-full h-full object-cover",loading:"lazy"})}),e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("p",{className:"text-accent hover:underline leading-snug line-clamp-2",style:{fontSize:"13px",lineHeight:"18px"},children:y.title}),(y.publishedAt??y.createdAt)&&e.jsx("p",{className:"text-muted-foreground mt-0.5",style:{fontSize:"11px"},children:new Date(y.publishedAt??y.createdAt).toLocaleDateString("en-US",{month:"short",day:"numeric",year:"numeric"})})]})]})},y.id))})]})]})]})}),e.jsxs("div",{className:"max-w-[1280px] mx-auto px-4 pb-6",children:[t.length>0&&e.jsxs("div",{className:"mb-6",children:[e.jsxs("div",{className:"bg-primary px-3 py-2 mb-3 flex items-center gap-2",children:[e.jsx("span",{className:"inline-block w-2 h-2 rounded-full bg-white animate-pulse"}),e.jsx("h2",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Live Now"}),e.jsx(O,{to:"/watch-live-events",className:"ml-auto text-white/80 hover:text-white text-xs font-medium transition-colors",children:"View all →"})]}),e.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 lg:grid-cols-4 gap-3",children:t.slice(0,4).map(y=>e.jsxs(O,{to:`/live/${y.slug}`,className:"flex flex-col border border-border bg-card hover:border-primary transition-colors",children:[e.jsxs("div",{className:"relative w-full bg-black overflow-hidden",style:{aspectRatio:"16/9"},children:[y.thumbnailUrl?e.jsx("img",{src:y.thumbnailUrl,alt:y.title,width:320,height:180,className:"absolute inset-0 w-full h-full object-cover",loading:"lazy"}):e.jsx("div",{className:"absolute inset-0 flex items-center justify-center bg-gray-900",children:e.jsx(Fn,{size:24,className:"text-gray-600"})}),e.jsxs("div",{className:"absolute top-1.5 left-1.5 bg-primary text-white text-xs font-bold px-1.5 py-0.5 flex items-center gap-1 pointer-events-none",children:[e.jsx("span",{className:"inline-block w-1.5 h-1.5 rounded-full bg-white animate-pulse"}),e.jsx("span",{children:"LIVE"})]})]}),e.jsxs("div",{className:"px-2 py-2 flex flex-col gap-1",children:[e.jsx("p",{className:"font-semibold text-foreground leading-snug line-clamp-2",style:{fontSize:"13px"},children:y.title}),e.jsxs("div",{className:"flex items-center gap-1.5 text-muted-foreground",style:{fontSize:"12px"},children:[e.jsx(ys,{size:11}),e.jsx("span",{children:o(y.startAt,y.title)})]})]})]},y.id))})]}),e.jsx(wu,{title:"Recently Added Videos",videos:p,totalPages:a.length,seeAllHref:"/videos"}),e.jsx(wu,{title:"Popular Videos",videos:x,totalPages:a.length,seeAllHref:"/videos"}),b.length>0&&e.jsx(wu,{title:"Horse Racing Videos",videos:b,totalPages:r.length,seeAllHref:"/category/horse-racing"}),e.jsx(wu,{title:"How To Videos",videos:g8,totalPages:33,seeAllHref:"/category/how-to-videos"})]}),e.jsxs("div",{className:"max-w-[1280px] mx-auto px-4 pb-6",children:[e.jsxs("div",{className:"bg-primary px-3 py-2 mb-3 flex items-center justify-between",children:[e.jsx("h2",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Community"}),e.jsx(O,{to:"/community",className:"text-white/80 hover:text-white text-xs font-medium transition-colors",children:"See all →"})]}),e.jsx(L2,{limit:5,hidePostBox:!0}),e.jsx("div",{className:"mt-3 text-center",children:e.jsx(O,{to:"/community",className:"inline-block text-sm text-accent hover:underline font-medium",children:"See all c
633ommunity posts →"})})]}),e.jsx(nE,{})]})]})}const Kj="https://totalhorsechannel.com",Ij="Community – Total Horse Channel",Bj="Share photos and updates with the horse industry. Free account required to post.";function v8(){return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:Ij}),e.jsx("meta",{name:"description",content:Bj}),e.jsx("link",{rel:"canonical",href:`${Kj}/community`}),e.jsx("meta",{property:"og:title",content:Ij}),e.jsx("meta",{property:"og:description",content:Bj}),e.jsx("meta",{property:"og:url",content:`${Kj}/community`}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"})]}),e.jsx("main",{className:"max-w-7xl mx-auto px-4 py-6",children:e.jsxs("div",{className:"flex flex-col lg:flex-row gap-6",children:[e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsxs("div",{className:"mb-5",children:[e.jsx("h1",{className:"text-2xl font-bold text-foreground",children:"Community"}),e.jsx("p",{className:"text-sm text-muted-foreground mt-1",children:"Share photos and updates with the horse industry. Free account required to post."})]}),e.jsx(L2,{})]}),e.jsxs("aside",{className:"w-full lg:w-64 shrink-0 flex flex-col gap-4",children:[e.jsx(zs,{}),e.jsx(Cr,{})]})]})})]})}const D2="https://totalhorsechannel.com";function j8(t){return t?t.startsWith("http://")||t.startsWith("https://")?t:`${D2}${t.startsWith("/")?"":"/"}${t}`:null}function w8(){var x;const{post:t}=sg(),a=(t==null?void 0:t.name)||(t==null?void 0:t.username)||"Member",r=t!=null&&t.contestSourceType?` — ${t.contestSourceType.replace(/-/g," ").replace(/\b\w/g,b=>b.toUpperCase())} Contest`:"",o=t?`${a}${r} on Total Horse Channel`:"Community Post — Total Horse Channel",d=(t!=null&&t.body?t.body.split(`
634`).map(b=>b.trim()).find(b=>b.length>0)??"":"").slice(0,160)||"Join the conversation on Total Horse Channel Community.",u=((x=t==null?void 0:t.images)==null?void 0:x[0])??(t==null?void 0:t.imageUrl)??null,m=j8(u),p=`${D2}/community/p/${(t==null?void 0:t.id)??""}`;return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:o}),e.jsx("meta",{name:"description",content:d}),e.jsx("link",{rel:"canonical",href:p}),e.jsx("meta",{property:"og:type",content:"article"}),e.jsx("meta",{property:"og:url",content:p}),e.jsx("meta",{property:"og:title",content:o}),e.jsx("meta",{property:"og:description",content:d}),m&&e.jsx("meta",{property:"og:image",content:m}),m&&e.jsx("meta",{property:"og:image:width",content:"1200"}),m&&e.jsx("meta",{property:"og:image:height",content:"630"}),e.jsx("meta",{property:"og:site_name",content:"Total Horse Channel"}),e.jsx("meta",{name:"twitter:card",content:m?"summary_large_image":"summary"}),e.jsx("meta",{name:"twitter:title",content:o}),e.jsx("meta",{name:"twitter:description",content:d}),m&&e.jsx("meta",{name:"twitter:image",content:m}),e.jsx("meta",{name:"twitter:site",content:"@TotalHorseChnl"})]}),e.jsxs("main",{className:"max-w-2xl mx-auto px-4 py-8",children:[e.jsx("h1",{className:"sr-only",children:e.jsx(_,{devId:"aeaa82",guard:{file:"src/pages/community/p/[postId].tsx",tagName:"h1",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:b659bda8b601b21b4c369419ae57654a75affee5c25077c7f523f758ff8b4652"},children:o})}),e.jsxs(O,{to:"/community",className:"inline-flex items-center gap-1 text-sm text-muted-foreground hover:text-primary mb-6 transition-colors",children:[e.jsx(En,{size:15}),"Back to Community"]}),t?e.jsx(_2,{post:t}):e.jsxs("div",{className:"text-center py-16",children:[e.jsx("p",{className:"text-muted-foreground",children:"This post could not be found."}),e.jsx(O,{to:"/community",className:"mt-4 inline-block text-primary hover:underline text-sm",children:"Browse the community feed"})]})]})]})}const N8="https://totalhorsechannel.com";function S8(t,a){return An(t,a)}function C8({ev:t}){return e.jsxs(O,{to:`/live/${t.slug}`,className:"flex flex-col border border-border bg-card hover:border-primary transition-colors group",children:[e.jsxs("div",{className:"relative w-full bg-black overflow-hidden",style:{aspectRatio:"16/9"},children:[t.thumbnailUrl?e.jsx("img",{src:t.thumbnailUrl,alt:t.title,width:320,height:180,className:"absolute inset-0 w-full h-full object-cover group-hover:opacity-90 transition-opacity",loading:"lazy"}):e.jsx("div",{className:"absolute inset-0 flex items-center justify-center bg-gray-900",children:e.jsx(Vs,{size:24,className:"text-gray-600"})}),e.jsx("div",{className:"absolute inset-0 flex items-center justify-center opacity-0 group-hover:opacity-100 transition-opacity pointer-events-none",children:e.jsx("div",{className:"w-10 h-10 rounded-full bg-primary/80 flex items-center justify-center",children:e.jsx("svg",{className:"w-4 h-4 text-white ml-0.5",fill:"currentColor",viewBox:"0 0 20 20",children:e.jsx("path",{d:"M6.3 2.841A1.5 1.5 0 004 4.11V15.89a1.5 1.5 0 002.3 1.269l9.344-5.89a1.5 1.5 0 000-2.538L6.3 2.84z"})})})}),t.isArchived?e.jsxs("div",{className:"absolute top-1.5 left-1.5 bg-secondary text-white text-[10px] font-bold uppercase px-1.5 py-0.5 flex items-center gap-1 pointer-events-none",children:[e.jsx(Vs,{size:8}),"Archive"]}):t.videoType==="live"?e.jsxs("div",{className:"absolute top-1.5 left-1.5 bg-primary text-white text-[10px] font-bold uppercase px-1.5 py-0.5 flex items-center gap-1 pointer-events-none",children:[e.jsx(Ft,{size:8}),"Live"]}):t.videoType==="upcoming"?e.jsxs("div",{className:"absolute top-1.5 left-1.5 bg-accent text-white text-[10px] font-bold uppercase px-1.5 py-0.5 flex items-center gap-1 pointer-events-none",children:[e.jsx(Ft,{size:8}),"Upcoming"]}):e.jsxs("div",{className:"absolute top-1.5 left-1.5 bg-secondary text-white text-[10px] font-bold uppercase px-1.5 py-0.5 flex items-center gap-1 pointer-events-none",children:[e.jsx(Vs,{size:8}),"Video"]})]}),e.jsxs("div",{className:"px-2 py-2 flex flex-col gap-1",children:[e.jsx("p",{className:"font-semibold text-foreground leading-snug line-clamp-2 group-hover:text-accent transition-colors",style:{fontSize:"13px"},children:e.jsx(_,{devId:"0fe46f",guard:{file:"src/pages/search.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionH
634ash:"sha256:940358fa95ea1497f9b63f15c13b830cddaffcfff65328ed4d4d4e8e024ac21d"},children:t.title})}),e.jsxs("div",{className:"flex items-center gap-2 flex-wrap",style:{fontSize:"11px"},children:[t.category&&e.jsx("span",{className:"text-primary font-medium truncate",children:e.jsx(_,{devId:"f345c5",guard:{file:"src/pages/search.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:f824327c0ee15f1f2565a6163c254a601b38b71919e80d7ad2bb943683b217c6"},children:t.category})}),t.providedBy&&e.jsx("span",{className:"text-muted-foreground truncate",children:e.jsx(_,{devId:"f345c6",guard:{file:"src/pages/search.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:5c5176ac949fb29f6bc040b290182c6415ce5fb7f7e110ce44ab61359e19901a"},children:t.providedBy})}),t.startAt&&e.jsxs("span",{className:"flex items-center gap-1 text-muted-foreground",children:[e.jsx(ys,{size:10}),S8(t.startAt,t.title)]})]})]})]})}function k8(){const[t,a]=Bm(),r=ga(),o=t.get("q")??"",[l,d]=g.useState(o),[u,m]=g.useState({categories:[],events:[],members:[]}),[p,x]=g.useState(!1),[b,y]=g.useState(!1),v=g.useRef(null),w=g.useCallback(async E=>{if(!E.trim()){m({categories:[],events:[],members:[]}),y(!1);return}x(!0);try{const U=await fetch(`/api/search?q=${encodeURIComponent(E.trim())}`);if(U.ok){const q=await U.json();m(q),y(!0)}}catch{}finally{x(!1)}},[]);g.useEffect(()=>{d(o),w(o)},[o,w]);function C(E){const U=E.target.value;d(U),v.current&&clearTimeout(v.current),v.current=setTimeout(()=>{a(U.trim()?{q:U.trim()}:{},{replace:!0})},300)}function A(E){E.preventDefault(),l.trim()&&a({q:l.trim()})}const S=u.events.length>0,z=u.members.length>0,T=u.categories.length>0,M=b&&!p&&!S&&!z&&!T,P=o?`Search: "${o}" – Total Horse Channel`:"Search – Total Horse Channel";return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:P}),e.jsx("meta",{name:"description",content:"Search horse videos, live events, and members on Total Horse Channel."}),e.jsx("link",{rel:"canonical",href:`${N8}/search`}),e.jsx("meta",{name:"robots",content:"noindex"})]}),e.jsx("main",{children:e.jsx("div",{className:"max-w-[1280px] mx-auto px-4 py-6",children:e.jsxs("div",{className:"flex flex-col lg:flex-row gap-6",children:[e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsxs("div",{className:"flex items-center gap-3 mb-6",children:[e.jsxs("button",{onClick:()=>r(-1),className:"shrink-0 flex items-center gap-1 text-sm text-muted-foreground hover:text-foreground transition-colors","aria-label":"Go back",children:[e.jsx(En,{size:16}),e.jsx("span",{className:"hidden sm:inline",children:"Back"})]}),e.jsx("form",{onSubmit:A,className:"flex-1 max-w-2xl",children:e.jsxs("div",{className:"flex items-center border-2 border-primary rounded overflow-hidden bg-white",children:[e.jsx("input",{type:"text",value:l,onChange:C,placeholder:"Search videos, lives, members…",className:"flex-1 px-4 py-2.5 text-sm outline-none bg-white text-foreground","aria-label":"Search",autoComplete:"off",autoFocus:!0}),e.jsx("button",{type:"submit",className:"px-4 py-2.5 bg-primary text-white hover:bg-primary/90 transition-colors","aria-label":"Search",children:e.jsx(pi,{size:16})})]})})]}),o&&e.jsx("h1",{className:"text-foreground font-bold mb-4",style:{fontSize:"20px"},children:e.jsx(_,{devId:"43d996",guard:{file:"src/pages/search.tsx",tagName:"h1",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:9190c47323dae93db6da0571ccaba2d10d3c62f4a72d9d8896cb585ede9f0300"},children:p?"Searching…":b?e.jsxs(e.Fragment,{children:[u.events.length+u.members.length," result",u.events.length+u.members.length!==1?"s":""," for ",e.jsxs("span",{className:"text-primary",children:["“",o,"”"]})]}):null})}),p&&e.jsx("div",{className:"flex justify-center py-16",children:e.jsx("div",{className:"w-8 h-8 border-2 border-primary border-t-transparent rounded-full animate-spin"})}),M&&e.jsxs("div",{className:"border border-border bg-card px-6 py-12 text-center",children:[e.jsxs("p",{className:"text-muted-foreground text-base mb-2",children:["No results found for “",o,"”"]}
634),e.jsx("p",{className:"text-muted-foreground text-sm",children:"Try a different search term or browse a category below."}),e.jsx("div",{className:"flex flex-wrap justify-center gap-3 mt-6",children:[{label:"Horse Racing",href:"/category/horse-racing"},{label:"Reining",href:"/category/reining"},{label:"Show Jumping",href:"/category/show-jumping"},{label:"Western Dressage",href:"/category/western-dressage"},{label:"How-To Videos",href:"/category/how-to-videos"}].map(E=>e.jsx(O,{to:E.href,className:"text-accent text-sm hover:underline border border-border px-3 py-1.5 rounded",children:E.label},E.href))})]}),!o&&!p&&e.jsxs("div",{className:"border border-border bg-card px-6 py-12 text-center",children:[e.jsx(pi,{size:32,className:"mx-auto text-muted-foreground mb-3"}),e.jsx("p",{className:"text-muted-foreground text-base",children:"Type something above to search videos, live events, and members."})]}),!p&&z&&e.jsxs("div",{className:"mb-6",children:[e.jsxs("div",{className:"bg-secondary px-3 py-2 mb-4 flex items-center gap-2",children:[e.jsx(Ha,{size:13,className:"text-white"}),e.jsx("h2",{className:"text-white font-bold uppercase text-xs tracking-wide",children:"Members"})]}),e.jsx("div",{className:"flex flex-wrap gap-3",children:u.members.map(E=>e.jsxs(O,{to:`/u/${E.username}`,className:"flex items-center gap-3 border border-border bg-card hover:border-primary hover:bg-muted transition-colors px-3 py-2.5 min-w-[180px]",children:[e.jsx("div",{className:"w-9 h-9 rounded-full bg-muted border border-border overflow-hidden shrink-0 flex items-center justify-center",children:E.avatarUrl?e.jsx("img",{src:E.avatarUrl,alt:E.name??E.username,className:"w-full h-full object-cover",width:36,height:36,loading:"lazy"}):e.jsx(Ha,{size:16,className:"text-muted-foreground",strokeWidth:1.5})}),e.jsxs("div",{className:"min-w-0",children:[e.jsx("p",{className:"text-sm font-semibold text-foreground truncate leading-tight",children:E.name??E.username}),e.jsxs("p",{className:"text-xs text-muted-foreground truncate",children:["@",E.username]})]})]},E.username))})]}),!p&&T&&e.jsxs("div",{className:"mb-6",children:[e.jsxs("div",{className:"bg-secondary px-3 py-2 mb-3 flex items-center gap-2",children:[e.jsx(Qf,{size:13,className:"text-white"}),e.jsx("h2",{className:"text-white font-bold uppercase text-xs tracking-wide",children:"Category Pages"})]}),e.jsx("div",{className:"flex flex-wrap gap-2",children:u.categories.map(E=>e.jsxs(O,{to:`/category/${E.slug}`,className:"flex items-center gap-2 border border-border bg-card hover:border-primary hover:bg-muted transition-colors px-3 py-2 text-sm font-semibold text-accent",children:[e.jsx(Qf,{size:12,className:"text-primary shrink-0"}),E.label]},E.slug))})]}),!p&&S&&e.jsxs("div",{className:"mb-8",children:[e.jsxs("div",{className:"bg-primary px-3 py-2 mb-4 flex items-center gap-2",children:[e.jsx(Vs,{size:13,className:"text-white"}),e.jsxs("h2",{className:"text-white font-bold uppercase text-xs tracking-wide",children:["Videos & Live Events",e.jsxs("span",{className:"ml-2 font-normal opacity-80",children:["(",u.events.length,")"]})]})]}),e.jsx("div",{className:"grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-4 gap-4",children:u.events.map(E=>e.jsx(C8,{ev:E},E.id))})]})]}),e.jsxs("div",{className:"w-full lg:w-[300px] shrink-0 flex flex-col gap-4",children:[e.jsx(zs,{placement:"sidebar-search"}),e.jsx(O,{to:"/watch-live-events",className:"block w-full text-center text-white font-bold uppercase py-3 text-base bg-primary hover:bg-primary/90 transition-colors",children:"WATCH LIVE EVENTS"}),e.jsx(Cr,{placement:"sidebar-search-220"})]})]})})})]})}function T8(t=5){const[a,r]=g.useState(null);return g.useEffect(()=>{fetch(`/api/news?limit=${t}`).then(o=>o.ok?o.json():Promise.reject(o.status)).then(o=>r((o.articles??[]).slice(0,t))).catch(()=>r([]))},[t]),a}const O2={youtube:"YouTube",rumble:"Rumble",vimeo:"Vimeo",box:"Box",other:"Live"};function A8(t,a){return An(t,a)}const kf=25;function E8({total:t,page:a,perPage:r,onPage:o}){const l=Math.max(1,Math.ceil(t/r));if(l<=1)return null;const d=[],u=m=>{d.includes(m)||d.push(m)};u(1),a-2>2&&d.push("ellipsis-start");for(let m=Math.max(2,a-1);m<=Math.min(l-1,a+1);m++)u(m);return a+2<l-1&&d.push("ellipsis-end"),l>1&&u(l),e.jsxs("div",{className:"flex flex-wrap items-center gap-1 text-sm mt-4 mb-2",children:[e.jsxs("button",{onClick:()=>o(a-1),disabled:a===1,className:"flex items-center gap-0.5 px-2 py-1 border border-border hover:bg-muted disabled:opacity-40 disabled:cursor-not-allowed",children:[e.jsx(En,{size:13})," Prev"]}),d.map(m=>typeof m=="string"?e.jsx("span",{className:"px-1 text-muted-foreground",children:"…"},m):e.jsx("button",{onClick:()=>o(m),className:`px-2.5 py-1 border ${a===m?"bg-primary text-white border-primary font-bold":"border-border hover:bg-muted"}`,children:m},m)),e.jsxs("button",{onClick:()=>o(a+1),disabled:a===l,className:"flex items-center gap-0.5 px-2 py-1 border border-border hover:bg-muted disabled:opacity-40 disabled:cursor-not-allowed",children:["Next ",e.jsx(Lt,{size:13})]}),e.jsxs("span",{className:"ml-2 text-xs text-muted-foreground",children:[t," item",t!==1?"s":""," · page ",a," of ",l]})]})}const Ic="https://totalhorsechannel.com",Zu=`${Ic}/watch-live-events`;function H8({ev:t}){const a=(()=>{try{const r=new Date(t.startAt);
634if(!isNaN(r.getTime()))return r.toLocaleString("en-US",{weekday:"short",month:"short",day:"numeric",year:"numeric",hour:"numeric",minute:"2-digit",hour12:!0})}catch{}return""})();return e.jsxs(O,{to:`/live/${t.slug}`,className:"flex flex-col border border-blue-200 bg-blue-50 hover:border-blue-500 transition-colors",children:[e.jsxs("div",{className:"relative w-full bg-blue-900 overflow-hidden",style:{aspectRatio:"16/9"},children:[t.thumbnailUrl?e.jsx("img",{src:t.thumbnailUrl,alt:t.title,width:320,height:180,className:"absolute inset-0 w-full h-full object-cover opacity-80",loading:"lazy"}):e.jsx("div",{className:"absolute inset-0 flex items-center justify-center bg-blue-900",children:e.jsx(Ms,{size:28,className:"text-blue-300"})}),e.jsx("div",{className:"absolute top-1.5 left-1.5 bg-blue-700 text-white text-[10px] font-bold uppercase px-1.5 py-0.5 rounded",children:"Upcoming"})]}),e.jsxs("div",{className:"px-2 py-2 flex flex-col gap-1",children:[e.jsx("p",{className:"font-semibold text-foreground leading-snug line-clamp-2",style:{fontSize:"13px"},children:e.jsx(_,{devId:"7f2b0f",guard:{file:"src/pages/watch-live-events.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:940358fa95ea1497f9b63f15c13b830cddaffcfff65328ed4d4d4e8e024ac21d"},children:t.title})}),a&&e.jsxs("div",{className:"flex items-center gap-1.5 text-blue-700 font-medium",style:{fontSize:"11px"},children:[e.jsx(Ms,{size:11}),e.jsx("span",{children:e.jsx(_,{devId:"8c0065",guard:{file:"src/pages/watch-live-events.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:335d8c409e239640bb6c80c6c5cb05e905d5494a05346e20f8d62a0788a4a41e"},children:a})})]}),e.jsx("div",{className:"flex items-center gap-2 text-muted-foreground",style:{fontSize:"11px"},children:e.jsx("span",{className:"capitalize",children:e.jsx(_,{devId:"cdd546",guard:{file:"src/pages/watch-live-events.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:984f6eb135fc8b1f393aeaa1b484e6d247f17cc6b8e401df416ee4284fed9752"},children:O2[t.source]??t.source})})})]})]})}function $j({ev:t,showCategory:a}){var o;const r=(o=t.category)==null?void 0:o.trim();return e.jsxs(O,{to:`/live/${t.slug}`,className:"flex flex-col border border-border bg-card hover:border-primary transition-colors",children:[e.jsx("div",{className:"relative w-full bg-black overflow-hidden",style:{aspectRatio:"16/9"},children:t.thumbnailUrl?e.jsx("img",{src:t.thumbnailUrl,alt:t.title,width:320,height:180,className:"absolute inset-0 w-full h-full object-cover",loading:"lazy"}):e.jsx("div",{className:"absolute inset-0 flex items-center justify-center bg-gray-900",children:e.jsx(Fn,{size:28,className:"text-gray-600"})})}),e.jsxs("div",{className:"px-2 py-2 flex flex-col gap-1",children:[a&&r&&e.jsx("span",{className:"inline-block text-[10px] font-bold uppercase tracking-wide text-primary leading-none mb-0.5",children:e.jsx(_,{devId:"491491",guard:{file:"src/pages/watch-live-events.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:2cdbefe6cee40a9272c17f9ff7a3197712c71f006f4b56aad187077c29c54593"},children:r})}),e.jsx("p",{className:"font-semibold text-foreground leading-snug line-clamp-2",style:{fontSize:"13px"},children:e.jsx(_,{devId:"7f2b0f",guard:{file:"src/pages/watch-live-events.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:940358fa95ea1497f9b63f15c13b830cddaffcfff65328ed4d4d4e8e024ac21d"},children:t.title})}),e.jsxs("div",{className:"flex items-center gap-2 text-muted-foreground",style:{fontSize:"12px"},children:[e.jsx(ys,{size:11}),e.jsx("span",{children:e.jsx(_,{devId:"8c0065",guard:{file:"src/pages/watch-live-events.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:9e142355625fcc35411f344a0cb4b166decfdd22fdc54c5de335bfd0ea75c5b3"},children:A8(t.startAt,t.title)})}),e.jsx("span",{className:"capitalize",children:e.jsx(_,{devId:"8c0066",guard:{file:"src/pages/watch-live-events.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionH
634ash:"sha256:984f6eb135fc8b1f393aeaa1b484e6d247f17cc6b8e401df416ee4284fed9752"},children:O2[t.source]??t.source})})]}),e.jsxs("div",{className:"flex items-center gap-3 text-muted-foreground",style:{fontSize:"12px"},children:[e.jsxs("span",{className:"flex items-center gap-1",children:[e.jsx(xa,{size:11}),e.jsx("span",{children:e.jsx(_,{devId:"4a2369",guard:{file:"src/pages/watch-live-events.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:81f5c583f6262c391413ad0cba73abb650d1b71421cf7d2975d63eae6f1440c7"},children:(t.viewCount??0).toLocaleString()})})]}),e.jsxs("span",{className:"flex items-center gap-1",children:[e.jsx(Gn,{size:11}),e.jsx("span",{children:e.jsx(_,{devId:"8bf84a",guard:{file:"src/pages/watch-live-events.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:1f002b2bc890952dc27ff2e8d39c28eaf340b02407f04cf6c9f4451b865ac99b"},children:(t.likeCount??0).toLocaleString()})})]})]})]})]})}const z8={"@context":"https://schema.org","@type":"WebPage","@id":`${Zu}#webpage`,name:"Watch Live Events – Total Horse Channel",url:Zu,isPartOf:{"@id":`${Ic}/#website`},about:{"@id":`${Ic}/#organization`}};function R8(){const{liveEvents:t,archivedEvents:a,upcomingEvents:r,loading:o}=ed(),{isAuthenticated:l}=Us(),d=T8(5),u=ga(),[m,p]=g.useState(""),x=g.useRef(null),[b,y]=g.useState(1);function v(z){z.preventDefault();const T=m.trim();T&&u(`/search?q=${encodeURIComponent(T)}`)}const w=t,C=t.some(z=>z.videoType==="live"),A=a,S=A.slice((b-1)*kf,b*kf);return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Watch Live Events – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Watch live horse shows, western dressage championships, horse racing, and equine events streamed live on Total Horse Channel."}),e.jsx("link",{rel:"canonical",href:Zu}),e.jsx("meta",{property:"og:title",content:"Watch Live Events – Total Horse Channel"}),e.jsx("meta",{property:"og:description",content:"Watch live horse shows, western dressage championships, horse racing, and equine events streamed live on Total Horse Channel."}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{property:"og:url",content:Zu}),e.jsx("meta",{property:"og:image",content:`${Ic}/assets/images/03d4cc3463b5f931df4f08c7c706f416.png`}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("meta",{name:"twitter:title",content:"Watch Live Events – Total Horse Channel"}),e.jsx("meta",{name:"twitter:description",content:"Watch live horse shows, western dressage championships, horse racing, and equine events streamed live."}),e.jsx("meta",{name:"twitter:image",content:`${Ic}/assets/images/03d4cc3463b5f931df4f08c7c706f416.png`}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify(z8)})]}),e.jsx("main",{children:e.jsx("div",{className:"max-w-[1280px] mx-auto px-4 py-4",children:e.jsxs("div",{className:"flex flex-col lg:flex-row gap-6",children:[e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsxs("div",{className:"flex flex-col sm:flex-row items-stretch sm:items-center gap-2 mb-4",children:[e.jsxs("form",{onSubmit:v,className:"flex flex-1 min-w-0",children:[e.jsxs("div",{className:"relative flex-1 min-w-0",children:[e.jsx("input",{ref:x,type:"text",value:m,onChange:z=>p(z.target.value),placeholder:"Search videos, lives, and archives",className:"w-full border border-border bg-background text-foreground px-3 py-2 text-sm focus:outline-none focus:border-primary pr-8"}),m&&e.jsx("button",{type:"button",onClick:()=>{p(""),requestAnimationFrame(()=>{var z;return(z=x.current)==null?void 0:z.focus()})},className:"absolute right-2 top-1/2 -translate-y-1/2 text-muted-foreground hover:text-foreground transition-colors","aria-label":"Clear search",children:e.jsxs("svg",{width:"14",height:"14",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2.5",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:[e.jsx("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),e.jsx("line",{x1:"6",y1:"6",x2:"18",y2:"18"})]})})]}),e.jsxs("button",{type:"submit",className:"bg-primary text-white px-3 py-2 hover:opacity-90 transition-opacity flex items-center gap-1 text-sm font-semibold shrink-0","aria-label":"Search",children:[e.jsx(pi,{size:14}),e.jsx("span",{className:"hidden sm:inline",children:"Search"})]})]}),l?e.jsxs(O,{to:"/add-video-live",className:"flex items-center justify-center gap-1.5 bg-secondary text-white px-4 py-2 text-sm font-bold uppercase hover:opacity-90 transition-opacity shrink-0",children:[e.jsx(sl,{size:15}),"Add Video / Live"]}):e.jsxs(O,{to:"/login",state:{from:{pathname:"/add-video-live"}},className:"flex items-center justify-center gap-1.5 bg-secondary text-white px-4 py-2 text-sm font-bold uppercase hover:opacity-90 transition-opacity shrink-0",children:[e.jsx(sl,{size:15}),"Add Video / Live"]})]}),e.jsx(O,{to:"/community",className:"flex items-center justify-center w-full text-white font-bold uppercase py-2 text-sm bg-primary hover:bg-primary/90 transition-colors mb-4",children:"SHARE PHOTOS & UPDATES"}),o&&e.jsxs("div",{className:"flex items-center gap-2 text-muted-foreground text-sm mb-4 py-2",children:[e.jsx(Rt,{size:14,className:"animate-spin"})," Loading live events…"]}),!o&&e.jsxs("div",{className:"mb-4",children:[e.jsxs("div",{className:"flex items-center justify-between bg-blue-700 px-3 py-2 mb-3",children:[e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(Ms,{size:13,className:"text-white shrink-0"}),e.jsx("h1",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Upcoming Live Events"})]}),r.length>0&&e.jsx(O,{to:"/live/upcoming",className:"text-white/80 text-xs hover:text-white whitespace-nowrap",children:"View all upcoming →"})]}),r.length===0?e.jsx("p",{className:"text-muted-foreground text-sm mb-2",children:"No upcoming events scheduled at this time."}):e.jsx("div",{className:"flex gap-3 overflow-x-auto pb-2",style:{scrollbarWidth:"thin"},children:r.map(z=>e.jsx("div",{className:"shrink-0 w-[160px]",children:e.jsx(H8,{ev:z})},z.id))})]}),!o&&e.jsxs("div",{className:"mb-4",children:[e.jsxs("div",{className:"bg-primary px-3 py-2 mb-3 flex items-center gap-2",children:[C&&e.jsx("span",{className:"inline-block w-2 h-2 rounded-full bg-white animate-pulse shrink-0"}),e.jsx("h2",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Current Live Events"})]}),t.length===0?e.jsx("p",{className:"text-muted-foreground text-sm mb-2",children:"No current live events at this time. Check back soon!"}):e.jsx("div",{style:{display:"grid",gridTemplateColumns:"repeat(auto-fill, minmax(160px, 1fr))",gap:"12px",marginBottom:"8px"},children:w.map(z=>e.jsx($j,{ev:z,showCategory:!0},z.id))})]}),!o&&e.jsxs("div",{children:[e.jsx("div",{className:"bg-secondary px-3 py-2 mb-3",children:e.jsx("h2",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Live Event Archives"})}),A.length===0?e.jsx("p",{className:"text-muted-foreground text-sm mb-4",children:"No archived events yet."}):e.jsxs(e.Fragment,{children:[e.jsx("div",{style:{display:"grid",gridTemplateColumns:"repeat(auto-fill, minmax(160px, 1fr))",gap:"12px",marginBottom:"8px"},children:S.map(z=>e.jsx($j,{ev:z},z.id))}),e.jsx(E8,{total:A.length,page:b,perPage:kf,onPage:z=>{y(z),window.scrollTo({top:0,behavior:"smooth"})}})]})]})]}),e.jsxs("div",{className:"w-full lg:w-[340px] shrink-0 flex flex-col gap-4",children:[e.jsx(zs,{placement:"sidebar-watch-live"}),e.jsx(O,{to:"/",className:"block w-full text-center text-white font-bold uppercase py-2 text-sm bg-secondary hover:opacity-90 transition-opacity",children:"← Back to Home"}),e.jsx(O,{to:"/mission",className:"block w-full text-center font-bold uppercase py-2 text-sm bg-gray-200 text-gray-800 hover:bg-gray-300 transition-colors",children:"Our Mission"}),d!==null&&d.length>0&&e.jsxs("div",{children:[e.jsx("div",{className:"bg-primary px-3 py-2",children:e.jsx("h2",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Recent News"})}),e.jsx("ul",{className:"border border-border divide-y divide-border",children:d.map(z=>e.jsxs("li",{className:"flex items-start gap-2 px-3 py-2",children:[z.imageUrl&&e.jsx("img",{src:z.imageUrl,alt:"",className:"w-12 h-12 object-cover flex-shrink-0 rounded-sm",loading:"lazy"}),e.jsx(O,{to:`/news/${z.slug}`,className:"text-accent hover:underline leading-snug",style:{fontSize:"13px",lineHeight:"20px"},children:z.title})]},z.id))}),e.jsx("div",{className:"border border-t-0 border-border px-3 py-1",children:e.jsx(O,{to:"/news",className:"text-accent hover:underline text-xs",children:"All news →"})})]}),e.jsx("a",{href:"mailto:[email protected]",className:"block w-full",children:e.jsx("img",{src:"/airo-assets/images/pages/advertise/sidebar-thc-promo",alt:"Total Horse Channel — Where the industry meets the viewers! Advert
634ise with us.",width:500,height:750,className:"w-full h-auto block",loading:"lazy"})})]})]})})})]})}function pl({placement:t="sidebar-wdaa-order-220"}){return e.jsx("div",{className:"flex justify-center w-full",children:e.jsx("aside",{"aria-label":"WDAA Order Videos advertisement",children:e.jsx(Jc,{bannerId:"wdaa-order-video-220x300",placement:t,href:"/#video-orders",target:"_self",rel:"",className:"block",children:e.jsx("div",{style:{width:"220px",height:"300px"},children:e.jsx("img",{src:"/airo-assets/images/sidebar/wdaa-order-video-220x300",alt:"Watch the Show LIVE – Order Videos, Record Your Rides – Only $35 per class – TotalHorseChannel.com",width:220,height:300,className:"w-full h-full object-contain",loading:"lazy"})})})})})}function ji(){return e.jsxs("div",{className:"border border-primary bg-card flex flex-col sm:flex-row items-stretch gap-0 overflow-hidden mb-0",children:[e.jsx("div",{className:"sm:w-1.5 w-full h-1.5 sm:h-auto bg-primary shrink-0"}),e.jsxs("div",{className:"flex-1 px-3 py-2.5 flex flex-col gap-1.5",children:[e.jsxs("div",{className:"flex items-center gap-2 flex-wrap",children:[e.jsx(Xs,{size:13,className:"text-primary shrink-0"}),e.jsx("span",{className:"font-bold text-foreground leading-tight",style:{fontSize:"12px",textTransform:"uppercase",letterSpacing:"0.04em"},children:"Western Dressage | Category Icon Photo Contest"})]}),e.jsxs("p",{className:"text-foreground font-semibold leading-snug",style:{fontSize:"11px"},children:["🏆 Winner: ",e.jsx("span",{className:"text-primary",children:"Alex Maximus"})," (Pete Lichau)"]}),e.jsxs("p",{className:"text-muted-foreground",style:{fontSize:"11px"},children:[e.jsx("span",{className:"font-semibold text-foreground",children:"Submissions:"})," Sep 14–19  · ",e.jsx("span",{className:"font-semibold text-foreground",children:"Voting:"})," Sep 20–25"]}),e.jsx("div",{className:"flex items-center gap-3 flex-wrap mt-0.5",children:e.jsx(O,{to:"/contests",className:"text-accent hover:underline",style:{fontSize:"11px"},children:"View Final Results"})})]})]})}const _8="https://totalhorsechannel.com",Vj=`${_8}/wdaa-video-orders`,Tf=6,Fj=8;function fx(){return{className:""}}function Af(){return{horseName:"",horseColorBreed:"",ridersName:"",riderNumber:"",colorWearing:"",classes:[fx()]}}function L8(){if(typeof window>"u")return null;const t=new URLSearchParams(window.location.search),a=t.get("paypal");return a?{status:a,orderId:t.get("orderId")??"",videos:Number(t.get("videos")??0),amount:Number(t.get("amount")??0),email:t.get("email")??"",msg:t.get("msg")??""}:null}function D8(){const t=pc.pricePerVideo,[a,r]=g.useState({name:"",email:"",phone:"",captcha:""}),[o,l]=g.useState([Af()]),[d,u]=g.useState(""),[m,p]=g.useState(!1),{user:x}=Us(),b=(x==null?void 0:x.isAdmin)===!0,[y]=g.useState(()=>L8());g.useEffect(()=>{y&&typeof window<"u"&&window.history.replaceState({},"","/wdaa-video-orders")},[y]);const v=o.reduce((D,W)=>D+W.classes.length,0),w=v*t;function C(D){r(W=>({...W,[D.target.name]:D.target.value}))}function A(D,W,I){l(k=>k.map((K,L)=>L===D?{...K,[W]:I}:K))}function S(D,W,I){l(k=>k.map((K,L)=>{if(L!==D)return K;const se=K.classes.map((X,le)=>le===W?{className:I}:X);return{...K,classes:se}}))}function z(D){l(W=>W.map((I,k)=>k!==D||I.classes.length>=Tf?I:{...I,classes:[...I.classes,fx()]}))}function T(D,W){l(I=>I.map((k,K)=>{if(K!==D)return k;const L=k.classes.filter((se,X)=>X!==W);return{...k,classes:L.length===0?[fx()]:L}}))}function M(){o.length<Fj&&l(D=>[...D,Af()])}function P(D){o.length!==1&&l(W=>W.filter((I,k)=>k!==D))}async function E(D){if(!a.name.trim()||!a.email.trim()||!a.phone.trim()){u("Please fill in your name, email, and phone number.");return}if(!a.captcha.trim()){u("Please complete the security check.");return}if(v===0){u("Please add at least one class to order.");return}u(""),p(!0);try{const W=await fetch("/api/wdaa-orders/paypal-create",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({totalAmount:D,description:`WDAA Video Order — ${v} video${v!==1?"s":""}${D!==w?" [ADMIN TEST]":""}`})}),I=await W.json();if(!W.ok||!I.paypalOrderId||!I.approveUrl){u(I.error??"Could not connect to PayPal. Please try again."),p(!1);return}await fetch("/api/wdaa-orders/paypal-pending",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({paypalOrderId:I.paypalOrderId,name:a.name,email:a.email,phone:a.phone,horses:o,totalVideos:v,totalAmount:D})}),window.location.href=I.approveUrl}catch(W){console.error("paypal.pay_now.error",W),u("Network error. Please check your connection and try again."),p(!1)}}async function U(D){D.preventDefault(),await E(w)}async function q(D){D.preventDefault(),await E(1)}
634function H(){r({name:"",email:"",phone:"",captcha:""}),l([Af()]),u("")}const J="w-full border border-input px-3 py-2 text-sm focus:outline-none focus:ring-2 focus:ring-primary bg-background",B=(y==null?void 0:y.status)==="success"&&(y.amount??0)>0&&(y.videos??0)>0,Y=(y==null?void 0:y.status)==="cancel",$=(y==null?void 0:y.status)==="error"||(y==null?void 0:y.status)==="success"&&!B;return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"WDAA Video Orders – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Order your WDAA class ride video. Receive your own copy of your ride sent directly to your email as a downloadable link. $35 per video."}),e.jsx("link",{rel:"canonical",href:Vj}),e.jsx("meta",{property:"og:title",content:"WDAA Video Orders – Total Horse Channel"}),e.jsx("meta",{property:"og:description",content:"Order your WDAA class ride video for $35. Delivered to your email as a downloadable link."}),e.jsx("meta",{property:"og:url",content:Vj}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"})]}),e.jsx("main",{className:"bg-background min-h-screen",children:e.jsx("div",{className:"max-w-[1100px] mx-auto px-4 py-6",children:e.jsxs("div",{className:"flex flex-col lg:flex-row gap-6 items-start",children:[e.jsxs("div",{className:"flex-1 min-w-0 
634w-full",children:[e.jsx("div",{className:"bg-secondary px-4 py-2 mb-4",children:e.jsx("h1",{className:"text-white font-bold uppercase text-lg tracking-wide",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"1eb931",guard:{file:"src/pages/wdaa-video-orders.tsx",tagName:"h1",sourceKind:"content-key",contentKey:"wdaa_video_orders.pageTitle",contentKeyTemplate:null,expressionHash:null},children:pc.pageTitle})})}),B&&e.jsxs("div",{className:"border border-green-600 bg-green-50 text-green-900 p-6 mb-4",children:[e.jsx("p",{className:"text-xl font-bold mb-2",children:"Payment received — thank you!"}),e.jsxs("p",{className:"mb-1",children:["Your order of ",e.jsxs("strong",{children:[y.videos," video",y.videos!==1?"s":""]})," ($",y.amount,".00) is confirmed."]}),y.email&&e.jsxs("p",{className:"mb-1",children:["A confirmation has been sent to ",e.jsx("strong",{children:y.email}),"."]}),e.jsxs("p",{className:"text-sm text-green-800 mb-4",children:["Your videos will be delivered as a downloadable link after the show. Questions? Email ",e.jsx("a",{href:"mailto:[email protected]",className:"underline",children:"[email protected]"}),"."]}),e.jsx("button",{onClick:H,className:"bg-primary text-white font-bold px-6 py-2 hover:opacity-90 transition-opacity text-sm",children:"Place Another Order"})]}),Y&&e.jsx("div",{className:"border border-yellow-500 bg-yellow-50 text-yellow-900 p-4 mb-4 text-sm",children:"Payment was cancelled. Your order was not charged. You can try again below."}),$&&e.jsxs("div",{className:"border border-destructive bg-red-50 text-red-900 p-4 mb-4 text-sm",children:["There was a problem processing your payment. Please try again or email ",e.jsx("a",{href:"mailto:[email protected]",className:"underline",children:"[email protected]"}),"."]}),!B&&e.jsxs("div",{className:"border border-border bg-card p-6",children:[e.jsx("h2",{className:"text-base font-bold text-foreground mb-1",children:"Order your Class Video!"}),e.jsx("p",{className:"text-muted-foreground text-sm mb-1",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"039f2c",guard:{file:"src/pages/wdaa-video-orders.tsx",tagName:"p",sourceKind:"content-key",contentKey:"wdaa_video_orders.intro",contentKeyTemplate:null,expressionHash:null},children:pc.intro})}),e.jsx("p",{className:"text-muted-foreground text-xs mb-4",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"039f2d",guard:{file:"src/pages/wdaa-video-orders.tsx",tagName:"p",sourceKind:"content-key",contentKey:"wdaa_video_orders.note",contentKeyTemplate:null,expressionHash:null},children:pc.note})}),e.jsxs("div",{className:"border border-border mb-4 text-sm",children:[e.jsxs("div",{className:"flex justify-between px-3 py-1.5 border-b border-border bg-muted",children:[e.jsx("span",{className:"font-semibold text-xs uppercase tracking-wide",children:"Item"}),e.jsx("span",{className:"font-semibold text-xs uppercase tracking-wide",children:"Price"})]}),e.jsxs("div",{className:"flex justify-between px-3 py-1.5 border-b border-border",children:[e.jsxs("span",{children:["(",v,") Order Video",v!==1?"s":""]}),e.jsxs("span",{children:["$",w,".00"]})]}),e.jsxs("div",{className:"flex justify-between px-3 py-1.5 font-bold",children:[e.jsx("span",{children:"Total"}),e.jsxs("span",{children:["$",w,".00"]})]})]}),e.jsxs("form",{onSubmit:U,className:"space-y-4",children:[e.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-3 gap-3",children:[e.jsxs("div",{children:[e.jsxs("label",{className:"block text-xs font-semibold mb-1",children:["Name ",e.jsx("span",{className:"text-primary",children:"*"})]}),e.jsx("input",{name:"name",value:a.name,onChange:C,required:!0,className:J,placeholder:"Your full name"})]}),e.jsxs("div",{children:[e.jsxs("label",{className:"block text-xs font-semibold mb-1",children:["Email ",e.jsx("span",{className:"text-primary",children:"*"})]}),e.jsx("input",{name:"email",type:"email",value:a.email,onChange:C,required:!0,className:J,placeholder:"[email protected]"})]}),e.jsxs("div",{children:[e.jsxs("label",{className:"block text-xs font-semibold mb-1",children:["Phone ",e.jsx("span",{className:"text-primary",children:"*"})]}
634),e.jsx("input",{name:"phone",type:"tel",value:a.phone,onChange:C,required:!0,className:J,placeholder:"(555) 000-0000"})]})]}),e.jsxs("div",{className:"space-y-4",children:[o.map((D,W)=>e.jsxs("div",{className:"border border-border",children:[e.jsxs("div",{className:"flex items-center justify-between bg-muted px-3 py-1.5 border-b border-border",children:[e.jsxs("span",{className:"font-bold text-xs uppercase tracking-wide text-foreground",children:["Horse ",W+1]}),o.length>1&&e.jsx("button",{type:"button",onClick:()=>P(W),className:"text-xs text-primary hover:underline",children:"Remove"})]}),e.jsxs("div",{className:"p-3 space-y-3",children:[e.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-3 gap-3",children:[e.jsxs("div",{children:[e.jsx("label",{className:"block text-xs font-semibold mb-1",children:"Horse's Name"}),e.jsx("input",{value:D.horseName,onChange:I=>A(W,"horseName",I.target.value),className:J})]}),e.jsxs("div",{children:[e.jsx("label",{className:"block text-xs font-semibold mb-1",children:"Horse Color/Breed"}),e.jsx("input",{value:D.horseColorBreed,onChange:I=>A(W,"horseColorBreed",I.target.value),className:J})]}),e.jsxs("div",{children:[e.jsx("label",{className:"block text-xs font-semibold mb-1",children:"Color Rider was Wearing"}),e.jsx("input",{value:D.colorWearing,onChange:I=>A(W,"colorWearing",I.target.value),className:J})]}),e.jsxs("div",{children:[e.jsx("label",{className:"block text-xs font-semibold mb-1",children:"Rider's Name"}),e.jsx("input",{value:D.ridersName,onChange:I=>A(W,"ridersName",I.target.value),className:J})]}),e.jsxs("div",{children:[e.jsx("label",{className:"block text-xs font-semibold mb-1",children:"Rider's Number"}),e.jsx("input",{value:D.riderNumber,onChange:I=>A(W,"riderNumber",I.target.value),className:J})]})]}),e.jsxs("div",{children:[e.jsxs("p",{className:"text-xs font-semibold mb-1.5 text-muted-foreground uppercase tracking-wide",children:["Classes — up to ",Tf," per horse (",D.classes.length," added)"]}),e.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-2",children:D.classes.map((I,k)=>e.jsxs("div",{className:"flex gap-2 items-center",children:[e.jsxs("span",{className:"text-xs text-muted-foreground w-14 shrink-0",children:["Class ",k+1]}),e.jsx("input",{value:I.className,onChange:K=>S(W,k,K.target.value),placeholder:"e.g. WD-101",className:"flex-1 border border-input px-2 py-1.5 text-xs focus:outline-none focus:ring-2 focus:ring-primary bg-background"}),D.classes.length>1&&e.jsx("button",{type:"button",onClick:()=>T(W,k),className:"text-primary hover:text-primary/70 text-lg leading-none px-1","aria-label":"Remove class",children:"×"})]},k))}),D.classes.length<Tf&&e.jsx("button",{type:"button",onClick:()=>z(W),className:"mt-2 text-xs text-accent hover:underline font-semibold",children:"+ Add Another Class"})]})]})]},W)),o.length<Fj&&e.jsx("button",{type:"button",onClick:M,className:"w-full border-2 border-dashed border-border py-3 text-sm font-bold text-muted-foreground hover:border-primary hover:text-primary transition-colors uppercase tracking-wide",children:"+ Add Another Horse"})]}),e.jsxs("div",{children:[e.jsxs("label",{className:"block text-xs font-semibold mb-1",children:["Security Check ",e.jsx("span",{className:"text-primary",children:"*"})]}),e.jsx("p",{className:"text-xs text-muted-foreground mb-1",children:"For security verification, please enter any random two digit number. For example: 35"}),e.jsx("input",{name:"captcha",value:a.captcha,onChange:C,required:!0,maxLength:2,className:"w-24 border border-input px-3 py-1.5 text-sm focus:outline-none focus:ring-2 focus:ring-primary bg-background",placeholder:"e.g. 35"})]}),d&&e.jsx("p",{className:"text-primary text-sm font-semibold",children:e.jsx(_,{devId:"64fdb1",guard:{file:"src/pages/wdaa-video-orders.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:ca00fccfb408989eddc401062c4d1219a6aceb6b9b55412357f1790862e8f178"},children:d})}),e.jsxs("div",{className:"flex flex-wrap items-center gap-3",children:[e.jsx("button",{type:"submit",disabled:m,className:"bg-primary text-white font-bold uppercase px-8 py-3 hover:opacity-90 transition-opacity text-sm tracking-wide disabled:opacity-60 disabled:cursor-not-allowed",children:e.jsx(_,{devId:"7a6774",guard:{file:"src/pages/wdaa-video-orders.tsx",tagName:"button",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionH
634ash:"sha256:d237e7f990503d4b226878fac7c444eb231dcf2ea0ddf5ae13f6f9c06549fecf"},children:m?"Opening PayPal…":`Pay Now — $${w}.00`})}),b&&e.jsx("button",{type:"button",onClick:q,disabled:m,title:"Admin only — charges $1.00 via PayPal to verify the full checkout flow",className:"border border-secondary text-secondary font-semibold px-4 py-3 text-xs hover:bg-secondary hover:text-white transition-colors disabled:opacity-50 disabled:cursor-not-allowed",children:"$1 Test Order"}),m&&e.jsx("p",{className:"text-xs text-muted-foreground w-full",children:"Connecting to PayPal, please wait…"})]})]})]})]}),e.jsxs("div",{className:"w-full lg:w-[220px] lg:shrink-0 flex flex-col gap-4",children:[e.jsx(vi,{placement:"sidebar-wdaa-video-orders"}),e.jsx(pl,{placement:"sidebar-wdaa-video-orders-220"}),e.jsxs("a",{href:"https://www.showsecretary.com/Razor/Calendar/ClassList/1183?SClassDate=9%2F15%2F2026",target:"_blank",rel:"noopener noreferrer",className:"flex items-center justify-center gap-2 w-full text-center bg-secondary text-white font-semibold py-2.5 text-sm border border-border hover:bg-secondary/80 transition-colors",children:["Class Schedule",e.jsx(dt,{size:13,className:"shrink-0"})]}),e.jsx(ji,{}),e.jsxs("div",{children:[e.jsx("div",{className:"bg-secondary px-3 py-2",children:e.jsx("h2",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Helpful Links"})}),e.jsx("ul",{className:"border border-border divide-y divide-border",children:pc.helpfulLinks.map(D=>e.jsx("li",{children:e.jsx("a",{href:D.href,className:"block px-3 py-2 text-accent hover:underline",style:{whiteSpace:"pre-line",fontSize:"13px",lineHeight:"20px"},children:D.label})},D.id))})]})]})]})})})]})}const Bc="https://totalhorsechannel.com",Ju=`${Bc}/news`,O8={"@context":"https://schema.org","@type":"WebPage","@id":`${Ju}#webpage`,name:"News – Total Horse Channel",url:Ju,isPartOf:{"@id":`${Bc}/#website`},about:{"@id":`${Bc}/#organization`}};function M8(t){if(!t)return"";const a=new Date(t);return isNaN(a.getTime())?"":a.toLocaleDateString("en-US",{year:"numeric",month:"long",day:"numeric"})}function U8(t){return t.replace(/<[^>]+>/g," ").replace(/\s+/g," ").trim()}const Su=15;function P8(){var u,m;const t=sg(),a=((u=t==null?void 0:t.articles)==null?void 0:u.slice(0,Su))??[],r=(((m=t==null?void 0:t.articles)==null?void 0:m.length)??0)>Su,[o]=Bm(),l=ga(),d=Number(o.get("offset")??0);return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"News – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"The latest horse industry news — racing, western dressage, show jumping, equine health, and more from Total Horse Channel."}),e.jsx("link",{rel:"canonical",href:Ju}),e.jsx("meta",{property:"og:title",content:"News – Total Horse Channel"}),e.jsx("meta",{property:"og:description",content:"The latest horse industry news — racing, western dressage, show jumping, equine health, and more from Total Horse Channel."}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{property:"og:url",content:Ju}),e.jsx("meta",{property:"og:image",content:`${Bc}/assets/images/03d4cc3463b5f931df4f08c7c706f416.png`}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("meta",{name:"twitter:title",content:"News – Total Horse Channel"}),e.jsx("meta",{name:"twitter:description",content:"The latest horse industry news — racing, western dressage, show jumping, equine health, and more."}),e.jsx("meta",{name:"twitter:image",content:`${Bc}/assets/images/03d4cc3463b5f931df4f08c7c706f416.png`}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify(O8)})]}),e.jsx("main",{children:e.jsx("div",{className:"max-w-[1280px] mx-auto px-4 py-4",children:e.jsxs("div",{className:"flex flex-col lg:flex-row gap-6",children:[e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsxs("div",{className:"bg-primary px-3 py-2 mb-4 flex items-center justify-between gap-3",children:[e.jsx("h1",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"News"}),e.jsxs(O,{to:"/news/submit",className:"flex items-center gap-1.5 bg-white text-primary font-bold text-xs uppercase px-3 py-1.5 hover:bg-white/90 transition-opacity shrink-0",children:[e.jsx(sl,{size:13}),"Submit Article"]})]}),a.length===0&&e.jsxs("div",{className:"text-sm text-muted-foreground py-6 text-center border border-border bg-card",children:["No articles published yet."," ",e.jsx(O,{to:"/news/submit",className:"text-accent hover:underline",children:"Submit the first one →"})]}),a.length>0&&e.jsx("div",{className:"flex flex-col divide-y divide-border border border-border mb-5",children:a.map(p=>e.jsxs(O,{to:`/news/${p.slug}`,className:"flex gap-3 px-4 py-4 bg-card hover:bg-muted transition-colors",children:[p.imageUrl?e.jsx("div",{className:"shrink-0 w-[120px] h-[80px] overflow-hidden bg-muted",children:e.jsx("img",{src:p.imageUrl,alt:p.title,width:120,height:80,className:"w-full h-full object-cover",loading:"lazy"})}):null,e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("h2",{className:"font-bold text-accent hover:underline mb-1",style:{fontSize:"16px",lineHeight:"22px"},children:p.title}),e.jsxs("div",{className:"flex items-center gap-1.5 text-muted-foreground mb-1",style:{fontSize:"12px"},children:[e.jsx(ys,{size:11}),e.jsx("span",{children:M8(p.publishedAt??p.createdAt)}),p.authorName&&e.jsxs(e.Fragment,{children:[e.jsx("span",{children:"·"}),e.jsx("span",{children:p.authorName})]})]}),e.jsx("p",{className:"text-foreground line-clamp-2",style:{fontSize:"14px",lineHeight:"21px"},children:U8(p.body).slice(0,200)})]})]}
634,p.id))}),(a.length>0||d>0)&&e.jsxs("div",{className:"flex items-center gap-2 text-sm mb-6",children:[d>0&&e.jsx("button",{onClick:()=>l(`/news?offset=${Math.max(0,d-Su)}`),className:"px-3 py-1 border border-border hover:bg-muted transition-colors",children:"← Prev"}),r&&e.jsx("button",{onClick:()=>l(`/news?offset=${d+Su}`),className:"px-3 py-1 border border-border hover:bg-muted transition-colors",children:"Next →"})]})]}),e.jsxs("div",{className:"w-full lg:w-[340px] shrink-0 flex flex-col gap-4",children:[e.jsxs(O,{to:"/news/submit",className:"flex items-center justify-center gap-2 w-full text-center text-white font-bold uppercase py-3 text-sm bg-secondary hover:opacity-90 transition-opacity",children:[e.jsx(sl,{size:15}),"Submit an Article"]}),e.jsx(zs,{placement:"sidebar-news"}),e.jsx(O,{to:"/",className:"block w-full text-center text-white font-bold uppercase py-2 text-sm bg-secondary hover:opacity-90 transition-opacity",children:"← Back to Home"}),e.jsx(O,{to:"/mission",className:"block w-full text-center font-bold uppercase py-2 text-sm bg-gray-200 text-gray-800 hover:bg-gray-300 transition-colors",children:"Our Mission"}),e.jsx(O,{to:"/watch-live-events",className:"block w-full text-center text-white font-bold uppercase py-3 text-base bg-primary hover:bg-primary/90 transition-colors",children:"WATCH LIVE EVENTS"}),e.jsx(Cr,{placement:"sidebar-news-220"})]})]})})})]})}function sd(){return e.jsxs("div",{className:"flex flex-wrap gap-2 mb-4",children:[e.jsxs(O,{to:"/u/WDAA",className:"flex items-center gap-2 bg-secondary text-white text-sm font-semibold px-4 py-2 hover:bg-accent transition-colors",children:[e.jsx(Dc,{size:15,className:"shrink-0"}),"Follow WDAA"]}),e.jsxs(O,{to:"/u/VLeMaster",className:"flex items-center gap-2 bg-secondary text-white text-sm font-semibold px-4 py-2 hover:bg-accent transition-colors",children:[e.jsx(zc,{size:15,className:"shrink-0"}),"Follow Official Photographer"]}),e.jsxs("a",{href:"https://www.showsecretary.com/Razor/Calendar/Results/1183",target:"_blank",rel:"noopener noreferrer",className:"flex items-center gap-2 bg-primary text-white text-sm font-semibold px-4 py-2 hover:bg-secondary transition-colors",children:["Results",e.jsx(dt,{size:14,className:"shrink-0"})]})]})}const $c="https://totalhorsechannel.com",Xu=`${$c}/home/wdaa`,K8={"@context":"https://schema.org","@type":"WebPage","@id":`${Xu}#webpage`,name:"2026 WDAA Western Dressage World Championship Show – Total Horse Channel",url:Xu,isPartOf:{"@id":`${$c}/#website`},about:{"@id":`${$c}/#organization`}};function I8(){const[t,a]=g.useState(0);return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"2026 WDAA Western Dressage World Championship Show – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Watch the 2026 WDAA Western Dressage World Championship Show live from all four rings. September 15–19, 2026 at Lazy E Arena, Guthrie, Oklahoma."}),e.jsx("link",{rel:"canonical",href:Xu}),e.jsx("meta",{property:"og:title",content:"2026 WDAA Western Dressage World Championship Show – Total Horse Channel"}),e.jsx("meta",{property:"og:description",content:"Watch the 2026 WDAA Western Dressage World Championship Show live from all four rings. September 15–19, 2026 at Lazy E Arena, Guthrie, Oklahoma."}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{property:"og:url",content:Xu}),e.jsx("meta",{property:"og:image",content:`${$c}/assets/images/03d4cc3463b5f931df4f08c7c706f416.png`}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("meta",{name:"twitter:title",content:"2026 WDAA Western Dressage World Championship Show – Total Horse Channel"}),e.jsx("meta",{name:"twitter:description",content:"Watch the 2026 WDAA Western Dressage World Championship Show live. September 15–19, 2026 at Lazy E Arena, Guthrie, Oklahoma."}),e.jsx("meta",{name:"twitter:image",content:`${$c}/assets/images/03d4cc3463b5f931df4f08c7c706f416.png`}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify(K8)})]}),e.jsx("main",{children:e.jsx("div",{className:"max-w-[1280px] mx-auto px-4 py-4",children:e.jsxs("div",{className:"flex flex-col lg:flex-row gap-6",children:[e.jsxs("div",{className:"flex-1 min-w-0 max-w-[780px]",children:[e.jsx("div",{className:"bg-primary px-3 py-2 mb-3",children:e.jsx("h1",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"2026 Western Dressage World Championship Show"})}),e.jsx("div",{className:"w-full bg-black mb-1",style:{aspectRatio:"16/9"},children:e.jsx("iframe",{src:"https://rumble.com/embed/v7disi8/?pub=mqmap",title:"2026 WDAA Western Dressage World Championship Show — Day Five",frameBorder:"0",allow:"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture;
634 web-share",referrerPolicy:"strict-origin-when-cross-origin",allowFullScreen:!0,className:"w-full h-full border-0"})}),e.jsx(Ng,{placement:"wdaa-hub-player-leaderboard"}),e.jsx(sd,{}),e.jsx("p",{className:"my-3 text-foreground text-sm leading-relaxed",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"4820c0",guard:{file:"src/pages/wdaa-hub.tsx",tagName:"p",sourceKind:"content-key",contentKey:"wdaa_hub.intro",contentKeyTemplate:null,expressionHash:null},children:Nr.intro})}),e.jsx("div",{className:"bg-secondary px-3 py-2 mb-0",children:e.jsxs("h2",{className:"text-white font-bold uppercase text-sm tracking-wide flex items-center gap-2",children:[e.jsx(Ft,{size:14,className:"text-red-400 animate-pulse"}),"Watch Live — Select a Ring"]})}),e.jsx("div",{className:"flex flex-wrap gap-0 mb-5 border border-t-0 border-border",children:Nr.rings.map((r,o)=>e.jsxs("a",{href:r.embedUrl,target:"_blank",rel:"noopener noreferrer",className:["flex items-center gap-1.5 px-4 py-2.5 text-sm font-bold uppercase transition-colors",t===o?"bg-primary text-white":"bg-muted text-foreground hover:bg-secondary hover:text-white"].join(" "),onMouseEnter:()=>a(o),children:[r.isLive&&e.jsx(Ft,{size:11,className:"animate-pulse text-red-500 shrink-0"}),r.label]},r.id))}),e.jsxs("div",{className:"flex flex-col sm:flex-row gap-5 mb-5 items-start",children:[e.jsx("a",{href:"https://www.wdaaworldshow.org/",target:"_blank",rel:"noopener noreferrer",className:"shrink-0 w-full sm:w-64 block",children:e.jsx("img",{src:"/airo-assets/images/pages/wdaa-hub/event-poster",alt:"2026 WDAA Western Dressage World Championship Show — September 15–19 at Lazy E Arena, Guthrie Oklahoma",width:640,height:853,className:"w-full h-auto object-contain shadow-md",loading:"lazy"})}),e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("h2",{className:"text-foreground font-bold text-xl leading-tight mb-2",children:"WDAA Western Dressage World Championship Show"}),e.jsxs("div",{className:"space-y-2 text-sm text-foreground mb-4",children:[e.jsxs("div",{className:"flex items-start gap-2",children:[e.jsx("span",{className:"font-bold text-primary shrink-0 w-20",children:"Dates:"}),e.jsxs("span",{children:["September 15",e.jsx("sup",{children:"th"})," – 19",e.jsx("sup",{children:"th"}),", 2026"]})]}),e.jsxs("div",{className:"flex items-start gap-2",children:[e.jsx("span",{className:"font-bold text-primary shrink-0 w-20",children:"Location:"}),e.jsxs("span",{children:["Lazy E Arena",e.jsx("br",{}),"Guthrie, Oklahoma"]})]}),e.jsxs("div",{className:"flex items-start gap-2",children:[e.jsx("span",{className:"font-bold text-primary shrink-0 w-20",children:"Website:"}),e.jsx("a",{href:"https://www.wdaaworldshow.org/",target:"_blank",rel:"noopener noreferrer",className:"text-accent hover:underline break-all",children:"WDAAWorldShow.org"})]}),e.jsxs("div",{className:"flex items-start gap-2",children:[e.jsx("span",{className:"font-bold text-primary shrink-0 w-20",children:"Schedule:"}),e.jsx("a",{href:"https://www.showsecretary.com/Razor/Calendar/ClassList/1183?SClassDate=9%2F15%2F2026",target:"_blank",rel:"noopener noreferrer",className:"text-accent hover:underline break-all",children:"Class Schedule"})]})]}),e.jsxs("div",{className:"flex flex-col gap-2",children:[e.jsxs(O,{to:"/wdaa-video-orders",className:"flex items-center gap-3 bg-primary text-white px-4 py-3 hover:bg-secondary transition-colors group",children:[e.jsx(ml,{size:22,className:"shrink-0"}),e.jsxs("div",{children:[e.jsx("div",{className:"font-bold text-sm uppercase leading-tight",children:"Order Your Videos"}),e.jsx("div",{className:"text-xs text-white/80",children:"$35/video — download link via email"})]}),e.jsx(Lt,{size:16,className:"ml-auto group-hover:translate-x-1 transition-transform"})]}),e.jsxs(O,{to:"/watch-live-events",className:"flex items-center gap-3 bg-secondary text-white px-4 py-3 hover:bg-accent transition-colors group border border-border",children:[e.jsx(Ft,{size:22,className:"shrink-0 text-red-400"}),e.jsxs("div",{children:[e.jsx("div",{className:"font-bold text-sm uppercase leading-tight",children:"All Live Events"}),e.jsx("div",{className:"text-xs text-white/70",children:"Racing, shows, and more"})]}),e.jsx(Lt,{size:16,className:"ml-auto group-hover:translate-x-1 transition-transform"})]})]})]})]}),e.jsxs("div",{className:"border border-border mb-5",children:[e.jsx("div",{className:"bg-secondary px-3 py-2",children:e.jsx("h2",{className:"text-white font-bold uppercase text-sm tracking-wide",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"62c517",guard:{file:"src/pages/wdaa-hub.tsx",tagName:"h2",sourceKind:"content-key",contentKey:"wdaa_sponsorships.currentSponsorsHeading",contentKeyTemplate:null,expressionH
634ash:null},children:gs.currentSponsorsHeading})})}),e.jsxs("div",{className:"p-4",children:[e.jsx("div",{className:"grid grid-cols-2 sm:grid-cols-3 gap-3",children:gs.sponsors.map(r=>e.jsxs("a",{href:r.href,target:r.href.startsWith("http")?"_blank":void 0,rel:r.href.startsWith("http")?"noopener noreferrer":void 0,className:"flex flex-col items-center justify-center p-2 border border-border bg-white hover:border-primary hover:shadow-sm transition-all group",children:[e.jsx("img",{src:r.logoSrc,alt:r.name,width:160,height:80,className:"w-full h-16 object-contain",loading:"lazy"}),e.jsx("span",{className:"text-xs text-muted-foreground text-center mt-1.5 group-hover:text-primary transition-colors leading-tight",style:{whiteSpace:"pre-line"},children:r.name})]},r.id))}),e.jsx("div",{className:"mt-4 pt-3 border-t border-border text-center",children:e.jsxs("a",{href:"/wdaa-sponsorships",className:"inline-flex items-center gap-1.5 text-sm font-semibold text-accent hover:text-primary transition-colors",children:["View Sponsorship Opportunities",e.jsx(Lt,{size:14})]})})]})]}),e.jsx(ji,{}),e.jsxs("div",{className:"border border-border",children:[e.jsx("div",{className:"bg-secondary px-3 py-2",children:e.jsx("h2",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Helpful Links"})}),e.jsx("ul",{className:"divide-y divide-border",children:Nr.helpfulLinks.map(r=>e.jsx("li",{children:e.jsxs("a",{href:r.href,target:r.href.startsWith("http")?"_blank":void 0,rel:r.href.startsWith("http")?"noopener noreferrer":void 0,className:"flex items-center justify-between px-3 py-2.5 text-sm text-accent hover:bg-muted transition-colors group",children:[e.jsx("span",{style:{whiteSpace:"pre-line"},children:r.label}),r.href.startsWith("http")?e.jsx(dt,{size:13,className:"text-muted-foreground group-hover:text-accent transition-colors shrink-0"}):e.jsx(Lt,{size:14,className:"text-muted-foreground group-hover:text-accent transition-colors shrink-0"})]})},r.id))})]}),e.jsxs("p",{className:"mt-4 text-sm text-muted-foreground",children:["Share photos and updates in"," ",e.jsx(O,{to:"/community",className:"text-primary hover:underline font-medium",children:"Community"}),"."]})]}),e.jsxs("div",{className:"w-full lg:w-[340px] shrink-0 flex flex-col gap-4",children:[e.jsx(vi,{placement:"sidebar-wdaa-hub"}),e.jsx(O,{to:"/",className:"block w-full text-center text-foreground font-semibold py-2 text-sm border border-border hover:bg-muted transition-colors",children:"← Back to Home"}),e.jsx(O,{to:"/mission",className:"block w-full text-center font-bold uppercase py-2 text-sm bg-gray-200 text-gray-800 hover:bg-gray-300 transition-colors",children:"Our Mission"}),e.jsxs("a",{href:"https://www.showsecretary.com/Razor/Calendar/ClassList/1183?SClassDate=9%2F15%2F2026",target:"_blank",rel:"noopener noreferrer",className:"flex items-center justify-center gap-2 w-full text-center bg-secondary text-white font-semibold py-2.5 text-sm border border-border hover:bg-accent transition-colors",children:["Class Schedule",e.jsx(dt,{size:13,className:"shrink-0"})]}),e.jsx(O,{to:"/community",className:"flex items-center justify-center w-full text-center bg-primary text-white font-bold py-2.5 text-sm hover:bg-secondary transition-colors",children:"SHARE PHOTOS & UPDATES"})]})]})})})]})}const B8=[{name:"WDAA Western Dressage Association",img:"/airo-assets/images/sponsors/wdaa",href:"https://www.wdaa.us/"},{name:"Purina Animal Nutrition",img:"/airo-assets/images/sponsors/purina",href:"https://www.purina.com/"},{name:"Absorbine",img:"/airo-assets/images/sponsors/absorbine",href:"https://www.absorbine.com/"},{name:"Circa Resort & Casino",img:"/airo-assets/images/sponsors/circa-resort-casino",href:"https://circalasvegas.com/"},{name:"Killian Insurance Agency",img:"/airo-assets/images/sponsors/killian-insurance",href:"https://www.killianinsurance.com/"},{name:"State Line Tack",img:"/airo-assets/images/sponsors/state-line-tack",href:"https://www.statelinetack.com/"},{name:"Dressage Illustrated",img:"/airo-assets/images/sponsors/dressage-illustrated",href:"https://dressageillustrated.com/"}
634,{name:"Skyline Gold & Silversmiths",img:"/airo-assets/images/sponsors/skyline-gold-silversmiths",href:"https://www.skylinegoldsilversmiths.com/"},{name:"Tioga Territory Ltd",img:"/airo-assets/images/sponsors/tioga-territory",href:"https://www.tiogaterritory.com/"},{name:"100X Equine",img:"/airo-assets/images/sponsors/100x-equine",href:"https://www.100xequine.com/"},{name:"Spotlight Horse Shows",img:"/airo-assets/images/sponsors/spotlight-horse-shows",href:"https://www.spotlighthorseshows.com/"},{name:"US Equestrian",img:"/airo-assets/images/sponsors/us-equestrian",href:"https://www.usef.org/"}];function Gm(){return e.jsxs("div",{className:"border border-border mb-5",children:[e.jsx("div",{className:"bg-secondary px-3 py-2",children:e.jsx("h2",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Thank You to Our 2026 Sponsors"})}),e.jsx("div",{className:"p-3 bg-card grid grid-cols-2 sm:grid-cols-3 gap-3",children:B8.map(t=>e.jsxs("a",{href:t.href,target:"_blank",rel:"noopener noreferrer",className:"flex flex-col items-center justify-between border border-border bg-white hover:border-primary transition-colors p-3 gap-2",children:[e.jsx("div",{className:"flex items-center justify-center w-full h-[80px]",children:e.jsx("img",{src:t.img,alt:t.name,className:"max-h-[72px] max-w-full w-auto h-auto object-contain",loading:"lazy"})}),e.jsx("span",{className:"text-center text-foreground text-[11px] leading-tight",children:t.name})]},t.name))})]})}const Qu="https://totalhorsechannel.com",em=`${Qu}/video/wdaa-world-championship-show-live/`,$8=[{label:"Ring 1",href:"/video/wdaa-world-championship-show-live"},{label:"Ring 2",href:"/video/wdaa-world-championship-show-live-ring-2"},{label:"Ring 3",href:"/video/wdaa-world-championship-show-live-ring-3"},{label:"Ring 4",href:"/video/wdaa-world-championship-show-live-ring-4"}],V8={"@context":"https://schema.org","@type":"VideoObject","@id":`${em}#video`,name:li.pageTitle,description:li.description,url:em,isPartOf:{"@id":`${Qu}/#website`}},F8=new Date("2026-09-15T00:00:00-04:00");function W8(){const t=new Date>=F8;return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsxs("title",{children:[li.pageTitle," – Total Horse Channel"]}),e.jsx("meta",{name:"description",content:li.description}),e.jsx("link",{rel:"canonical",href:em}),e.jsx("meta",{property:"og:title",content:`${li.pageTitle} – Total Horse Channel`}),e.jsx("meta",{property:"og:description",content:li.description}),e.jsx("meta",{property:"og:type",content:"video.other"}),e.jsx("meta",{property:"og:url",content:em}),e.jsx("meta",{property:"og:image",content:`${Qu}/airo-assets/images/videos/wdaa-live-ring1`}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("meta",{name:"twitter:title",content:`${li.pageTitle} – Total Horse Channel`}),e.jsx("meta",{name:"twitter:description",content:li.description}),e.jsx("meta",{name:"twitter:image",content:`${Qu}/airo-assets/images/videos/wdaa-live-ring1`}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify(V8)})]}),e.jsx("main",{children:e.jsx("div",{className:"max-w-[1280px] mx-auto px-4 py-4",children:e.jsxs("div",{className:"flex flex-col lg:flex-row gap-6",children:[e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("div",{className:"bg-primary px-3 py-2 mb-0",children:e.jsxs("h1",{className:"text-white font-bold uppercase text-sm tracking-wide flex items-center gap-2",children:[e.jsx(Ft,{size:13,className:"animate-pulse text-red-300 shrink-0"}),"2026 Western Dressage World Championship Show — Ring 1 Live"]})}),e.jsx("div",{className:"flex flex-wrap gap-0 mb-0 border border-t-0 border-b-0 border-border",children:$8.map(a=>{const r=a.label==="Ring 1";return e.jsxs(O,{to:a.href,className:["flex items-center gap-1.5 px-5 py-2.5 text-sm font-bold uppercase transition-colors",r?"bg-secondary text-white":"bg-muted text-foreground hover:bg-primary hover:text-white"].join(" "),children:[e.jsx(Ft,{size:11,className:r?"animate-pulse text-red-400 shrink-0":"text-muted-foreground shrink-0"}),a.label]},a.label)})}),e.jsx("div",{className:"w-full bg-black relative",style:{aspectRatio:"16/9"},children:e.jsx("iframe",{src:"https://rumble.com/embed/v7disi8/?pub=mqmap",title:"YouTube video player",frameBorder:"0",allow:"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture;
634 web-share",referrerPolicy:"strict-origin-when-cross-origin",allowFullScreen:!0,className:"absolute inset-0 w-full h-full border-0"})}),e.jsx(Ng,{placement:"ring1-player-leaderboard"}),e.jsxs("div",{className:"flex items-center gap-2 px-3 py-2 bg-secondary text-white text-sm mb-4",children:[e.jsx(Ft,{size:13,className:t?"text-red-400 animate-pulse shrink-0":"text-gray-400 shrink-0"}),t?e.jsxs(e.Fragment,{children:[e.jsx("span",{className:"font-semibold",children:"Now Watching:"}),e.jsx("span",{children:"2026 WDAA Western Dressage World Championship Show — Day Five"}),e.jsx("span",{className:"ml-auto bg-primary text-white text-xs font-bold px-2 py-0.5 uppercase tracking-wide",children:"Live"})]}):e.jsxs(e.Fragment,{children:[e.jsx("span",{className:"font-semibold",children:"Coming Soon:"}),e.jsx("span",{children:"2026 WDAA Western Dressage World Championship Show — Day Five"}),e.jsx("span",{className:"ml-auto text-gray-300 text-xs font-semibold whitespace-nowrap",children:"Show starts September 15th"})]})]}),e.jsx(sd,{}),e.jsxs("div",{className:"flex flex-col sm:flex-row gap-5 mb-5 items-start",children:[e.jsx("a",{href:"https://www.wdaaworldshow.org/",target:"_blank",rel:"noopener noreferrer",className:"shrink-0 w-full sm:w-56 block",children:e.jsx("img",{src:"/airo-assets/images/pages/wdaa-hub/event-poster",alt:"2026 WDAA Western Dressage World Championship Show — September 15–19 at Lazy E Arena, Guthrie Oklahoma",width:640,height:853,className:"w-full h-auto object-contain shadow-md",loading:"lazy"})}),e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("h2",{className:"text-foreground font-bold text-xl leading-tight mb-2",children:"WDAA Western Dressage World Championship Show"}),e.jsxs("div",{className:"space-y-2 text-sm text-foreground mb-4",children:[e.jsxs("div",{className:"flex items-start gap-2",children:[e.jsx("span",{className:"font-bold text-primary shrink-0 w-20",children:"Dates:"}),e.jsxs("span",{children:["September 15",e.jsx("sup",{children:"th"})," – 19",e.jsx("sup",{children:"th"}),", 2026"]})]}),e.jsxs("div",{className:"flex items-start gap-2",children:[e.jsx("span",{className:"font-bold text-primary shrink-0 w-20",children:"Location:"}),e.jsxs("span",{children:["Lazy E Arena",e.jsx("br",{}),"Guthrie, Oklahoma"]})]}),e.jsxs("div",{className:"flex items-start gap-2",children:[e.jsx("span",{className:"font-bold text-primary shrink-0 w-20",children:"Website:"}),e.jsx("a",{href:"https://www.wdaaworldshow.org/",target:"_blank",rel:"noopener noreferrer",className:"text-accent hover:underline break-all",children:"WDAAWorldShow.org"})]}),e.jsxs("div",{className:"flex items-start gap-2",children:[e.jsx("span",{className:"font-bold text-primary shrink-0 w-20",children:"Past Shows:"}),e.jsx("a",{href:"/wdaa-replays",className:"text-accent hover:underline break-all",children:"WDAA Past World Shows"})]}),e.jsxs("div",{className:"flex items-start gap-2",children:[e.jsx("span",{className:"font-bold text-primary shrink-0 w-20",children:"On Rumble:"}),e.jsx("a",{href:"https://rumble.com/c/TotalHorseChannel",target:"_blank",rel:"noopener noreferrer",className:"text-accent hover:underline break-all",children:"Watch on Rumble"})]}),e.jsxs("div",{className:"flex items-start gap-2",children:[e.jsx("span",{className:"font-bold text-primary shrink-0 w-20",children:"Schedule:"}),e.jsx("a",{href:"https://www.showsecretary.com/Razor/Calendar/ClassList/1183?SClassDate=9%2F15%2F2026",target:"_blank",rel:"noopener noreferrer",className:"text-accent hover:underline break-all",children:"Class Schedule"})]})]}),e.jsxs("div",{className:"flex flex-col gap-2",children:[e.jsxs(O,{to:"/wdaa-video-orders",className:"flex items-center gap-3 bg-primary text-white px-4 py-3 hover:bg-secondary transition-colors group",children:[e.jsx(ml,{size:20,className:"shrink-0"}),e.jsxs("div",{children:[e.jsx("div",{className:"font-bold text-sm uppercase leading-tight",children:"Order Your Videos"}),e.jsx("div",{className:"text-xs text-white/80",children:"$35/video — download link via email"})]}),e.jsx(Lt,{size:16,className:"ml-auto group-hover:translate-x-1 transition-transform"})]}),e.jsxs(O,{to:"/home/wdaa",className:"flex items-center gap-3 bg-secondary text-white px-4 py-3 hover:bg-accent transition-colors group border border-border",children:[e.jsx(Ft,{size:20,className:"shrink-0 text-red-400"}),e.jsxs("div",{children:[e.jsx("div",{className:"font-bold text-sm uppercase leading-tight",children:"WDAA Hub"}),e.jsx("div",{className:"text-xs text-white/70",children:"Show info, all rings & replays"})]}),e.jsx(Lt,{size:16,className:"ml-auto group-hover:translate-x-1 transition-transform"})]})]})]})]}),e.jsx(Gm,{}),e.jsx(ji,{}),e.jsxs("div",{className:"border border-border",children:[e.jsx("div",{className:"bg-secondary px-3 py-2",children:e.jsx("h2",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Helpful Links"})}),e.jsx("ul",{className:"divide-y divide-border",children:Nr.helpfulLinks.map(a=>e.jsx("li",{children:e.jsxs("a",{href:a.href,target:a.href.startsWith("http")?"_blank":void 0,rel:a.href.startsWith("http")?"noopener noreferrer":void 0,className:"flex items-center justify-between px-3 py-2.5 text-sm text-accent hover:bg-muted transition-colors group",children:[e.jsx("span",{style:{whiteSpace:"pre-line"},children:a.label}),a.href.startsWith("http")?e.jsx(dt,{size:13,className:"text-muted-foreground group-hover:text-accent shrink-0"}):e.jsx(Lt,{size:14,className:"text-muted-foreground group-hover:text-accent shrink-0"})]})},a.id))})]})]}),e.jsxs("div",{className:"w-full lg:w-[340px] shrink-0 flex flex-col gap-4",children:[e.jsx(vi,{placement:"sidebar-wdaa-ring1"}),e.jsx(pl,{placement:"sidebar-wdaa-ring1-220"}),e.jsx(O,{to:"/home/wdaa",className:"block w-full text-center text-foreground font-semibold py-2 text-sm border border-border hover:bg-muted transition-colors",children:"← Back to WDAA Hub"}),e.jsxs("a",{href:"https://www.showsecretary.com/Razor/Calendar/ClassList/1183?SClassDate=9%2F15%2F2026",target:"_blank",rel:"noopener noreferrer",className:"flex items-center justify-center gap-2 w-full text-center bg-secondary text-white font-semibold py-2.5 text-sm border border-border hover:bg-accent transition-colors",children:["Class Schedule",e.jsx(dt,{size:13,className:"shrink-0"})]}),e.jsx(O,{to:"/community",className:"flex items-center justify-center w-full text-center bg-primary text-white font-bold py-2.5 text-sm hover:bg-secondary transition-colors",children:"SHARE PHOTOS & UPDATES"})]})]})})})]})}const tm="https://totalhorsechannel.com",sm=`${tm}/video/wdaa-world-championship-show-live-ring-2/`,q8=[{label:"Ring 1",href:"/video/wdaa-world-championship-show-live"},{label:"Ring 2",href:"/video/wdaa-world-championship-show-live-ring-2"},{label:"Ring 3",href:"/video/wdaa-world-championship-show-live-ring-3"},{label:"Ring 4",href:"/video/wdaa-world-championship-show-live-ring-4"}],Y8={"@context":"https://schema.org","@type":"VideoObject","@id":`${sm}#video`,name:Un.pageTitle,description:Un.description,url:sm,isPartOf:{"@id":`${tm}/#website`}},G8=new Date("2026-09-16T00:00:00-04:00");function Z8(){const t=new Date>=G8;return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsxs("title",{children:[Un.pageTitle," – Total Horse Channel"]}),e.jsx("meta",{name:"description",content:Un.description}),e.jsx("link",{rel:"canonical",href:sm}),e.jsx("meta",{property:"og:title",content:`${Un.pageTitle} – Total Horse Channel`}),e.jsx("meta",{property:"og:description",content:Un.description}),e.jsx("meta",{property:"og:type",content:"video.other"}),e.jsx("meta",{property:"og:url",content:sm}),e.jsx("meta",{property:"og:image",content:`${tm}/airo-assets/images/videos/wdaa-live-ring1`}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("meta",{name:"twitter:title",content:`${Un.pageTitle} – Total Horse Channel`}),e.jsx("meta",{name:"twitter:description",content:Un.description}),e.jsx("meta",{name:"twitter:image",content:`${tm}/airo-assets/images/videos/wdaa-live-ring1`}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify(Y8)})]}),e.jsx("main",{children:e.jsx("div",{className:"max-w-[1280px] mx-auto px-4 py-4",children:e.jsxs("div",{className:"flex flex-col lg:flex-row gap-6",children:[e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("div",{className:"bg-primary px-3 py-2 mb-0",children:e.jsxs("h1",{className:"text-white font-bold uppercase text-sm tracking-wide flex items-center gap-2",children:[e.jsx(Ft,{size:13,className:"animate-pulse text-red-300 shrink-0"}),"2026 Western Dressage World Championship Show — Ring 2 Live"]})}),e.jsx("div",{className:"flex flex-wrap gap-0 mb-0 border border-t-0 border-b-0 border-border",children:q8.map(a=>{const r=a.label==="Ring 2";return e.jsxs(O,{to:a.href,className:["flex items-center gap-1.5 px-5 py-2.5 text-sm font-bold uppercase transition-colors",r?"bg-secondary text-white":"bg-muted text-foreground hover:bg-primary hover:text-white"].join(" "),children:[e.jsx(Ft,{size:11,className:r?"animate-pulse text-red-400 shrink-0":"text-muted-foreground shrink-0"}),a.label]},a.label)})}),e.jsx("div",{className:"w-full bg-black relative",style:{aspectRatio:"16/9"},children:e.jsx("iframe",{src:Un.embedUrl,title:"YouTube video player",frameBorder:"0",allow:"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture;
634 web-share",referrerPolicy:"strict-origin-when-cross-origin",allowFullScreen:!0,className:"absolute inset-0 w-full h-full border-0"})}),e.jsxs("div",{className:"flex items-center gap-2 px-3 py-2 bg-secondary text-white text-sm mb-4",children:[e.jsx(Ft,{size:13,className:t?"text-red-400 animate-pulse shrink-0":"text-gray-400 shrink-0"}),t?e.jsxs(e.Fragment,{children:[e.jsx("span",{className:"font-semibold",children:"Now Watching:"}),e.jsx("span",{children:"2026 WDAA World Championship — Ring 2"}),e.jsx("span",{className:"ml-auto bg-primary text-white text-xs font-bold px-2 py-0.5 uppercase tracking-wide",children:"Live"})]}):e.jsxs(e.Fragment,{children:[e.jsx("span",{className:"font-semibold",children:"Coming Soon:"}),e.jsx("span",{children:"2026 WDAA World Championship — Ring 2"}),e.jsx("span",{className:"ml-auto text-gray-300 text-xs font-semibold whitespace-nowrap",children:"Show starts September 16th"})]})]}),e.jsx(sd,{}),e.jsxs("div",{className:"flex flex-col sm:flex-row gap-5 mb-5 items-start",children:[e.jsx("a",{href:"https://www.wdaaworldshow.org/",target:"_blank",rel:"noopener noreferrer",className:"shrink-0 w-full sm:w-56 block",children:e.jsx("img",{src:"/airo-assets/images/pages/wdaa-hub/event-poster",alt:"2026 WDAA Western Dressage World Championship Show — September 15–19 at Lazy E Arena, Guthrie Oklahoma",width:640,height:853,className:"w-full h-auto object-contain shadow-md",loading:"lazy"})}),e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("h2",{className:"text-foreground font-bold text-xl leading-tight mb-2",children:"WDAA Western Dressage World Championship Show"}),e.jsxs("div",{className:"space-y-2 text-sm text-foreground mb-4",children:[e.jsxs("div",{className:"flex items-start gap-2",children:[e.jsx("span",{className:"font-bold text-primary shrink-0 w-20",children:"Dates:"}),e.jsxs("span",{children:["September 15",e.jsx("sup",{children:"th"})," – 19",e.jsx("sup",{children:"th"}),", 2026"]})]}),e.jsxs("div",{className:"flex items-start gap-2",children:[e.jsx("span",{className:"font-bold text-primary shrink-0 w-20",children:"Location:"}),e.jsxs("span",{children:["Lazy E Arena",e.jsx("br",{}),"Guthrie, Oklahoma"]})]}),e.jsxs("div",{className:"flex items-start gap-2",children:[e.jsx("span",{className:"font-bold text-primary shrink-0 w-20",children:"Website:"}),e.jsx("a",{href:"https://www.wdaaworldshow.org/",target:"_blank",rel:"noopener noreferrer",className:"text-accent hover:underline break-all",children:"WDAAWorldShow.org"})]}),e.jsxs("div",{className:"flex items-start gap-2",children:[e.jsx("span",{className:"font-bold text-primary shrink-0 w-20",children:"Past Shows:"}),e.jsx("a",{href:Un.replaysUrl,className:"text-accent hover:underline break-all",children:"WDAA Past World Shows"})]}),e.jsxs("div",{className:"flex items-start gap-2",children:[e.jsx("span",{className:"font-bold text-primary shrink-0 w-20",children:"On Rumble:"}),e.jsx("a",{href:"https://rumble.com/c/TotalHorseChannel",target:"_blank",rel:"noopener noreferrer",className:"text-accent hover:underline break-all",children:"Watch on Rumble"})]}),e.jsxs("div",{className:"flex items-start gap-2",children:[e.jsx("span",{className:"font-bold text-primary shrink-0 w-20",children:"Schedule:"}),e.jsx("a",{href:"https://www.showsecretary.com/Razor/Calendar/ClassList/1183?SClassDate=9%2F15%2F2026",target:"_blank",rel:"noopener noreferrer",className:"text-accent hover:underline break-all",children:"Class Schedule"})]})]}),e.jsxs("div",{className:"flex flex-col gap-2",children:[e.jsxs(O,{to:"/wdaa-video-orders",className:"flex items-center gap-3 bg-primary text-white px-4 py-3 hover:bg-secondary transition-colors group",children:[e.jsx(ml,{size:20,className:"shrink-0"}),e.jsxs("div",{children:[e.jsx("div",{className:"font-bold text-sm uppercase leading-tight",children:"Order Your Videos"}),e.jsx("div",{className:"text-xs text-white/80",children:"$35/video — download link via email"})]}),e.jsx(Lt,{size:16,className:"ml-auto group-hover:translate-x-1 transition-transform"})]}),e.jsxs(O,{to:"/home/wdaa",className:"flex items-center gap-3 bg-secondary text-white px-4 py-3 hover:bg-accent transition-colors group border border-border",children:[e.jsx(Ft,{size:20,className:"shrink-0 text-red-400"}),e.jsxs("div",{children:[e.jsx("div",{className:"font-bold text-sm uppercase leading-tight",children:"WDAA Hub"}),e.jsx("div",{className:"text-xs text-white/70",children:"Show info, all rings & replays"})]}),e.jsx(Lt,{size:16,className:"ml-auto group-hover:translate-x-1 transition-transform"})]})]})]})]}),e.jsx(Gm,{}),e.jsx(ji,{}),e.jsxs("div",{className:"border border-border",children:[e.jsx("div",{className:"bg-secondary px-3 py-2",children:e.jsx("h2",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Helpful Links"})}),e.jsx("ul",{className:"divide-y divide-border",children:Nr.helpfulLinks.map(a=>e.jsx("li",{children:e.jsxs("a",{href:a.href,target:a.href.startsWith("http")?"_blank":void 0,rel:a.href.startsWith("http")?"noopener noreferrer":void 0,className:"flex items-center justify-between px-3 py-2.5 text-sm text-accent hover:bg-muted transition-colors group",children:[e.jsx("span",{style:{whiteSpace:"pre-line"},children:a.label}),a.href.startsWith("http")?e.jsx(dt,{size:13,className:"text-muted-foreground group-hover:text-accent shrink-0"}):e.jsx(Lt,{size:14,className:"text-muted-foreground group-hover:text-accent shrink-0"})]})},a.id))})]})]}),e.jsxs("div",{className:"w-full lg:w-[340px] shrink-0 flex flex-col gap-4",children:[e.jsx(vi,{placement:"sidebar-wdaa-ring2"}),e.jsx(pl,{placement:"sidebar-wdaa-ring2-220"}),e.jsx(O,{to:"/home/wdaa",className:"block w-full text-center text-foreground font-semibold py-2 text-sm border border-border hover:bg-muted transition-colors",children:"← Back to WDAA Hub"}),e.jsxs("a",{href:"https://www.showsecretary.com/Razor/Calendar/ClassList/1183?SClassDate=9%2F15%2F2026",target:"_blank",rel:"noopener noreferrer",className:"flex items-center justify-center gap-2 w-full text-center bg-secondary text-white font-semibold py-2.5 text-sm border border-border hover:bg-accent transition-colors",children:["Class Schedule",e.jsx(dt,{size:13,className:"shrink-0"})]}),e.jsx(O,{to:"/community",className:"flex items-center justify-center w-full text-center bg-primary text-white font-bold py-2.5 text-sm hover:bg-secondary transition-colors",children:"SHARE PHOTOS & UPDATES"})]})]})})})]})}const am="https://totalhorsechannel.com",nm=`${am}/video/wdaa-world-championship-show-live-ring-3/`,J8=[{label:"Ring 1",href:"/video/wdaa-world-championship-show-live"},{label:"Ring 2",href:"/video/wdaa-world-championship-show-live-ring-2"},{label:"Ring 3",href:"/video/wdaa-world-championship-show-live-ring-3"},{label:"Ring 4",href:"/video/wdaa-world-championship-show-live-ring-4"}],X8={"@context":"https://schema.org","@type":"VideoObject","@id":`${nm}#video`,name:Pn.pageTitle,description:Pn.description,url:nm,isPartOf:{"@id":`${am}/#website`}},Q8=new Date("2026-09-16T00:00:00-04:00");function e9(){const t=new Date>=Q8;return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsxs("title",{children:[Pn.pageTitle," – Total Horse Channel"]}),e.jsx("meta",{name:"description",content:Pn.description}),e.jsx("link",{rel:"canonical",href:nm}),e.jsx("meta",{property:"og:title",content:`${Pn.pageTitle} – Total Horse Channel`}),e.jsx("meta",{property:"og:description",content:Pn.description}),e.jsx("meta",{property:"og:type",content:"video.other"}),e.jsx("meta",{property:"og:url",content:nm}),e.jsx("meta",{property:"og:image",content:`${am}/airo-assets/images/videos/wdaa-live-ring1`}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("meta",{name:"twitter:title",content:`${Pn.pageTitle} – Total Horse Channel`}),e.jsx("meta",{name:"twitter:description",content:Pn.description}),e.jsx("meta",{name:"twitter:image",content:`${am}/airo-assets/images/videos/wdaa-live-ring1`}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify(X8)})]}),e.jsx("main",{children:e.jsx("div",{className:"max-w-[1280px] mx-auto px-4 py-4",children:e.jsxs("div",{className:"flex flex-col lg:flex-row gap-6",children:[e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("div",{className:"bg-primary px-3 py-2 mb-0",children:e.jsxs("h1",{className:"text-white font-bold uppercase text-sm tracking-wide flex items-center gap-2",children:[e.jsx(Ft,{size:13,className:"animate-pulse text-red-300 shrink-0"}),"2026 Western Dressage World Championship Show — Ring 3 Live"]})}),e.jsx("div",{className:"flex flex-wrap gap-0 mb-0 border border-t-0 border-b-0 border-border",children:J8.map(a=>{const r=a.label==="Ring 3";return e.jsxs(O,{to:a.href,className:["flex items-center gap-1.5 px-5 py-2.5 text-sm font-bold uppercase transition-colors",r?"bg-secondary text-white":"bg-muted text-foreground hover:bg-primary hover:text-white"].join(" "),children:[e.jsx(Ft,{size:11,className:r?"animate-pulse text-red-400 shrink-0":"text-muted-foreground shrink-0"}),a.label]},a.label)})}),e.jsx("div",{className:"w-full bg-black relative",style:{aspectRatio:"16/9"},children:e.jsx("iframe",{src:Pn.embedUrl,title:"YouTube video player",frameBorder:"0",allow:"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture;
634 web-share",referrerPolicy:"strict-origin-when-cross-origin",allowFullScreen:!0,className:"absolute inset-0 w-full h-full border-0"})}),e.jsxs("div",{className:"flex items-center gap-2 px-3 py-2 bg-secondary text-white text-sm mb-4",children:[e.jsx(Ft,{size:13,className:t?"text-red-400 animate-pulse shrink-0":"text-gray-400 shrink-0"}),t?e.jsxs(e.Fragment,{children:[e.jsx("span",{className:"font-semibold",children:"Now Watching:"}),e.jsx("span",{children:"2026 WDAA World Championship — Ring 3"}),e.jsx("span",{className:"ml-auto bg-primary text-white text-xs font-bold px-2 py-0.5 uppercase tracking-wide",children:"Live"})]}):e.jsxs(e.Fragment,{children:[e.jsx("span",{className:"font-semibold",children:"Coming Soon:"}),e.jsx("span",{children:"2026 WDAA World Championship — Ring 3"}),e.jsx("span",{className:"ml-auto text-gray-300 text-xs font-semibold whitespace-nowrap",children:"Show starts September 16th"})]})]}),e.jsx(sd,{}),e.jsxs("div",{className:"flex flex-col sm:flex-row gap-5 mb-5 items-start",children:[e.jsx("a",{href:"https://www.wdaaworldshow.org/",target:"_blank",rel:"noopener noreferrer",className:"shrink-0 w-full sm:w-56 block",children:e.jsx("img",{src:"/airo-assets/images/pages/wdaa-hub/event-poster",alt:"2026 WDAA Western Dressage World Championship Show — September 15–19 at Lazy E Arena, Guthrie Oklahoma",width:640,height:853,className:"w-full h-auto object-contain shadow-md",loading:"lazy"})}),e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("h2",{className:"text-foreground font-bold text-xl leading-tight mb-2",children:"WDAA Western Dressage World Championship Show"}),e.jsxs("div",{className:"space-y-2 text-sm text-foreground mb-4",children:[e.jsxs("div",{className:"flex items-start gap-2",children:[e.jsx("span",{className:"font-bold text-primary shrink-0 w-20",children:"Dates:"}),e.jsxs("span",{children:["September 15",e.jsx("sup",{children:"th"})," – 19",e.jsx("sup",{children:"th"}),", 2026"]})]}),e.jsxs("div",{className:"flex items-start gap-2",children:[e.jsx("span",{className:"font-bold text-primary shrink-0 w-20",children:"Location:"}),e.jsxs("span",{children:["Lazy E Arena",e.jsx("br",{}),"Guthrie, Oklahoma"]})]}),e.jsxs("div",{className:"flex items-start gap-2",children:[e.jsx("span",{className:"font-bold text-primary shrink-0 w-20",children:"Website:"}),e.jsx("a",{href:"https://www.wdaaworldshow.org/",target:"_blank",rel:"noopener noreferrer",className:"text-accent hover:underline break-all",children:"WDAAWorldShow.org"})]}),e.jsxs("div",{className:"flex items-start gap-2",children:[e.jsx("span",{className:"font-bold text-primary shrink-0 w-20",children:"Past Shows:"}),e.jsx("a",{href:Pn.replaysUrl,className:"text-accent hover:underline break-all",children:"WDAA Past World Shows"})]}),e.jsxs("div",{className:"flex items-start gap-2",children:[e.jsx("span",{className:"font-bold text-primary shrink-0 w-20",children:"On Rumble:"}),e.jsx("a",{href:"https://rumble.com/c/TotalHorseChannel",target:"_blank",rel:"noopener noreferrer",className:"text-accent hover:underline break-all",children:"Watch on Rumble"})]}),e.jsxs("div",{className:"flex items-start gap-2",children:[e.jsx("span",{className:"font-bold text-primary shrink-0 w-20",children:"Schedule:"}),e.jsx("a",{href:"https://www.showsecretary.com/Razor/Calendar/ClassList/1183?SClassDate=9%2F15%2F2026",target:"_blank",rel:"noopener noreferrer",className:"text-accent hover:underline break-all",children:"Class Schedule"})]})]}),e.jsxs("div",{className:"flex flex-col gap-2",children:[e.jsxs(O,{to:"/wdaa-video-orders",className:"flex items-center gap-3 bg-primary text-white px-4 py-3 hover:bg-secondary transition-colors group",children:[e.jsx(ml,{size:20,className:"shrink-0"}),e.jsxs("div",{children:[e.jsx("div",{className:"font-bold text-sm uppercase leading-tight",children:"Order Your Videos"}),e.jsx("div",{className:"text-xs text-white/80",children:"$35/video — download link via email"})]}),e.jsx(Lt,{size:16,className:"ml-auto group-hover:translate-x-1 transition-transform"})]}),e.jsxs(O,{to:"/home/wdaa",className:"flex items-center gap-3 bg-secondary text-white px-4 py-3 hover:bg-accent transition-colors group border border-border",children:[e.jsx(Ft,{size:20,className:"shrink-0 text-red-400"}),e.jsxs("div",{children:[e.jsx("div",{className:"font-bold text-sm uppercase leading-tight",children:"WDAA Hub"}),e.jsx("div",{className:"text-xs text-white/70",children:"Show info, all rings & replays"})]}),e.jsx(Lt,{size:16,className:"ml-auto group-hover:translate-x-1 transition-transform"})]})]})]})]}),e.jsx(Gm,{}),e.jsx(ji,{}),e.jsxs("div",{className:"border border-border",children:[e.jsx("div",{className:"bg-secondary px-3 py-2",children:e.jsx("h2",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Helpful Links"})}),e.jsx("ul",{className:"divide-y divide-border",children:Nr.helpfulLinks.map(a=>e.jsx("li",{children:e.jsxs("a",{href:a.href,target:a.href.startsWith("http")?"_blank":void 0,rel:a.href.startsWith("http")?"noopener noreferrer":void 0,className:"flex items-center justify-between px-3 py-2.5 text-sm text-accent hover:bg-muted transition-colors group",children:[e.jsx("span",{style:{whiteSpace:"pre-line"},children:a.label}),a.href.startsWith("http")?e.jsx(dt,{size:13,className:"text-muted-foreground group-hover:text-accent shrink-0"}):e.jsx(Lt,{size:14,className:"text-muted-foreground group-hover:text-accent shrink-0"})]})},a.id))})]})]}),e.jsxs("div",{className:"w-full lg:w-[340px] shrink-0 flex flex-col gap-4",children:[e.jsx(vi,{placement:"sidebar-wdaa-ring3"}),e.jsx(pl,{placement:"sidebar-wdaa-ring3-220"}),e.jsx(O,{to:"/home/wdaa",className:"block w-full text-center text-foreground font-semibold py-2 text-sm border border-border hover:bg-muted transition-colors",children:"← Back to WDAA Hub"}),e.jsxs("a",{href:"https://www.showsecretary.com/Razor/Calendar/ClassList/1183?SClassDate=9%2F15%2F2026",target:"_blank",rel:"noopener noreferrer",className:"flex items-center justify-center gap-2 w-full text-center bg-secondary text-white font-semibold py-2.5 text-sm border border-border hover:bg-accent transition-colors",children:["Class Schedule",e.jsx(dt,{size:13,className:"shrink-0"})]}),e.jsx(O,{to:"/community",className:"flex items-center justify-center w-full text-center bg-primary text-white font-bold py-2.5 text-sm hover:bg-secondary transition-colors",children:"SHARE PHOTOS & UPDATES"})]})]})})})]})}const rm="https://totalhorsechannel.com",im=`${rm}/video/wdaa-world-championship-show-live-ring-4/`,t9=[{label:"Ring 1",href:"/video/wdaa-world-championship-show-live"},{label:"Ring 2",href:"/video/wdaa-world-championship-show-live-ring-2"},{label:"Ring 3",href:"/video/wdaa-world-championship-show-live-ring-3"},{label:"Ring 4",href:"/video/wdaa-world-championship-show-live-ring-4"}],s9={"@context":"https://schema.org","@type":"VideoObject","@id":`${im}#video`,name:Kn.pageTitle,description:Kn.description,url:im,isPartOf:{"@id":`${rm}/#website`}},a9=new Date("2026-09-16T00:00:00-04:00");function n9(){const t=new Date>=a9;return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsxs("title",{children:[Kn.pageTitle," – Total Horse Channel"]}),e.jsx("meta",{name:"description",content:Kn.description}),e.jsx("link",{rel:"canonical",href:im}),e.jsx("meta",{property:"og:title",content:`${Kn.pageTitle} – Total Horse Channel`}),e.jsx("meta",{property:"og:description",content:Kn.description}),e.jsx("meta",{property:"og:type",content:"video.other"}),e.jsx("meta",{property:"og:url",content:im}),e.jsx("meta",{property:"og:image",content:`${rm}/airo-assets/images/videos/wdaa-live-ring1`}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("meta",{name:"twitter:title",content:`${Kn.pageTitle} – Total Horse Channel`}),e.jsx("meta",{name:"twitter:description",content:Kn.description}),e.jsx("meta",{name:"twitter:image",content:`${rm}/airo-assets/images/videos/wdaa-live-ring1`}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify(s9)})]}),e.jsx("main",{children:e.jsx("div",{className:"max-w-[1280px] mx-auto px-4 py-4",children:e.jsxs("div",{className:"flex flex-col lg:flex-row gap-6",children:[e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("div",{className:"bg-primary px-3 py-2 mb-0",children:e.jsxs("h1",{className:"text-white font-bold uppercase text-sm tracking-wide flex items-center gap-2",children:[e.jsx(Ft,{size:13,className:"animate-pulse text-red-300 shrink-0"}),"2026 Western Dressage World Championship Show — Ring 4 Live"]})}),e.jsx("div",{className:"flex flex-wrap gap-0 mb-0 border border-t-0 border-b-0 border-border",children:t9.map(a=>{const r=a.label==="Ring 4";return e.jsxs(O,{to:a.href,className:["flex items-center gap-1.5 px-5 py-2.5 text-sm font-bold uppercase transition-colors",r?"bg-secondary text-white":"bg-muted text-foreground hover:bg-primary hover:text-white"].join(" "),children:[e.jsx(Ft,{size:11,className:r?"animate-pulse text-red-400 shrink-0":"text-muted-foreground shrink-0"}),a.label]},a.label)})}),e.jsx("div",{className:"w-full bg-black relative",style:{aspectRatio:"16/9"},children:e.jsx("iframe",{src:Kn.embedUrl,title:"YouTube video player",frameBorder:"0",allow:"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture;
634 web-share",referrerPolicy:"strict-origin-when-cross-origin",allowFullScreen:!0,className:"absolute inset-0 w-full h-full border-0"})}),e.jsxs("div",{className:"flex items-center gap-2 px-3 py-2 bg-secondary text-white text-sm mb-4",children:[e.jsx(Ft,{size:13,className:t?"text-red-400 animate-pulse shrink-0":"text-gray-400 shrink-0"}),t?e.jsxs(e.Fragment,{children:[e.jsx("span",{className:"font-semibold",children:"Now Watching:"}),e.jsx("span",{children:"2026 WDAA World Championship — Ring 4"}),e.jsx("span",{className:"ml-auto bg-primary text-white text-xs font-bold px-2 py-0.5 uppercase tracking-wide",children:"Live"})]}):e.jsxs(e.Fragment,{children:[e.jsx("span",{className:"font-semibold",children:"Coming Soon:"}),e.jsx("span",{children:"2026 WDAA World Championship — Ring 4"}),e.jsx("span",{className:"ml-auto text-gray-300 text-xs font-semibold whitespace-nowrap",children:"Show starts September 16th"})]})]}),e.jsx(sd,{}),e.jsxs("div",{className:"flex flex-col sm:flex-row gap-5 mb-5 items-start",children:[e.jsx("a",{href:"https://www.wdaaworldshow.org/",target:"_blank",rel:"noopener noreferrer",className:"shrink-0 w-full sm:w-56 block",children:e.jsx("img",{src:"/airo-assets/images/pages/wdaa-hub/event-poster",alt:"2026 WDAA Western Dressage World Championship Show — September 15–19 at Lazy E Arena, Guthrie Oklahoma",width:640,height:853,className:"w-full h-auto object-contain shadow-md",loading:"lazy"})}),e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("h2",{className:"text-foreground font-bold text-xl leading-tight mb-2",children:"WDAA Western Dressage World Championship Show"}),e.jsxs("div",{className:"space-y-2 text-sm text-foreground mb-4",children:[e.jsxs("div",{className:"flex items-start gap-2",children:[e.jsx("span",{className:"font-bold text-primary shrink-0 w-20",children:"Dates:"}),e.jsxs("span",{children:["September 15",e.jsx("sup",{children:"th"})," – 19",e.jsx("sup",{children:"th"}),", 2026"]})]}),e.jsxs("div",{className:"flex items-start gap-2",children:[e.jsx("span",{className:"font-bold text-primary shrink-0 w-20",children:"Location:"}),e.jsxs("span",{children:["Lazy E Arena",e.jsx("br",{}),"Guthrie, Oklahoma"]})]}),e.jsxs("div",{className:"flex items-start gap-2",children:[e.jsx("span",{className:"font-bold text-primary shrink-0 w-20",children:"Website:"}),e.jsx("a",{href:"https://www.wdaaworldshow.org/",target:"_blank",rel:"noopener noreferrer",className:"text-accent hover:underline break-all",children:"WDAAWorldShow.org"})]}),e.jsxs("div",{className:"flex items-start gap-2",children:[e.jsx("span",{className:"font-bold text-primary shrink-0 w-20",children:"Past Shows:"}),e.jsx("a",{href:Kn.replaysUrl,className:"text-accent hover:underline break-all",children:"WDAA Past World Shows"})]}),e.jsxs("div",{className:"flex items-start gap-2",children:[e.jsx("span",{className:"font-bold text-primary shrink-0 w-20",children:"On Rumble:"}),e.jsx("a",{href:"https://rumble.com/c/TotalHorseChannel",target:"_blank",rel:"noopener noreferrer",className:"text-accent hover:underline break-all",children:"Watch on Rumble"})]}),e.jsxs("div",{className:"flex items-start gap-2",children:[e.jsx("span",{className:"font-bold text-primary shrink-0 w-20",children:"Schedule:"}),e.jsx("a",{href:"https://www.showsecretary.com/Razor/Calendar/ClassList/1183?SClassDate=9%2F15%2F2026",target:"_blank",rel:"noopener noreferrer",className:"text-accent hover:underline break-all",children:"Class Schedule"})]})]}),e.jsxs("div",{className:"flex flex-col gap-2",children:[e.jsxs(O,{to:"/wdaa-video-orders",className:"flex items-center gap-3 bg-primary text-white px-4 py-3 hover:bg-secondary transition-colors group",children:[e.jsx(ml,{size:20,className:"shrink-0"}),e.jsxs("div",{children:[e.jsx("div",{className:"font-bold text-sm uppercase leading-tight",children:"Order Your Videos"}),e.jsx("div",{className:"text-xs text-white/80",children:"$35/video — download link via email"})]}),e.jsx(Lt,{size:16,className:"ml-auto group-hover:translate-x-1 transition-transform"})]}),e.jsxs(O,{to:"/home/wdaa",className:"flex items-center gap-3 bg-secondary text-white px-4 py-3 hover:bg-accent transition-colors group border border-border",children:[e.jsx(Ft,{size:20,className:"shrink-0 text-red-400"}),e.jsxs("div",{children:[e.jsx("div",{className:"font-bold text-sm uppercase leading-tight",children:"WDAA Hub"}),e.jsx("div",{className:"text-xs text-white/70",children:"Show info, all rings & replays"})]}),e.jsx(Lt,{size:16,className:"ml-auto group-hover:translate-x-1 transition-transform"})]})]})]})]}),e.jsx(Gm,{}),e.jsx(ji,{}),e.jsxs("div",{className:"border border-border",children:[e.jsx("div",{className:"bg-secondary px-3 py-2",children:e.jsx("h2",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Helpful Links"})}),e.jsx("ul",{className:"divide-y divide-border",children:Nr.helpfulLinks.map(a=>e.jsx("li",{children:e.jsxs("a",{href:a.href,target:a.href.startsWith("http")?"_blank":void 0,rel:a.href.startsWith("http")?"noopener noreferrer":void 0,className:"flex items-center justify-between px-3 py-2.5 text-sm text-accent hover:bg-muted transition-colors group",children:[e.jsx("span",{style:{whiteSpace:"pre-line"},children:a.label}),a.href.startsWith("http")?e.jsx(dt,{size:13,className:"text-muted-foreground group-hover:text-accent shrink-0"}):e.jsx(Lt,{size:14,className:"text-muted-foreground group-hover:text-accent shrink-0"})]})},a.id))})]})]}),e.jsxs("div",{className:"w-full lg:w-[340px] shrink-0 flex flex-col gap-4",children:[e.jsx(vi,{placement:"sidebar-wdaa-ring4"}),e.jsx(pl,{placement:"sidebar-wdaa-ring4-220"}),e.jsx(O,{to:"/home/wdaa",className:"block w-full text-center text-foreground font-semibold py-2 text-sm border border-border hover:bg-muted transition-colors",children:"← Back to WDAA Hub"}),e.jsxs("a",{href:"https://www.showsecretary.com/Razor/Calendar/ClassList/1183?SClassDate=9%2F15%2F2026",target:"_blank",rel:"noopener noreferrer",className:"flex items-center justify-center gap-2 w-full text-center bg-secondary text-white font-semibold py-2.5 text-sm border border-border hover:bg-accent transition-colors",children:["Class Schedule",e.jsx(dt,{size:13,className:"shrink-0"})]}),e.jsx(O,{to:"/community",className:"flex items-center justify-center w-full text-center bg-primary text-white font-bold py-2.5 text-sm hover:bg-secondary transition-colors",children:"SHARE PHOTOS & UPDATES"})]})]})})})]})}const om="https://totalhorsechannel.com",lm=`${om}/wdaa-replays/`,r9={"@context":"https://schema.org","@type":"WebPage","@id":`${lm}#webpage`,name:vr.pageTitle,description:vr.description,url:lm,isPartOf:{"@id":`${om}/#website`}};function i9(){return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsxs("title",{children:[vr.pageTitle," – Total Horse Channel"]}),e.jsx("meta",{name:"description",content:vr.description}),e.jsx("link",{rel:"canonical",href:lm}),e.jsx("meta",{property:"og:title",content:`${vr.pageTitle} – Total Horse Channel`}),e.jsx("meta",{property:"og:description",content:vr.description}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{property:"og:url",content:lm}),e.jsx("meta",{property:"og:image",content:`${om}/airo-assets/images/sidebar/wdaa-banner`}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("meta",{name:"twitter:title",content:`${vr.pageTitle} – Total Horse Channel`}),e.jsx("meta",{name:"twitter:description",content:vr.description}),e.jsx("meta",{name:"twitter:image",content:`${om}/airo-assets/images/sidebar/wdaa-banner`}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify(r9)})]}),e.jsx("main",{children:e.jsxs("div",{className:"max-w-[1280px] mx-auto px-4 py-4",children:[e.jsx("div",{className:"bg-primary px-3 py-2 mb-4",children:e.jsxs("h1",{className:"text-white font-bold uppercase text-sm tracking-wide flex items-center gap-2",children:[e.jsx(Rc,{size:14,className:"shrink-0"}),"WDAA Past World Shows"]})}),e.jsxs("div",{className:"flex flex-col lg:flex-row gap-6",children:[e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsxs("div",{className:"border border-border p-4 mb-5 bg-muted/40",children:[e.jsx("h2",{className:"text-foreground font-bold text-lg mb-1",children:"WDAA Past World Shows"}),e.jsxs("p",{className:"text-sm text-foreground leading-relaxed",children:["Watch replays of the ",e.jsx("strong",{children:"LIVESTREAMS"})," from the WDAA Western Dressage World Championship Show. Individual rides and classes are available for"," ",e.jsx(O,{to:"/wdaa-video-orders",className:"text-accent hover:underline font-medium",children:"purchase"})," ","from 2018 through 2025."]})]}),vr.years.map(t=>e.jsxs("div",{className:"mb-6 border border-border",children:[e.jsx("div",{className:"bg-secondary px-3 py-2 flex items-center gap-2",children:e.jsxs("span",{className:"text-white font-bold text-sm uppercase tracking-wide",children:[t.year," WDAA World Championship Show"]})}),e.jsxs("div",{className:"flex flex-col sm:flex-row gap-0",children:[e.jsx("div",{className:"sm:w-48 shrink-0 flex items-center justify-center p-4 border-b sm:border-b-0 sm:border-r border-border bg-white",children:e.jsx("img",{src:t.logoSrc,alt:`WDAA ${t.year} Western Dressage World Championship Show logo`,width:160,height:160,className:"w-32 h-32 object-contain",loading:"lazy"})}),e.jsxs("div",{className:"flex-1 p-4",children:[t.note?e.jsx("p",{className:"text-sm text-foreground mb-3 leading-relaxed",children:t.note.includes("purchase")?e.jsxs(e.Fragment,{children:[t.note.split("purchase")[0],e.jsx(O,{to:"/wdaa-video-orders",className:"text-accent hover:underline font-medium",children:"purchase"}),t.note.split("purchase")[1]]}):t.note}):null,e.jsx("ul",{className:"space-y-1",children:t.days.map(a=>e.jsx("li",{children:e.jsxs("a",{href:a.href,target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-1.5 text-sm text-accent hover:underline hover:text-primary transition-colors",children:[e.jsx(Rc,{size:13,className:"shrink-0 text-primary"}),e.jsx("span",{style:{whiteSpace:"pre-line"},children:a.label}),e.jsx(dt,{size:11,className:"text-muted-foreground shrink-0"})]})},a.id))})]})]})]},t.id)),e.jsxs("div",{className:"border border-border p-4 bg-muted/40 flex flex-col sm:flex-row items-start sm:items-center gap-4",children:[e.jsxs("div",{className:"flex-1",children:[e.jsx("p",{className:"font-bold text-sm text-foreground mb-0.5",children:"Need a specific ride or class?"}),e.jsx("p",{className:"text-xs text-muted-foreground",children:"Individual rides and classes available for purchase from 2018 through 2025 — $35/video, download link via email."})]}),e.jsxs(O,{to:"/wdaa-video-orders",className:"flex items-center gap-2 bg-primary text-white px-4 py-2.5 text-sm font-bold uppercase hover:bg-primary/90 transition-colors shrink-0",children:[e.jsx(ml,{size:15}),"Order Videos"]})]})]}),e.jsxs("div",{className:"w-full lg:w-[340px] shrink-0 flex flex-col gap-4",children:[e.jsx(vi,{placement:"sidebar-wdaa-replays"}),e.jsx(pl,{placement:"sidebar-wdaa-replays-220"}),e.jsx(O,{to:"/home/wdaa",className:"block w-full text-center text-foreground font-semibold py-2 text-sm border border-border hover:bg-muted transition-colors",children:"← WDAA Hub"}),e.jsxs("a",{href:"https://www.showsecretary.com/Razor/Calendar/ClassList/1183?SClassDate=9%2F15%2F2026",target:"_blank",rel:"noopener noreferrer",className:"flex items-center justify-center gap-2 w-full text-center bg-secondary text-white font-semibold py-2.5 text-sm border border-border hover:bg-secondary/80 transition-colors",children:["Class Schedule",e.jsx(dt,{size:13,className:"shrink-0"})]}),e.jsx(ji,{}),e.jsxs("div",{className:"border border-border",children:[e.jsx("div",{className:"bg-secondary px-3 py-2",children:e.jsx("h2",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Helpful Links"})}),e.jsx("ul",{className:"divide-y divide-border",children:Nr.helpfulLinks.map(t=>e.jsx("li",{children:e.jsxs("a",{href:t.href,target:t.href.startsWith("http")?"_blank":void 0,rel:t.href.startsWith("http")?"noopener noreferrer":void 0,className:"flex items-center justify-between px-3 py-2.5 text-sm text-accent hover:bg-muted transition-colors group",children:[e.jsx("span",{style:{whiteSpace:"pre-line"},children:t.label}),t.href.startsWith("http")?e.jsx(dt,{size:13,className:"text-muted-foreground group-hover:text-accent shrink-0"}):e.jsx(Lt,{size:14,className:"text-muted-foreground group-hover:text-accent shrink-0"})]})},t.id))})]})]})]})]})})]})}const Vc="https://totalhorsechannel.com",cm=`${Vc}/wdaa-sponsorships`,o9={"@context":"https://schema.org","@type":"WebPage","@id":`${cm}#webpage`,name:gs.pageTitle,description:gs.description,url:cm,isPartOf:{"@id":`${Vc}/#website`},about:{"@id":`${Vc}/#organization`}};function l9(){return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsxs("title",{children:[gs.pageTitle," – Total Horse Channel"]}),e.jsx("meta",{name:"description",content:gs.description}),e.jsx("link",{rel:"canonical",href:cm}),e.jsx("meta",{property:"og:title",content:`${gs.pageTitle} – Total Horse Channel`}),e.jsx("meta",{property:"og:description",content:gs.description}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{property:"og:url",content:cm}),e.jsx("meta",{property:"og:image",content:`${Vc}/airo-assets/images/sidebar/wdaa-banner`}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("meta",{name:"twitter:title",content:`${gs.pageTitle} – Total Horse Channel`}),e.jsx("meta",{name:"twitter:description",content:gs.description}),e.jsx("meta",{name:"twitter:image",content:`${Vc}/airo-assets/images/sidebar/wdaa-banner`}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify(o9)})]}),e.jsx("main",{children:e.jsxs("div",{className:"max-w-[1280px] mx-auto px-4 py-4",children:[e.jsx("div",{className:"bg-primary px-3 py-2 mb-4",children:e.jsxs("h1",{className:"text-white font-bold uppercase text-sm tracking-wide flex items-center gap-2",children:[e.jsx(V0,{size:14,className:"shrink-0"}),gs.heading]})}),e.jsxs("div",{className:"flex flex-col lg:flex-row gap-6",children:[e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsxs("div",{className:"mb-6",children:[e.jsx("div",{className:"bg-secondary px-3 py-2 mb-0",children:e.jsx("h2",{className:"text-white font-bold uppercase text-sm tracking-wide",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"fbd3ef",guard:{file:"src/pages/wdaa-sponsorships.tsx",tagName:"h2",sourceKind:"content-key",contentKey:"wdaa_sponsorships.sponsorVideoLabel",contentKeyTemplate:null,expressionH
634ash:null},children:gs.sponsorVideoLabel})})}),e.jsxs("div",{className:"border border-border border-t-0 p-3 bg-black/5",children:[e.jsx("p",{className:"text-xs text-muted-foreground mb-2 italic",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"f31086",guard:{file:"src/pages/wdaa-sponsorships.tsx",tagName:"p",sourceKind:"content-key",contentKey:"wdaa_sponsorships.sponsorVideoNote",contentKeyTemplate:null,expressionHash:null},children:gs.sponsorVideoNote})}),e.jsx("div",{className:"w-full bg-black",style:{aspectRatio:"16/9"},children:e.jsx("video",{src:"/airo-assets/videos/pages/wdaa-sponsorships/sponsor-video",controls:!0,playsInline:!0,className:"w-full h-full object-contain",poster:"/airo-assets/images/pages/wdaa-sponsorships/sponsor-video-poster"})})]})]}),e.jsxs("div",{className:"mb-6",children:[e.jsx("div",{className:"bg-secondary px-3 py-2 mb-0",children:e.jsx("h2",{className:"text-white font-bold uppercase text-sm tracking-wide",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"ef3150",guard:{file:"src/pages/wdaa-sponsorships.tsx",tagName:"h2",sourceKind:"content-key",contentKey:"wdaa_sponsorships.currentSponsorsHeading",contentKeyTemplate:null,expressionHash:null},children:gs.currentSponsorsHeading})})}),e.jsx("div",{className:"border border-border border-t-0 p-4",children:e.jsx("div",{className:"grid grid-cols-2 sm:grid-cols-3 gap-4",children:gs.sponsors.map(t=>e.jsxs("a",{href:t.href,target:t.href.startsWith("http")?"_blank":void 0,rel:t.href.startsWith("http")?"noopener noreferrer":void 0,className:"flex flex-col items-center justify-center p-3 border border-border bg-white hover:border-primary hover:shadow-sm transition-all group",children:[e.jsx("img",{src:t.logoSrc,alt:t.name,width:160,height:100,className:"w-full h-20 object-contain",loading:"lazy"}),e.jsx("span",{className:"text-xs text-muted-foreground text-center mt-2 group-hover:text-primary transition-colors leading-tight",style:{whiteSpace:"pre-line"},children:t.name})]},t.id))})})]}),e.jsxs("div",{className:"mb-6 border border-border overflow-hidden",children:[e.jsx("div",{className:"h-1 w-full bg-primary"}),e.jsxs("div",{className:"p-5",children:[e.jsx("p",{className:"text-base text-foreground leading-relaxed mb-4",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"ac7b08",guard:{file:"src/pages/wdaa-sponsorships.tsx",tagName:"p",sourceKind:"content-key",contentKey:"wdaa_sponsorships.intro",contentKeyTemplate:null,expressionHash:null},children:gs.intro})}),e.jsx("div",{className:"border-t border-border my-4"}),e.jsx("p",{className:"text-sm text-foreground leading-relaxed mb-1",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"ac7b09",guard:{file:"src/pages/wdaa-sponsorships.tsx",tagName:"p",sourceKind:"content-key",contentKey:"wdaa_sponsorships.sponsorIntro",contentKeyTemplate:null,expressionHash:null},children:gs.sponsorIntro})}),e.jsxs("div",{className:"mt-5",children:[e.jsxs("a",{href:gs.sponsorLearnMoreUrl,target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-2 bg-primary text-white font-bold uppercase px-6 py-3 text-sm hover:bg-primary/90 transition-colors",children:[e.jsx(Ku,{size:15}),"Learn More About Sponsorship Opportunities"]}),e.jsx("p",{className:"text-xs text-muted-foreground mt-2",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"85469d",guard:{file:"src/pages/wdaa-sponsorships.tsx",tagName:"p",sourceKind:"content-key",contentKey:"wdaa_sponsorships.sponsorLearnMoreText",contentKeyTemplate:null,expressionHash:null},children:gs.sponsorLearnMoreText})})]})]})]}),e.jsxs("div",{className:"mb-6",children:[e.jsx("div",{className:"bg-secondary px-3 py-2 mb-0",children:e.jsx("h2",{className:"text-white font-bold uppercase text-sm tracking-wide",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"d5ec12",guard:{file:"src/pages/wdaa-sponsorships.tsx",tagName:"h2",sourceKind:"content-key",contentKey:"wdaa_sponsorships.packagesHeading",contentKeyTemplate:null,expressionHash:null},children:gs.packagesHeading})})}),e.jsx("div",{className:"border border-border border-t-0 divide-y divide-border",children:gs.packages.map(t=>e.jsxs("div",{className:"p-4",children:[e.jsxs("div",{className:"flex items-center justify-between mb-2",children:[e.jsxs("h3",{className:"font-bold text-foreground text-base flex items-center gap-2",children:[e.jsx(V0,{size:14,className:"text-primary shrink-0"}),t.name]}),e.jsx("span",{className:"text-xs font-semibold text-primary border border-primary px-2 py-0.5",style:{whiteSpace:"pre-line"},children:t.price})]}),e.jsx("ul",{className:"space-y-1",children:t.features.map((a,r)=>
634e.jsxs("li",{className:"flex items-start gap-2 text-sm text-foreground",children:[e.jsx(kn,{size:13,className:"text-primary shrink-0 mt-0.5"}),e.jsx("span",{style:{whiteSpace:"pre-line"},children:a})]},r))})]},t.id))})]}),e.jsxs("div",{className:"border border-border mb-6",children:[e.jsx("div",{className:"bg-primary px-3 py-2",children:e.jsxs("h2",{className:"text-white font-bold uppercase text-sm tracking-wide flex items-center gap-2",children:[e.jsx(nn,{size:14,className:"shrink-0"}),gs.contactHeading]})}),e.jsx("div",{className:"divide-y divide-border",children:gs.contacts.map(t=>e.jsxs("div",{className:"flex flex-col sm:flex-row sm:items-center justify-between gap-2 px-4 py-3",children:[e.jsxs("div",{children:[e.jsx("p",{className:"font-semibold text-sm text-foreground",style:{whiteSpace:"pre-line"},children:t.type}),e.jsxs("p",{className:"text-xs text-muted-foreground",children:["Contact: ",t.contact]})]}),e.jsxs("a",{href:`mailto:${t.email}`,className:"inline-flex items-center gap-1.5 text-sm text-accent hover:text-primary transition-colors font-medium shrink-0",children:[e.jsx(nn,{size:13}),t.email]})]},t.id))})]})]}),e.jsxs("div",{className:"w-full lg:w-[340px] shrink-0 flex flex-col gap-4",children:[e.jsx(vi,{placement:"sidebar-wdaa-sponsorships"}),e.jsx(O,{to:"/home/wdaa",className:"block w-full text-center text-foreground font-semibold py-2 text-sm border border-border hover:bg-muted transition-colors",children:"← WDAA Hub"}),e.jsxs("a",{href:"https://www.showsecretary.com/Razor/Calendar/ClassList/1183?SClassDate=9%2F15%2F2026",target:"_blank",rel:"noopener noreferrer",className:"flex items-center justify-center gap-2 w-full text-center bg-secondary text-white font-semibold py-2.5 text-sm border border-border hover:bg-secondary/80 transition-colors",children:["Class Schedule",e.jsx(dt,{size:13,className:"shrink-0"})]}),e.jsx(ji,{}),e.jsxs("div",{className:"border border-border",children:[e.jsx("div",{className:"bg-secondary px-3 py-2",children:e.jsx("h2",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Helpful Links"})}),e.jsx("ul",{className:"divide-y divide-border",children:Nr.helpfulLinks.map(t=>e.jsx("li",{children:e.jsxs("a",{href:t.href,target:t.href.startsWith("http")?"_blank":void 0,rel:t.href.startsWith("http")?"noopener noreferrer":void 0,className:"flex items-center justify-between px-3 py-2.5 text-sm text-accent hover:bg-muted transition-colors group",children:[e.jsx("span",{style:{whiteSpace:"pre-line"},children:t.label}),t.href.startsWith("http")?e.jsx(dt,{size:13,className:"text-muted-foreground group-hover:text-accent shrink-0"}):e.jsx(Lt,{size:14,className:"text-muted-foreground group-hover:text-accent shrink-0"})]})},t.id))})]})]})]})]})})]})}const Cu="thc_admin_token",Ef="thc_admin_role",c9=g.createContext("admin");async function Wj(t){try{const a=await fetch("/api/admin/verify-token",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({token:t})});return a.ok?{ok:!0,role:(await a.json()).role??"admin"}:{ok:!1,role:"admin"}}catch{return{ok:!1,role:"admin"}}}function kr({children:t,pageTitle:a="Admin Dashboard",requiredRole:r}){const[o,l]=g.useState("checking"),[d,u]=g.useState("admin"),[m,p]=g.useState(""),[x,b]=g.useState(!1),[y,v]=g.useState(""),[w,C]=g.useState(!1);g.useEffect(()=>{const S=sessionStorage.getItem(Cu);if(!S){l("locked");return}Wj(S).then(({ok:z,role:T})=>{z?(u(T),l(r==="admin"&&T==="live_helper"?"forbidden":"unlocked")):(sessionStorage.removeItem(Cu),sessionStorage.removeItem(Ef),l("locked"))})},[]);const A=g.useCallback(async S=>{S.preventDefault();const z=m.trim();if(!z)return;C(!0),v("");const{ok:T,role:M}=await Wj(z);if(T){if(r==="admin"&&M==="live_helper"){v("This page requires the main admin token."),C(!1);return}sessionStorage.setItem(Cu,z),sessionStorage.setItem(Ef,M),u(M),l("unlocked")}else v("Incorrect token. Please try again.");C(!1)},[m,r]);return o==="checking"?e.jsx("div",{className:"min-h-screen flex items-center justify-center bg-background",children:e.jsx(Rt,{size:28,className:"animate-spin text-muted-foreground"})}):o==="forbidden"?e.jsx("div",{className:"min-h-screen flex items-center justify-center bg-muted/30 px-4",children:e.jsxs("div",{className:"w-full max-w-sm bg-card border border-border shadow-lg p-8 text-center",children:[e.jsx(so,{size:28,className:"text-destructive mx-auto mb-4"}),e.jsx("h1",{className:"font-bold text-foreground text-lg mb-2",children:"Access Denied"}),e.jsx("p",{className:"text-muted-foreground text-sm",children:"This page requires the main admin token. Your current session does not have access."}),e.jsx("button",{className:"mt-5 text-xs text-primary underline",onClick:()=>{sessionStorage.removeItem(Cu),sessionStorage.removeItem(Ef),l("locked")},children:"Sign in with a different token"})]})}):o==="locked"?e.jsx("div",{className:"min-h-screen flex items-center justify-center bg-muted/30 px-4",children:e.jsxs("div",{className:"w-full max-w-sm bg-card border border-border shadow-lg p-8",children:[e.jsxs("div",{className:"flex flex-col items-center gap-3 mb-6",children:[e.jsx("div",{className:"w-12 h-12 rounded-full bg-primary/10 flex items-center justify-center",children:e.jsx(so,{size:22,className:"text-primary"})}),e.jsxs("div",{className:"text-center",children:[e.jsx("h1",{className:"font-bold text-foreground text-lg",children:"Admin Access"}),e.jsx("p",{className:"text-muted-foreground text-sm mt-0.5",children:e.jsx(_,{devId:"f6e648",guard:{file:"src/components/AdminGuard.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionH
634ash:"sha256:9a78e38970c446bc2c1c8229ce705be1015fc164c034a3383a5538551b659702"},children:a})})]})]}),e.jsxs("form",{onSubmit:A,className:"flex flex-col gap-3",children:[e.jsx("label",{className:"text-sm font-medium text-foreground",htmlFor:"admin-token",children:"Admin Token"}),e.jsxs("div",{className:"relative",children:[e.jsx("input",{id:"admin-token",type:x?"text":"password",value:m,onChange:S=>p(S.target.value),placeholder:"Enter admin token",autoComplete:"current-password",className:"w-full border border-border bg-background text-foreground px-3 py-2 pr-10 text-sm focus:outline-none focus:border-primary",disabled:w}),e.jsx("button",{type:"button",onClick:()=>b(S=>!S),className:"absolute right-2 top-1/2 -translate-y-1/2 text-muted-foreground hover:text-foreground",tabIndex:-1,"aria-label":x?"Hide token":"Show token",children:e.jsx(_,{devId:"67b1c4",guard:{file:"src/components/AdminGuard.tsx",tagName:"button",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:7f5ccd2857b780333ef3b6e53b2171d29d7956b7c340139221c3efcb5dcf08c2"},children:x?e.jsx(to,{size:15}):e.jsx(xa,{size:15})})})]}),y&&e.jsx("p",{className:"text-destructive text-xs",children:e.jsx(_,{devId:"e8bd44",guard:{file:"src/components/AdminGuard.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:ca00fccfb408989eddc401062c4d1219a6aceb6b9b55412357f1790862e8f178"},children:y})}),e.jsxs("button",{type:"submit",disabled:w||!m.trim(),className:"bg-primary text-white font-bold py-2 text-sm uppercase hover:opacity-90 transition-opacity disabled:opacity-50 disabled:cursor-not-allowed flex items-center justify-center gap-2",children:[w&&e.jsx(Rt,{size:14,className:"animate-spin"}),w?"Verifying…":"Enter Dashboard"]})]}),e.jsx("p",{className:"text-center text-xs text-muted-foreground mt-5",children:"Total Horse Channel · Admin Area"})]})}):e.jsx(c9.Provider,{value:d,children:t})}function d9(){return e.jsx(kr,{pageTitle:"WDAA Orders – Admin",children:e.jsx(u9,{})})}function u9(){const[t,a]=g.useState([]),[r,o]=g.useState(!0),[l,d]=g.useState(""),[u,m]=g.useState("all"),[p,x]=g.useState(new Set),[b,y]=g.useState(null),v=g.useCallback(async()=>{o(!0),d("");try{const E=await fetch("/api/admin/wdaa-orders",{credentials:"include"});if(!E.ok)throw new Error(`HTTP ${E.status}`);const U=await E.json();a([...U].reverse())}catch(E){d(`Failed to load orders: ${String(E)}`)}finally{o(!1)}},[]);g.useEffect(()=>{v()},[v]);async function w(E,U){y(E);try{const q=await fetch("/api/admin/wdaa-orders/complete",{method:"POST",credentials:"include",headers:{"Content-Type":"application/json"},body:JSON.stringify({orderId:E,completed:!U})});if(!q.ok)throw new Error(`HTTP ${q.status}`);a(H=>H.map(J=>J.id===E?{...J,completed:!U}:J))}catch(q){alert(`Failed to update order: ${String(q)}`)}finally{y(null)}}function C(E){x(U=>{const q=new Set(U);return q.has(E)?q.delete(E):q.add(E),q})}const A=t.filter(E=>u==="pending"?!E.completed:u==="completed"?E.completed:!0),S=t.filter(E=>!E.completed).length,z=t.filter(E=>E.completed).length,T=t.filter(E=>!!E.paypalCaptureId).reduce((E,U)=>E+(U.totalAmount??0),0),M=t.filter(E=>!!E.paypalCaptureId).reduce((E,U)=>E+(U.totalVideos??0),0);function P(E){try{return new Date(E).toLocaleString("en-US",{timeZone:"America/New_York",month:"short",day:"numeric",year:"numeric",hour:"numeric",minute:"2-digit",hour12:!0})}catch{return E}}return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"WDAA Orders – Admin – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Admin panel for managing WDAA video orders."}),e.jsx("meta",{name:"robots",content:"noindex,nofollow"})]}),e.jsx("div",{className:"min-h-screen bg-background",children:e.jsxs("div",{className:"max-w-[1200px] mx-auto px-4 py-6",children:[e.jsxs("div",{className:"flex items-center justify-between mb-6",children:[e.jsxs("div",{children:[e.jsx("h1",{className:"text-2xl font-bold text-foreground",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"61758f",guard:{file:"src/pages/admin/wdaa-orders.tsx",tagName:"h1",sourceKind:"content-key",contentKey:"admin_wdaa_orders.pageTitle",contentKeyTemplate:null,expressionH
634ash:null},children:Bi.pageTitle})}),e.jsx("p",{className:"text-sm text-muted-foreground mt-0.5",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"48e5c6",guard:{file:"src/pages/admin/wdaa-orders.tsx",tagName:"p",sourceKind:"content-key",contentKey:"admin_wdaa_orders.pageSubtitle",contentKeyTemplate:null,expressionHash:null},children:Bi.pageSubtitle})})]}),e.jsxs("button",{onClick:v,disabled:r,className:"flex items-center gap-2 px-4 py-2 border border-border text-sm font-semibold text-foreground hover:bg-muted transition-colors disabled:opacity-50",children:[e.jsx($0,{size:14,className:r?"animate-spin":""}),Bi.refreshLabel]})]}),e.jsxs("div",{className:"grid grid-cols-2 md:grid-cols-4 gap-3 mb-6",children:[e.jsxs("div",{className:"border border-border bg-card p-4 text-center",children:[e.jsx("div",{className:"text-2xl font-bold text-foreground",children:String(t.length)}),e.jsx("div",{className:"text-xs text-muted-foreground uppercase tracking-wide mt-1",children:Bi.statTotalOrders})]}),e.jsxs("div",{className:"border border-border bg-card p-4 text-center",children:[e.jsx("div",{className:"text-2xl font-bold text-primary",children:String(S)}),e.jsx("div",{className:"text-xs text-muted-foreground uppercase tracking-wide mt-1",children:Bi.statPending})]}),e.jsxs("div",{className:"border border-border bg-card p-4 text-center",children:[e.jsx("div",{className:"text-2xl font-bold text-green-600",children:String(z)}),e.jsx("div",{className:"text-xs text-muted-foreground uppercase tracking-wide mt-1",children:Bi.statCompleted})]}),e.jsxs("div",{className:"border border-border bg-card p-4 text-center",children:[e.jsx("div",{className:"text-2xl font-bold text-green-600",children:`$${T}`}),e.jsx("div",{className:"text-xs text-muted-foreground",children:`${M} video${M!==1?"s":""}`}),e.jsx("div",{className:"text-xs text-muted-foreground uppercase tracking-wide mt-1",children:Bi.statRevenue})]})]}),e.jsx("div",{className:"flex gap-2 mb-4 border-b border-border pb-3",children:["all","pending","completed"].map(E=>e.jsxs("button",{onClick:()=>m(E),className:`px-4 py-1.5 text-sm font-semibold capitalize border transition-colors ${u===E?"bg-primary text-white border-primary":"bg-card text-muted-foreground border-border hover:border-primary hover:text-primary"}`,children:[E,E==="pending"&&S>0&&e.jsx("span",{className:"ml-1.5 bg-primary text-white text-xs rounded-full px-1.5 py-0.5",children:S})]},E))}),r&&e.jsx("div",{className:"flex justify-center py-16",children:e.jsx($0,{size:20,className:"animate-spin text-muted-foreground"})}),!r&&l&&e.jsx("div",{className:"border border-destructive bg-destructive/10 text-destructive text-sm px-4 py-3 mb-4",children:l}),!r&&!l&&A.length===0&&e.jsx("p",{className:"text-muted-foreground text-sm py-12 text-center",children:"No orders found."}),!r&&!l&&e.jsx("div",{className:"space-y-3",children:A.map(E=>{const U=p.has(E.id),q=b===E.id;return e.jsxs("div",{className:`border bg-card transition-colors ${E.completed?"border-green-300":"border-border"}`,children:[e.jsxs("div",{className:"flex items-center gap-3 px-4 py-3",children:[e.jsx("span",{className:`shrink-0 text-xs font-bold px-2 py-0.5 ${E.paypalCaptureId?E.completed?"bg-green-100 text-green-700":"bg-primary/10 text-primary":"bg-yellow-100 text-yellow-800"}`,children:E.paypalCaptureId?E.completed?"✓ DONE":"PENDING":"⚠ NO PAYMENT"}),e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("div",{className:"font-semibold text-sm text-foreground truncate",children:E.name}),e.jsxs("div",{className:"flex flex-wrap items-center gap-x-3 gap-y-0.5 mt-0.5",children:[e.jsxs("span",{className:"flex items-center gap-1 text-xs text-muted-foreground",children:[e.jsx(nn,{size:11}),e.jsx("a",{href:`mailto:${E.email}`,className:"hover:text-primary hover:underline",children:E.email})]}),E.phone&&e.jsxs("span",{className:"flex items-center gap-1 text-xs text-muted-foreground",children:[e.jsx(lg,{size:11}),E.phone]}),e.jsxs("span",{className:"flex items-center gap-1 text-xs text-muted-foreground",children:[e.jsx(CC,{size:11}),P(E.submittedAt)]})]})]}),e.jsxs("div",{className:"shrink-0 text-right hidden sm:block",children:[e.jsxs("div",{className:"flex items-center gap-1 font-bold text-sm text-foreground justify-end",children:[e.jsx(AC,{size:13}),E.totalAmount,".00"]}),e.jsxs("div",{className:"text-xs text-muted-foreground",children:[E.totalVideos," video",E.totalVideos!==1?"s":""," · ",E.horses.length," horse",E.horses.length!==1?"s":""]})]}),e.jsxs("div",{className:"shrink-0 flex items-center gap-2",children:[e.jsx("button",{onClick:()=>w(E.id,E.completed),disabled:q,className:`text-xs font-semibold px-3 py-1.5 border transition-colors disabled:opacity-50 ${E.completed?"border-border text-muted-foreground hover:border-primary hover:text-primary":"border-green-500 text-green-600 hover:bg-green-500 hover:text-white"}`,children:q?"…":E.completed?"Mark Pending":"Mark Done"}),e.jsx("button",{onClick:()=>C(E.id),className:"p-1.5 border border-border text-muted-foreground hover:text-foreground hover:border-foreground transition-colors","aria-label":U?"Collapse order":"Expand order",children:U?e.jsx(Zc,{size:14}):e.jsx($n,{size:14})})]})]}),U&&e.jsxs("div",{className:"border-t border-border px-4 py-4 bg-muted/30",children:[e.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-3 mb-3",children:E.horses.map((H,J)=>e.jsxs("div",{className:"border border-border bg-card p-3 text-sm",children:[e.jsxs("div",{className:"font-bold text-foreground mb-1",children:["Horse ",J+1,": ",H.horseName||"(unnamed)",H.horseColorBreed&&e.jsxs("span",{className:"font-normal text-muted-foreground",children:[" — ",H.horseColorBreed]})]}),e.jsxs("div",{className:"text-xs text-muted-foreground mb-2 space-y-0.5",children:[e.jsxs("div",{children:["Rider: ",e.jsx("span",{className:"text-foreground",children:H.ridersName||"—"})]}),e.jsxs("div",{children:["Number: ",e.jsxs("span",{className:"text-foreground",children:["#",H.riderNumber||"—"]})]}),e.jsxs("div",{children:["Wearing: ",e.jsx("span",{className:"text-foreground",children:H.colorWearing||"—"})]})]}),e.jsx("div",{className:"space-y-0.5",children:H.classes.map((B,Y)=>e.jsxs("div",{className:"flex gap-2 text-xs",children:[e.jsxs("span",{className:"text-muted-foreground w-14 shrink-0",children:["Class ",Y+1,":"]}),e.jsx("span",{className:"text-foreground",children:B.className||"(not specified)"})]},Y))})]},J))}),E.paypalOrderId&&e.jsxs("p",{className:"text-xs text-muted-foreground",children:["PayPal Order ID: ",e.jsx("span",{className:"font-mono",children:E.paypalOrderId})]}),E.paypalCaptureId?e.jsxs("p",{className:"text-xs text-green-700 font-semibold",children:["PayPal Capture ID (transaction): ",e.jsx("span",{className:"font-mono",children:E.paypalCaptureId})]}):e.jsx("p",{className:"text-xs text-yellow-700 font-semibold",children:"⚠ No PayPal Capture ID — this order has no confirmed payment."}),e.jsxs("p",{className:"text-xs text-muted-foreground mt-1",children:["Order ID: ",e.jsx("span",{className:"font-mono",children:E.id})]})]})]},E.id)})})]})})]})}const m9=["https://www.youtube.com","https://youtube.com","https://www.youtube-nocookie.com","https://youtube-nocookie.com","https://player.vimeo.com","https://rumble.com","https://app.box.c
634om","https://totalhorsechannel.box.com","https://iframe.dacast.com"],h9=new Set(["src","id","width","height","frameborder","allowfullscreen","allow","title","loading","referrerpolicy","class","scrolling","webkitallowfullscreen","mozallowfullscreen","oallowfullscreen","msallowfullscreen"]);function M2(t){return/youtube\.com|youtu\.be/i.test(t)?"youtube":/rumble\.com/i.test(t)?"rumble":/vimeo\.com/i.test(t)?"vimeo":/box\.com/i.test(t)?"box":/dacast\.com/i.test(t)?"dacast":"other"}function U2(t,a){let r;try{r=new URL(t)}catch{throw new Error(`${a}: not a valid URL.`)}if(r.protocol!=="https:")throw new Error(`${a}: only https:// URLs are allowed.`);const o=t.toLowerCase();if(o.includes("javascript:")||o.includes("data:")||o.includes("vbscript:"))throw new Error(`${a}: dangerous scheme detected.`);return r}function xx(t){const a=t.origin;if(!m9.some(r=>a===r||a.endsWith("."+r.replace("https://",""))))throw new Error(`Embed origin "${a}" is not on the allowed list. Supported: YouTube, Rumble, Vimeo, Box.`)}function p9(t){var r,o;let a=t.searchParams.get("v")||(t.hostname==="youtu.be"?t.pathname.slice(1):null)||(t.pathname.startsWith("/live/")?(r=t.pathname.split("/live/")[1])==null?void 0:r.split("?")[0]:null)||(t.pathname.startsWith("/embed/")?(o=t.pathname.split("/embed/")[1])==null?void 0:o.split("?")[0]:null);if(!a)throw new Error("Could not extract YouTube video ID from URL.");return a=a.split("?")[0].split("&")[0].split("#")[0],`https://www.youtube.com/embed/${a}?rel=0`}function f9(t){if(t.pathname.startsWith("/embed/"))return t.origin+t.pathname.replace(/\/?$/,"/");const a=t.pathname.match(/^\/([vV][A-Za-z0-9]+)/);if(a)return`https://rumble.com/embed/${a[1]}/`;throw new Error("Could not convert Rumble URL to embed. Paste a URL like rumble.com/vXXXXX-title.html or a full Rumble embed iframe.")}function x9(t){if(t.hostname==="player.vimeo.com")return t.href;const a=t.pathname.match(/\/(\d+)/);if(!a)throw new Error("Could not extract Vimeo video ID from URL.");return`https://player.vimeo.com/video/${a[1]}`}function g9(t){return t.pathname.startsWith("/embed/")?t.href:`https://app.box.com${t.pathname.replace(/^\/(s|v)\//,"/embed/s/")}`}function b9(t){const a=U2(t,"Video URL"),r=M2(t);let o;switch(r){case"youtube":o=p9(a);break;case"rumble":o=f9(a);break;case"vimeo":o=x9(a);break;case"box":o=g9(a);break;case"dacast":xx(a),o=t;break;default:xx(a),o=t}return{src:o,source:r}}function P2(t,a="Live Event Video",r){return r==="rumble"?`<iframe class="rumble" width="640" height="360" src="${t}" frameborder="0" allowfullscreen></iframe>`:`<iframe src="${t}" width="100%" height="100%" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" allowfullscreen loading="lazy" referrerpolicy="no-referrer-when-downgrade" title="${a.replace(/"/g,"&quot;")}"></iframe>`}function y9(t,a){const r=t.trim();if(!/^<iframe[\s>]/i.test(r))throw new Error("Embed code must start with <iframe …>.");const o=/\s([\w-]+)(?:\s*=\s*(?:"([^"]*)"|'([^']*)'|([^\s>]+)))?/gi,l={};let d;for(;(d=o.exec(r))!==null;){const v=d[1].toLowerCase(),w=d[2]??d[3]??d[4]??"";l[v]=w}const u=l.src;if(!u)throw new Error("iframe embed code is missing a src attribute.");const m=U2(u,"iframe src"),p=M2(u);p!=="other"&&xx(m);const x=[],b=new Set(["allowfullscreen","webkitallowfullscreen","mozallowfullscreen","oallowfullscreen","msallowfullscreen"]);for(const[v,w]of Object.entries(l))h9.has(v)&&(v==="src"?x.push(`src="${u}"`):b.has(v)?x.push(v):x.push(`${v}="${w.replace(/"/g,"&quot;")}"`));if(p==="rumble"){const v=l.src??"";return{embedHtml:P2(v,a,"rumble"),source:p}}return l.width||x.push('width="100%"'),l.height||x.push('height="100%"'),l.title||x.push(`title="${a.replace(/"/g,"&quot;")}"`),l.loading||x.push('loading="lazy"'),{embedHtml:`<iframe ${x.join(" ")}></iframe>`,source:p}}function v9(t,a){const r=t.trim();if(!r)throw new Error("Video URL or embed code is required.");if(/^<iframe[\s>]/i.test(r))return y9(r,a);const{src:o,source:l}=b9(r);return{embedHtml:P2(o,a,l),source:l}}function K2(t){try{return v9(t,"preview"),null}catch(a){return a instanceof Error?a.message:"Invalid embed input."}}const Sn=[{group:"Breeds",items:["Akhal-Teke","American Quarter Horse","American Saddlebred","Andalusian","Anglo-Arab","Appaloosa","Arabian","Barb (Barbe)","Belgian Draft","Campolina","Cavalo Crioulo","Clydesdale","Connemara","Draft Horse","Fjord","Friesian","Gypsy Vanner","Hackney","Haflinger","Hanoverian","Icelandic","Irish Sport Horse","Kentucky Mountain Saddle Horse","Lipizzan","Lusitano","Mangalarga Marchador","Miniature Horse","Missouri Fox Trotter","Morgan","Mustang","National Show Horse","Paint Horse","Paso Fino","Percheron","Peruvian Paso","Pinto","Pony","Rocky Mountain Horse","Shetland Pony","Shire","Standardbred","Straight Egyptian Arabian","Tennessee Walking Horse","Thoroughbred","Trakehner","Warmblood","Welsh Pony"]},{group:"Disciplines / Other",items:["Barrel Racing","Campdraft","Cowboy Dressage","Cow Horse","Cross Country","Cutting Horse","Dressage","Dressage to Music / Freestyle","Driving","Endurance","Eventing","Farms","Foals","4-H","Halter","Harness Racing","Horse For Sale","Horse Racing","Horse Sale","Horse Show","Hunter/Jumper","Mounted Archery","Mounted Shooting","Horse Music Videos","Podcast","Polo","Ranch Riding","Reined Cow Horse","Reining","Rodeo","Roping","Show Jumping","Sporthorse","Trail","Vaulting","Western Dressage","Western Pleasure","Working Equitation","Other / General"]}];Sn.flatMap(t=>t.items);function Zo(t){if(!t)return[];try{const a=JSON.parse(t);return Array.isArray(a)?a.filter(r=>typeof r=="string"&&r.trim().length>0).slice(0,2):[]}catch{return[]}}const j9={title:"",startAt:"",source:"youtube",videoInput:"",description:"",thumbnailUrl:"",thumbnailFile:null,thumbnailMode:"url",published:!1,isArchived:!1,videoType:"video",providedBy:"",providerLink:"",location:"",moreInfoUrl:"",category:"",extraCat1:"",extraCat2:"",extraCat3:"",postAs:"thc"},w9=[{value:"youtube",label:"YouTube"},{value:"rumble",label:"Rumble"},{value:"vimeo",label:"Vimeo"},{value:"box",label:"Box"},{value:"dacast",label:"Dacast / Seehorse"},{value:"other",label:"Other"}],N9=[{value:"thc",label:"Total Horse Channel"},{value:"raindancer",label:"RainDancer Video"},{value:"nsb",label:"National Sports Broadcasting"}];function S9(t,a){try{const r=new Date(t);
634if(!isNaN(r.getTime())&&!Va(r))return r.toLocaleString("en-US",{month:"short",day:"numeric",year:"numeric",hour:"numeric",minute:"2-digit",hour12:!0});if(a){const o=td(a);if(o)return o.toLocaleDateString("en-US",{month:"short",day:"numeric",year:"numeric"})}return""}catch{return""}}function C9(t){const a=[];let r="",o=!1;for(let p=0;p<t.length;p++){const x=t[p];x==='"'?o&&t[p+1]==='"'?(r+='"',p++):o=!o:(x===`
635`||x==="\r")&&!o?(x==="\r"&&t[p+1]===`
636`&&p++,a.push(r),r=""):r+=x}r&&a.push(r);function l(p){const x=[];let b="",y=!1;for(let v=0;v<p.length;v++){const w=p[v];w==='"'?y&&p[v+1]==='"'?(b+='"',v++):y=!y:w===","&&!y?(x.push(b.trim()),b=""):b+=w}return x.push(b.trim()),x}const d=a.filter(p=>p.trim());if(d.length<2)return[];const u=l(d[0]).map(p=>p.toLowerCase().trim().replace(/\s+/g,"_")),m=[];for(let p=1;p<d.length;p++){const x=l(d[p]),b={};u.forEach((y,v)=>{b[y]=x[v]??""}),m.push(b)}return m}function k9({onClose:t,onImported:a}){const r=g.useRef(null),[o,l]=g.useState([]),[d,u]=g.useState(""),[m,p]=g.useState(""),[x,b]=g.useState(!1),[y,v]=g.useState(null),[w,C]=g.useState(!1);function A(T){var E;const M=(E=T.target.files)==null?void 0:E[0];if(!M)return;p(""),v(null),u(M.name);const P=new FileReader;P.onload=U=>{var q;try{const H=(q=U.target)==null?void 0:q.result,J=C9(H);if(J.length===0){p("No data rows found. Make sure the file has a header row and at least one data row."),l([]);return}l(J)}catch{p("Could not parse the CSV file. Please check the format."),l([])}},P.readAsText(M)}async function S(){if(o.length!==0){b(!0),v(null);try{const T=await fetch("/api/live-events/import-csv",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({rows:o})}),M=await T.json();if(!T.ok)throw new Error(M.error??"Import failed.");v(M),(M.imported>0||M.updated>0)&&a()}catch(T){p(T instanceof Error?T.message:"Import failed.")}finally{b(!1)}}}const z=["title","date","start_time","source","video_url_or_iframe","thumbnail_url","category","provided_by","provider_link","country","city_venue","description","type","status"];return e.jsx("div",{className:"fixed inset-0 z-50 flex items-start justify-center bg-black/60 overflow-y-auto py-8 px-4",children:e.jsxs("div",{className:"bg-white w-full max-w-[640px] rounded shadow-xl",children:[e.jsxs("div",{className:"flex items-center justify-between px-5 py-4 border-b border-gray-200",children:[e.jsxs("h2",{className:"font-bold text-gray-900 text-base flex items-center gap-2",children:[e.jsx(Zf,{size:16,className:"text-primary"}),"Import Events from CSV"]}),e.jsx("button",{onClick:t,className:"text-gray-400 hover:text-gray-700 transition-colors",children:e.jsx(Vt,{size:18})})]}),e.jsxs("div",{className:"px-5 py-5 flex flex-col gap-5",children:[e.jsxs("div",{className:"bg-gray-50 border border-gray-200 rounded p-3",children:[e.jsx("p",{className:"text-xs font-semibold text-gray-600 mb-1.5 uppercase tracking-wide",children:"Expected CSV columns (in any order):"}),e.jsx("p",{className:"text-xs text-gray-500 font-mono leading-relaxed break-all",children:e.jsx(_,{devId:"4ee221",guard:{file:"src/pages/admin/live-events.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:57839353e60372b4032f277c86554fb178387011a76e8868e1c94540132ae1ab"},children:z.join(", ")})}),e.jsxs("div",{className:"mt-2 text-xs text-gray-500 flex flex-col gap-0.5",children:[e.jsxs("span",{children:[e.jsx("strong",{children:"type"}),": ",e.jsx("code",{children:"Live"})," or ",e.jsx("code",{children:"Video"})]}),e.jsxs("span",{children:[e.jsx("strong",{children:"status"}),": ",e.jsx("code",{children:"Current"})," = not archived · anything else = archived"]}),e.jsxs("span",{children:["All imported rows default to ",e.jsx("strong",{children:"Published"}),". Duplicate titles are ",e.jsx("strong",{children:"updated"})," (date, thumbnail, category, URL, status)."]})]})]}),e.jsxs("div",{children:[e.jsx("label",{className:"block text-xs font-semibold text-gray-700 mb-1.5",children:"Select CSV file"}),e.jsxs("div",{className:"flex items-center gap-3",children:[e.jsxs("button",{onClick:()=>{var T;return(T=r.current)==null?void 0:T.click()},className:"flex items-center gap-2 px-4 py-2 border border-gray-300 rounded text-sm text-gray-700 hover:bg-gray-50 transition-colors",children:[e.jsx(ln,{size:14}),"Choose File"]}),d&&e.jsx("span",{className:"text-sm text-gray-600 truncate max-w-[280px]",children:e.jsx(_,{devId:"ed7437",guard:{file:"src/pages/admin/live-events.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionH
636ash:"sha256:163ae561517b145d7cf4ab863737302346045717a3d5e3d3a5aa55a91eab88fe"},children:d})})]}),e.jsx("input",{ref:r,type:"file",accept:".csv,text/csv",className:"hidden",onChange:A})]}),m&&e.jsxs("div",{className:"flex items-start gap-2 bg-red-50 border border-red-200 text-red-700 text-sm px-3 py-2.5 rounded",children:[e.jsx(Xi,{size:14,className:"mt-0.5 shrink-0"}),e.jsx("span",{children:e.jsx(_,{devId:"9e67c4",guard:{file:"src/pages/admin/live-events.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:fe34f8cd61437c52ace2e641054d7ce7b612726586b25b4834af49d0da2ff560"},children:m})})]}),o.length>0&&!y&&e.jsxs("div",{className:"flex items-center gap-2 text-sm text-gray-700 bg-blue-50 border border-blue-200 px-3 py-2.5 rounded",children:[e.jsx(kn,{size:14,className:"text-blue-500 shrink-0"}),e.jsxs("span",{children:[e.jsx("strong",{children:o.length})," row",o.length!==1?"s":""," parsed and ready to import."]})]}),y&&e.jsxs("div",{className:"flex flex-col gap-2",children:[e.jsxs("div",{className:"flex items-center gap-2 text-sm bg-green-50 border border-green-200 px-3 py-2.5 rounded text-green-800",children:[e.jsx(kn,{size:14,className:"text-green-600 shrink-0"}),e.jsxs("span",{children:[e.jsx("strong",{children:y.imported})," imported · ",e.jsx("strong",{children:y.updated??0})," updated · ",e.jsx("strong",{children:y.skipped})," skipped",y.errors.length>0&&e.jsxs(e.Fragment,{children:[" · ",e.jsx("strong",{className:"text-red-600",children:y.errors.length})," error",y.errors.length!==1?"s":""]})]})]}),y.errors.length>0&&e.jsxs("div",{className:"border border-red-200 rounded overflow-hidden",children:[e.jsxs("button",{onClick:()=>C(T=>!T),className:"w-full flex items-center justify-between px-3 py-2 bg-red-50 text-red-700 text-xs font-semibold hover:bg-red-100 transition-colors",children:[e.jsxs("span",{children:["Show error details (",y.errors.length,")"]}),w?e.jsx(Zc,{size:13}):e.jsx($n,{size:13})]}),w&&e.jsx("div",{className:"max-h-[200px] overflow-y-auto",children:e.jsxs("table",{className:"w-full text-xs",children:[e.jsx("thead",{className:"bg-gray-50",children:e.jsxs("tr",{children:[e.jsx("th",{className:"px-3 py-1.5 text-left text-gray-600 font-semibold",children:"Row"}),e.jsx("th",{className:"px-3 py-1.5 text-left text-gray-600 font-semibold",children:"Title"}),e.jsx("th",{className:"px-3 py-1.5 text-left text-gray-600 font-semibold",children:"Reason"})]})}),e.jsx("tbody",{children:y.errors.map((T,M)=>e.jsxs("tr",{className:"border-t border-gray-100",children:[e.jsx("td",{className:"px-3 py-1.5 text-gray-500",children:T.row}),e.jsx("td",{className:"px-3 py-1.5 text-gray-700 max-w-[160px] truncate",children:T.title}),e.jsx("td",{className:"px-3 py-1.5 text-red-600",children:T.reason})]},M))})]})})]})]})]}),e.jsxs("div",{className:"flex items-center justify-end gap-3 px-5 py-4 border-t border-gray-200 bg-gray-50",children:[e.jsx("button",{onClick:t,className:"px-4 py-2 text-sm text-gray-600 hover:text-gray-900 transition-colors",children:e.jsx(_,{devId:"76e219",guard:{file:"src/pages/admin/live-events.tsx",tagName:"button",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:9868505db1e0e74ab01bb01177564921ad21d1ef9f1f2a7bc58fff9ae7b9c0b5"},children:y?"Close":"Cancel"})}),!y&&e.jsxs("button",{onClick:S,disabled:o.length===0||x,className:"flex items-center gap-2 px-5 py-2 bg-primary text-white text-sm font-semibold rounded hover:bg-primary/90 disabled:opacity-50 transition-colors",children:[x?e.jsx(Rt,{size:13,className:"animate-spin"}):e.jsx(Zf,{size:13}),x?"Importing…":`Import ${o.length>0?o.length+" rows":""}`]})]})]})})}function T9({initial:t,formId:a,onSave:r,onCancel:o,saving:l,error:d,isAdmin:u}){const m=!!t.title,[p,x]=g.useState(t),[b,y]=g.useState(""),[v,w]=g.useState(""),[C,A]=g.useState(""),[S,z]=g.useState(t.thumbnailUrl||""),T=g.useRef(null);function M(B){var D,W;const Y=B.trim();try{const I=new URL(Y);if(/youtube\.com|youtu\.be/i.test(I.hostname))return I.searchParams.get("v")||(I.hostname==="youtu.be"?I.pathname.slice(1).split("?")[0]:null)||(I.pathname.startsWith("/live/")?(D=I.pathname.split("/live/")[1])==null?void 0:D.split("?")[0]:null)||(I.pathname.startsWith("/embed/")?(W=I.pathname.split("/embed/")[1])==null?void 0:W.split("?")[0]:null)||null}catch{}const $=Y.match(/youtube\.com\/embed\/([a-zA-Z0-9_-]+)/);return $?$[1]:null}function P(B){const Y=B.trim(),$=Y.match(/rumble\.com\/embed\/([vV][A-Za-z0-9]+)/);if($)return $[1];const D=Y.match(/rumble\.com\/([vV][A-Za-z0-9]+)/);return D?D[1]:null}function E(B,Y){if(B==="videoInput"&&typeof Y=="string"){y("");const $=M(Y);if($){x(W=>{if(!(W.thumbnailFile||W.thumbnailUrl.trim())){const k=`https://img.youtube.com/vi/${$}/hqdefault.jpg`;return z(k),{...W,videoInput:Y,thumbnailUrl:k,thumbnailMode:"url"}}return{...W,videoInput:Y}});return}const D=P(Y);if(D){x(W=>{if(!(W.thumbnailFile||W.thumbnailUrl.trim())){const k=`https://sp.rmbl.ws/s8/1/${D}.jpg`;return z(k),{...W,videoInput:Y,thumbnailUrl:k,thumbnailMode:"url"}}return{...W,videoInput:Y}});return}}x($=>({...$,[B]:Y}))}function U(B){var D;const Y=(D=B.target.files)==null?void 0:D[0];if(w(""),!Y)return;if(!["image/jpeg","image/png","image/avif","image/webp"].includes(Y.type)){w("Only JPG, PNG, AVIF, or WebP files are allowed.");return}if(Y.size>5*1024*1024){w("File must be under 5 MB.");return}E("thumbnailFile",Y),E("thumbnailUrl","");const $=new FileReader;$.onload=W=>{var I;return z((I=W.target)==null?void 0:I.result)}
636,$.readAsDataURL(Y)}function q(B){E("thumbnailUrl",B.target.value),E("thumbnailFile",null),z(B.target.value),w("")}function H(B){const Y=B.target.value.trim();E("thumbnailUrl",Y),z(Y)}function J(B){if(B.preventDefault(),p.published){if(!p.videoInput.trim()){y("Add a URL or embed before publishing.");return}const Y=K2(p.videoInput);if(Y){y(Y);return}}if(!p.category.trim()){A("Please choose a category.");return}if(A(""),p.published&&!m&&!p.thumbnailFile&&!p.thumbnailUrl.trim()){w("A thumbnail is required. Upload an image or paste a URL.");return}w(""),r(p)}return e.jsx("div",{className:"fixed inset-0 z-50 flex items-start justify-center bg-black/60 overflow-y-auto py-8 px-4",children:e.jsxs("div",{className:"bg-white w-full max-w-[640px] rounded shadow-xl",children:[e.jsxs("div",{className:"flex items-center justify-between px-5 py-4 border-b border-gray-200",children:[e.jsx("h2",{className:"font-bold text-base text-gray-900",children:e.jsx(_,{devId:"d8b035",guard:{file:"src/pages/admin/live-events.tsx",tagName:"h2",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:ebd2a100165418770b6707454979472d917db114e7a55e051144b31b5d70a856"},children:m?"Edit Video / Live":"Add Video / Live"})}),e.jsx("button",{onClick:o,className:"text-gray-400 hover:text-gray-600 transition-colors",children:e.jsx(Vt,{size:18})})]}),e.jsxs("form",{onSubmit:J,noValidate:!0,className:"p-5 space-y-4",children:[d&&e.jsx("div",{className:"bg-red-50 border border-red-200 text-red-700 text-sm px-3 py-2 rounded",children:d}),e.jsxs("div",{children:[e.jsxs("label",{className:"block text-xs font-semibold text-gray-700 mb-1",children:["Title ",e.jsx("span",{className:"text-red-500",children:"*"})]}),e.jsx("input",{type:"text",value:p.title,onChange:B=>E("title",B.target.value),onBlur:B=>E("title",B.target.value.trim()),required:!0,maxLength:500,placeholder:"e.g. WDAA World Championship Show – Ring 1 LIVE",className:"w-full border border-gray-300 rounded px-3 py-2 text-sm focus:outline-none focus:border-primary"})]}),u&&e.jsxs("div",{children:[e.jsx("label",{className:"block text-xs font-semibold text-gray-700 mb-1",children:"Post as (Owner)"}),e.jsx("select",{value:p.postAs,onChange:B=>E("postAs",B.target.value),className:"w-full border border-gray-300 rounded px-3 py-2 text-sm focus:outline-none focus:border-primary bg-white",children:N9.map(B=>e.jsx("option",{value:B.value,children:B.label},B.value))}),e.jsx("p",{className:"text-gray-400 text-xs mt-1",children:"Determines the Follow button, Provided By credit, and profile listing for this video."})]}),e.jsxs("div",{children:[e.jsx("label",{className:"block text-xs font-semibold text-gray-700 mb-1",children:"Start Date & Time"}),e.jsx("input",{type:"datetime-local",value:p.startAt,onChange:B=>E("startAt",B.target.value),className:"w-full border border-gray-300 rounded px-3 py-2 text-sm focus:outline-none focus:border-primary"})]}),e.jsxs("div",{children:[e.jsxs("label",{className:"block text-xs font-semibold text-gray-700 mb-1",children:["Video Source ",e.jsx("span",{className:"text-red-500",children:"*"})]}),e.jsx("select",{value:p.source,onChange:B=>E("source",B.target.value),className:"w-full border border-gray-300 rounded px-3 py-2 text-sm focus:outline-none focus:border-primary bg-white",children:w9.map(B=>e.jsx("option",{value:B.value,children:B.label},B.value))})]}),e.jsxs("div",{children:[e.jsxs("label",{className:"block text-xs font-semibold text-gray-700 mb-1",children:["Video URL or Embed Code"," ",p.published?e.jsx("span",{className:"text-red-500",children:"*"}):e.jsx("span",{className:"text-gray-400 font-normal",children:"(required to publish)"})]}),e.jsx("textarea",{value:p.videoInput,onChange:B=>E("videoInput",B.target.value),onBlur:B=>E("videoInput",B.target.value.trim()),rows:4,placeholder:"Paste a YouTube watch URL (youtube.com/watch?v=... or youtu.be/...), Rumble URL, Vimeo URL, or any full <iframe> embed code.",className:"w-full border border-gray-300 rounded px-3 py-2 text-sm font-mono focus:outline-none focus:border-primary resize-y"}),b&&e.jsx("p",{className:"text-red-600 text-xs mt-1",children:e.jsx(_,{devId:"12e9f5",guard:{file:"src/pages/admin/live-events.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionH
636ash:"sha256:08ef0c41d4772e8c5dfca14ebc47b570791d6ab046ff6678be42e7e45f0f0f12"},children:b})}),e.jsxs("p",{className:"text-gray-400 text-xs mt-1",children:["YouTube watch URLs (",e.jsx("code",{children:"youtube.com/watch?v=…"})," or ",e.jsx("code",{children:"youtu.be/…"}),") are converted to embed URLs automatically. Rumble, Vimeo, Box, and Dacast URLs also work, as does any full ",e.jsx("code",{children:"<iframe>"})," embed code (including Dacast / Seehorse iframes)."]})]}),e.jsxs("div",{children:[e.jsx("label",{className:"block text-xs font-semibold text-gray-700 mb-1",children:"Short Description"}),e.jsx("textarea",{value:p.description,onChange:B=>E("description",B.target.value),rows:3,maxLength:1e3,placeholder:"Optional — shown on the public event page.",className:"w-full border border-gray-300 rounded px-3 py-2 text-sm focus:outline-none focus:border-primary resize-y"})]}),e.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-2 gap-3",children:[e.jsxs("div",{children:[e.jsx("label",{className:"block text-xs font-semibold text-gray-700 mb-1",children:"Provided By"}),e.jsx("input",{type:"text",value:p.providedBy,onChange:B=>E("providedBy",B.target.value),onBlur:B=>E("providedBy",B.target.value.trim()),maxLength:200,placeholder:"e.g. Fairmount Park Casino & Racing",className:"w-full border border-gray-300 rounded px-3 py-2 text-sm focus:outline-none focus:border-primary"}),e.jsx("p",{className:"text-gray-400 text-xs mt-1",children:"The farm, track, show, or channel — not the platform."})]}),e.jsxs("div",{children:[e.jsx("label",{className:"block text-xs font-semibold text-gray-700 mb-1",children:"Provider Link"}),e.jsx("input",{type:"url",value:p.providerLink,onChange:B=>E("providerLink",B.target.value),maxLength:500,placeholder:"https://www.fairmountpark.com",className:"w-full border border-gray-300 rounded px-3 py-2 text-sm focus:outline-none focus:border-primary"}),e.jsx("p",{className:"text-gray-400 text-xs mt-1",children:"YouTube channel or provider website URL."})]})]}),e.jsxs("div",{children:[e.jsx("label",{className:"block text-xs font-semibold text-gray-700 mb-1",children:"Location"}),e.jsx("input",{type:"text",value:p.location,onChange:B=>E("location",B.target.value),onBlur:B=>E("location",B.target.value.trim()),maxLength:200,placeholder:"e.g. Lazy E Arena, Guthrie OK",className:"w-full border border-gray-300 rounded px-3 py-2 text-sm focus:outline-none focus:border-primary"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"block text-xs font-semibold text-gray-700 mb-1",children:"More Information URL"}),e.jsx("input",{type:"url",value:p.moreInfoUrl,onChange:B=>E("moreInfoUrl",B.target.value),maxLength:500,placeholder:"https://example.com/event-info",className:"w-full border border-gray-300 rounded px-3 py-2 text-sm focus:outline-none focus:border-primary"})]}),e.jsxs("div",{className:"flex flex-col gap-2",children:[e.jsxs("div",{children:[e.jsxs("label",{className:"block text-xs font-semibold text-gray-700 mb-1",children:["Category ",e.jsx("span",{className:"text-red-500",children:"*"})]}),e.jsxs("select",{value:p.category,onChange:B=>{E("category",B.target.value),A("")},className:`w-full border rounded px-3 py-2 text-sm focus:outline-none focus:border-primary bg-white ${C?"border-red-500":"border-gray-300"}`,children:[e.jsx("option",{value:"",children:"— Select primary category —"}),Sn.map(B=>e.jsx("optgroup",{label:B.group,children:B.items.map(Y=>e.jsx("option",{value:Y,children:Y},Y))},B.group))]}),C?e.jsx("p",{className:"text-red-600 text-xs mt-1",children:e.jsx(_,{devId:"69ebf5",guard:{file:"src/pages/admin/live-events.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:abb8bc7d9fb5bed45dddd65b76efe3b995d406dcdc623cd751b6eb238f9e5653"},children:C})}):e.jsx("p",{className:"text-gray-400 text-xs mt-1",children:"Primary — used for homepage rows and Top Categories."})]}),e.jsxs("div",{children:[e.jsxs("label",{className:"block text-xs font-semibold text-gray-700 mb-1",children:["Additional category ",e.jsx("span",{className:"text-gray-400 font-normal",children:"(optional)"})]}),e.jsxs("select",{value:p.extraCat1,onChange:B=>E("extraCat1",B.target.value),className:"w-full border border-gray-300 rounded px-3 py-2 text-sm focus:outline-none focus:border-primary bg-white",children:[e.jsx("option",{value:"",children:"— None —"}),Sn.map(B=>e.jsx("optgroup",{label:B.group,children:B.items.filter(Y=>Y!==p.category&&Y!==p.extraCat2).map(Y=>e.jsx("option",{value:Y,children:Y},Y))},B.group))]})]}),p.extraCat1&&e.jsxs("div",{children:[e.jsxs("label",{className:"block text-xs font-semibold text-gray-700 mb-1",children:["Additional category 2 ",e.jsx("span",{className:"text-gray-400 font-normal",children:"(optional)"})]}
636),e.jsxs("select",{value:p.extraCat2,onChange:B=>E("extraCat2",B.target.value),className:"w-full border border-gray-300 rounded px-3 py-2 text-sm focus:outline-none focus:border-primary bg-white",children:[e.jsx("option",{value:"",children:"— None —"}),Sn.map(B=>e.jsx("optgroup",{label:B.group,children:B.items.filter(Y=>Y!==p.category&&Y!==p.extraCat1).map(Y=>e.jsx("option",{value:Y,children:Y},Y))},B.group))]})]}),p.extraCat1&&p.extraCat2&&e.jsxs("div",{children:[e.jsxs("label",{className:"block text-xs font-semibold text-gray-700 mb-1",children:["Additional category 3 ",e.jsx("span",{className:"text-gray-400 font-normal",children:"(optional)"})]}),e.jsxs("select",{value:p.extraCat3,onChange:B=>E("extraCat3",B.target.value),className:"w-full border border-gray-300 rounded px-3 py-2 text-sm focus:outline-none focus:border-primary bg-white",children:[e.jsx("option",{value:"",children:"— None —"}),Sn.map(B=>e.jsx("optgroup",{label:B.group,children:B.items.filter(Y=>Y!==p.category&&Y!==p.extraCat1&&Y!==p.extraCat2).map(Y=>e.jsx("option",{value:Y,children:Y},Y))},B.group))]})]})]}),e.jsxs("div",{children:[e.jsxs("label",{className:"block text-xs font-semibold text-gray-700 mb-1",children:["Thumbnail",!m&&e.jsx("span",{className:"text-red-500",children:" *"}),m&&e.jsx("span",{className:"text-gray-400 font-normal",children:" — optional, leave blank to keep existing"})]}),e.jsxs("div",{className:"flex gap-0 mb-2 border border-gray-300 rounded overflow-hidden w-fit",children:[e.jsxs("button",{type:"button",onClick:()=>{E("thumbnailMode","upload")},className:`flex items-center gap-1.5 px-3 py-1.5 text-xs font-semibold transition-colors ${p.thumbnailMode==="upload"?"bg-primary text-white":"bg-white text-gray-600 hover:bg-gray-50"}`,children:[e.jsx(ln,{size:12})," Upload File"]}),e.jsxs("button",{type:"button",onClick:()=>{E("thumbnailMode","url")},className:`flex items-center gap-1.5 px-3 py-1.5 text-xs font-semibold transition-colors ${p.thumbnailMode==="url"?"bg-primary text-white":"bg-white text-gray-600 hover:bg-gray-50"}`,children:[e.jsx(Lc,{size:12})," Paste URL"]})]}),p.thumbnailMode==="upload"?e.jsxs("div",{children:[e.jsx("input",{ref:T,type:"file",accept:"image/jpeg,image/png,image/avif,image/webp",onChange:U,className:"hidden"}),e.jsxs("button",{type:"button",onClick:()=>{var B;return(B=T.current)==null?void 0:B.click()},className:"flex items-center gap-2 border border-dashed border-gray-300 rounded px-4 py-3 text-sm text-gray-500 hover:border-primary hover:text-primary transition-colors w-full",children:[e.jsx(ln,{size:14}),p.thumbnailFile?p.thumbnailFile.name:"Choose image…"]}),e.jsx("p",{className:"text-gray-400 text-xs mt-1",children:"Max 5 MB. JPG, PNG, AVIF, or WebP. For YouTube and Rumble, paste the URL above first — the thumbnail fills in automatically."})]}):e.jsxs("div",{children:[e.jsx("input",{type:"text",value:p.thumbnailUrl,onChange:q,onBlur:H,placeholder:"https://img.youtube.com/vi/VIDEO_ID/hqdefault.jpg or /airo-assets/uploads/…",className:"w-full border border-gray-300 rounded px-3 py-2 text-sm focus:outline-none focus:border-primary"}),e.jsx("p",{className:"text-gray-400 text-xs mt-1",children:"Paste a direct image URL or an /airo-assets/uploads/… path."})]}),v&&e.jsx("p",{className:"text-red-600 text-xs mt-1",children:e.jsx(_,{devId:"1622a2",guard:{file:"src/pages/admin/live-events.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:61e2c2aad3557dc14e77ecb04f6b4779519b56564a8d2def1c7d797d13704e02"},children:v})}),S&&e.jsx("div",{className:"mt-2",children:e.jsx("img",{src:S,alt:"Thumbnail preview",className:"h-20 w-auto rounded border border-gray-200 object-cover",onError:()=>z("")})})]}),e.jsxs("div",{className:"flex items-center gap-3 py-1",children:[e.jsx("button",{type:"button",onClick:()=>E("published",!p.published),className:`relative inline-flex h-5 w-9 items-center rounded-full transition-colors ${p.published?"bg-green-600":"bg-gray-300"}`,"aria-pressed":p.published,children:e.jsx("span",{className:`inline-block h-3.5 w-3.5 transform rounded-full bg-white shadow transition-transform ${p.published?"translate-x-4":"translate-x-1"}`})}),e.jsx("span",{className:"text-sm text-gray-700",children:e.jsx(_,{devId:"231c25",guard:{file:"src/pages/admin/live-events.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionH
636ash:"sha256:26f2b547aee7ff1bae5eecac8230f5f8eea61b125d026e0a232f4fafd7ce6f97"},children:p.published?e.jsx("span",{className:"text-green-700 font-medium",children:"Published — visible to the public"}):e.jsx("span",{className:"text-yellow-700 font-medium",children:"Draft — not visible to the public"})})})]}),e.jsxs("div",{className:"border-t border-gray-100 pt-3",children:[e.jsxs("label",{className:"block text-xs font-semibold text-gray-700 mb-2",children:["Type / Status ",e.jsx("span",{className:"text-red-500",children:"*"})]}),e.jsxs("div",{className:"grid grid-cols-2 gap-2",children:[e.jsxs("label",{className:`flex items-start gap-2.5 border rounded px-3 py-2.5 cursor-pointer transition-colors ${p.videoType==="upcoming"&&!p.isArchived?"border-blue-500 bg-blue-50":"border-gray-200 hover:bg-gray-50"}`,children:[e.jsx("input",{type:"radio",name:`typeStatus-${a}`,checked:p.videoType==="upcoming"&&!p.isArchived,onChange:()=>{E("videoType","upcoming"),E("isArchived",!1)},className:"mt-0.5 accent-blue-600 shrink-0"}),e.jsxs("div",{children:[e.jsx("p",{className:"text-xs font-semibold text-gray-800 leading-tight",children:"Upcoming"}),e.jsx("p",{className:"text-xs text-gray-500 mt-0.5",children:"Shows in Upcoming Live Events section with start date/time."})]})]}),e.jsxs("label",{className:`flex items-start gap-2.5 border rounded px-3 py-2.5 cursor-pointer transition-colors ${p.videoType==="live"&&!p.isArchived?"border-primary bg-primary/5":"border-gray-200 hover:bg-gray-50"}`,children:[e.jsx("input",{type:"radio",name:`typeStatus-${a}`,checked:p.videoType==="live"&&!p.isArchived,onChange:()=>{E("videoType","live"),E("isArchived",!1)},className:"mt-0.5 accent-primary shrink-0"}),e.jsxs("div",{children:[e.jsx("p",{className:"text-xs font-semibold text-gray-800 leading-tight",children:"Current (Live)"}),e.jsx("p",{className:"text-xs text-gray-500 mt-0.5",children:"Appears in Current Live Events, floats to top of category."})]})]}),e.jsxs("label",{className:`flex items-start gap-2.5 border rounded px-3 py-2.5 cursor-pointer transition-colors ${p.videoType==="video"&&!p.isArchived?"border-gray-600 bg-gray-50":"border-gray-200 hover:bg-gray-50"}`,children:[e.jsx("input",{type:"radio",name:`typeStatus-${a}`,checked:p.videoType==="video"&&!p.isArchived,onChange:()=>{E("videoType","video"),E("isArchived",!1)},className:"mt-0.5 accent-gray-600 shrink-0"}),e.jsxs("div",{children:[e.jsx("p",{className:"text-xs font-semibold text-gray-800 leading-tight",children:"Video"}),e.jsx("p",{className:"text-xs text-gray-500 mt-0.5",children:"Appears in Current Live Events under its category (not floated)."})]})]}),e.jsxs("label",{className:`flex items-start gap-2.5 border rounded px-3 py-2.5 cursor-pointer transition-colors ${p.isArchived?"border-orange-400 bg-orange-50":"border-gray-200 hover:bg-gray-50"}`,children:[e.jsx("input",{type:"radio",name:`typeStatus-${a}`,checked:p.isArchived,onChange:()=>{E("isArchived",!0)},className:"mt-0.5 accent-orange-500 shrink-0"}),e.jsxs("div",{children:[e.jsx("p",{className:"text-xs font-semibold text-gray-800 leading-tight",children:"Archive"}),e.jsx("p",{className:"text-xs text-gray-500 mt-0.5",children:"Moves to Live Event Archives. Not in Current or Upcoming."})]})]})]})]}),e.jsxs("div",{className:"flex items-center justify-end gap-3 pt-2 border-t border-gray-100",children:[e.jsx("button",{type:"button",onClick:o,className:"px-4 py-2 text-sm text-gray-600 hover:text-gray-900 transition-colors",children:"Cancel"}),e.jsx("button",{type:"button",disabled:l,onClick:()=>{if(!p.category.trim()){A("Please choose a category.");return}A(""),y(""),r({...p,published:!1})},className:"flex items-center gap-2 px-4 py-2 border border-gray-300 text-gray-700 text-sm font-medium rounded hover:bg-gray-50 transition-colors disabled:opacity-60",children:"Save draft"}),e.jsxs("button",{type:"submit",disabled:l,className:"flex items-center gap-2 px-5 py-2 bg-primary text-white text-sm font-semibold rounded hover:bg-primary/90 transition-colors disabled:opacity-60",children:[l?e.jsx(Rt,{size:14,className:"animate-spin"}):e.jsx(Ea,{size:14}),l?"Saving…":p.published?"Publish":"Save"]})]})]})]})})}const A9=[25,50];function E9({total:t,page:a,perPage:r,onPage:o,onPerPage:l}){const d=Math.max(1,Math.ceil(t/r)),u=[],m=p=>{u.includes(p)||u.push(p)};m(1),a-2>2&&u.push("ellipsis-start");for(let p=Math.max(2,a-1);p<=Math.min(d-1,a+1);p++)m(p);return a+2<d-1&&u.push("ellipsis-end"),d>1&&m(d),e.jsxs("div",{className:"flex flex-wrap items-center gap-2 mt-4 text-sm border-t border-gray-200 pt-3",children:[e.jsxs("div",{className:"flex items-center gap-1 text-xs text-gray-500 mr-2",children:[e.jsx("span",{children:"Show:"}),A9.map(p=>e.jsx("button",{onClick:()=>{l(p),o(1)},className:`px-2 py-0.5 border rounded text-xs ${r===p?"bg-primary text-white border-primary font-bold":"border-gray-300 hover:bg-gray-100"}`,children:p},p)),e.jsx("span",{className:"ml-1",children:"per page"})]}),d>1&&e.jsxs(e.Fragment,{children:[e.jsxs("button",{onClick:()=>o(a-1),disabled:a===1,className:"flex items-center gap-0.5 px-2 py-1 border border-gray-300 rounded hover:bg-gray-100 disabled:opacity-40 disabled:cursor-not-allowed text-xs",children:[e.jsx(En,{size:12})," Prev"]}),u.map(p=>typeof p=="string"?e.jsx("span",{className:"px-1 text-gray-400",children:"…"},p):e.jsx("button",{onClick:()=>o(p),className:`px-2.5 py-1 border rounded text-xs ${a===p?"bg-primary text-white border-primary font-bold":"border-gray-300 hover:bg-gray-100"}`,children:p},p)),e.jsxs("button",{onClick:()=>o(a+1),disabled:a===d,className:"flex items-center gap-0.5 px-2 py-1 border border-gray-300 rounded hover:bg-gray-100 disabled:opacity-40 disabled:cursor-not-allowed text-xs",children:["Next ",e.jsx(Lt,{size:12})]})]}),e.jsxs("span",{className:"ml-auto text-xs text-gray-400",children:[t," event",t!==1?"s":"",d>1?` · page ${a} of ${d}`:""]})]})}const H9=[{id:"all",label:"All"},{id:"live",label:"Current (Live)"},{id:"upcoming",label:"Upcoming"},{id:"video",label:"Video"}
636,{id:"archive",label:"Archive"},{id:"draft",label:"Draft"}];function qj(t,a){return a==="all"?!0:a==="draft"?!t.published:a==="archive"?!!t.isArchived:a==="live"?!t.isArchived&&t.videoType==="live":a==="upcoming"?!t.isArchived&&t.videoType==="upcoming":a==="video"?!t.isArchived&&t.videoType==="video":!0}function z9(t,a){if(!a)return!0;const r=a.toLowerCase(),o=(t.location??"").toLowerCase().split(" — ");return t.title.toLowerCase().includes(r)||(t.ownerName??"").toLowerCase().includes(r)||(t.ownerUsername??"").toLowerCase().includes(r)||(t.providedBy??"").toLowerCase().includes(r)||o.some(l=>l.includes(r))}function R9(){return e.jsx(kr,{pageTitle:"Manage Live Events",children:e.jsx(_9,{})})}function _9(){var Ye;const{session:t,isPending:a}=Us(),[r,o]=g.useState([]),[l,d]=g.useState(!0),[u,m]=g.useState(""),[p,x]=g.useState(!1),[b,y]=g.useState(null),[v,w]=g.useState(null),[C,A]=g.useState(!1),[S,z]=g.useState(""),[T,M]=g.useState(null),[P,E]=g.useState(!1),[U,q]=g.useState(!1),[H,J]=g.useState(""),[B,Y]=g.useState("all"),[$,D]=g.useState(1),[W,I]=g.useState(25),k=((Ye=t==null?void 0:t.user)==null?void 0:Ye.isAdmin)===!0,K=r.filter(te=>qj(te,B)&&z9(te,H));g.useEffect(()=>{k&&fetch("/api/admin/fix-embed-sources",{method:"POST"}).then(te=>te.json()).then(te=>{(te.fixed??0)>0&&console.info(`[fix-embed-sources] fixed ${te.fixed} events`)}).catch(()=>{})},[k]);const L=g.useCallback(async()=>{d(!0),m("");try{const te=await fetch("/api/live-events?all=1"),me=await te.json();if(!te.ok)throw new Error(me.error??"Failed to load events.");o((me.events??[]).map(Le=>({...Le,isArchived:!!Le.isArchived,published:!!Le.published})))}catch(te){m(te instanceof Error?te.message:"Failed to load events.")}finally{d(!1)}},[]);g.useEffect(()=>{L()},[L]);async function se(te){A(!0),z("");try{const me=!!b,Le=me?`/api/live-events/${b.id}`:"/api/live-events",Ie=me?"PUT":"POST",ve=te.startAt?new Date(te.startAt).toISOString():"";let ze=te.thumbnailUrl;if(te.thumbnailFile){const Ot=new FormData;Ot.append("file",te.thumbnailFile);const Et=await fetch("/api/live-events/upload-thumbnail",{method:"POST",body:Ot}),Zt=await Et.json();if(!Et.ok)throw new Error(Zt.error??"Thumbnail upload failed.");ze=Zt.url??""}const Ue=await fetch(Le,{method:Ie,headers:{"Content-Type":"application/json"},body:JSON.stringify({...te,startAt:ve,thumbnailUrl:ze,thumbnailFile:void 0,videoType:(te.isArchived,te.videoType),extraCategories:[te.extraCat1,te.extraCat2,te.extraCat3].filter(Boolean),postAs:te.postAs})}),ct=await Ue.json();if(!Ue.ok)throw new Error(ct.error??"Save failed.");x(!1),y(null),w(null),await L()}catch(me){z(me instanceof Error?me.message:"Save failed.")}finally{A(!1)}}async function X(te){E(!0);try{const me=await fetch(`/api/live-events/${te}`,{method:"DELETE"});if(!me.ok){const Le=await me.json();throw new Error(Le.error??"Delete failed.")}M(null),await L()}catch(me){alert(me instanceof Error?me.message:"Delete failed.")}finally{E(!1)}}async function le(te){try{const me=await fetch(`/api/live-events/${te.id}`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({published:!te.published})});if(!me.ok){const Le=await me.json();throw new Error(Le.error??"Failed to update.")}await L()}catch(me){alert(me instanceof Error?me.message:"Failed to update.")}}async function ge(te){try{const me=await fetch(`/api/live-events/${te.id}`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({isArchived:!te.isArchived})});if(!me.ok){const Le=await me.json();throw new Error(Le.error??"Failed to update.")}await L()}catch(me){alert(me instanceof Error?me.message:"Failed to update.")}}function Se(){y(null),z(""),x(!0)}function Me(te){y(te),z(""),x(!0)}function st(te){const Le={...We(te),title:"",startAt:"",videoInput:"",published:!1,isArchived:!1};y(null),w(Le),z(""),x(!0)}function We(te){const me=new Date(te.startAt),Le=Ue=>String(Ue).padStart(2,"0"),Ie=!isNaN(me.getTime())&&!Va(me)?`${me.getFullYear()}-${Le(me.getMonth()+1)}-${Le(me.getDate())}T${Le(me.getHours())}:${Le(me.getMinutes())}`:"";let ve="thc";const ze=(te.ownerUsername??"").toLowerCase();return ze==="raindancervideo"?ve="raindancer":ze.startsWith("nationalsports")&&(ve="nsb"),{title:te.title,startAt:Ie,source:te.source,videoInput:te.videoInput,description:te.description??"",thumbnailUrl:te.thumbnailUrl??"",thumbnailFile:null,thumbnailMode:te.thumbnailUrl?"url":"upload",published:!!te.published,isArchived:!!te.isArchived,videoType:te.videoType??"video",providedBy:te.providedBy??"",providerLink:te.providerLink??"",location:te.location??"",moreInfoUrl:te.moreInfoUrl??"",category:te.category??"",extraCat1:Zo(te.extraCategories)[0]??"",extraCat2:Zo(te.extraCategories)[1]??"",extraCat3:Zo(te.extraCategories)[2]??"",postAs:ve}}return a?e.jsx("main",{className:"flex items-center justify-center min-h-[300px]",children:e.jsx(Rt,{className:"animate-spin text-primary",size:28})}):!t||!k?e.jsxs("main",{className:"max-w-[800px] mx-auto px-4 py-12 text-center",children:[e.jsx("h1",{className:"text-xl font-bold text-gray-800 mb
636-2",children:"Admin Access Required"}),e.jsx("p",{className:"text-gray-500 text-sm",children:"You must be logged in as an admin to view this page."})]}):e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsxs("title",{children:[Cj.pageTitle," | Total Horse Channel"]}),e.jsx("meta",{name:"description",content:"Admin panel for managing live events on Total Horse Channel."}),e.jsx("link",{rel:"canonical",href:"https://totalhorsechannel.com/admin/live-events"}),e.jsx("meta",{name:"robots",content:"noindex,nofollow"})]}),p&&e.jsx(T9,{initial:b?We(b):v??j9,formId:(b==null?void 0:b.id)??"new",onSave:se,onCancel:()=>{x(!1),y(null),w(null)},saving:C,error:S,isAdmin:k}),U&&e.jsx(k9,{onClose:()=>q(!1),onImported:()=>{L()}}),T&&e.jsx("div",{className:"fixed inset-0 z-50 flex items-center justify-center bg-black/60 px-4",children:e.jsxs("div",{className:"bg-white rounded shadow-xl p-6 max-w-[400px] w-full",children:[e.jsx("h3",{className:"font-bold text-gray-900 mb-2",children:"Delete this event?"}),e.jsx("p",{className:"text-sm text-gray-600 mb-5",children:"This cannot be undone."}),e.jsxs("div",{className:"flex justify-end gap-3",children:[e.jsx("button",{onClick:()=>M(null),className:"px-4 py-2 text-sm text-gray-600 hover:text-gray-900",children:"Cancel"}),e.jsxs("button",{onClick:()=>X(T),disabled:P,className:"flex items-center gap-2 px-4 py-2 bg-red-600 text-white text-sm font-semibold rounded hover:bg-red-700 disabled:opacity-60",children:[P?e.jsx(Rt,{size:13,className:"animate-spin"}):e.jsx(Tn,{size:13}),"Delete"]})]})]})}),e.jsx("main",{children:e.jsxs("div",{className:"max-w-[1280px] mx-auto px-4 py-4",children:[e.jsxs("div",{className:"bg-primary px-3 py-2 mb-6 flex items-center justify-between",children:[e.jsxs("div",{className:"flex items-center gap-4",children:[e.jsx("h1",{className:"text-white font-bold uppercase text-sm tracking-wide",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"b78c0a",guard:{file:"src/pages/admin/live-events.tsx",tagName:"h1",sourceKind:"content-key",contentKey:"admin_live_events.pageTitle",contentKeyTemplate:null,expressionHash:null},children:Cj.pageTitle})}),e.jsx("a",{href:"/admin/users",className:"text-white/70 hover:text-white text-xs transition-colors",children:"Manage Users"}),e.jsx("a",{href:"/admin/articles",className:"text-white/70 hover:text-white text-xs transition-colors",children:"Articles"}),e.jsx("a",{href:"/admin/contests",className:"text-white/70 hover:text-white text-xs transition-colors",children:"Contests"})]}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsxs("button",{onClick:()=>q(!0),className:"flex items-center gap-1.5 bg-white/20 text-white text-xs font-bold px-3 py-1.5 rounded hover:bg-white/30 transition-colors border border-white/30",children:[e.jsx(Zf,{size:13}),"Import CSV"]}),e.jsxs("button",{onClick:Se,className:"flex items-center gap-1.5 bg-white text-primary text-xs font-bold px-3 py-1.5 rounded hover:bg-gray-100 transition-colors",children:[e.jsx(Iu,{size:13}),"Add Video / Live"]})]})]}),l&&e.jsxs("div",{className:"flex items-center gap-2 text-gray-500 text-sm py-8",children:[e.jsx(Rt,{size:16,className:"animate-spin"})," Loading events…"]}),u&&e.jsx("div",{className:"bg-red-50 border border-red-200 text-red-700 text-sm px-4 py-3 rounded mb-4",children:u}),!l&&r.length===0&&e.jsxs("div",{className:"text-center py-16 text-gray-400",children:[e.jsx("p",{className:"text-sm mb-3",children:"No live events yet."}),e.jsxs("button",{onClick:Se,className:"inline-flex items-center gap-2 bg-primary text-white text-sm font-semibold px-5 py-2.5 rounded hover:bg-primary/90 transition-colors",children:[e.jsx(Iu,{size:14})," Add Video / Live"]})]}),!l&&r.length>0&&e.jsxs("div",{children:[e.jsxs("div",{className:"flex flex-col sm:flex-row sm:items-center gap-3 mb-3",children:[e.jsxs("div",{className:"relative flex-1 max-w-sm",children:[e.jsx(pi,{size:14,className:"absolute left-2.5 top-1/2 -translate-y-1/2 text-gray-400 pointer-events-none"}),e.jsx("input",{type:"search",value:H,onChange:te=>{J(te.target.value),D(1)},placeholder:"Search title, owner, provided by, country, city…",className:"w-full pl-8 pr-3 py-1.5 border border-gray-300 rounded text-sm focus:outline-none focus:border-primary"})]}),e.jsx("div",{className:"flex flex-wrap gap-1",children:H9.map(te=>{const me=r.filter(Le=>qj(Le,te.id)).length;return e.jsxs("button",{onClick:()=>{Y(te.id),D(1)},className:`px-3 py-1 text-xs font-semibold rounded border transition-colors ${B===te.
636id?"bg-primary text-white border-primary":"bg-white text-gray-600 border-gray-300 hover:bg-gray-50"}`,children:[te.label,e.jsx("span",{className:`ml-1.5 ${B===te.id?"text-white/80":"text-gray-400"}`,children:me})]},te.id)})})]}),e.jsxs("div",{className:"overflow-x-auto",children:[e.jsxs("table",{className:"w-full text-sm border-collapse",children:[e.jsx("thead",{children:e.jsxs("tr",{className:"bg-gray-100 text-left",children:[e.jsx("th",{className:"px-3 py-2 font-semibold text-gray-700 text-xs uppercase tracking-wide",children:"Title"}),e.jsx("th",{className:"px-3 py-2 font-semibold text-gray-700 text-xs uppercase tracking-wide whitespace-nowrap",children:"Added"}),e.jsx("th",{className:"px-3 py-2 font-semibold text-gray-700 text-xs uppercase tracking-wide whitespace-nowrap",children:"Start"}),e.jsx("th",{className:"px-3 py-2 font-semibold text-gray-700 text-xs uppercase tracking-wide",children:"Source"}),e.jsx("th",{className:"px-3 py-2 font-semibold text-gray-700 text-xs uppercase tracking-wide",children:"Categories"}),e.jsx("th",{className:"px-3 py-2 font-semibold text-gray-700 text-xs uppercase tracking-wide",children:"Status"}),e.jsx("th",{className:"px-3 py-2 font-semibold text-gray-700 text-xs uppercase tracking-wide text-right",children:"Actions"})]})}),e.jsx("tbody",{children:K.length===0?e.jsx("tr",{children:e.jsx("td",{colSpan:7,className:"px-3 py-8 text-center text-gray-400 text-sm",children:"No events match your search or filter."})}):K.slice(($-1)*W,$*W).map(te=>e.jsxs("tr",{className:"border-t border-gray-200 hover:bg-gray-50",children:[e.jsxs("td",{className:"px-3 py-3 max-w-[280px]",children:[e.jsx("span",{className:"font-medium text-gray-900 line-clamp-2",children:te.title}),e.jsxs("span",{className:"block text-xs text-gray-400 mt-0.5",children:["/live/",te.slug]})]}),e.jsx("td",{className:"px-3 py-3 whitespace-nowrap text-gray-600 text-xs",children:te.createdAt?new Date(te.createdAt).toLocaleDateString("en-US",{month:"short",day:"numeric",year:"numeric"}):"—"}),e.jsx("td",{className:"px-3 py-3 whitespace-nowrap text-gray-600 text-xs",children:S9(te.startAt,te.title)}),e.jsx("td",{className:"px-3 py-3",children:e.jsx("span",{className:"inline-block bg-gray-100 text-gray-600 text-xs px-2 py-0.5 rounded capitalize",children:te.source})}),e.jsx("td",{className:"px-3 py-3",children:e.jsxs("div",{className:"flex flex-col gap-0.5",children:[te.category&&e.jsx("span",{className:"inline-block bg-primary/10 text-primary text-xs px-2 py-0.5 rounded font-medium",children:te.category}),Zo(te.extraCategories).map(me=>e.jsx("span",{className:"inline-block bg-gray-100 text-gray-600 text-xs px-2 py-0.5 rounded",children:me},me))]})}),e.jsx("td",{className:"px-3 py-3",children:e.jsxs("div",{className:"flex flex-col gap-1",children:[e.jsx("span",{className:`inline-block text-xs px-2 py-0.5 rounded font-medium ${te.published?"bg-green-100 text-green-700":"bg-yellow-100 text-yellow-700"}`,children:te.published?"Published":"Draft"}),e.jsx("span",{className:`inline-block text-xs px-2 py-0.5 rounded font-medium ${te.isArchived?"bg-orange-100 text-orange-700":te.videoType==="upcoming"?"bg-blue-100 text-blue-700":te.videoType==="live"?"bg-green-100 text-green-700":"bg-gray-100 text-gray-600"}`,children:te.isArchived?"Archive":te.videoType==="upcoming"?"Upcoming":te.videoType==="live"?"Current (Live)":"Video"})]})}),e.jsx("td",{className:"px-3 py-3",children:e.jsxs("div",{className:"flex items-center justify-end gap-1",children:[e.jsx("a",{href:`/live/${te.slug}?admin_preview=1`,target:"_blank",rel:"noopener noreferrer",title:"View public page",className:"p-1.5 text-gray-400 hover:text-primary transition-colors",children:e.jsx(dt,{size:14})}),te.published?e.jsxs("button",{onClick:()=>le(te),title:"Unpublish this event",className:"flex items-center gap-1 px-2 py-1 text-xs font-semibold bg-yellow-100 text-yellow-800 hover:bg-yellow-200 transition-colors rounded",children:[e.jsx(to,{size:12}),"Unpublish"]}):e.jsxs("button",{onClick:()=>le(te),title:"Publish this event",className:"flex items-center gap-1 px-2 py-1 text-xs font-semibold bg-green-100 text-green-800 hover:bg-green-200 transition-colors rounded",children:[e.jsx(xa,{size:12}),"Publish"]}),e.jsx("button",{onClick:()=>ge(te),title:te.isArchived?"Move to Current Live Events":"Move to Archives",className:`p-1.5 transition-colors ${te.isArchived?"text-blue-500 hover:text-blue-700":"text-gray-400 hover:text-blue-500"}`,children:te.isArchived?e.jsx(X1,{size:14}):e.jsx(Qi,{size:14})}),e.jsx("button",{onClick:()=>st(te),title:"Duplicate",className:"p-1.5 text-gray-400 hover:text-accent transition-colors",children:e.jsx(Qo,{size:14})}),e.jsx("button",{onClick:()=>Me(te),title:"Edit",className:"p-1.5 text-gray-400 hover:text-primary transition-colors",children:e.jsx(Vn,{size:14})}),e.jsx("button",{onClick:()=>M(te.id),title:"Delete",className:"p-1.5 text-gray-400 hover:text-red-600 transition-colors",children:e.jsx(Tn,{size:14})})]})})]},te.id))})]}),e.jsx(E9,{total:K.length,page:$,perPage:W,onPage:D,onPerPage:te=>{I(te),D(1)}})]})]})]})})]})}const L9=[{value:"rookie",label:"Rookie"},{value:"maiden",label:"Maiden"},{value:"grand_prix",label:"Grand Prix"},{value:"invitational",label:"Invitational (coming soon)"},{value:"championship",label:"Championship (coming soon)"}],D9=[{value:"horse_lover",label:"Horse Enthusiast"},{value:"farm_trainer_business",label:"Trainer"},{value:"business",label:"Business"},{value:"event_show",label:"Show"},{value:"association_org",label:"Organization"},{value:"videographer",label:"Videographer"},{value:"photographer",label:"Photographer"},{value:"media_company",label:"Media Company"}];function O9(t){return t?new Date(t).toLocaleDateString("en-US",{month:"short",day:"numeric",year:"numeric"}):"—"}function M9(){return e.jsx(kr,{pageTitle:"Manage Users",children:e.jsx(U9,{})})}function U9(){const{isAuthenticated:t,isPending:a,user:r}=Us(),o=ga(),[l,d]=g.useState([]),[u,m]=g.useState(!0),[p,x]=g.useState(""),[b,y]=g.useState(null),[v,w]=g.useState(""),[C,A]=g.useState("all"),[S,z]=g.useState(null),[T,M]=g.useState(""),[P,E]=g.useState(!1);async function U(L){const se=T.trim();if(se){E(!0);try{(await fetch(`/api/admin/users/${L.id}`,{method:"PATCH",headers:{"Content-Type":"application/json"},credentials:"include",body:JSON.stringify({name:se})})).ok&&(d(le=>le.map(ge=>ge.id===L.id?{...ge,name:se}:ge)),z(null))}finally{E(!1)}}}g.useEffect(()=>{if(a)return;if(!t){o("/login");return}if(!(r==null?void 0:r.isAdmin)){o("/");return}fetch("/api/admin/users",{credentials:"include"}).then(se=>se.json()).then(se=>{Array.isArray(se)?d(se):x(se.error??"Failed to load users.")}).catch(()=>x("Network error loading users.")).finally(()=>m(!1))},[a,t,r,o]);const q=l.filter(L=>!!L.isAdmin).length;async function H(L,se){y(L.id+"-plan");try{const X=await fetch(`/api/admin/users/${L.id}`,{method:"PATCH",headers:{"Content-Type":"application/json"},credentials:"include",body:JSON.stringify({plan:se})}),le=await X.json();X.ok&&le.plan!==void 0&&d(ge=>ge.map(Se=>Se.id===L.id?{...Se,plan:le.plan}:Se))}finally{y(null)}}async function J(L,se){y(L.id+"-type");try{const X=await fetch(`/api/admin/users/${L.id}`,{method:"PATCH",headers:{"Content-Type":"application/json"},credentials:"include",body:JSON.stringify({accountType:se})}),le=await X.json();X.ok&&d(ge=>ge.map(Se=>Se.id===L.id?{...Se,accountType:le.accountType??se}:Se))}finally{y(null)}}async function B(L){y(L.id);try{const se=await fetch(`/api/admin/users/${L.id}`,{method:"PATCH",headers:{"Content-Type":"application/json"},credentials:"include",body:JSON.stringify({isApproved:!L.isApproved})}),X=await se.json();se.ok&&X.isApproved!==void 0&&d(le=>le.map(ge=>ge.id===L.id?{...ge,isApproved:X.isApproved}:ge))}finally{y(null)}}async function Y(L){if(confirm(`${L.isAdmin?"Remove admin from":"Make admin"}: ${L.email}?`)){y(L.id+"-admin");try{const se=await fetch(`/api/admin/users/${L.id}`,{method:"PATCH",headers:{"Content-Type":"application/json"},credentials:"include",body:JSON.stringify({isAdmin:!L.isAdmin})}),X=await se.json();se.ok&&X.isAdmin!==void 0&&d(le=>le.map(ge=>ge.id===L.id?{...ge,isAdmin:X.isAdmin}:ge))}finally{y(null)}}}async function $(L){y(L.id+"-lh");try{const se=await fetch(`/api/admin/users/${L.id}`,{method:"PATCH",headers:{"Content-Type":"application/json"},credentials:"include",body:JSON.stringify({isLiveHelper:!L.isLiveHelper})}),X=await se.json();se.ok&&X.isLiveHelper!==void 0&&d(le=>le.map(ge=>ge.id===L.id?{...ge,isLiveHelper:X.isLiveHelper}:ge))}finally{y(null)}}async function D(L){const se=L.isPaused?"Unpause":"Pause";if(confirm(`${se} account: ${L.name??L.email}?
637
638Paused accounts cannot log in or post.`)){y(L.id+"-pause");try{const X=await fetch(`/api/admin/users/${L.id}`,{method:"PATCH",headers:{"Content-Type":"application/json"},credentials:"include",body:JSON.stringify({isPaused:!L.isPaused})}),le=await X.json();
638X.ok&&le.isPaused!==void 0&&d(ge=>ge.map(Se=>Se.id===L.id?{...Se,isPaused:le.isPaused}:Se))}finally{y(null)}}}async function W(L){if(L.isAdmin&&q<=1){alert("Cannot delete the last admin account.");return}if(confirm(`Delete this account and their Community posts? Videos stay unpublished.
639
640${L.name??L.email} (${L.email})`)){y(L.id+"-delete");try{const X=await fetch(`/api/admin/users/${L.id}`,{method:"DELETE",credentials:"include"});if(X.ok)d(le=>le.filter(ge=>ge.id!==L.id));else{const le=await X.json().catch(()=>({}));alert(le.error??"Failed to delete user.")}}finally{y(null)}}}const I=l.filter(L=>{const se=v.toLowerCase(),X=!se||(L.name??"").toLowerCase().includes(se)||(L.username??"").toLowerCase().includes(se)||L.email.toLowerCase().includes(se),le=C==="all"||C==="approved"&&L.isApproved||C==="unapproved"&&!L.isApproved;return X&&le}),k=l.filter(L=>L.isApproved).length,K=l.filter(L=>!L.isApproved).length;return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:Aa.pageTitle}),e.jsx("meta",{name:"description",content:"Admin user management for Total Horse Channel."}),e.jsx("link",{rel:"canonical",href:"https://totalhorsechannel.com/admin/users"}),e.jsx("meta",{name:"robots",content:"noindex"})]}),e.jsx("main",{children:e.jsxs("div",{className:"max-w-[1400px] mx-auto px-4 py-4",children:[e.jsxs("div",{className:"bg-primary px-3 py-2 mb-4 flex items-center gap-2 flex-wrap",children:[e.jsx(o2,{size:16,className:"text-white"}),e.jsx("h1",{className:"text-white font-bold uppercase text-sm tracking-wide",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"28f416",guard:{file:"src/pages/admin/users.tsx",tagName:"h1",sourceKind:"content-key",contentKey:"admin_users.heading",contentKeyTemplate:null,expressionHash:null},children:Aa.heading})}),e.jsx("a",{href:"/admin/articles",className:"text-white/70 hover:text-white text-xs transition-colors ml-2",children:"Articles"}),e.jsx("a",{href:"/admin/live-events",className:"text-white/70 hover:text-white text-xs transition-colors",children:"Live Events"}),e.jsx("a",{href:"/admin/contests",className:"text-white/70 hover:text-white text-xs transition-colors",children:"Contests"})]}),!u&&!p&&e.jsxs("div",{className:"flex flex-wrap gap-4 mb-4 text-sm",children:[e.jsxs("span",{className:"text-muted-foreground",children:[e.jsx("strong",{className:"text-foreground",children:l.length})," ",e.jsx("span",{style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"00dff3",guard:{file:"src/pages/admin/users.tsx",tagName:"span",sourceKind:"content-key",contentKey:"admin_users.totalLabel",contentKeyTemplate:null,expressionHash:null},children:Aa.totalLabel})})]}),e.jsxs("span",{className:"text-green-700",children:[e.jsx("strong",{children:k})," ",e.jsx("span",{style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"42b4d4",guard:{file:"src/pages/admin/users.tsx",tagName:"span",sourceKind:"content-key",contentKey:"admin_users.approvedLabel",contentKeyTemplate:null,expressionHash:null},children:Aa.approvedLabel})})]}),e.jsxs("span",{className:"text-yellow-700",children:[e.jsx("strong",{children:K})," ",e.jsx("span",{children:"awaiting approval"})]})]}),!u&&!p&&e.jsxs("div",{className:"flex flex-wrap gap-3 mb-4",children:[e.jsx("input",{type:"search",placeholder:Aa.searchPlaceholder,value:v,onChange:L=>w(L.target.value),className:"border border-border px-3 py-1.5 text-sm bg-background focus:outline-none focus:ring-2 focus:ring-primary w-64"}),e.jsx("div",{className:"flex gap-1",children:["all","approved","unapproved"].map(L=>e.jsx("button",{onClick:()=>A(L),className:`px-3 py-1.5 text-xs font-semibold capitalize transition-colors ${C===L?"bg-primary text-white":"border border-border hover:bg-muted"}`,children:L},L))})]}),u&&e.jsxs("div",{className:"flex items-center gap-2 text-muted-foreground text-sm py-8",children:[e.jsx(Rt,{size:16,className:"animate-spin"})," Loading users…"]}),p&&e.jsx("div",{className:"bg-red-50 border border-red-200 text-red-700 text-sm px-4 py-3 rounded mb-4",children:p}),!u&&!p&&I.length===0&&e.jsx("p",{className:"text-muted-foreground text-sm py-8 text-center",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"f21399",guard:{file:"src/pages/admin/users.tsx",tagName:"p",sourceKind:"content-key",contentKey:"admin_users.noResults",contentKeyTemplate:null,expressionH
640ash:null},children:Aa.noResults})}),!u&&!p&&I.length>0&&e.jsx("div",{className:"overflow-x-auto",children:e.jsxs("table",{className:"w-full text-sm border-collapse",children:[e.jsx("thead",{children:e.jsxs("tr",{className:"bg-gray-100 text-left",children:[e.jsx("th",{className:"px-3 py-2 font-semibold text-gray-700 text-xs uppercase tracking-wide",children:Aa.colMember}),e.jsx("th",{className:"px-3 py-2 font-semibold text-gray-700 text-xs uppercase tracking-wide",children:Aa.colType}),e.jsx("th",{className:"px-3 py-2 font-semibold text-gray-700 text-xs uppercase tracking-wide",children:Aa.colTier}),e.jsx("th",{className:"px-3 py-2 font-semibold text-gray-700 text-xs uppercase tracking-wide",children:Aa.colJoined}),e.jsx("th",{className:"px-3 py-2 font-semibold text-gray-700 text-xs uppercase tracking-wide text-center",children:Aa.colApproved}),e.jsx("th",{className:"px-3 py-2 font-semibold text-gray-700 text-xs uppercase tracking-wide text-center",children:Aa.colAdmin}),e.jsx("th",{className:"px-3 py-2 font-semibold text-gray-700 text-xs uppercase tracking-wide text-center",children:Aa.colLiveHelper}),e.jsx("th",{className:"px-3 py-2 font-semibold text-gray-700 text-xs uppercase tracking-wide text-center",children:"Paused"}),e.jsx("th",{className:"px-3 py-2 font-semibold text-gray-700 text-xs uppercase tracking-wide text-center",children:Aa.colDelete})]})}),e.jsx("tbody",{children:I.map(L=>{const se=!!L.isAdmin&&q<=1;return e.jsxs("tr",{className:"border-t border-gray-200 hover:bg-gray-50",children:[e.jsxs("td",{className:"px-3 py-3 min-w-[180px]",children:[S===L.id?e.jsxs("div",{className:"flex items-center gap-1 mb-0.5",children:[e.jsx("input",{type:"text",value:T,onChange:X=>M(X.target.value.slice(0,100)),autoFocus:!0,className:"flex-1 min-w-0 border border-input rounded px-1.5 py-0.5 text-xs font-medium focus:outline-none focus:ring-1 focus:ring-primary",onKeyDown:X=>{X.key==="Enter"&&U(L),X.key==="Escape"&&z(null)}}),e.jsx("button",{type:"button",onClick:()=>U(L),disabled:P,className:"shrink-0 p-0.5 text-green-700 hover:text-green-900 disabled:opacity-60","aria-label":"Save name",children:e.jsx(Ea,{size:13})}),e.jsx("button",{type:"button",onClick:()=>z(null),className:"shrink-0 p-0.5 text-muted-foreground hover:text-foreground","aria-label":"Cancel",children:e.jsx(Vt,{size:13})})]}):e.jsxs("div",{className:"flex items-center gap-1 mb-0.5 group",children:[L.username?e.jsx(O,{to:`/u/${L.username}`,className:"font-medium text-primary hover:underline text-sm",children:L.name??"(no name)"}):e.jsx("span",{className:"font-medium text-gray-900 text-sm",children:L.name??"(no name)"}),e.jsx("button",{type:"button",onClick:()=>{M(L.name??""),z(L.id)},className:"shrink-0 opacity-0 group-hover:opacity-100 text-muted-foreground hover:text-primary transition-opacity","aria-label":"Edit display name",title:"Edit display name (admin — no limit)",children:e.jsx(Vn,{size:11})})]}),L.username&&e.jsxs(O,{to:`/u/${L.username}`,className:"text-xs text-muted-foreground hover:underline block",children:["@",L.username]}),e.jsx("span",{className:"block text-xs text-gray-400",children:L.email})]}),e.jsx("td",{className:"px-3 py-3",children:b===L.id+"-type"?e.jsx(Rt,{size:14,className:"animate-spin text-primary"}):e.jsx("select",{value:L.accountType??"horse_lover",onChange:X=>J(L,X.target.value),className:"text-xs border border-border rounded px-2 py-1 bg-background focus:outline-none focus:ring-1 focus:ring-primary cursor-pointer","aria-label":`Account type for ${L.name??L.email}`,children:D9.map(X=>e.jsx("option",{value:X.value,children:X.label},X.value))})}),e.jsx("td",{className:"px-3 py-3",children:b===L.id+"-plan"?e.jsx(Rt,{size:14,className:"animate-spin text-primary"}):e.jsx("select",{value:L.plan,onChange:X=>H(L,X.target.value),className:"text-xs border border-border rounded px-2 py-1 bg-background focus:outline-none focus:ring-1 focus:ring-primary cursor-pointer","aria-label":`Set tier for ${L.name??L.email}`,children:L9.map(X=>e.jsx("option",{value:X.value,children:X.label},X.value))})}),e.jsx("td",{className:"px-3 py-3 text-xs text-gray-500 whitespace-nowrap",children:O9(L.createdAt)}),e.jsx("td",{className:"px-3 py-3 text-center",children:e.jsxs("button",{onClick:()=>B(L),disabled:b===L.id,title:L.isApproved?"Revoke approval":"Approve member",className:`inline-flex items-center gap-1 px-2 py-1 text-xs font-semibold rounded transition-colors disabled:opacity-60 ${L.isApproved?"bg-green-100 text-green-800 hover:bg-green-200":"bg-yellow-100 text-yellow-800 hover:bg-yellow-200"}`,children:[b===L.id?e.jsx(Rt,{size:11,className:"animate-spin"}):L.isApproved?e.jsx(kn,{size:11}):e.jsx($m,{size:11}),L.isApproved?"Approved":"Unapproved"]})}),e.jsx("td",{className:"px-3 py-3 text-center",children:e.jsxs("button",{onClick:()=>Y(L),disabled:b===L.id+"-admin",title:L.isAdmin?"Remove admin":"Make admin",className:`inline-flex items-center gap-1 px-2 py-1 text-xs font-semibold rounded transition-colors disabled:opacity-60 ${L.isAdmin?"bg-primary/10 text-primary hover:bg-primary/20":"bg-gray-100 text-gray-500 hover:bg-gray-200"}`,children:[b===L.id+"-admin"?e.jsx(Rt,{size:11,className:"animate-spin"}):e.jsx(cg,{size:11}),L.isAdmin?"Admin":"Member"]})}),e.jsx("td",{className:"px-3 py-3 text-center",children:e.jsxs("button",{onClick:()=>$(L),disabled:b===L.id+"-lh",title:L.isLiveHelper?"Remove live helper access":"Grant live helper access",className:`inline-flex items-center gap-1 px-2 py-1 text-xs font-semibold rounded transition-colors disabled:opacity-60 ${L.isLiveHelper?"bg-blue-100 text-blue-800 hover:bg-blue-200":"bg-gray-100 text-gray-500 hover:bg-gray-200"}`,children:[b===L.id+"-lh"?e.jsx(Rt,{size:11,className:"animate-spin"}):e.jsx(ex,{size:11}),L.isLiveHelper?"Live Helper":"Off"]})}),e.jsx("td",{className:"px-3 py-3 text-center",children:e.jsxs("button",{onClick:()=>D(L),disabled:b===L.id+"-pause"||!!L.isAdmin,title:L.isAdmin?"Cannot pause an admin account":L.isPaused?"Unpause account":"Pause account",className:`inline-flex items-center gap-1 px-2 py-1 text-xs font-semibold rounded transition-colors disabled:opacity-40 disabled:cursor-not-allowed ${L.isPaused?"bg-orange-100 text-orange-800 hover:bg-orange-200":"bg-gray-100 text-gray-500 hover:bg-gray-200"}`,children:[b===L.id+"-pause"?e.jsx(Rt,{size:11,className:"animate-spin"}
640):L.isPaused?e.jsx(Rc,{size:11}):e.jsx(TC,{size:11}),L.isPaused?"Paused":"Active"]})}),e.jsx("td",{className:"px-3 py-3 text-center",children:e.jsxs("button",{onClick:()=>W(L),disabled:b===L.id+"-delete"||se,title:se?"Cannot delete the last admin":"Delete account",className:"inline-flex items-center gap-1 px-2 py-1 text-xs font-semibold rounded text-red-600 hover:bg-red-50 transition-colors disabled:opacity-40 disabled:cursor-not-allowed",children:[b===L.id+"-delete"?e.jsx(Rt,{size:11,className:"animate-spin"}):e.jsx(Tn,{size:11}),"Delete"]})})]},L.id)})})]})})]})})]})}const P9={title:"",startAt:"",source:"youtube",videoInput:"",description:"",thumbnailUrl:"",thumbnailFile:null,thumbnailMode:"url",published:!1,isArchived:!1,videoType:"video",providedBy:"",providerLink:"",location:"",moreInfoUrl:"",category:"",extraCat1:"",extraCat2:"",extraCat3:""};function K9(t,a){try{const r=new Date(t);if(!isNaN(r.getTime())&&!Va(r))return r.toLocaleString("en-US",{month:"short",day:"numeric",year:"numeric",hour:"numeric",minute:"2-digit",hour12:!0});if(a){const o=td(a);if(o)return o.toLocaleDateString("en-US",{month:"short",day:"numeric",year:"numeric"})}return""}catch{return""}}function I9({initial:t,formId:a,onSave:r,onCancel:o,saving:l,error:d}){const u=!!t.title,[m,p]=g.useState(t),[x,b]=g.useState(""),[y,v]=g.useState(""),[w,C]=g.useState(""),[A,S]=g.useState(t.thumbnailUrl||""),z=g.useRef(null);function T(D){var k,K;const W=D.trim();try{const L=new URL(W);if(/youtube\.com|youtu\.be/i.test(L.hostname))return L.searchParams.get("v")||(L.hostname==="youtu.be"?L.pathname.slice(1).split("?")[0]:null)||(L.pathname.startsWith("/live/")?(k=L.pathname.split("/live/")[1])==null?void 0:k.split("?")[0]:null)||(L.pathname.startsWith("/embed/")?(K=L.pathname.split("/embed/")[1])==null?void 0:K.split("?")[0]:null)||null}catch{}const I=W.match(/youtube\.com\/embed\/([a-zA-Z0-9_-]+)/);return I?I[1]:null}function M(D){const W=D.trim(),I=W.match(/rumble\.com\/embed\/([vV][A-Za-z0-9]+)/);if(I)return I[1];const k=W.match(/rumble\.com\/([vV][A-Za-z0-9]+)/);return k?k[1]:null}function P(D,W){if(D==="videoInput"&&typeof W=="string"){b("");const I=T(W);if(I){p(K=>{if(!(K.thumbnailFile||K.thumbnailUrl.trim())){const se=`https://img.youtube.com/vi/${I}/hqdefault.jpg`;return S(se),{...K,videoInput:W,thumbnailUrl:se,thumbnailMode:"url"}}return{...K,videoInput:W}});return}const k=M(W);if(k){p(K=>{if(!(K.thumbnailFile||K.thumbnailUrl.trim())){const se=`https://sp.rmbl.ws/s8/1/${k}.jpg`;return S(se),{...K,videoInput:W,thumbnailUrl:se,thumbnailMode:"url"}}return{...K,videoInput:W}});return}}p(I=>({...I,[D]:W}))}function E(D){var k;const W=(k=D.target.files)==null?void 0:k[0];if(v(""),!W)return;if(!["image/jpeg","image/png","image/avif","image/webp"].includes(W.type)){v("Only JPG, PNG, AVIF, or WebP files are allowed.");return}if(W.size>5*1024*1024){v("File must be under 5 MB.");return}P("thumbnailFile",W),P("thumbnailUrl","");const I=new FileReader;I.onload=K=>{var L;return S((L=K.target)==null?void 0:L.result)},I.readAsDataURL(W)}function U(D){P("thumbnailUrl",D.target.value),P("thumbnailFile",null),S(D.target.value),v("")}function q(D){const W=D.target.value.trim();P("thumbnailUrl",W),S(W)}function H(D){if(D.preventDefault(),m.published){if(!m.videoInput.trim()){b("Add a URL or embed before publishing.");return}const W=K2(m.videoInput);if(W!==null){b(W??"Invalid embed input.");return}if(!m.category.trim()){C("Select a category before publishing.");return}}C(""),r(m)}const B=Sn.flatMap(D=>D.items).filter(D=>D!==m.category&&D!==m.extraCat1&&D!==m.extraCat2),Y="w-full border border-border bg-background text-foreground px-3 py-2 text-sm focus:outline-none focus:border-primary",$="block text-xs font-semibold text-foreground mb-1";return e.jsxs("form",{id:a,onSubmit:H,noValidate:!0,className:"flex flex-col gap-5",children:[e.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-4",children:[e.jsxs("div",{children:[e.jsx("label",{className:$,htmlFor:`${a}-title`,children:"Title *"}),e.jsx("input",{id:`${a}-title`,type:"text",value:m.title,onChange:D=>P("title",D.target.value),required:!0,className:Y,placeholder:"Event or video title"})]}),e.jsxs("div",{children:[e.jsx("label",{className:$,htmlFor:`${a}-startAt`,children:"Date & Time"}),e.jsx("input",{id:`${a}
640-startAt`,type:"datetime-local",value:m.startAt,onChange:D=>P("startAt",D.target.value),className:Y})]})]}),e.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-4",children:[e.jsxs("div",{children:[e.jsx("label",{className:$,htmlFor:`${a}-source`,children:"Source"}),e.jsx("select",{id:`${a}-source`,value:m.source,onChange:D=>P("source",D.target.value),className:Y,children:hA.SOURCE_OPTIONS.map(D=>e.jsx("option",{value:D.value,children:D.label},D.value))})]}),e.jsxs("div",{children:[e.jsx("label",{className:$,htmlFor:`${a}-videoType`,children:"Type"}),e.jsxs("select",{id:`${a}-videoType`,value:m.videoType,onChange:D=>P("videoType",D.target.value),className:Y,children:[e.jsx("option",{value:"live",children:"Live"}),e.jsx("option",{value:"video",children:"Video"}),e.jsx("option",{value:"upcoming",children:"Upcoming"})]})]})]}),e.jsxs("div",{children:[e.jsx("label",{className:$,htmlFor:`${a}-videoInput`,children:"Video URL or Embed Code"}),e.jsx("textarea",{id:`${a}-videoInput`,value:m.videoInput,onChange:D=>P("videoInput",D.target.value),rows:3,className:`${Y} resize-y font-mono text-xs`,placeholder:"Paste YouTube/Rumble URL, watch link, or full iframe embed code"}),x&&e.jsxs("p",{className:"text-destructive text-xs mt-1 flex items-center gap-1",children:[e.jsx(Xi,{size:11}),x]})]}),e.jsxs("div",{children:[e.jsx("label",{className:$,children:"Thumbnail"}),e.jsxs("div",{className:"flex gap-2 mb-2",children:[e.jsxs("button",{type:"button",onClick:()=>P("thumbnailMode","url"),className:`flex items-center gap-1.5 px-3 py-1.5 text-xs font-semibold border transition-colors ${m.thumbnailMode==="url"?"bg-primary text-white border-primary":"border-border text-muted-foreground hover:bg-muted"}`,children:[e.jsx(Lc,{size:12})," Paste URL"]}),e.jsxs("button",{type:"button",onClick:()=>P("thumbnailMode","upload"),className:`flex items-center gap-1.5 px-3 py-1.5 text-xs font-semibold border transition-colors ${m.thumbnailMode==="upload"?"bg-primary text-white border-primary":"border-border text-muted-foreground hover:bg-muted"}`,children:[e.jsx(ln,{size:12})," Upload File"]})]}),m.thumbnailMode==="url"?e.jsx("input",{type:"url",value:m.thumbnailUrl,onChange:U,onBlur:q,className:Y,placeholder:"https://img.youtube.com/vi/VIDEO_ID/hqdefault.jpg"}):e.jsxs("div",{children:[e.jsxs("button",{type:"button",onClick:()=>{var D;return(D=z.current)==null?void 0:D.click()},className:"flex items-center gap-2 px-4 py-2 border border-border text-sm text-foreground hover:bg-muted transition-colors",children:[e.jsx(ln,{size:14}),m.thumbnailFile?m.thumbnailFile.name:"Choose image file"]}),e.jsx("input",{ref:z,type:"file",accept:"image/jpeg,image/png,image/avif,image/webp",className:"hidden",onChange:E})]}),y&&e.jsxs("p",{className:"text-destructive text-xs mt-1 flex items-center gap-1",children:[e.jsx(Xi,{size:11}),y]}),A&&e.jsxs("div",{className:"mt-2 relative w-32 h-20 border border-border overflow-hidden bg-muted",children:[e.jsx("img",{src:A,alt:"Thumbnail preview",className:"w-full h-full object-cover",onError:()=>S("")}),e.jsx("button",{type:"button",onClick:()=>{P("thumbnailUrl",""),P("thumbnailFile",null),S("")},className:"absolute top-0.5 right-0.5 bg-black/60 text-white rounded-full p-0.5 hover:bg-black/80","aria-label":"Remove thumbnail",children:e.jsx(Vt,{size:10})})]})]}),e.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-3 gap-4",children:[e.jsxs("div",{children:[e.jsx("label",{className:$,htmlFor:`${a}-category`,children:"Category"}),e.jsxs("select",{id:`${a}-category`,value:m.category,onChange:D=>{P("category",D.target.value),C("")},className:Y,children:[e.jsx("option",{value:"",children:"— Select —"}),Sn.map(D=>e.jsx("optgroup",{label:D.group,children:D.items.map(W=>e.jsx("option",{value:W,children:W},W))},D.group))]}),w&&e.jsx("p",{className:"text-destructive text-xs mt-1",children:e.jsx(_,{devId:"b53a93",guard:{file:"src/pages/live-helper.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:abb8bc7d9fb5bed45dddd65b76efe3b995d406dcdc623cd751b6eb238f9e5653"},children:w})})]}),e.jsxs("div",{children:[e.jsx("label",{className:$,htmlFor:`${a}-extraCat1`,children:"Extra category 1"}),e.jsxs("select",{id:`${a}-extraCat1`,value:m.extraCat1,onChange:D=>P("extraCat1",D.target.value),className:Y,children:[e.jsx("option",{value:"",children:"— None —"}),B.map(D=>e.jsx("option",{value:D,children:D},D))]})]}),e.jsxs("div",{children:[e.jsx("label",{className:$,htmlFor:`${a}-extraCat2`,children:"Extra category 2"}),e.jsxs("select",{id:`${a}
640-extraCat2`,value:m.extraCat2,onChange:D=>P("extraCat2",D.target.value),className:Y,children:[e.jsx("option",{value:"",children:"— None —"}),B.filter(D=>D!==m.extraCat1).map(D=>e.jsx("option",{value:D,children:D},D))]})]})]}),e.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-4",children:[e.jsxs("div",{children:[e.jsx("label",{className:$,htmlFor:`${a}-providedBy`,children:"Provided by"}),e.jsx("input",{id:`${a}-providedBy`,type:"text",value:m.providedBy,onChange:D=>P("providedBy",D.target.value),className:Y,placeholder:"e.g. Woodbine Entertainment"})]}),e.jsxs("div",{children:[e.jsx("label",{className:$,htmlFor:`${a}-providerLink`,children:"Provider link"}),e.jsx("input",{id:`${a}-providerLink`,type:"url",value:m.providerLink,onChange:D=>P("providerLink",D.target.value),className:Y,placeholder:"https://…"})]})]}),e.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-4",children:[e.jsxs("div",{children:[e.jsx("label",{className:$,htmlFor:`${a}-location`,children:"Location"}),e.jsx("input",{id:`${a}-location`,type:"text",value:m.location,onChange:D=>P("location",D.target.value),className:Y,placeholder:"City, Venue"})]}),e.jsxs("div",{children:[e.jsx("label",{className:$,htmlFor:`${a}-moreInfoUrl`,children:"More info URL"}),e.jsx("input",{id:`${a}-moreInfoUrl`,type:"url",value:m.moreInfoUrl,onChange:D=>P("moreInfoUrl",D.target.value),className:Y,placeholder:"https://…"})]})]}),e.jsxs("div",{children:[e.jsx("label",{className:$,htmlFor:`${a}-description`,children:"Description"}),e.jsx("textarea",{id:`${a}-description`,value:m.description,onChange:D=>P("description",D.target.value),rows:3,className:`${Y} resize-y`,placeholder:"Optional short description"})]}),e.jsxs("div",{className:"flex flex-wrap gap-6",children:[e.jsxs("label",{className:"flex items-center gap-2 cursor-pointer select-none",children:[e.jsx("input",{type:"checkbox",checked:m.published,onChange:D=>P("published",D.target.checked),className:"w-4 h-4 accent-primary"}),e.jsx("span",{className:"text-sm font-medium text-foreground",children:"Published"})]}),e.jsxs("label",{className:"flex items-center gap-2 cursor-pointer select-none",children:[e.jsx("input",{type:"checkbox",checked:m.isArchived,onChange:D=>P("isArchived",D.target.checked),className:"w-4 h-4 accent-primary"}),e.jsx("span",{className:"text-sm font-medium text-foreground",children:"Archived"})]})]}),d&&e.jsxs("div",{className:"flex items-start gap-2 bg-red-50 border border-red-200 text-red-700 text-sm px-3 py-2.5",children:[e.jsx(Xi,{size:14,className:"mt-0.5 shrink-0"}),e.jsx("span",{children:e.jsx(_,{devId:"5f3e26",guard:{file:"src/pages/live-helper.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:ca00fccfb408989eddc401062c4d1219a6aceb6b9b55412357f1790862e8f178"},children:d})})]}),e.jsxs("div",{className:"flex items-center gap-3 pt-1",children:[e.jsxs("button",{type:"submit",disabled:l||!m.title.trim(),className:"flex items-center gap-2 bg-primary text-white font-bold px-5 py-2 text-sm uppercase hover:opacity-90 transition-opacity disabled:opacity-50",children:[l?e.jsx(Rt,{size:14,className:"animate-spin"}):e.jsx(Ea,{size:14}),l?"Saving…":u?"Save changes":"Add video"]}),e.jsx("button",{type:"button",onClick:o,disabled:l,className:"px-4 py-2 text-sm text-muted-foreground hover:text-foreground transition-colors",children:"Cancel"})]})]})}function B9(){return e.jsx(kr,{pageTitle:"Live Helper — Add / Edit Videos",children:e.jsx($9,{})})}function $9(){const[t,a]=g.useState([]),[r,o]=g.useState(!0),[l,d]=g.useState(""),[u,m]=g.useState(!1),[p,x]=g.useState(null),[b,y]=g.useState(null),[v,w]=g.useState(!1),[C,A]=g.useState(""),[S,z]=g.useState(null),[T,M]=g.useState(!1),[P,E]=g.useState(""),U=g.useCallback(async()=>{o(!0),d("");try{const k=await fetch("/api/live-events?all=1"),K=await k.json();if(!k.ok)throw new Error(K.error??"Failed to load events.");a((K.events??[]).map(L=>({...L,isArchived:!!L.isArchived,published:!!L.published})))}catch(k){d(k instanceof Error?k.message:"Failed to load events.")}finally{o(!1)}},[]);g.useEffect(()=>{U()},[U]);
640async function q(k){w(!0),A("");try{const K=!!p,L=K?`/api/live-events/${p.id}`:"/api/live-events",se=K?"PUT":"POST",X=k.startAt?new Date(k.startAt).toISOString():"";let le=k.thumbnailUrl;if(k.thumbnailFile){const Me=new FormData;Me.append("file",k.thumbnailFile);const st=await fetch("/api/live-events/upload-thumbnail",{method:"POST",body:Me}),We=await st.json();if(!st.ok)throw new Error(We.error??"Thumbnail upload failed.");le=We.url??""}const ge=await fetch(L,{method:se,headers:{"Content-Type":"application/json"},body:JSON.stringify({...k,startAt:X,thumbnailUrl:le,thumbnailFile:void 0,extraCategories:[k.extraCat1,k.extraCat2,k.extraCat3].filter(Boolean)})}),Se=await ge.json();if(!ge.ok)throw new Error(Se.error??"Save failed.");m(!1),x(null),y(null),await U()}catch(K){A(K instanceof Error?K.message:"Save failed.")}finally{w(!1)}}async function H(k){M(!0);try{const K=await fetch(`/api/live-events/${k}`,{method:"DELETE"});if(!K.ok){const L=await K.json();throw new Error(L.error??"Delete failed.")}z(null),await U()}catch(K){alert(K instanceof Error?K.message:"Delete failed.")}finally{M(!1)}}async function J(k){try{const K=await fetch(`/api/live-events/${k.id}`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({published:!k.published})});if(!K.ok){const L=await K.json();throw new Error(L.error??"Failed to update.")}await U()}catch(K){alert(K instanceof Error?K.message:"Failed to update.")}}async function B(k){try{const K=await fetch(`/api/live-events/${k.id}`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({isArchived:!k.isArchived})});if(!K.ok){const L=await K.json();throw new Error(L.error??"Failed to update.")}await U()}catch(K){alert(K instanceof Error?K.message:"Failed to update.")}}function Y(){x(null),A(""),m(!0)}function $(k){x(k),A(""),m(!0)}function D(k){const L={...W(k),title:"",startAt:"",videoInput:"",published:!1,isArchived:!1};x(null),y(L),A(""),m(!0)}function W(k){const K=new Date(k.startAt),L=le=>String(le).padStart(2,"0"),se=Va(K)||isNaN(K.getTime())?"":`${K.getFullYear()}-${L(K.getMonth()+1)}-${L(K.getDate())}T${L(K.getHours())}:${L(K.getMinutes())}`,X=Zo(k.extraCategories);return{title:k.title,startAt:se,source:k.source,videoInput:k.videoInput,description:k.description??"",thumbnailUrl:k.thumbnailUrl??"",thumbnailFile:null,thumbnailMode:"url",published:k.published,isArchived:k.isArchived,videoType:k.videoType,providedBy:k.providedBy??"",providerLink:k.providerLink??"",location:k.location??"",moreInfoUrl:k.moreInfoUrl??"",category:k.category??"",extraCat1:X[0]??"",extraCat2:X[1]??"",extraCat3:X[2]??""}}const I=t.filter(k=>{const K=P.toLowerCase();return K?k.title.toLowerCase().includes(K)||k.slug.toLowerCase().includes(K)||(k.providedBy??"").toLowerCase().includes(K)||(k.source??"").toLowerCase().includes(K)||(k.category??"").toLowerCase().includes(K)||Zo(k.extraCategories).some(L=>L.toLowerCase().includes(K)):!0});return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Live Helper | Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Restricted live video management dashboard for authorized helpers."}),e.jsx("link",{rel:"canonical",href:"https://totalhorsechannel.com/live-helper"}),e.jsx("meta",{name:"robots",content:"noindex, nofollow"})]}),e.jsx("main",{children:e.jsxs("div",{className:"max-w-[1200px] mx-auto px-4 py-4",children:[e.jsxs("div",{className:"bg-primary px-3 py-2 mb-4 flex items-center justify-between gap-2",children:[e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(ex,{size:16,className:"text-white"}),e.jsx("h1",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Live Helper — Add / Edit Videos"})]}),!u&&e.jsxs("button",{onClick:Y,className:"flex items-center gap-1.5 bg-white text-primary font-bold text-xs uppercase px-3 py-1.5 hover:bg-gray-100 transition-colors",children:[e.jsx(Iu,{size:13})," Add Video"]})]}),u&&e.jsxs("div",{className:"border border-border bg-card p-5 mb-6",children:[e.jsxs("div",{className:"flex items-center justify-between mb-4",children:[e.jsx("h2",{className:"font-bold text-foreground text-base",children:e.jsx(_,{devId:"2671ff",guard:{file:"src/pages/live-helper.tsx",tagName:"h2",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionH
640ash:"sha256:a0e59f87dd1e5443a4f290be89708429dd880f93c8ebed43182d3301b2f3bd8f"},children:p?"Edit Video":b?"Duplicate Video":"Add New Video"})}),e.jsx("button",{onClick:()=>{m(!1),x(null),y(null)},className:"text-muted-foreground hover:text-foreground","aria-label":"Close form",children:e.jsx(Vt,{size:18})})]}),e.jsx(I9,{initial:p?W(p):b??P9,formId:"lh-event-form",onSave:q,onCancel:()=>{m(!1),x(null),y(null)},saving:v,error:C})]}),!u&&e.jsx("div",{className:"mb-4",children:e.jsxs("div",{className:"relative w-72",children:[e.jsx(pi,{size:14,className:"absolute left-2.5 top-1/2 -translate-y-1/2 text-gray-400 pointer-events-none"}),e.jsx("input",{type:"search",placeholder:"Search title, provider, category…",value:P,onChange:k=>E(k.target.value),className:"border border-border pl-8 pr-3 py-1.5 text-sm bg-background focus:outline-none focus:ring-2 focus:ring-primary w-full"})]})}),r&&e.jsxs("div",{className:"flex items-center gap-2 text-muted-foreground text-sm py-8",children:[e.jsx(Rt,{size:16,className:"animate-spin"})," Loading events…"]}),l&&e.jsx("div",{className:"bg-red-50 border border-red-200 text-red-700 text-sm px-4 py-3 mb-4",children:l}),!r&&!l&&e.jsx("div",{className:"overflow-x-auto",children:e.jsxs("table",{className:"w-full text-sm border-collapse",children:[e.jsx("thead",{children:e.jsxs("tr",{className:"bg-gray-100 text-left",children:[e.jsx("th",{className:"px-3 py-2 text-xs font-semibold text-gray-700 uppercase tracking-wide",children:"Thumb"}),e.jsx("th",{className:"px-3 py-2 text-xs font-semibold text-gray-700 uppercase tracking-wide",children:"Title"}),e.jsx("th",{className:"px-3 py-2 text-xs font-semibold text-gray-700 uppercase tracking-wide",children:"Date"}),e.jsx("th",{className:"px-3 py-2 text-xs font-semibold text-gray-700 uppercase tracking-wide text-center",children:"Status"}),e.jsx("th",{className:"px-3 py-2 text-xs font-semibold text-gray-700 uppercase tracking-wide text-center",children:"Actions"})]})}),e.jsxs("tbody",{children:[I.length===0&&e.jsx("tr",{children:e.jsx("td",{colSpan:5,className:"px-3 py-8 text-center text-muted-foreground text-sm",children:P?"No events match your search.":'No events yet. Click "Add Video" to get started.'})}),I.map(k=>e.jsxs("tr",{className:"border-t border-gray-200 hover:bg-gray-50",children:[e.jsx("td",{className:"px-3 py-2",children:k.thumbnailUrl?e.jsx("img",{src:k.thumbnailUrl,alt:"",className:"w-16 h-10 object-cover border border-gray-200",loading:"lazy"}):e.jsx("div",{className:"w-16 h-10 bg-gray-100 border border-gray-200 flex items-center justify-center",children:e.jsx(ex,{size:14,className:"text-gray-400"})})}),e.jsxs("td",{className:"px-3 py-2 min-w-[200px]",children:[e.jsx("span",{className:"font-medium text-foreground line-clamp-2",children:k.title}),k.providedBy&&e.jsx("span",{className:"block text-xs text-muted-foreground",children:k.providedBy}),k.category&&e.jsx("span",{className:"inline-block mt-0.5 text-[10px] bg-gray-100 text-gray-600 px-1.5 py-0.5 rounded",children:k.category})]}),e.jsx("td",{className:"px-3 py-2 text-xs text-gray-500 whitespace-nowrap",children:K9(k.startAt,k.title)||"—"}),e.jsx("td",{className:"px-3 py-2 text-center",children:e.jsxs("div",{className:"flex flex-col items-center gap-1",children:[e.jsx("span",{className:`text-[10px] font-semibold px-1.5 py-0.5 rounded ${k.published?"bg-green-100 text-green-800":"bg-yellow-100 text-yellow-800"}`,children:k.published?"Published":"Draft"}),k.isArchived&&e.jsx("span",{className:"text-[10px] font-semibold px-1.5 py-0.5 rounded bg-gray-100 text-gray-600",children:"Archived"})]})}),e.jsx("td",{className:"px-3 py-2",children:e.jsxs("div",{className:"flex items-center justify-center gap-1 flex-wrap",children:[e.jsx("button",{onClick:()=>D(k),title:"Duplicate",className:"p-1.5 text-gray-500 hover:text-accent hover:bg-accent/10 rounded transition-colors",children:e.jsx(Qo,{size:13})}),e.jsx("button",{onClick:()=>$(k),title:"Edit",className:"p-1.5 text-gray-500 hover:text-primary hover:bg-primary/10 rounded transition-colors",children:e.jsx(Vn,{size:13})}),e.jsx("button",{onClick:()=>J(k),title:k.published?"Unpublish":"Publish",className:`p-1.5 rounded transition-colors ${k.published?"text-green-600 hover:bg-green-50":"text-gray-400 hover:text-green-600 hover:bg-green-50"}`,children:k.published?e.jsx(xa,{size:13}):e.jsx(to,{size:13})}),e.jsx("button",{onClick:()=>B(k),title:k.isArchived?"Unarchive":"Archive",className:"p-1.5 text-gray-400 hover:text-gray-700 hover:bg-gray-100 rounded transition-colors",children:k.isArchived?e.jsx(X1,{size:13}):e.jsx(Qi,{size:13})}),k.slug&&e.jsx("a",{href:`/live/${k.slug}`,target:"_blank",rel:"noopener noreferrer",title:"View on site",className:"p-1.5 text-gray-400 hover:text-primary hover:bg-primary/10 rounded transition-colors",children:e.jsx(dt,{size:13})}),S===k.id?e.jsxs("div",{className:"flex items-center gap-1",children:[e.jsx("button",{onClick:()=>H(k.id),disabled:T,className:"p-1.5 text-red-600 hover:bg-red-50 rounded transition-colors disabled:opacity-50",title:"Confirm delete",children:T?e.jsx(Rt,{size:13,className:"animate-spin"}):e.jsx(Ea,{size:13})}),e.jsx("button",{onClick:()=>z(null),className:"p-1.5 text-gray-400 hover:text-gray-700 rounded transition-colors",title:"Cancel",children:e.jsx(Vt,{size:13})})]}):e.jsx("button",{onClick:()=>z(k.id),title:"Delete",className:"p-1.5 text-gray-400 hover:text-red-600 hover:bg-red-50 rounded transition-colors",children:e.jsx(Tn,{size:13})})]})})]},k.id))]})]})}),!r&&!l&&e.jsxs("p",{className:"text-xs text-muted-foreground mt-3",children:[I.length," event",I.length!==1?"s":""," shown",P?` matching "${P}"`:""]})]})})]})}function Yj(){const t="thc_like_token";let a=localStorage.getItem(t);return a||(a=crypto.randomUUID(),localStorage.setItem(t,a)),a}function Gj(t){return t>=1e6?`${(t/1e6).toFixed(1)}M`:t>=1e3?`${(t/1e3).toFixed(1)}K`:String(t)}function V9({slug:t,initialViews:a,initialLikes:r}){const[o,l]=g.useState(a),[d,u]=g.useState(r),[m,p]=g.useState(!1),[x,b]=g.useState(!1);g.useEffect(()=>{new URLSearchParams(window.location.search).get("admin_preview")!=="1"&&fetch(`/api/live-events/${t}/view`,{method:"POST"}).then(w=>
640w.json()).then(w=>{typeof w.viewCount=="number"&&l(w.viewCount)}).catch(()=>{})},[t]),g.useEffect(()=>{const v=Yj();fetch(`/api/live-events/${t}/like?token=${encodeURIComponent(v)}`).then(w=>w.json()).then(w=>{typeof w.liked=="boolean"&&p(w.liked),typeof w.likeCount=="number"&&u(w.likeCount)}).catch(()=>{})},[t]);async function y(){if(x)return;b(!0);const v=m;p(!v),u(w=>v?Math.max(0,w-1):w+1);try{const w=Yj(),A=await(await fetch(`/api/live-events/${t}/like`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({token:w})})).json();typeof A.liked=="boolean"&&p(A.liked),typeof A.likeCount=="number"&&u(A.likeCount)}catch{p(v),u(w=>v?w+1:Math.max(0,w-1))}finally{b(!1)}}return e.jsxs("div",{className:"flex items-center gap-5 select-none",children:[e.jsxs("span",{className:"flex items-center gap-2 text-gray-500",children:[e.jsx(xa,{size:20,className:"shrink-0"}),e.jsx("span",{className:"text-lg font-semibold tabular-nums text-gray-700",children:e.jsx(_,{devId:"ab8125",guard:{file:"src/components/EventStats.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:39700ca93c003170b746a14148a8d8b940af90c98237d5197ee7f551dbb8eeac"},children:Gj(o)})})]}),e.jsx("span",{className:"w-px h-6 bg-gray-200","aria-hidden":"true"}),e.jsxs("button",{onClick:y,disabled:x,"aria-label":m?"Unlike this event":"Like this event","aria-pressed":m,className:["flex items-center gap-2 transition-colors",m?"text-primary":"text-gray-500 hover:text-primary",x?"opacity-60 cursor-wait":"cursor-pointer"].join(" "),children:[e.jsx(Gn,{size:20,className:"shrink-0"}),e.jsx("span",{className:"text-lg font-semibold tabular-nums",children:e.jsx(_,{devId:"f3a76f",guard:{file:"src/components/EventStats.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:ab769325a8610b6b12f3e201f7f366928bf75acced5cb02a22f5f6c72d69e34f"},children:Gj(d)})})]})]})}const Zj="thc_browser_id",I2="thc_comment_likes",Jj=[{label:"Horses & Animals",emojis:["🐴","🐎","🦄","🤠","🐄","🐂","🐕","🐈","🦅","🌾","🏇","🎠"]},{label:"Reactions",emojis:["😀","😂","🤣","😍","🥰","😎","🤩","😮","😲","🥺","😢","😭"]},{label:"Hands & Hearts",emojis:["❤️","🧡","💛","💚","💙","💜","🖤","🤍","👍","👎","👏","🙌"]},{label:"Symbols",emojis:["🔥","⭐","🌟","✨","🏆","🥇","🎉","🎊","💪","🙏","✅","❌"]}];function F9(){try{let t=localStorage.getItem(Zj);return t||(t=crypto.randomUUID(),localStorage.setItem(Zj,t)),t}catch{return"anon"}}function W9(){try{const t=localStorage.getItem(I2);return new Set(t?JSON.parse(t):[])}catch{return new Set}}function q9(t){try{localStorage.setItem(I2,JSON.stringify([...t]))}catch{}}function Y9(t){try{const a=new Date(t);return a.toLocaleDateString("en-US",{month:"short",day:"numeric",year:"numeric"})+" at "+a.toLocaleTimeString("en-US",{hour:"numeric",minute:"2-digit",hour12:!0})}catch{return t}}function G9({onSelect:t,onClose:a}){const r=g.useRef(null),[o,l]=g.useState(0);g.useEffect(()=>{function u(m){r.current&&!r.current.contains(m.target)&&a()}return document.addEventListener("mousedown",u),()=>document.removeEventListener("mousedown",u)},[a]),g.useEffect(()=>{function u(m){m.key==="Escape"&&a()}return document.addEventListener("keydown",u),()=>document.removeEventListener("keydown",u)},[a]);const d=Jj[o];return e.jsxs("div",{ref:r,className:"absolute bottom-full right-0 mb-2 z-50 bg-white border border-gray-200 rounded-lg shadow-lg w-64",role:"dialog","aria-label":"Emoji picker",children:[e.jsx("div",{className:"flex border-b border-gray-100 overflow-x-auto",children:Jj.map((u,m)=>e.jsx("button",{type:"button",onClick:()=>l(m),className:["flex-1 min-w-0 px-2 py-2 text-xs font-medium whitespace-nowrap transition-colors",m===o?"text-primary border-b-2 border-primary bg-primary/5":"text-gray-500 hover:text-gray-700 hover:bg-gray-50"].join(" "),title:u.label,children:u.emojis[0]},u.label))}),e.jsx("div",{className:"px-3 pt-2 pb-1",children:e.jsx("span",{className:"text-xs text-gray-400 font-medium",children:e.jsx(_,{devId:"2ee70e",guard:{file:"src/components/EventComments.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionH
640ash:"sha256:40ae71e08628df7ddc8f38ee083e93e44daac3e4fc01a2910f8007d2adf7101d"},children:d.label})})}),e.jsx("div",{className:"grid grid-cols-6 gap-0.5 px-2 pb-3",children:d.emojis.map(u=>e.jsx("button",{type:"button",onClick:()=>{t(u)},className:"flex items-center justify-center w-9 h-9 text-xl rounded hover:bg-gray-100 transition-colors","aria-label":u,title:u,children:u},u))})]})}function Z9({slug:t}){const{user:a}=Us(),r=ga(),o=!!a,l=!!(a!=null&&a.isAdmin),[d,u]=g.useState([]),[m,p]=g.useState(!0),[x,b]=g.useState(!1),[y,v]=g.useState(""),[w,C]=g.useState(!1),[A,S]=g.useState(null),[z,T]=g.useState(null),[M,P]=g.useState(new Set),[E,U]=g.useState(null),[q,H]=g.useState(!1),J=g.useRef(null);g.useEffect(()=>{P(W9())},[]);const B=g.useCallback(async()=>{b(!1);try{const k=await fetch(`/api/live-events/${t}/comments`);if(!k.ok)throw new Error("Failed");const K=await k.json();u(K.comments??[])}catch{b(!0)}finally{p(!1)}},[t]);g.useEffect(()=>{B()},[B]);function Y(k){const K=J.current;if(!K){v(le=>le+k);return}const L=K.selectionStart??y.length,se=K.selectionEnd??y.length,X=y.slice(0,L)+k+y.slice(se);v(X),requestAnimationFrame(()=>{K.focus();const le=L+k.length;K.setSelectionRange(le,le)})}async function $(k){if(k.preventDefault(),!(!y.trim()||w)){C(!0),S(null),H(!1);try{const K=await fetch(`/api/live-events/${t}/comments`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({body:y.trim()})}),L=await K.json();if(!K.ok){S(L.error??"Failed to post comment.");return}L.comment&&(u(se=>[L.comment,...se]),v(""))}catch{S("Something went wrong. Please try again.")}finally{C(!1)}}}async function D(k){if(E===k)return;U(k);const K=F9();M.has(k);try{const L=await fetch(`/api/live-events/${t}/comments/${k}/like`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({browserId:K})});if(!L.ok)return;const se=await L.json();u(le=>le.map(ge=>ge.id===k?{...ge,likeCount:se.likeCount}:ge));const X=new Set(M);se.liked?X.add(k):X.delete(k),P(X),q9(X)}catch{}finally{U(null)}}async function W(k){if(window.confirm("Delete this comment?")){T(k);try{(await fetch(`/api/live-events/${t}/comments/${k}`,{method:"DELETE"})).ok&&u(L=>L.filter(se=>se.id!==k))}finally{T(null)}}}function I(){o||r("/login")}return e.jsxs("section",{className:"mt-6","aria-label":"Comments",children:[e.jsxs("div",{className:"flex items-center gap-2 mb-3",children:[e.jsx(ig,{size:16,className:"text-primary shrink-0"}),e.jsxs("h2",{className:"text-sm font-bold text-gray-800 uppercase tracking-wide",children:["Comments",d.length>0&&e.jsxs("span",{className:"ml-1.5 text-gray-400 font-normal normal-case tracking-normal",children:["(",d.length,")"]})]})]}),e.jsx("div",{className:"bg-white border border-gray-200 rounded p-4 mb-4",children:o?e.jsx("form",{onSubmit:$,children:e.jsxs("div",{className:"flex items-start gap-3",children:[e.jsx("div",{className:"w-8 h-8 rounded-full bg-primary/10 flex items-center justify-center shrink-0 mt-0.5",children:e.jsx(Ha,{size:14,className:"text-primary"})}),e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("textarea",{ref:J,value:y,onChange:k=>v(k.target.value),placeholder:"Write a comment...",rows:3,maxLength:2e3,className:"w-full border border-gray-300 rounded px-3 py-2 text-sm resize-none focus:outline-none focus:border-primary transition-colors"}),A&&e.jsx("p",{className:"text-red-600 text-xs mt-1",children:e.jsx(_,{devId:"03342c",guard:{file:"src/components/EventComments.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:1a05a33f630014b4d6de08baaf19caf5115c37911cd5e7bfa1224d9a04c1bff4"},children:A})}),e.jsxs("div",{className:"flex items-center justify-between mt-2",children:[e.jsx("span",{className:"text-xs text-gray-400",children:e.jsx(_,{devId:"dc9a22",guard:{file:"src/components/EventComments.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:111c0c73b66f95514763eaba2920d10ff29e879eb86fe11ce6ee00da61533c49"},children:y.length>0&&`${y.length}/2000`})}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsxs("div",{className:"relative",children:[e.jsx("button",{type:"button",onClick:()=>H(k=>!k),className:["inline-flex items-center justify-center w-8 h-8 rounded transition-colors",q?"bg-primary/10 text-primary":"text-gray-400 hover:text-primary hover:bg-gray-100"].join(" "),"aria-label":"Open emoji picker",title:"Add emoji",children:e.jsx(i2,{size:16})}),q&&e.jsx(G9,{onSelect:k=>Y(k),onClose:()=>H(!1)})]}),e.jsxs("button",{type:"submit",disabled:!y.trim()||w,className:"inline-flex items-center gap-1.5 bg-primary text-white text-xs font-semibold px-4 py-2 rounded hover:bg-primary/90 transition-colors disabled:opacity-50 disabled:cursor-not-allowed",children:[w?e.jsx(Rt,{size:13,className:"animate-spin"}):e.jsx(fi,{size:13}),"Post"]})]})]})]})]})}):e.jsxs("div",{className:"flex items-center gap-3 cursor-pointer",onClick:()=>r("/login"),role:"button",tabIndex:0,onKeyDown:k=>k.key==="Enter"&&r("/login"),"aria-label":"Log in to comment",children:[e.jsx("div",{className:"w-8 h-8 rounded-full bg-gray-100 flex items-center justify-center shrink-0",children:e.jsx(Ha,{size:14,className:"text-gray-400"})}),e.jsxs("div",{className:"flex-1 border border-gray-200 rounded px-3 py-2.5 text-sm text-gray-400 bg-gray-50 cursor-pointer select-none",onFocus:I,children:[e.jsx(O,{to:"/login",className:"text-primary font-medium hover:underline",onClick:k=>k.stopPropagation(),children:"Log in"})," ","or"," ",e.jsx(O,{to:"/become-member",className:"text-primary font-medium hover:underline",onClick:k=>k.stopPropagation(),children:"sign up"})," ","to leave a comment."]})]})}),m?e.jsx("div",{className:"flex justify-center py-8",children:e.jsx(Rt,{size:22,className:"animate-spin text-primary"})}):x?e.jsxs("p",{className:"text-sm text-gray-500 text-center py-6",children:["Could not load comments."," ",e.jsx("button",{onClick:B,className:"text-primary hover:underline",children:"Retry"})]}):d.length===0?e.jsx("p",{className:"text-sm text-gray-400 text-center py-6",children:"No comments yet. Be the first to comment!"}):e.jsx("ol",{className:"space-y-0","aria-label":"Comment list",children:d.map((k,K)=>{const L=M.has(k.id),se=E===k.id;return e.jsxs("li",{className:["bg-white px-4 py-3 flex gap-3",K===0?"rounded-t border border-gray-200":"border-x border-gray-200",K<d.length-1?"border-b border-gray-100":"rounded-b border-b border-gray-200"].join(" "),children:[e.jsx("div",{className:"w-8 h-8 rounded-full bg-primary/10 flex items-center justify-center shrink-0 mt-0.5",children:e.jsx(Ha,{size:14,className:"text-primary"})}),e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsxs("div",{className:"flex items-baseline gap-2 flex-wrap mb-1",children:[e.jsx("span",{className:"text-sm font-semibold text-gray-800",children:k.displayName??k.username??"Member"}),k.username&&e.jsxs("span",{className:"text-xs text-gray-400",children:["@",k.username]}),e.jsx("span",{className:"text-xs text-gray-400 ml-auto shrink-0",children:e.jsx("time",{dateTime:k.createdAt,children:Y9(k.createdAt)})})]}),e.jsxs("div",{className:"flex items-start gap-2",children:[e.jsx("p",{className:"flex-1 text-sm text-gray-700 leading-relaxed whitespace-pre-wrap break-words min-w-0",children:k.body}
640),e.jsxs("button",{onClick:()=>D(k.id),disabled:se,className:["inline-flex items-center gap-1 text-xs font-medium px-2 py-1 rounded transition-colors disabled:opacity-50 shrink-0 mt-0.5",L?"text-primary bg-primary/10 hover:bg-primary/20":"text-gray-400 hover:text-primary hover:bg-gray-100"].join(" "),"aria-label":L?"Unlike comment":"Like comment",title:L?"Unlike":"Like",children:[se?e.jsx(Rt,{size:12,className:"animate-spin"}):e.jsx(Gn,{size:12,className:L?"fill-primary text-primary":""}),k.likeCount>0&&e.jsx("span",{children:k.likeCount})]})]})]}),l&&e.jsx("button",{onClick:()=>W(k.id),disabled:z===k.id,className:"shrink-0 text-gray-300 hover:text-red-500 transition-colors disabled:opacity-40 mt-0.5","aria-label":"Delete comment",title:"Delete comment",children:z===k.id?e.jsx(Rt,{size:14,className:"animate-spin"}):e.jsx(Tn,{size:14})})]},k.id)})})]})}function Hf({uploader:t,initialFollowing:a,viewerId:r}){const[o,l]=g.useState(a),[d,u]=g.useState(!1),m=r===t.id,p=t.username?`/u/${t.username}`:null,x=t.name.split(" ").map(v=>v[0]??"").slice(0,2).join("").toUpperCase();async function b(){if(!(!t.username||d)){u(!0);try{const v=await fetch(`/api/users/${t.username}/follow`,{method:"POST",credentials:"include"});if(v.ok){const w=await v.json();l(w.following)}}catch{}finally{u(!1)}}}const y=e.jsx("div",{className:"w-8 h-8 rounded-full overflow-hidden bg-gray-200 shrink-0 flex items-center justify-center",children:t.avatarUrl?e.jsx("img",{src:t.avatarUrl,alt:t.name,width:32,height:32,className:"w-full h-full object-cover",loading:"lazy"}):e.jsx("span",{className:"text-xs font-bold text-gray-500",children:e.jsx(_,{devId:"5745c8",guard:{file:"src/components/UploaderCredit.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:2e594f378ca3942b64c92d4ef120295c17b25fbd14d6f5e5a40affd85f70dc17"},children:x})})});return e.jsxs("div",{className:"flex items-center gap-2 flex-wrap",children:[p?e.jsxs(O,{to:p,className:"flex items-center gap-2 hover:opacity-80 transition-opacity min-w-0",children:[y,e.jsxs("div",{className:"min-w-0",children:[e.jsx("p",{className:"text-sm font-semibold text-foreground leading-tight truncate",children:e.jsx(_,{devId:"28cd59",guard:{file:"src/components/UploaderCredit.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:642b906d1d3f858a11c9052ebe8ccb9f9c671cbd59ef258092d816278ef5e751"},children:t.name})}),e.jsxs("p",{className:"text-xs text-muted-foreground leading-tight truncate",children:["@",t.username]})]})]}):e.jsxs("div",{className:"flex items-center gap-2 min-w-0",children:[y,e.jsx("div",{className:"min-w-0",children:e.jsx("p",{className:"text-sm font-semibold text-foreground leading-tight truncate",children:e.jsx(_,{devId:"8f51ce",guard:{file:"src/components/UploaderCredit.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:642b906d1d3f858a11c9052ebe8ccb9f9c671cbd59ef258092d816278ef5e751"},children:t.name})})})]}),!m&&t.username&&(r?e.jsxs("button",{onClick:b,disabled:d,className:`inline-flex items-center gap-1 text-xs font-semibold px-2.5 py-1 border transition-colors ${o?"border-gray-300 text-gray-500 hover:border-red-400 hover:text-red-600":"border-primary text-primary hover:bg-primary hover:text-white"} disabled:opacity-60`,children:[d?e.jsx(Rt,{className:"w-3 h-3 animate-spin"}):e.jsx(Dc,{className:"w-3 h-3"}),o?"Following":"Follow"]}):e.jsxs(O,{to:"/login",className:"inline-flex items-center gap-1 text-xs font-semibold px-2.5 py-1 border border-primary text-primary hover:bg-primary hover:text-white transition-colors",children:[e.jsx(Dc,{className:"w-3 h-3"}),"Follow"]}))]})}const zf="https://totalhorsechannel.com",J9={youtube:"YouTube",rumble:"Rumble",vimeo:"Vimeo",box:"Box",other:"Live Stream"},X9={youtube:"Watch on YouTube",rumble:"Watch on Rumble",vimeo:"Watch on Vimeo",box:"Watch on Box",other:"Watch on Source"};function Q9(t,a){const r=t.match(/src="([^"]+)"/i);if(!r)return null;const o=r[1];if(a==="youtube"){const l=o.match(/\/embed\/([^?/]+)/);if(l)return`https://www.youtube.com/watch?v=${l[1]}`}if(a==="rumble"){const l=o.match(/\/embed\/([^/?]+)/);if(l)return`https://rumble.com/${l[1]}`}if(a==="vimeo"){const l=o.match(/\/video\/(\d+)/);if(l)return`https://vimeo.com/${l[1]}`}return o}function eH(t,a){const r=new Date(t);if(!isNaN(r.getTime())&&!Va(r))return r.toLocaleDateString("en-US",{weekday:"long",month:"long",day:"numeric",year:"numeric"});if(a){const o=td(a);if(o)return o.toLocaleDateString("en-US",{month:"long",day:"numeric",year:"numeric"})}return""}function tH(t){try{const a=new Date(t);return Va(a)?"":a.toLocaleTimeString("en-US",{hour:"numeric",minute:"2-digit",hour12:!0})}catch{return""}}function sH({html:t,title:a,source:r}){const[o,l]=g.useState(!1),d=g.useRef(null),u=Q9(t,r);return g.useEffect(()=>{l(!1);const m=d.current;if(!m)return;let p=t;if(r==="rumble"){const v=p.match(/src="(https:\/\/rumble\.com\/[^"]+)"/i);let w=v?v[1]:"";if(w&&!w.includes("/embed/")){const C=w.match(/rumble\.com\/([vV][A-Za-z0-9]+)/);C&&(w=`https://rumble.com/embed/${C[1]}/`)}w&&(p=`<iframe class="rumble" width="640" height="360" src="${w}" frameborder="0" allowfullscreen></iframe>`)}if(r==="youtube"){const v=p.match(/src="([^"]{1,500})"/i);if(v){const w=v[1];if(/youtube(?:-nocookie)?\.com\/embed\//i.test(w))try{const C=new URL(w.replace("youtube-nocookie.com","youtube.com"));C.hostname="www.youtube.com",C.searchParams.set("enablejsapi","1"),C.searchParams.delete("origin"),p=p.replace(v[0],`src="${C.toString()}"`)}catch{}}}m.innerHTML=p;const x=m.querySelector("iframe");
640if(!x){l(!0);return}if(x.style.width="100%",x.style.height="100%",x.style.border="none",x.style.display="block",x.getAttribute("referrerpolicy")||x.setAttribute("referrerpolicy","no-referrer-when-downgrade"),x.removeAttribute("sandbox"),r!=="youtube")return;function b(v){try{const w=typeof v.data=="string"?JSON.parse(v.data):v.data;(w==null?void 0:w.event)==="onError"&&[100,101,150,153].includes(Number(w==null?void 0:w.info))&&l(!0)}catch{}}function y(){l(!0)}return window.addEventListener("message",b),x.addEventListener("error",y),()=>{window.removeEventListener("message",b),x.removeEventListener("error",y)}},[t,r]),o?e.jsxs("div",{className:"w-full aspect-video bg-gray-900 flex flex-col items-center justify-center gap-4 text-white rounded",children:[e.jsx(Fn,{size:40,className:"text-gray-500 mb-1"}),e.jsx("p",{className:"text-base font-bold",children:"Embedding disabled for this video"}),e.jsxs("p",{className:"text-sm text-gray-400 text-center max-w-sm px-4",children:["The video owner has turned off embedding. You can still watch it directly on ",J9[r]??"the source site","."]}),u&&e.jsxs("a",{href:u,target:"_blank",rel:"noopener noreferrer",className:"mt-2 inline-flex items-center gap-2 bg-primary text-white text-sm font-semibold px-6 py-3 rounded hover:bg-primary/90 transition-colors",children:[e.jsx(dt,{size:15}),X9[r]??"Watch on Source"]})]}):e.jsx("div",{ref:d,className:"w-full aspect-video bg-black rounded overflow-hidden","aria-label":a})}function aH({slug:t}){const[a,r]=g.useState(!1),[o,l]=g.useState(""),[d,u]=g.useState("idle");async function m(p){p.preventDefault(),u("sending");try{await fetch(`/api/live-events/${encodeURIComponent(t)}/report`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({reason:o})}),u("sent")}catch{u("error")}}return a?d==="sent"?e.jsx("span",{className:"text-xs text-green-700 font-medium",children:"Report received — thank you."}):e.jsxs("form",{onSubmit:m,className:"flex flex-col gap-2 max-w-sm",children:[e.jsx("p",{className:"text-xs font-semibold text-gray-700",children:"Report this content"}),e.jsx("textarea",{rows:2,maxLength:500,value:o,onChange:p=>l(p.target.value),placeholder:"Optional: describe the issue (e.g. not horse-related, inappropriate)",className:"w-full border border-gray-300 px-2 py-1.5 text-xs resize-none focus:outline-none focus:border-primary"}),d==="error"&&e.jsx("p",{className:"text-xs text-red-600",children:"Could not send report. Please try again."}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx("button",{type:"submit",disabled:d==="sending",className:"bg-primary text-white text-xs font-semibold px-3 py-1.5 hover:bg-primary/90 transition-colors disabled:opacity-60",children:e.jsx(_,{devId:"6d109c",guard:{file:"src/pages/live/[slug].tsx",tagName:"button",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:51f32ebf5e7ddce3c3c665aab7ad9403b4cb9d5869d3e8465f7d3d0583a1a11d"},children:d==="sending"?"Sending…":"Send Report"})}),e.jsx("button",{type:"button",onClick:()=>{r(!1),u("idle"),l("")},className:"text-xs text-gray-500 hover:text-gray-800 transition-colors",children:"Cancel"})]})]}):e.jsxs("button",{onClick:()=>r(!0),className:"inline-flex items-center gap-1.5 text-xs text-gray-400 hover:text-red-600 transition-colors",title:"Report this content",children:[e.jsx(t2,{size:12}),"Report"]})}function nH(){var P;const{slug:t}=W1(),[a,r]=g.useState(null),[o,l]=g.useState(null),[d,u]=g.useState(!1),[m,p]=g.useState(null),[x,b]=g.useState(!0),[y,v]=g.useState(!1),[w,C]=g.useState(null),[A,S]=g.useState(!1);if(g.useEffect(()=>{fetch("/api/auth/get-session",{credentials:"include"}).then(E=>E.ok?E.json():null).then(E=>{var U;(U=E==null?void 0:E.user)!=null&&U.id&&p(E.user.id)}).catch(()=>{})},[]),g.useEffect(()=>{t&&(b(!0),v(!1),fetch(`/api/live-events/${t}`).then(E=>E.status===404?(v(!0),null):E.json()).then(E=>{E!=null&&E.event&&r(E.event),E!=null&&E.uploader&&l(E.uploader),u((E==null?void 0:E.isFollowingUploader)??!1)}).catch(()=>v(!0)).finally(()=>b(!1)))},[t]),g.useEffect(()=>{t==="2026-national-show-horse-finals"&&fetch("/api/users/Cindy",{credentials:"include"}).then(E=>E.ok?E.json():null).then(E=>{E!=null&&E.username&&(C({id:`username:${E.username}`,name:E.name??"Cindy",username:E.username,avatarUrl:E.avatarUrl??null}),S(E.viewerFollowing??!1))}).catch(()=>{})},[t]),x)return e.jsx("main",{className:"flex items-center justify-center min-h-[300px]",children:e.jsx(Rt,{className:"animate-spin text-primary",size:28})});if(y||!a)return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Event Not Found – Total Horse Channel"}),e.jsx("meta",{name:"robots",content:"noindex"})]}),e.jsxs("main",{className:"max-w-[800px] mx-auto px-4 py-16 text-center",children:[e.jsx(Fn,{size:40,className:"mx-auto text-gray-300 mb-4"}
640),e.jsx("h1",{className:"text-xl font-bold text-gray-800 mb-2",children:"Event Not Found"}),e.jsx("p",{className:"text-gray-500 text-sm mb-6",children:"This live event may have ended or been removed."}),e.jsx(O,{to:"/watch-live-events",className:"inline-flex items-center gap-2 bg-primary text-white text-sm font-semibold px-5 py-2.5 rounded hover:bg-primary/90 transition-colors",children:"View All Live Events"})]})]});const z=`${zf}/live/${a.slug}`,T=a.thumbnailUrl||`${zf}/assets/images/03d4cc3463b5f931df4f08c7c706f416.png`,M={"@context":"https://schema.org","@type":"VideoObject",name:a.title,description:a.description??`Watch ${a.title} live on Total Horse Channel.`,url:z,thumbnailUrl:T,uploadDate:Va(a.startAt)?((P=td(a.title))==null?void 0:P.toISOString())??void 0:a.startAt,embedUrl:z,publisher:{"@id":`${zf}/#organization`}};return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsxs("title",{children:[a.title," – Total Horse Channel"]}),e.jsx("meta",{name:"description",content:a.description??`Watch ${a.title} live on Total Horse Channel.`}),e.jsx("link",{rel:"canonical",href:z}),e.jsx("meta",{property:"og:title",content:`${a.title} – Total Horse Channel`}),e.jsx("meta",{property:"og:description",content:a.description??`Watch ${a.title} live on Total Horse Channel.`}),e.jsx("meta",{property:"og:type",content:"video.other"}),e.jsx("meta",{property:"og:url",content:z}),e.jsx("meta",{property:"og:image",content:T}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("meta",{name:"twitter:title",content:`${a.title} – Total Horse Channel`}),e.jsx("meta",{name:"twitter:image",content:T}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify(M)})]}),e.jsx("main",{children:e.jsxs("div",{className:"max-w-[1280px] mx-auto px-4 py-4",children:[e.jsxs("nav",{"aria-label":"Breadcrumb",className:"text-xs text-gray-500 mb-3 flex items-center gap-1",children:[e.jsx(O,{to:"/",className:"hover:text-primary transition-colors",children:"Home"}),e.jsx("span",{children:"/"}),e.jsx(O,{to:"/watch-live-events",className:"hover:text-primary transition-colors",children:"Live Events"}),e.jsx("span",{children:"/"}),e.jsx("span",{className:"text-gray-700 truncate max-w-[200px]",children:e.jsx(_,{devId:"4625fb",guard:{file:"src/pages/live/[slug].tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:b893322d77b54ddd3b75aaf3a20c3209577a9c72c9311f63a879f09f6c47cab6"},children:a.title})})]}),e.jsxs("div",{className:"flex flex-col lg:flex-row gap-6",children:[e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsxs("div",{className:"bg-primary px-3 py-2 mb-0 flex items-center gap-2",children:[e.jsx(Fn,{size:13,className:"text-white shrink-0"}),e.jsx("h1",{className:"text-white font-bold uppercase text-sm tracking-wide flex-1 min-w-0 truncate",children:e.jsx(_,{devId:"e7ddc6",guard:{file:"src/pages/live/[slug].tsx",tagName:"h1",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:b893322d77b54ddd3b75aaf3a20c3209577a9c72c9311f63a879f09f6c47cab6"},children:a.title})})]}),e.jsx(sH,{html:a.embedHtml,title:a.title,source:a.source}),e.jsxs("div",{className:"bg-white border-x border-b border-gray-200 px-4 pt-3 pb-4",children:[e.jsxs("div",{className:"flex items-start justify-between gap-4 flex-wrap",children:[e.jsx(V9,{slug:a.slug,initialViews:a.viewCount??0,initialLikes:a.likeCount??0}),e.jsx("div",{className:"pt-1",children:e.jsx(aH,{slug:a.slug})})]}),o&&t!=="2026-national-show-horse-finals"&&e.jsx("div",{className:"mt-3 pt-3 border-t border-gray-100",children:e.jsx(Hf,{uploader:o,initialFollowing:d,viewerId:m})}),t==="2026-national-show-horse-finals"&&(o||w)&&e.jsxs("div",{className:"mt-3 pt-3 border-t border-gray-100 flex flex-wrap gap-x-6 gap-y-3",children:[o&&e.jsxs("div",{className:"flex flex-col gap-1 min-w-0",children:[e.jsx("span",{className:"text-xs text-muted-foreground font-medium",children:"Stream by"}),e.jsx(Hf,{uploader:o,initialFollowing:d,viewerId:m})]}),w&&e.jsxs("div",{className:"flex flex-col gap-1 min-w-0",children:[e.jsx("span",{className:"text-xs text-muted-foreground font-medium",children:"National Show Horse Registry"}),e.jsx(Hf,{uploader:w,initialFollowing:A,viewerId:m})]})]})]}),e.jsx(O,{to:"/community",className:"flex items-center justify-center w-full text-white font-bold uppercase py-2.5 text-sm bg-primary hover:bg-primary/90 transition-colors mt-3",children:"SHARE PHOTOS & UPDATES"}),(a.slug==="2026-reno-snaffle-bit-futurity-friday"||a.slug==="2026-reno-snaffle-bit-futurity-saturday"||a.slug==="2026-reno-snaffle-bit-futurity-sunday"||a.slug==="2026-reno-snaffle-bit-futurity-monday"||a.slug==="2026-reno-snaffle-bit-futurity-tuesday"||a.slug==="2026-reno-snaffle-bit-futurity-wednesday"||a.slug==="2026-reno-snaffle-bit-futurity-thursday")&&e.jsxs("div",{className:"flex flex-wrap gap-2 mt-3",children:[e.jsxs("a",{href:"https://www.chclivescoring.com/shows.phtml/1811",target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-2 bg-accent text-white font-bold px-4 py-2.5 text-sm hover:opacity-90 transition-opacity",children:[e.jsx(Xs,{size:15}),e.jsx("span",{style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"5d5333",guard:{file:"src/pages/live/[slug].tsx",tagName:"span",sourceKind:"content-key",contentKey:"live_event_page.renoSbfButtons.liveScoring",contentKeyTemplate:null,expressionH
640ash:null},children:kj.renoSbfButtons.liveScoring})}),e.jsx(dt,{size:13,className:"opacity-75"})]}),e.jsxs("a",{href:"/data/RENO+SBF+SCHEDULE+Web+V2026.07.16 (1).pdf",target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-2 border-2 border-accent text-accent font-bold px-4 py-2.5 text-sm hover:bg-accent hover:text-white transition-colors",children:[e.jsx(e2,{size:15}),e.jsx("span",{style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"9f2814",guard:{file:"src/pages/live/[slug].tsx",tagName:"span",sourceKind:"content-key",contentKey:"live_event_page.renoSbfButtons.schedule",contentKeyTemplate:null,expressionHash:null},children:kj.renoSbfButtons.schedule})}),e.jsx(dt,{size:13,className:"opacity-75"})]})]}),e.jsx("div",{className:"mt-4 border border-gray-200 rounded bg-white",children:e.jsx("table",{className:"w-full text-sm",children:e.jsxs("tbody",{children:[e.jsxs("tr",{className:"border-b border-gray-100",children:[e.jsx("td",{className:"px-4 py-2.5 font-semibold text-gray-600 whitespace-nowrap w-32",children:e.jsxs("span",{className:"flex items-center gap-2",children:[e.jsx(ys,{size:14,className:"text-primary shrink-0"}),e.jsx("span",{children:"Date & Time"})]})}),e.jsx("td",{className:"px-4 py-2.5 text-gray-800",children:e.jsx("time",{dateTime:a.startAt,children:[eH(a.startAt,a.title),tH(a.startAt)].filter(Boolean).join(" · ")})})]}),a.providedBy&&e.jsxs("tr",{className:"border-b border-gray-100",children:[e.jsx("td",{className:"px-4 py-2.5 font-semibold text-gray-600 whitespace-nowrap",children:e.jsxs("span",{className:"flex items-center gap-2",children:[e.jsx(Fn,{size:14,className:"text-primary shrink-0"}),e.jsx("span",{children:"Provided by"})]})}),e.jsx("td",{className:"px-4 py-2.5 text-gray-800",children:a.providerLink?e.jsx("a",{href:a.providerLink,target:"_blank",rel:"noopener noreferrer",className:"text-primary hover:underline",children:e.jsx(_,{devId:"dd4a1f",guard:{file:"src/pages/live/[slug].tsx",tagName:"a",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:4338a75a7e6a72eb632d48c779862f687daf529f97ed7c0921393119a7844854"},children:a.providedBy})}):a.providedBy})]}),a.location&&e.jsxs("tr",{className:"border-b border-gray-100",children:[e.jsx("td",{className:"px-4 py-2.5 font-semibold text-gray-600 whitespace-nowrap",children:e.jsxs("span",{className:"flex items-center gap-2",children:[e.jsx(ul,{size:14,className:"text-primary shrink-0"}),e.jsx("span",{children:"Location"})]})}),e.jsx("td",{className:"px-4 py-2.5 text-gray-800",children:a.location})]}),a.description&&e.jsxs("tr",{className:a.moreInfoUrl?"border-b border-gray-100":"",children:[e.jsx("td",{className:"px-4 py-2.5 font-semibold text-gray-600 whitespace-nowrap align-top",children:e.jsxs("span",{className:"flex items-center gap-2 pt-0.5",children:[e.jsx(Ha,{size:14,className:"text-primary shrink-0"}),e.jsx("span",{children:"About"})]})}),e.jsx("td",{className:"px-4 py-2.5 text-gray-700 leading-relaxed",children:a.description})]}),a.moreInfoUrl&&e.jsxs("tr",{children:[e.jsx("td",{className:"px-4 py-2.5 font-semibold text-gray-600 whitespace-nowrap",children:e.jsxs("span",{className:"flex items-center gap-2",children:[e.jsx(dt,{size:14,className:"text-primary shrink-0"}),e.jsx("span",{children:"More Info"})]})}),e.jsx("td",{className:"px-4 py-2.5",children:e.jsx("a",{href:a.moreInfoUrl,target:"_blank",rel:"noopener noreferrer",className:"text-primary hover:underline break-all",children:e.jsx(_,{devId:"fcfd82",guard:{file:"src/pages/live/[slug].tsx",tagName:"a",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:24eba791c88b33100716d88e17d741a08d8acd1feca5cef33419dedbe994ebf0"},children:a.moreInfoUrl})})})]})]})})}),e.jsx(Z9,{slug:a.slug}),a.slug==="amha-world-show-day-1"&&e.jsxs("div",{className:"mt-4 border border-border bg-card flex flex-col sm:flex-row items-stretch gap-0 overflow-hidden",children:[e.jsx("div",{className:"sm:w-1.5 w-full h-1.5 sm:h-auto bg-primary shrink-0"}),e.jsxs("div",{className:"flex-1 px-4 py-3 flex flex-col gap-1.5",children:[e.jsxs("div",{className:"flex items-center gap-2 flex-wrap",children:[e.jsx(zc,{size:14,className:"text-primary shrink-0"}),e.jsx("span",{className:"font-bold text-foreground text-sm uppercase tracking-wide leading-tight",children:"Miniature Horse Category Icon Photo Contest"}),e.jsx("span",{className:"text-xs font-semibold px-1.5 py-0.5 rounded border bg-green-100 text-green-800 border-green-300",children:"Entries Open"})]}),e.jsx("p",{className:"text-muted-foreground text-xs leading-snug",children:"Have a great Miniature Horse photo and the right to use it? Enter — winner becomes the Miniature Horse icon on TotalHorseChannel.com for one year. No AI images."}),e.jsxs("div",{className:"flex items-center gap-3 flex-wrap mt-0.5",children:[e.jsx(O,{to:"/contests#miniature-horse-icon",className:"bg-primary text-white text-xs font-bold uppercase px-3 py-1.5 hover:opacity-90 transition-opacity shrink-0",children:"Enter Contest"}),e.jsx(O,{to:"/contests#miniature-horse-icon",className:"text-accent hover:underline text-xs shrink-0",children:"Contest Rules"})]}),e.jsxs("p",{className:"text-xs text-muted-foreground mt-1",children:["Sponsored by ",e.jsx("span",{className:"font-semibold text-foreground",children:"Total Horse Channel"})]})]})]}),e.jsx("div",{className:"mt-5",children:e.jsxs(O,{to:"/watch-live-events",className:"inline-flex items-center gap-1.5 text-primary text-sm font-medium hover:underline",children:[e.jsx(En,{size:15}),"Back to Live Events"]})})]}),e.jsx("div",{className:"w-full lg:w-[300px] shrink-0",children:e.jsxs("div",{className:"flex flex-col gap-4",children:[e.jsx(zs,{placement:"sidebar-live-event"}),e.jsx(O,{to:"/mission",className:"block w-full text-center font-bold uppercase py-2 text-sm bg-gray-200 text-gray-800 hover:bg-gray-300 transition-colors",children:"Our Mission"}),e.jsx(Cr,{placement:"sidebar-live-220"})]})})]})]})})]})}const gx="https://totalhorsechannel.com",dm=`${gx}/live/upcoming`,rH={youtube:"YouTube",rumble:"Rumble",vimeo:"Vimeo",box:"Box",other:"Live"};function iH(t){try{const a=new Date(t);
640if(!isNaN(a.getTime()))return a.toLocaleString("en-US",{weekday:"short",month:"short",day:"numeric",year:"numeric",hour:"numeric",minute:"2-digit",hour12:!0})}catch{}return An(t)??""}function oH({ev:t}){return e.jsxs(O,{to:`/live/${t.slug}`,className:"flex flex-col border border-blue-200 bg-blue-50 hover:border-blue-500 transition-colors",children:[e.jsxs("div",{className:"relative w-full bg-blue-900 overflow-hidden",style:{aspectRatio:"16/9"},children:[t.thumbnailUrl?e.jsx("img",{src:t.thumbnailUrl,alt:t.title,width:320,height:180,className:"absolute inset-0 w-full h-full object-cover opacity-80",loading:"lazy"}):e.jsx("div",{className:"absolute inset-0 flex items-center justify-center bg-blue-900",children:e.jsx(Ms,{size:28,className:"text-blue-300"})}),e.jsx("div",{className:"absolute top-1.5 left-1.5 bg-blue-700 text-white text-[10px] font-bold uppercase px-1.5 py-0.5 rounded",children:"Upcoming"})]}),e.jsxs("div",{className:"px-2 py-2 flex flex-col gap-1",children:[e.jsx("p",{className:"font-semibold text-foreground leading-snug line-clamp-2",style:{fontSize:"13px"},children:e.jsx(_,{devId:"7e8b3a",guard:{file:"src/pages/live/upcoming.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:940358fa95ea1497f9b63f15c13b830cddaffcfff65328ed4d4d4e8e024ac21d"},children:t.title})}),e.jsxs("div",{className:"flex items-center gap-1.5 text-blue-700 font-medium",style:{fontSize:"11px"},children:[e.jsx(Ms,{size:11}),e.jsx("span",{children:e.jsx(_,{devId:"9dc0f0",guard:{file:"src/pages/live/upcoming.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:c9156d6195964d2f01906f2a0fe3e73f2944f10c2c0f0031de059be3ee069219"},children:iH(t.startAt)})})]}),e.jsxs("div",{className:"flex items-center gap-2 text-muted-foreground",style:{fontSize:"11px"},children:[e.jsx(ys,{size:11}),e.jsx("span",{className:"capitalize",children:e.jsx(_,{devId:"df95d1",guard:{file:"src/pages/live/upcoming.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:984f6eb135fc8b1f393aeaa1b484e6d247f17cc6b8e401df416ee4284fed9752"},children:rH[t.source]??t.source})})]})]})]})}const lH={"@context":"https://schema.org","@type":"WebPage","@id":`${dm}#webpage`,name:"Upcoming Live Events – Total Horse Channel",url:dm,isPartOf:{"@id":`${gx}/#website`},about:{"@id":`${gx}/#organization`}};function cH(){const{upcomingEvents:t,loading:a}=ed();return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Upcoming Live Events – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"See all upcoming live horse shows, western dressage championships, racing events, and more streaming on Total Horse Channel."}),e.jsx("link",{rel:"canonical",href:dm}),e.jsx("meta",{property:"og:title",content:"Upcoming Live Events – Total Horse Channel"}),e.jsx("meta",{property:"og:description",content:"See all upcoming live horse shows, western dressage championships, racing events, and more streaming on Total Horse Channel."}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{property:"og:url",content:dm}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify(lH)})]}),e.jsx("main",{children:e.jsx("div",{className:"max-w-[1280px] mx-auto px-4 py-4",children:e.jsxs("div",{className:"flex flex-col lg:flex-row gap-6",children:[e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsxs("div",{className:"bg-blue-700 px-3 py-2 mb-4 flex items-center gap-2",children:[e.jsx(Ms,{size:14,className:"text-white"}),e.jsx("h1",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Upcoming Live Events"})]}),e.jsxs("div",{className:"mb-3 flex items-center gap-3 text-sm text-muted-foreground",children:[e.jsxs(O,{to:"/watch-live-events",className:"text-accent hover:underline flex items-center gap-1",children:[e.jsx(Fn,{size:13})," Current Live Events"]}),e.jsx("span",{children:"·"}),e.jsx(O,{to:"/live/archives",className:"text-accent hover:underline",children:"Live Archives"}),e.jsx("span",{children:"·"}),e.jsx(O,{to:"/videos",className:"text-accent hover:underline",children:"Videos"})]}),a&&e.jsx("p",{className:"text-muted-foreground text-sm py-4",children:"Loading upcoming events…"}),!a&&t.length===0&&e.jsx("p",{className:"text-muted-foreground text-sm py-4",children:"No upcoming events scheduled at this time. Check back soon!"}),!a&&t.length>0&&e.jsx("div",{style:{display:"grid",gridTemplateColumns:"repeat(auto-fill, minmax(180px, 1fr))",gap:"14px"},children:t.map(r=>e.jsx(oH,{ev:r},r.id))})]}),e.jsxs("div",{className:"w-full lg:w-[300px] shrink-0 flex flex-col gap-4",children:[e.jsx(zs,{placement:"sidebar-upcoming"}),e.jsx(O,{to:"/watch-live-events",className:"block w-full text-center text-white font-bold uppercase py-2 text-sm bg-primary hover:opacity-90 transition-opacity",children:"← Current Live Events"})]})]})})})]})}const bx="https://totalhorsechannel.com",um=`${bx}/live/archives`,Rf=24,dH={youtube:"YouTube",rumble:"Rumble",vimeo:"Vimeo",box:"Box",other:"Live"};function uH({ev:t}){const a=An(t.createdAt,t.title)||An(t.startAt,t.title);return e.jsxs(O,{to:`/live/${t.slug}`,className:"flex flex-col border border-border bg-card hover:border-primary transition-colors group",children:[e.jsxs("div",{className:"relative w-full bg-black overflow-hidden",style:{aspectRatio:"16/9"},children:[t.thumbnailUrl?e.jsx("img",{src:t.thumbnailUrl,alt:t.title,width:320,height:180,className:"absolute inset-0 w-full h-full object-cover group-hover:opacity-90 transition-opacity",loading:"lazy"}):e.jsx("div",{className:"absolute inset-0 flex items-center justify-center bg-gray-900",children:e.jsx(Fn,{size:28,className:"text-gray-600"})}),e.jsx("div",{className:"absolute top-1.5 left-1.5 bg-gray-700 text-white text-[10px] font-bold uppercase px-1.5 py-0.5 rounded",children:"Archive"})]}),e.jsxs("div",{className:"px-2 py-2 flex flex-col gap-1",children:[t.category&&e.jsx("span",{className:"text-[10px] font-bold uppercase tracking-wide text-primary leading-none",children:e.jsx(_,{devId:"a462ef",guard:{file:"src/pages/live/archives.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionH
640ash:"sha256:f824327c0ee15f1f2565a6163c254a601b38b71919e80d7ad2bb943683b217c6"},children:t.category})}),e.jsx("p",{className:"font-semibold text-foreground leading-snug line-clamp-2",style:{fontSize:"13px"},children:e.jsx(_,{devId:"3fe62d",guard:{file:"src/pages/live/archives.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:940358fa95ea1497f9b63f15c13b830cddaffcfff65328ed4d4d4e8e024ac21d"},children:t.title})}),e.jsxs("div",{className:"flex items-center gap-2 text-muted-foreground",style:{fontSize:"11px"},children:[e.jsx(ys,{size:11}),e.jsx("span",{children:e.jsx(_,{devId:"8c1d43",guard:{file:"src/pages/live/archives.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:0e87632cd46bd4907c516317eb6d81fe0f921a23c7643018f21292894b470681"},children:a})}),e.jsx("span",{className:"capitalize",children:e.jsx(_,{devId:"8c1d44",guard:{file:"src/pages/live/archives.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:984f6eb135fc8b1f393aeaa1b484e6d247f17cc6b8e401df416ee4284fed9752"},children:dH[t.source]??t.source})})]}),e.jsxs("div",{className:"flex items-center gap-3 text-muted-foreground",style:{fontSize:"11px"},children:[e.jsxs("span",{className:"flex items-center gap-1",children:[e.jsx(xa,{size:11}),(t.viewCount??0).toLocaleString()]}),e.jsxs("span",{className:"flex items-center gap-1",children:[e.jsx(Gn,{size:11}),(t.likeCount??0).toLocaleString()]})]})]})]})}function mH({total:t,page:a,perPage:r,onPage:o}){const l=Math.max(1,Math.ceil(t/r));if(l<=1)return null;const d=[],u=m=>{d.includes(m)||d.push(m)};u(1),a-2>2&&d.push("ellipsis-start");for(let m=Math.max(2,a-1);m<=Math.min(l-1,a+1);m++)u(m);return a+2<l-1&&d.push("ellipsis-end"),l>1&&u(l),e.jsxs("div",{className:"flex flex-wrap items-center gap-1 text-sm mt-4 mb-2",children:[e.jsxs("button",{onClick:()=>o(a-1),disabled:a===1,className:"flex items-center gap-0.5 px-2 py-1 border border-border hover:bg-muted disabled:opacity-40 disabled:cursor-not-allowed",children:[e.jsx(En,{size:13})," Prev"]}),d.map(m=>typeof m=="string"?e.jsx("span",{className:"px-1 text-muted-foreground",children:"…"},m):e.jsx("button",{onClick:()=>o(m),className:`px-2.5 py-1 border ${a===m?"bg-primary text-white border-primary font-bold":"border-border hover:bg-muted"}`,children:m},m)),e.jsxs("button",{onClick:()=>o(a+1),disabled:a===l,className:"flex items-center gap-0.5 px-2 py-1 border border-border hover:bg-muted disabled:opacity-40 disabled:cursor-not-allowed",children:["Next ",e.jsx(Lt,{size:13})]}),e.jsxs("span",{className:"ml-2 text-xs text-muted-foreground",children:[t," item",t!==1?"s":""," · page ",a," of ",l]})]})}const hH={"@context":"https://schema.org","@type":"WebPage","@id":`${um}#webpage`,name:"Live Event Archives – Total Horse Channel",url:um,isPartOf:{"@id":`${bx}/#website`},about:{"@id":`${bx}/#organization`}};function pH(){const{archivedEvents:t,loading:a}=ed(),[r,o]=g.useState(1),l=t.slice((r-1)*Rf,r*Rf);return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Live Event Archives – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Browse archived live horse events — western dressage, horse racing, show jumping, and more from Total Horse Channel."}),e.jsx("link",{rel:"canonical",href:um}),e.jsx("meta",{property:"og:title",content:"Live Event Archives – Total Horse Channel"}),e.jsx("meta",{property:"og:description",content:"Browse archived live horse events — western dressage, horse racing, show jumping, and more from Total Horse Channel."}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{property:"og:url",content:um}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify(hH)})]}),e.jsx("main",{children:e.jsx("div",{className:"max-w-[1280px] mx-auto px-4 py-4",children:e.jsxs("div",{className:"flex flex-col lg:flex-row gap-6",children:[e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsxs("div",{className:"bg-primary px-3 py-2 mb-4 flex items-center gap-2",children:[e.jsx(Qi,{size:14,className:"text-white"}),e.jsx("h1",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Live Event Archives"})]}),e.jsxs("div",{className:"mb-3 flex items-center gap-3 text-sm text-muted-foreground",children:[e.jsxs(O,{to:"/watch-live-events",className:"text-accent hover:underline flex items-center gap-1",children:[e.jsx(Fn,{size:13})," Current Live Events"]}),e.jsx("span",{children:"·"}),e.jsx(O,{to:"/live/upcoming",className:"text-accent hover:underline",children:"Upcoming"}),e.jsx("span",{children:"·"}),e.jsx(O,{to:"/videos",className:"text-accent hover:underline",children:"Videos"})]}),a&&e.jsx("p",{className:"text-muted-foreground text-sm py-4",children:"Loading archives…"}),!a&&t.length===0&&e.jsx("p",{className:"text-muted-foreground text-sm py-4",children:"No archived events yet."}),!a&&t.length>0&&e.jsxs(e.Fragment,{children:[e.jsx("div",{style:{display:"grid",gridTemplateColumns:"repeat(auto-fill, minmax(180px, 1fr))",gap:"14px"},children:l.map(d=>e.jsx(uH,{ev:d},d.id))}),e.jsx(mH,{total:t.length,page:r,perPage:Rf,onPage:d=>{o(d),window.scrollTo({top:0,behavior:"smooth"})}})]})]}),e.jsxs("div",{className:"w-full lg:w-[300px] shrink-0 flex flex-col gap-4",children:[e.jsx(zs,{placement:"sidebar-archives"}),e.jsx(O,{to:"/watch-live-events",className:"block w-full text-center text-white font-bold uppercase py-2 text-sm bg-primary hover:opacity-90 transition-opacity",children:"← Current Live Events"})]})]})})})]})}const yx="https://totalhorsechannel.com",mm=`${yx}/sponsors-partners`,fH={"@context":"https://schema.org","@type":"WebPage","@id":`${mm}#webpage`,name:"Sponsors & Partners – Total Horse Channel",url:mm,isPartOf:{"@id":`${yx}/#website`},about:{"@id":`${yx}/#organization`}};function xH(){return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Sponsors & Partners – Total Horse Channel"}),e.jsx("meta",{name:"description",content:ri.metaDescription}),e.jsx("link",{rel:"canonical",href:mm}),e.jsx("meta",{property:"og:title",content:"Sponsors & Partners – Total Horse Channel"}),e.jsx("meta",{property:"og:description",content:ri.metaDescription}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{property:"og:url",content:mm}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("meta",{name:"twitter:title",content:"Sponsors & Partners – Total Horse Channel"}),e.jsx("meta",{name:"twitter:description",content:ri.metaDescription}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify(fH)})]}),e.jsx("main",{children:e.jsx("div",{className:"max-w-[1400px] mx-auto px-4 py-4",children:e.jsxs("div",{className:"flex flex-col lg:flex-row gap-6",children:[e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsxs("div",{className:"bg-primary px-3 py-2 mb-4 flex items-center justify-between gap-3",children:[e.jsx("h1",{className:"text-white font-bold uppercase text-sm tracking-wide",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"e8c9d7",guard:{file:"src/pages/sponsors-partners.tsx",tagName:"h1",sourceKind:"content-key",contentKey:"sponsors_partners.pageTitle",contentKeyTemplate:null,expressionH
640ash:null},children:ri.pageTitle})}),e.jsx(O,{to:"/advertise",className:"shrink-0 inline-block px-4 py-1 bg-white text-primary font-bold text-xs uppercase tracking-wide hover:bg-white/90 transition-opacity whitespace-nowrap",children:"Advertise with Us"})]}),e.jsxs("div",{className:"mb-4",children:[e.jsx("h2",{className:"font-bold text-foreground mb-3",style:{whiteSpace:"pre-line",fontSize:"18px",lineHeight:"26px"},children:e.jsx(_,{devId:"3df6b9",guard:{file:"src/pages/sponsors-partners.tsx",tagName:"h2",sourceKind:"content-key",contentKey:"sponsors_partners.intro.heading",contentKeyTemplate:null,expressionHash:null},children:ri.intro.heading})}),ri.intro.body.map(t=>e.jsx("p",{className:"text-foreground mb-3",style:{whiteSpace:"pre-line",fontSize:"14px",lineHeight:"23px"},children:t.text},t.id))]}),e.jsx("div",{className:"border-l-4 border-primary pl-4 mb-6",children:e.jsxs("p",{className:"text-foreground",style:{fontSize:"14px",lineHeight:"23px"},children:["We don't replace other networks or a show's own website. We gather lives, videos, and profiles so fans can find the whole industry in one place."," ",e.jsx(O,{to:"/mission",className:"text-accent hover:underline font-medium",children:"Read our mission →"})]})}),e.jsx("div",{className:"bg-secondary px-3 py-2 mb-5",children:e.jsx("h2",{className:"text-white font-bold uppercase text-sm tracking-wide",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"e847fb",guard:{file:"src/pages/sponsors-partners.tsx",tagName:"h2",sourceKind:"content-key",contentKey:"sponsors_partners.partnersHeading",contentKeyTemplate:null,expressionHash:null},children:ri.partnersHeading})})}),e.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-5 mb-8",children:ri.partners.map(t=>e.jsxs("div",{className:"border border-border bg-card flex flex-col",children:[e.jsx("div",{className:"flex items-center justify-center bg-muted/30 px-8 py-6 border-b border-border",style:{minHeight:"160px"},children:t.logoSrc?e.jsx("img",{src:t.logoSrc,alt:t.logoAlt,width:320,height:150,className:"w-auto max-w-[300px] object-contain",style:{maxHeight:"130px"},loading:"lazy"}):e.jsx("span",{className:"text-muted-foreground text-sm",style:{whiteSpace:"pre-line"},children:t.name})}),e.jsxs("div",{className:"flex flex-col flex-1 px-5 py-4",children:[e.jsx("h3",{className:"font-bold text-foreground mb-2",style:{whiteSpace:"pre-line",fontSize:"15px"},children:t.name}),t.body.map(a=>e.jsx("p",{className:"text-foreground mb-2",style:{whiteSpace:"pre-line",fontSize:"13px",lineHeight:"22px"},children:a.text},a.id)),e.jsx("div",{className:"flex-1"}),t.website||t.ctaLabel?e.jsxs("div",{className:"flex flex-wrap items-center gap-3 mt-3 pt-3 border-t border-border",children:[t.website?e.jsxs("a",{href:t.website,target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-1 text-accent hover:underline text-sm",children:[e.jsx(dt,{size:13}),e.jsx("span",{children:t.websiteLabel||t.website})]}):null,t.ctaLabel?e.jsx("a",{href:t.ctaHref,target:"_blank",rel:"noopener noreferrer",className:"inline-block px-4 py-1.5 bg-primary text-white text-sm font-semibold hover:opacity-90 transition-opacity",style:{whiteSpace:"pre-line"},children:t.ctaLabel}):null]}):null]})]},t.id))}),e.jsxs("div",{className:"bg-primary px-5 py-4 flex flex-col sm:flex-row items-center justify-between gap-4",children:[e.jsx("p",{className:"text-white font-semibold",style:{fontSize:"14px"},children:"Want to reach the horse community? Join the partner list or run an ad."}),e.jsx(O,{to:"/advertise",className:"shrink-0 inline-block px-6 py-2.5 bg-white text-primary font-bold text-sm uppercase tracking-wide hover:bg-white/90 transition-opacity whitespace-nowrap",children:"Advertise with Us"})]})]}),e.jsxs("div",{className:"w-full lg:w-[300px] shrink-0 flex flex-col gap-4",children:[e.jsx(zs,{placement:"sidebar-sponsors"}),e.jsx(O,{to:"/watch-live-events",className:"block w-full text-center text-white font-bold uppercase py-3 text-base bg-primary hover:bg-primary/90 transition-colors",children:"WATCH LIVE EVENTS"}),e.jsx(O,{to:"/",className:"block w-full text-center text-white font-bold uppercase py-2 text-sm bg-secondary hover:opacity-90 transition-opacity",children:"← Back to Home"}),e.jsx(O,{to:"/mission",className:"block w-full text-center font-bold uppercase py-2 text-sm bg-gray-200 text-gray-800 hover:bg-gray-300 transition-colors",children:"Our Mission"})]})]})})})]})}const vx="https://totalhorsechannel.com",hm=`${vx}/help`,gH={"@context":"https://schema.org","@type":"ContactPage","@id":`${hm}
640#webpage`,name:"Help / Tech Support – Total Horse Channel",url:hm,isPartOf:{"@id":`${vx}/#website`},about:{"@id":`${vx}/#organization`}};function bH(){const[t,a]=g.useState(""),[r,o]=g.useState(""),[l,d]=g.useState(""),[u,m]=g.useState(Dn.contactForm.inquiryOptions[0].id),[p,x]=g.useState(""),[b,y]=g.useState("idle"),[v,w]=g.useState("");async function C(A){var z;if(A.preventDefault(),!t.trim()||!l.trim()||!p.trim()){w("Please fill in all required fields.");return}w(""),y("sending");const S=((z=Dn.contactForm.inquiryOptions.find(T=>T.id===u))==null?void 0:z.label)??u;try{if(!(await fetch("/api/help/contact",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:t,phone:r,email:l,inquiry:S,message:p})})).ok)throw new Error("Server error");y("success"),a(""),o(""),d(""),x(""),m(Dn.contactForm.inquiryOptions[0].id)}catch{y("error")}}return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Help / Tech Support – Total Horse Channel"}),e.jsx("meta",{name:"description",content:Dn.metaDescription}),e.jsx("link",{rel:"canonical",href:hm}),e.jsx("meta",{property:"og:title",content:"Help / Tech Support – Total Horse Channel"}),e.jsx("meta",{property:"og:description",content:Dn.metaDescription}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{property:"og:url",content:hm}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify(gH)})]}),e.jsx("main",{children:e.jsx("div",{className:"max-w-[1280px] mx-auto px-4 py-4",children:e.jsxs("div",{className:"flex flex-col lg:flex-row gap-6",children:[e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("div",{className:"bg-primary px-3 py-2 mb-4",children:e.jsx("h1",{className:"text-white font-bold uppercase text-sm tracking-wide",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"89987d",guard:{file:"src/pages/help.tsx",tagName:"h1",sourceKind:"content-key",contentKey:"help.pageTitle",contentKeyTemplate:null,expressionHash:null},children:Dn.pageTitle})})}),e.jsxs("div",{className:"flex flex-col md:flex-row gap-8",children:[e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("h2",{className:"font-bold text-foreground mb-4 text-center",style:{whiteSpace:"pre-line",fontSize:"22px"},children:e.jsx(_,{devId:"c370b3",guard:{file:"src/pages/help.tsx",tagName:"h2",sourceKind:"content-key",contentKey:"help.contactForm.heading",contentKeyTemplate:null,expressionHash:null},children:Dn.contactForm.heading})}),b==="success"?e.jsx("div",{className:"bg-muted border border-border text-foreground rounded p-4 text-sm",children:"Thank you! Your message has been sent. We'll get back to you shortly."}):e.jsxs("form",{onSubmit:C,className:"flex flex-col gap-3",children:[v&&e.jsx("p",{className:"text-destructive text-sm",children:e.jsx(_,{devId:"3fe82e",guard:{file:"src/pages/help.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:1c0238d2a5401216440d3a40ef09cf8a641cbbc703bbdb0cfe4af2625e4564c6"},children:v})}),b==="error"&&e.jsx("p",{className:"text-destructive text-sm",children:"Something went wrong. Please try again or email us directly."}),e.jsxs("div",{children:[e.jsx("label",{htmlFor:"help-name",className:"block text-sm font-semibold text-foreground mb-1",children:"Name"}),e.jsx("input",{id:"help-name",type:"text",value:t,onChange:A=>a(A.target.value),required:!0,className:"w-full border border-border rounded px-3 py-2 text-sm text-foreground bg-background focus:outline-none focus:ring-2 focus:ring-primary"})]}),e.jsxs("div",{children:[e.jsxs("label",{htmlFor:"help-phone",className:"block text-sm font-semibold text-foreground mb-1",children:["Phone ",e.jsx("span",{className:"font-normal text-muted-foreground",children:"(Optional)"})]}),e.jsx("input",{id:"help-phone",type:"tel",value:r,onChange:A=>o(A.target.value),className:"w-full border border-border rounded px-3 py-2 text-sm text-foreground bg-background focus:outline-none focus:ring-2 focus:ring-primary"})]}),e.jsxs("div",{children:[e.jsxs("label",{htmlFor:"help-email",className:"block text-sm font-semibold text-foreground mb-1",children:["Email ",e.jsx("span",{className:"text-destructive",children:"*"})]}
640),e.jsx("input",{id:"help-email",type:"email",value:l,onChange:A=>d(A.target.value),required:!0,className:"w-full border border-border rounded px-3 py-2 text-sm text-foreground bg-background focus:outline-none focus:ring-2 focus:ring-primary"})]}),e.jsxs("div",{children:[e.jsx("label",{htmlFor:"help-inquiry",className:"block text-sm font-semibold text-foreground mb-1",children:"Tell us more about your Inquiry"}),e.jsx("select",{id:"help-inquiry",value:u,onChange:A=>m(A.target.value),className:"w-full border border-border rounded px-3 py-2 text-sm text-foreground bg-background focus:outline-none focus:ring-2 focus:ring-primary",children:Dn.contactForm.inquiryOptions.map(A=>e.jsx("option",{value:A.id,children:A.label},A.id))})]}),e.jsxs("div",{children:[e.jsx("label",{htmlFor:"help-message",className:"block text-sm font-semibold text-foreground mb-1",children:"Message"}),e.jsx("textarea",{id:"help-message",value:p,onChange:A=>x(A.target.value),required:!0,rows:8,className:"w-full border border-border rounded px-3 py-2 text-sm text-foreground bg-background focus:outline-none focus:ring-2 focus:ring-primary resize-y"})]}),e.jsx("div",{children:e.jsx("button",{type:"submit",disabled:b==="sending",className:"bg-primary text-white font-semibold px-5 py-2 rounded text-sm hover:bg-primary/90 disabled:opacity-60 transition-colors",children:e.jsx(_,{devId:"58cc13",guard:{file:"src/pages/help.tsx",tagName:"button",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:11be4e235e914d04d1f4e1b1888ec81085dfeeff1b0c63a9ca0f5b646be6a4a8"},children:b==="sending"?"Sending…":"Submit"})})})]})]}),e.jsxs("div",{className:"w-full md:w-[260px] shrink-0 flex flex-col gap-6",children:[Dn.contactInfo.map(A=>e.jsxs("div",{children:[e.jsx("h3",{className:"font-bold text-foreground border-b border-border pb-1 mb-2",style:{whiteSpace:"pre-line",fontSize:"16px"},children:A.heading}),A.body?e.jsx("p",{className:"text-sm text-foreground mb-2",style:{whiteSpace:"pre-line"},children:A.body}):null,A.email?e.jsxs("p",{className:"text-sm mb-1 flex items-center gap-1",children:[e.jsx(nn,{size:13,className:"text-muted-foreground shrink-0"}),e.jsx("span",{className:"text-foreground",children:"Email: "}),e.jsx("a",{href:`mailto:${A.email}`,className:"text-accent hover:underline",style:{whiteSpace:"pre-line"},children:A.email})]}):null,A.phone?e.jsxs("p",{className:"text-sm mb-1 flex items-center gap-1",children:[e.jsx(lg,{size:13,className:"text-muted-foreground shrink-0"}),e.jsxs("span",{className:"text-foreground",children:["Phone: ",A.phone]})]}):null,A.id==="ci-advertising"&&e.jsx("p",{className:"text-sm mt-1",children:e.jsx(O,{to:"/advertise",className:"text-accent hover:underline",children:"Request our Media Kit"})})]},A.id)),e.jsx("div",{children:Dn.socialLinks.map(A=>e.jsxs("a",{href:A.href,target:"_blank",rel:"noopener noreferrer",className:"flex items-center gap-2 text-foreground font-bold border-b border-border pb-2 mb-2 hover:text-primary transition-colors",style:{fontSize:"15px"},children:[A.id==="sl-rumble"&&e.jsx("img",{src:"/airo-assets/images/social/rumble-logo",alt:"Rumble",width:18,height:18,className:"w-[18px] h-[18px] object-contain shrink-0"}),A.id==="sl-facebook"&&e.jsx(Vm,{size:18,className:"text-accent"}),A.id==="sl-youtube"&&e.jsx(Fm,{size:18,className:"text-primary"}),A.label]},A.id))})]})]})]}),e.jsxs("aside",{className:"w-full lg:w-[340px] shrink-0 flex flex-col gap-4",children:[e.jsx(zs,{placement:"sidebar-help"}),e.jsx(O,{to:"/watch-live-events",className:"block bg-primary text-white text-center font-bold uppercase py-3 px-4 text-sm tracking-wide hover:bg-primary/90 transition-colors",children:"Watch Live Events"}),e.jsx(O,{to:"/",className:"block bg-secondary text-white text-center font-bold uppercase py-3 px-4 text-sm tracking-wide hover:opacity-90 transition-opacity",children:"← Back to Home"}),e.jsx(O,{to:"/mission",className:"block w-full text-center font-bold uppercase py-2 text-sm bg-gray-200 text-gray-800 hover:bg-gray-300 transition-colors",children:"Our Mission"}),e.jsxs("div",{className:"border border-border p-4 text-center",children:[e.jsx("p",{className:"font-bold text-foreground mb-1",style:{fontSize:"14px"},children:"Advertise With Us"}),e.jsx("p",{className:"text-muted-foreground text-xs mb-3",children:"Reach thousands of horse enthusiasts. Request our media kit today."}),e.jsx(O,{to:"/advertise",className:"inline-block bg-primary text-white text-xs font-bold uppercase px-4 py-2 hover:bg-primary/90 transition-colors",children:"Learn More"})]})]})]})})})]})}const jx="https://totalhorsechannel.com",pm=`${jx}/donations`,yH={"@context":"https://schema.org","@type":"WebPage","@id":`${pm}#webpage`,name:"Support Total Horse Channel – Donations",url:pm,isPartOf:{"@id":`${jx}/#website`},about:{"@id":`${jx}/#organization`}},vH={"pm-paypal":{border:"hsl(var(--paypal-brand))",bg:"hsl(var(--paypal-bg))",btnBg:"hsl(var(--paypal-brand))",label:"hsl(var(--paypal-dark))"},"pm-venmo":{border:"hsl(var(--venmo-brand))",bg:"hsl(var(--venmo-bg))",btnBg:"hsl(var(--venmo-brand))",label:"hsl(var(--venmo-dark))"},"pm-zelle":{border:"hsl(var(--zelle-brand, 262 73% 46%))",bg:"hsl(var(--zelle-bg, 262 73% 97%))",btnBg:"hsl(var(--zelle-brand, 262 73% 46%))",label:"hsl(var(--zelle-dark, 262 73% 30%))"}};function jH(){return e.jsx("svg",{viewBox:"0 0 24 24",width:"32",height:"32",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true",children:e.jsx("path",{d:"M7.076 21.337H2.47a.641.641 0 0 1-.633-.74L4.944.901C5.026.382 5.474 0 5.998 0h7.46c2.57 0 4.578.543 5.69 1.81 1.01 1.15 1.304 2.42 1.012 4.287-.023.143-.047.288-.077.437-.983 5.05-4.349 6.797-8.647 6.797h-2.19c-.524 0-.968.382-1.05.9l-1.12 7.106zm14.146-14.42a3.35 3.35 0 0 0-.607-.541c-.013.076-.026.175-.041.254-.93 4.778-4.005 7.201-9.138 7.201h-2.19a.563.563 0 0 0-.556.479l-1.187 7.527h-.506l-.24 1.516a.56.56 0 0 0 .554.647h3.882c.46 0 .85-.334.922-.788.06-.26.76-4.852.8
64016-5.09a.932.932 0 0 1 .923-.788h.58c3.76 0 6.705-1.528 7.565-5.946.36-1.847.174-3.388-.777-4.471z",style:{fill:"hsl(var(--paypal-brand))"}})})}function wH(){return e.jsx("svg",{viewBox:"0 0 24 24",width:"32",height:"32",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true",children:e.jsx("path",{d:"M19.285 0c.683 1.139 1.026 2.278 1.026 3.759 0 4.672-3.988 10.74-7.23 15.013H6.113L3.714 1.026l5.7-.57 1.254 10.17c1.14-1.938 2.621-4.9 2.621-6.95 0-1.14-.228-1.938-.57-2.621z",style:{fill:"hsl(var(--venmo-brand))"}})})}function NH(){return e.jsx("svg",{viewBox:"0 0 24 24",width:"32",height:"32",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true",children:e.jsx("path",{d:"M12 0C5.373 0 0 5.373 0 12s5.373 12 12 12 12-5.373 12-12S18.627 0 12 0zm5.25 16.5H9.563l5.624-9H9.75V6h7.5v1.5L11.625 16.5H17.25v1.5z",style:{fill:"hsl(var(--zelle-brand, 262 73% 46%))"}})})}function SH(){return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Support Total Horse Channel – Donations"}),e.jsx("meta",{name:"description",content:Fi.metaDescription}),e.jsx("link",{rel:"canonical",href:pm}),e.jsx("meta",{property:"og:title",content:"Support Total Horse Channel – Donations"}),e.jsx("meta",{property:"og:description",content:Fi.metaDescription}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{property:"og:url",content:pm}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify(yH)})]}),e.jsx("main",{children:e.jsx("div",{className:"max-w-[1280px] mx-auto px-4 py-4",children:e.jsxs("div",{className:"flex flex-col lg:flex-row gap-6",children:[e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("div",{className:"bg-primary px-3 py-2 mb-4",children:e.jsx("h1",{className:"text-white font-bold uppercase text-sm tracking-wide",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"f13ee3",guard:{file:"src/pages/donations.tsx",tagName:"h1",sourceKind:"content-key",contentKey:"donations.pageTitle",contentKeyTemplate:null,expressionHash:null},children:Fi.pageTitle})})}),e.jsxs("div",{className:"mb-6 border border-border rounded p-5 bg-card",children:[e.jsxs("div",{className:"flex items-start gap-3 mb-3",children:[e.jsx(_c,{size:28,className:"text-primary shrink-0 mt-0.5",fill:"currentColor"}),e.jsx("h2",{className:"font-bold text-foreground leading-snug",style:{whiteSpace:"pre-line",fontSize:"22px"},children:e.jsx(_,{devId:"83cb99",guard:{file:"src/pages/donations.tsx",tagName:"h2",sourceKind:"content-key",contentKey:"donations.intro.heading",contentKeyTemplate:null,expressionHash:null},children:Fi.intro.heading})})]}),e.jsx("p",{className:"text-foreground leading-relaxed",style:{whiteSpace:"pre-line",fontSize:"15px"},children:e.jsx(_,{devId:"aced1b",guard:{file:"src/pages/donations.tsx",tagName:"p",sourceKind:"content-key",contentKey:"donations.intro.body",contentKeyTemplate:null,expressionHash:null},children:Fi.intro.body})})]}),e.jsx("div",{className:"grid grid-cols-1 md:grid-cols-3 gap-4 mb-6",children:Fi.paymentMethods.map(t=>{const a=vH[t.id],r=t.id==="pm-zelle";return e.jsxs("div",{className:"rounded flex flex-col overflow-hidden",style:{border:a?`2px solid ${a.border}`:"2px solid hsl(var(--border))",backgroundColor:a?a.bg:"hsl(var(--card))"},children:[e.jsxs("div",{className:"flex items-center gap-3 px-4 py-3",style:{borderBottom:a?`2px solid ${a.border}`:"2px solid hsl(var(--border))"},children:[t.id==="pm-paypal"&&e.jsx(jH,{}),t.id==="pm-venmo"&&e.jsx(wH,{}),t.id==="pm-zelle"&&e.jsx(NH,{}),e.jsxs("div",{children:[e.jsx("p",{className:"font-bold text-lg leading-tight",style:{whiteSpace:"pre-line",color:a?a.label:"hsl(var(--foreground))"},children:t.name}),!r&&e.jsx("p",{className:"font-mono text-sm font-semibold",style:{whiteSpace:"pre-line",color:a?a.label:"hsl(var(--foreground))"},children:t.handle})]})]}),e.jsxs("div",{className:"flex-1 px-4 py-3 flex flex-col gap-3",children:[e.jsx("p",{className:"text-sm text-foreground leading-snug",style:{whiteSpace:"pre-line"},children:t.instructions}),r?e.jsxs("div",{className:"mt-auto rounded px-3 py-3",style:{backgroundColor:a?a.border:"hsl(var(--muted))"},children:[e.jsx("p",{className:"text-xs font-semibold text-white mb-1",children:"Send to"}),e.jsx("p",{className:"font-mono font-bold text-white",style:{fontSize:"13px",whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis"},children:t.handle}),e.jsx("p",{className:"text-xs text-white/80 mt-1",children:"Use your bank's Zelle. There is no donate link."})]}):e.jsxs("a",{href:t.href,target:"_blank",rel:"noopener noreferrer",className:"block text-center font-bold text-sm py-2 px-4 roun
640ded transition-opacity hover:opacity-90 mt-auto",style:{backgroundColor:a?a.btnBg:"hsl(var(--primary))",color:"hsl(var(--primary-foreground))"},children:["Donate via ",t.name]})]})]},t.id)})}),e.jsxs("div",{className:"bg-muted border border-border rounded p-4 text-center",children:[e.jsx(_c,{size:18,className:"text-primary inline-block mr-2 mb-0.5",fill:"currentColor"}),e.jsx("span",{className:"text-foreground text-sm leading-relaxed",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"41d4df",guard:{file:"src/pages/donations.tsx",tagName:"span",sourceKind:"content-key",contentKey:"donations.thankYou",contentKeyTemplate:null,expressionHash:null},children:Fi.thankYou})})]}),e.jsxs("div",{className:"border border-border rounded p-4 text-center mt-4",children:[e.jsx("p",{className:"font-bold text-foreground mb-2",style:{fontSize:"14px"},children:"Mailing Address"}),e.jsxs("address",{className:"not-italic text-foreground leading-relaxed",style:{fontSize:"14px"},children:["Total Horse Channel",e.jsx("br",{}),"PO Box 773011",e.jsx("br",{}),"Ocala, FL 34477-3011"]})]})]}),e.jsxs("aside",{className:"w-full lg:w-[340px] shrink-0 flex flex-col gap-4",children:[e.jsx(zs,{placement:"sidebar-donations"}),e.jsx(O,{to:"/watch-live-events",className:"block bg-primary text-white text-center font-bold uppercase py-3 px-4 text-sm tracking-wide hover:bg-primary/90 transition-colors",children:"Watch Live Events"}),e.jsx(O,{to:"/",className:"block bg-secondary text-white text-center font-bold uppercase py-3 px-4 text-sm tracking-wide hover:opacity-90 transition-opacity",children:"← Back to Home"}),e.jsx(O,{to:"/mission",className:"block w-full text-center font-bold uppercase py-2 text-sm bg-gray-200 text-gray-800 hover:bg-gray-300 transition-colors",children:"Our Mission"}),e.jsxs("div",{className:"border border-border p-4 text-center",children:[e.jsx("p",{className:"font-bold text-foreground mb-1",style:{fontSize:"14px"},children:"Advertise With Us"}),e.jsx("p",{className:"text-muted-foreground text-xs mb-3",children:"Reach thousands of horse enthusiasts. Request our media kit today."}),e.jsx(O,{to:"/advertise",className:"inline-block bg-primary text-white text-xs font-bold uppercase px-4 py-2 hover:bg-primary/90 transition-colors",children:"Learn More"})]})]})]})})})]})}const wx="https://totalhorsechannel.com",fm=`${wx}/tech-support`,CH={"@context":"https://schema.org","@type":"WebPage","@id":`${fm}#webpage`,name:"Technical Support – Total Horse Channel",url:fm,isPartOf:{"@id":`${wx}/#website`},about:{"@id":`${wx}/#organization`}},kH=[RC,OC,kn,Xi];function TH(){return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Technical Support – Total Horse Channel"}),e.jsx("meta",{name:"description",content:Vo.metaDescription}),e.jsx("link",{rel:"canonical",href:fm}),e.jsx("meta",{property:"og:title",content:"Technical Support – Total Horse Channel"}),e.jsx("meta",{property:"og:description",content:Vo.metaDescription}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{property:"og:url",content:fm}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify(CH)})]}),e.jsx("main",{children:e.jsx("div",{className:"max-w-[1280px] mx-auto px-4 py-4",children:e.jsxs("div",{className:"flex flex-col lg:flex-row gap-6",children:[e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("div",{className:"bg-primary px-3 py-2 mb-4",children:e.jsx("h1",{className:"text-white font-bold uppercase text-sm tracking-wide",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"a335e2",guard:{file:"src/pages/tech-support.tsx",tagName:"h1",sourceKind:"content-key",contentKey:"tech_support.pageTitle",contentKeyTemplate:null,expressionHash:null},children:Vo.pageTitle})})}),e.jsxs("div",{className:"border border-border rounded p-5 bg-card mb-6",children:[e.jsx("h2",{className:"font-bold text-foreground mb-2",style:{whiteSpace:"pre-line",fontSize:"20px"},children:e.jsx(_,{devId:"f862c4",guard:{file:"src/pages/tech-support.tsx",tagName:"h2",sourceKind:"content-key",contentKey:"tech_support.intro.heading",contentKeyTemplate:null,expressionH
640ash:null},children:Vo.intro.heading})}),e.jsx("p",{className:"text-foreground leading-relaxed",style:{whiteSpace:"pre-line",fontSize:"15px"},children:e.jsx(_,{devId:"6c803a",guard:{file:"src/pages/tech-support.tsx",tagName:"p",sourceKind:"content-key",contentKey:"tech_support.intro.body",contentKeyTemplate:null,expressionHash:null},children:Vo.intro.body})})]}),e.jsx("div",{className:"flex flex-col gap-4 mb-6",children:Vo.steps.map((t,a)=>{const r=kH[a]??kn;return e.jsxs("div",{className:"border border-border rounded overflow-hidden",children:[e.jsxs("div",{className:"bg-secondary px-4 py-3 flex items-center gap-3",children:[e.jsx("div",{className:"bg-primary text-white font-bold rounded-full w-7 h-7 flex items-center justify-center shrink-0 text-sm",children:t.number}),e.jsx(r,{size:18,className:"text-white shrink-0"}),e.jsx("h3",{className:"text-white font-bold",style:{whiteSpace:"pre-line",fontSize:"15px"},children:t.title})]}),e.jsxs("div",{className:"px-4 py-4 bg-card",children:[e.jsx("p",{className:"text-foreground leading-relaxed mb-3",style:{whiteSpace:"pre-line",fontSize:"14px"},children:t.body}),t.tips.length>0&&e.jsx("ul",{className:"flex flex-col gap-2",children:t.tips.map(o=>e.jsxs("li",{className:"flex items-start gap-2 text-sm text-foreground",children:[e.jsx("span",{className:"text-primary mt-0.5 shrink-0",children:"✓"}),e.jsx("span",{children:o.text})]},o.id))}),t.id==="step-still-stuck"&&e.jsxs("div",{className:"mt-3 flex flex-wrap gap-3",children:[e.jsxs("a",{href:"mailto:[email protected]",className:"inline-flex items-center gap-2 bg-primary text-white font-semibold text-sm px-4 py-2 rounded hover:bg-primary/90 transition-colors",children:[e.jsx(nn,{size:14}),"Email Support"]}),e.jsx(O,{to:"/help",className:"inline-flex items-center gap-2 bg-secondary text-white font-semibold text-sm px-4 py-2 rounded hover:opacity-90 transition-opacity",children:"Contact Us"})]}),t.id==="step-connection"&&e.jsx("a",{href:"https://www.speedtest.net",target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-1 text-accent text-sm font-semibold hover:underline mt-1",children:"Test your speed at SpeedTest.net →"})]})]},t.id)})}),e.jsx("div",{className:"bg-primary px-3 py-2 mb-4",children:e.jsx("p",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Contact Our Team"})}),e.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-3 gap-4 mb-6",children:[e.jsxs("div",{className:"border border-border rounded p-4 bg-card min-w-0",children:[e.jsx("h3",{className:"font-bold text-foreground border-b border-border pb-2 mb-3",style:{fontSize:"15px"},children:"Customer Service"}),e.jsx("p",{className:"text-sm text-muted-foreground mb-3",children:"Assistance with accounts and billing."}),e.jsxs("div",{className:"flex flex-col gap-2",children:[e.jsxs("a",{href:"mailto:[email protected]",className:"flex items-start gap-2 text-accent hover:underline break-all",style:{fontSize:"11px"},children:[e.jsx(nn,{size:11,className:"shrink-0 mt-0.5"}),"[email protected]"]}),e.jsxs("p",{className:"flex items-center gap-2 text-foreground",style:{fontSize:"11px"},children:[e.jsx(lg,{size:11,className:"text-muted-foreground shrink-0"}),"404.827.8340"]}),e.jsxs("div",{className:"mt-1 pt-2 border-t border-border",children:[e.jsx("p",{className:"text-muted-foreground font-semibold mb-0.5",style:{fontSize:"10px",textTransform:"uppercase",letterSpacing:"0.05em"},children:"Mailing Address"}),e.jsxs("address",{className:"not-italic text-foreground leading-snug",style:{fontSize:"11px"},children:["Total Horse Channel",e.jsx("br",{}),"PO Box 773011",e.jsx("br",{}),"Ocala, FL 34477-3011"]})]})]})]}),e.jsxs("div",{className:"border border-border rounded p-4 bg-card min-w-0",children:[e.jsx("h3",{className:"font-bold text-foreground border-b border-border pb-2 mb-3",style:{fontSize:"15px"},children:"Technical Support"}),e.jsx("p",{className:"text-sm text-muted-foreground mb-3",children:"Playback issues, live stream errors, and device troubleshooting."}),e.jsxs("a",{href:"mailto:[email protected]",className:"flex items-start gap-1 text-accent hover:underline",style:{fontSize:"10.5px",wordBreak:"break-all"}
640,children:[e.jsx(nn,{size:10,className:"shrink-0 mt-0.5"}),"[email protected]"]})]}),e.jsxs("div",{className:"border border-border rounded p-4 bg-card min-w-0",children:[e.jsx("h3",{className:"font-bold text-foreground border-b border-border pb-2 mb-3",style:{fontSize:"15px"},children:"Advertising & Partnerships"}),e.jsx("p",{className:"text-sm text-muted-foreground mb-3",children:"Reach thousands of horse enthusiasts with a targeted campaign."}),e.jsxs("div",{className:"flex flex-col gap-2",children:[e.jsx(O,{to:"/advertise",className:"flex items-center gap-1 text-accent font-semibold hover:underline",style:{fontSize:"11px"},children:"Request our Media Kit →"}),e.jsxs("a",{href:"mailto:[email protected]",className:"flex items-start gap-2 text-accent hover:underline break-all",style:{fontSize:"11px"},children:[e.jsx(nn,{size:11,className:"shrink-0 mt-0.5"}),"[email protected]"]})]})]})]}),e.jsx("div",{className:"bg-primary px-3 py-2 mb-4",children:e.jsx("p",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Follow Total Horse Channel"})}),e.jsxs("div",{className:"flex flex-wrap gap-3 mb-4",children:[e.jsxs("a",{href:"https://rumble.com/c/TotalHorseChannel?e9s=src_v1_sa%2Csrc_v4_sa_o",target:"_blank",rel:"noopener noreferrer",className:"flex items-center gap-2 border border-border rounded px-4 py-2 text-sm font-semibold text-foreground hover:border-primary hover:text-primary transition-colors bg-card",children:[e.jsx("img",{src:"/airo-assets/images/social/rumble-logo",alt:"Rumble",width:16,height:16,className:"w-4 h-4 object-contain"}),"Watch us on Rumble"]}),e.jsxs("a",{href:"https://www.facebook.com/TotalHorseChannel",target:"_blank",rel:"noopener noreferrer",className:"flex items-center gap-2 border border-border rounded px-4 py-2 text-sm font-semibold text-foreground hover:border-accent hover:text-accent transition-colors bg-card",children:[e.jsx(Vm,{size:16,className:"text-accent"}),"Follow us on Facebook"]}),e.jsxs("a",{href:"https://www.youtube.com/@TotalHorseChannel",target:"_blank",rel:"noopener noreferrer",className:"flex items-center gap-2 border border-border rounded px-4 py-2 text-sm font-semibold text-foreground hover:border-primary hover:text-primary transition-colors bg-card",children:[e.jsx(Fm,{size:16,className:"text-primary"}),"Subscribe on YouTube"]})]})]}),e.jsxs("aside",{className:"w-full lg:w-[340px] shrink-0 flex flex-col gap-4",children:[e.jsx(zs,{placement:"sidebar-tech-support"}),e.jsx(O,{to:"/watch-live-events",className:"block bg-primary text-white text-center font-bold uppercase py-3 px-4 text-sm tracking-wide hover:bg-primary/90 transition-colors",children:"Watch Live Events"}),e.jsxs("div",{className:"border border-border p-4 bg-card",children:[e.jsx("p",{className:"font-bold text-foreground mb-3 border-b border-border pb-2",style:{fontSize:"14px"},children:"Helpful Links"}),e.jsxs("div",{className:"flex flex-col gap-2",children:[e.jsx(O,{to:"/help",className:"text-accent text-sm hover:underline",children:"→ Contact Us"}),e.jsx(O,{to:"/watch-live-events",className:"text-accent text-sm hover:underline",children:"→ Watch Live Events"}),e.jsx(O,{to:"/home/wdaa",className:"text-accent text-sm hover:underline",children:"→ WDAA Hub"}),e.jsx("a",{href:"https://www.speedtest.net/",target:"_blank",rel:"noopener noreferrer",className:"text-accent text-sm hover:underline",children:"→ SpeedTest.net"})]})]}),e.jsx(O,{to:"/",className:"block bg-secondary text-white text-center font-bold uppercase py-3 px-4 text-sm tracking-wide hover:opacity-90 transition-opacity",children:"← Back to Home"}),e.jsx(O,{to:"/mission",className:"block w-full text-center font-bold uppercase py-2 text-sm bg-gray-200 text-gray-800 hover:bg-gray-300 transition-colors",children:"Our Mission"}),e.jsxs("div",{className:"border border-border p-4 text-center",children:[e.jsx("p",{className:"font-bold text-foreground mb-1",style:{fontSize:"14px"},children:"Advertise With Us"}),e.jsx("p",{className:"text-muted-foreground text-xs mb-3",children:"Reach thousands of horse enthusiasts. Request our media kit today."}),e.jsx(O,{to:"/advertise",className:"inline-block bg-primary text-white text-xs font-bold uppercase px-4 py-2 hover:bg-primary/90 transition-colors",children:"Learn More"})]})]})]})})})]})}const Nx="https://totalhorsechannel.com",xm=`${Nx}/advertise`,AH={"@context":"https://schema.org","@type":"WebPage","@id":`${xm}#webpage`,name:"Advertise with Total Horse Channel",url:xm,isPartOf:{"@id":`${Nx}/#website`},about:{"@id":`${Nx}/#organization`}};function EH(){return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Advertise – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Reach horse owners, fans, and industry professionals by advertising on Total Horse Channel. View our rates for articles, banners, and partner listings."}),e.jsx("link",{rel:"canonical",href:xm}),e.jsx("meta",{property:"og:title",content:"Advertise – Total Horse Channel"}),e.jsx("meta",{property:"og:description",content:"Reach horse owners, fans, and industry professionals on Total Horse Channel."}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{property:"og:url",content:xm}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify(AH)})]}),e.jsx("main",{children:e.jsx("div",{className:"max-w-[1280px] mx-auto px-4 py-4",children:e.jsxs("div",{className:"flex flex-col lg:flex-row gap-6",children:[e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("div",{className:"bg-primary px-4 py-2 mb-4",children:e.jsx("h1",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Advertise with Total Horse Channel"})}),e.jsx("p",{className:"text-foreground mb-4",style:{fontSize:"15px",lineHeight:"24px"},children:"Reach horse owners, fans, and industry professionals on Total Horse Channel — the horse industry's premier livestream and video destination, covering all breeds and disciplines since 2006."}),e.jsx("div",{className:"border-l-4 border-primary pl-4 mb-6",children:e.jsxs("p",{className:"text-foreground",style:{fontSize:"14px",lineHeight:"23px"},children:["We don't replace other networks or a show's own website. We gather lives, videos, and profiles so fans can find the whole industry in one place."," ",e.jsx(O,{to:"/mission",className:"text-accent hover:underline font-medium",children:"Read our mission →"})]})}),e.jsx("div",{id:"featured-player",className:"bg-primary px-4 py-2 mb-4",children:e.jsx("h2",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Homepage Featured Player"})}),e.jsxs("div",{className:"border border-border bg-card px-5 py-5 mb-6",children:[e.jsx("p",{className:"text-foreground mb-4",style:{fontSize:"14px",lineHeight:"23px"},children:"The homepage video player is a single featured slot. Partners and Total Horse Channel programming fill it until a date is booked. This is a new offering while the site is rolling out."}),e.jsx("p",{className:"font-semibold text-foreground mb-2",style:{fontSize:"14px"},children:"You can buy:"}),e.jsxs("ul",{className:"mb-4 flex flex-col gap-1.5",children:[e.jsxs("li",{className:"flex items-baseline gap-2",style:{fontSize:"14px"},children:[e.jsx("span",{className:"text-primary font-bold shrink-0",children:"Session"}),e.jsx("span",{className:"text-muted-foreground",children:"— up to 5 hours —"}),e.jsx("span",{className:"font-bold text-foreground",children:"$99"})]}),e.jsxs("li",{className:"flex items-baseline gap-2",style:{fontSize:"14px"},children:[e.jsx("span",{className:"text-primary font-bold shrink-0",children:"Day"}),e.jsx("span",{className:"font-bold text-foreground",children:"— $249"})]}),e.jsxs("li",{className:"flex items-baseline gap-2",style:{fontSize:"14px"},children:[e.jsx("span",{className:"text-primary font-bold shrink-0",children:"Week"}),e.jsx("span",{className:"font-bold text-foreground",children:"— $798"})]})]}),e.jsx("p",{className:"text-foreground mb-4",style:{fontSize:"14px",lineHeight:"23px"},children:"We do not replace your site or your player. We embed your stream or video for that window so fans landing on TotalHorseChannel.com see your event first."}),e.jsxs("p",{className:"text-foreground mb-4",style:{fontSize:"14px",lineHeight:"23px"},children:["Dates are first-come by email to"," ",e.jsx("a",{href:"mailto:[email protected]",className:"text-accent hover:underline",children:"[email protected]"}),". Include the date, session or day or week, and the embed or URL."]})]}),e.jsx("div",{className:"bg-secondary px-4 py-2 mb-4",children:e.jsx("h2",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Rumble Featured Session"})}),e.jsxs("div",{className:"border border-border bg-card px-5 py-5 mb-6",children:[e.jsx("p",{className:"text-muted-foreground mb-3",style:{fontSize:"13px",lineHeight:"21px"},children:"Optional add-on."}),e.jsx("p",{className:"text-foreground mb-3",style:{fontSize:"14px",lineHeight:"23px"},children:"We stream one session of your event on the Total Horse Channel Rumble channel and link back to your site. Rumble has featured our partner streams and given Editor's Picks on some of them. That is extra discovery. It does not replace your own livestream."}),e.jsxs("p",{className:"text-foreground mb-3",style:{fontSize:"14px",lineHeight:"23px"},children:["Our Rumble channel recorded"," ",e.jsx("span",{className:"font-bold text-foreground",children:"3,964,887 views"}),"."]}),e.jsxs("p",{className:"text-foreground mb-5",style:{fontSize:"14px",lineHeight:"23px"},children:["Email"," ",e.jsx("a",{href:"mailto:[email protected]",className:"text-accent hover:underline",children:"[email protected]"})," ","with the date and session. Pricing is part of a custom package."]}),e.jsxs("a",{href:"https://rumble.com/c/TotalHorseChannel",target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-2 px-5 py-2.5 font-semibold text-sm hover:opacity-90 transition-opacity",style:{backgroundColor:"hsl(var(--rumble-brand)
640)",color:"hsl(var(--rumble-brand-foreground))"},children:[e.jsx("img",{src:"/airo-assets/images/social/rumble-logo",alt:"",width:18,height:18,className:"h-[18px] w-auto object-contain"}),"Watch on Rumble"]})]}),e.jsx("div",{className:"bg-secondary px-4 py-2 mb-5",children:e.jsx("h2",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Advertising Rates"})}),e.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-4 mb-8",children:uA.RATES.map(t=>e.jsxs("div",{className:"border border-border bg-card flex flex-col",children:[e.jsxs("div",{className:"bg-primary/10 border-b border-border px-4 py-3 flex items-baseline justify-between gap-2",children:[e.jsx("h3",{className:"font-bold text-foreground",style:{fontSize:"14px"},children:t.label}),e.jsxs("div",{className:"text-right shrink-0",children:[e.jsx("span",{className:"font-bold text-primary",style:{fontSize:"20px"},children:t.price}),e.jsx("span",{className:"text-muted-foreground text-xs ml-1",children:t.period})]})]}),e.jsxs("div",{className:"px-4 py-3 flex-1 flex flex-col gap-2",children:[e.jsx("p",{className:"text-foreground",style:{fontSize:"13px",lineHeight:"21px"},children:t.description}),t.restriction&&e.jsxs("p",{style:{fontSize:"13px",lineHeight:"21px"},children:[e.jsx("span",{className:"font-bold text-primary",children:"Some restrictions apply: "}),e.jsx("span",{className:"text-foreground",children:t.restriction})]})]})]},t.id))}),e.jsx("div",{id:"sponsor-a-contest",className:"bg-primary px-4 py-2 mb-4",children:e.jsx("h2",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Sponsor a Contest"})}),e.jsxs("div",{className:"border border-border bg-card px-5 py-5 mb-6",children:[e.jsx("p",{className:"text-foreground mb-4",style:{fontSize:"14px",lineHeight:"23px"},children:"We run the contest on the site. We issue the Visa gift card to the winner. You may also provide a product or item; it ships to us first. Product-only sponsors still pay a listing fee. Rules apply."}),e.jsxs("div",{className:"flex flex-col gap-4 mb-5",children:[e.jsxs("div",{className:"border-b border-border pb-4",children:[e.jsxs("div",{className:"flex items-baseline gap-3 mb-1",children:[e.jsx("span",{className:"font-bold text-primary shrink-0",style:{fontSize:"20px"},children:"$250"}),e.jsx("span",{className:"font-semibold text-foreground",style:{fontSize:"14px"},children:"Photo or category-icon contest"})]}),e.jsx("p",{className:"text-muted-foreground",style:{fontSize:"13px",lineHeight:"20px"},children:"$150 Visa gift card to the winner  +  $100 Total Horse Channel fee. Same style as the Western Dressage Icon contest."}),e.jsx("p",{className:"text-muted-foreground",style:{fontSize:"13px",lineHeight:"20px",marginTop:"4px"},children:"Includes a linked sponsor logo on that contest page and do-follow links in the contest write-up. Not a sitewide banner."})]}),e.jsxs("div",{className:"border-b border-border pb-4",children:[e.jsxs("div",{className:"flex items-baseline gap-3 mb-1",children:[e.jsx("span",{className:"font-bold text-primary shrink-0",style:{fontSize:"20px"},children:"$450"}),e.jsx("span",{className:"font-semibold text-foreground",style:{fontSize:"14px"},children:"Photo plus short story contest"})]}),e.jsx("p",{className:"text-muted-foreground",style:{fontSize:"13px",lineHeight:"20px"},children:"$300 Visa gift card to the winner  +  $150 Total Horse Channel fee."}),e.jsx("p",{className:"text-muted-foreground",style:{fontSize:"13px",lineHeight:"20px",marginTop:"4px"},children:"Includes a linked sponsor logo on that contest page and do-follow links in the contest write-up. Not a sitewide banner."})]}),e.jsxs("div",{children:[e.jsxs("div",{className:"flex items-baseline gap-3 mb-1",children:[e.jsx("span",{className:"font-bold text-primary shrink-0",style:{fontSize:"20px"},children:"$750+"}),e.jsx("span",{className:"font-semibold text-foreground",style:{fontSize:"14px"},children:"Video contest"})]}),e.jsx("p",{className:"text-muted-foreground",style:{fontSize:"13px",lineHeight:"20px"},children:"$500+ Visa gift card to the winner  +  $250+ Total Horse Channel fee. The Horse Music Video Contest is this level."}),e.jsx("p",{className:"text-muted-foreground",style:{fontSize:"13px",lineHeight:"20px",marginTop:"4px"},children:"Includes a linked sponsor logo on that contest page and do-follow links in the contest write-up. Not a sitewide banner."})]})]}),e.jsxs("p",{className:"text-foreground mb-1",style:{fontSize:"14px",lineHeight:"23px"},children:["Email"," ",e.jsx("a",{href:"mailto:[email protected]",className:"text-accent hover:underline",children:"[email protected]"})," ","with the prize and dates."]})]}),e.jsxs("div",{className:"border border-border bg-muted/30 px-5 py-5 mb-6",children:[e.jsx("h2",{className:"font-bold text-foreground mb-2",style:{fontSize:"15px"},children:"Custom Packages"}),e.jsx("p",{className:"text-foreground mb-4",style:{fontSize:"14px",lineHeight:"22px"},children:"Custom packages and higher-tier banner control are available. Whether you want a multi-month campaign, event sponsorship, or a tailored combination of placements, we can build something that works for your budget and goals."}),e.jsx("p",{className:"text-foreground mb-4",style:{fontSize:"14px",lineHeight:"22px"}
640,children:"Contact us to discuss your needs:"}),e.jsxs("a",{href:"mailto:[email protected]",className:"inline-flex items-center gap-2 px-5 py-2.5 bg-primary text-white font-semibold text-sm hover:opacity-90 transition-opacity",children:[e.jsx(nn,{size:15}),"[email protected]"]})]}),e.jsx("div",{className:"flex items-center gap-4",children:e.jsx(O,{to:"/sponsors-partners",className:"text-accent hover:underline text-sm",children:"← View Current Partners"})})]}),e.jsxs("div",{className:"w-full lg:w-[300px] shrink-0 flex flex-col gap-4",children:[e.jsxs("div",{className:"border border-border",children:[e.jsx("div",{className:"bg-secondary px-3 py-2",children:e.jsx("p",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Get in Touch"})}),e.jsxs("div",{className:"p-4 flex flex-col gap-3",children:[e.jsx("p",{className:"text-sm text-foreground",children:"Ready to advertise or have questions? Email us and we'll get back to you quickly."}),e.jsxs("a",{href:"mailto:[email protected]",className:"inline-flex items-center gap-2 text-sm text-accent hover:underline break-all",children:[e.jsx(nn,{size:14}),"[email protected]"]})]})]}),e.jsx(O,{to:"/watch-live-events",className:"block w-full text-center text-white font-bold uppercase py-3 text-base bg-primary hover:bg-primary/90 transition-colors",children:"WATCH LIVE EVENTS"}),e.jsx(O,{to:"/",className:"block w-full text-center text-white font-bold uppercase py-2 text-sm bg-secondary hover:opacity-90 transition-opacity",children:"← Back to Home"}),e.jsx(O,{to:"/mission",className:"block w-full text-center font-bold uppercase py-2 text-sm bg-gray-200 text-gray-800 hover:bg-gray-300 transition-colors",children:"Our Mission"}),e.jsxs("div",{className:"border border-border",children:[e.jsx("div",{className:"bg-secondary px-3 py-2",children:e.jsx("p",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Why Advertise Here?"})}),e.jsx("div",{className:"p-4",children:e.jsx("ul",{className:"flex flex-col gap-2",children:["All breeds & disciplines","Live event audiences","Horse owners & professionals","Global reach since 2006","Engaged equine community"].map(t=>e.jsxs("li",{className:"flex items-start gap-2 text-sm text-foreground",children:[e.jsx("span",{className:"text-primary font-bold mt-0.5",children:"✓"}),e.jsx("span",{children:t})]},t))})})]}),e.jsx("a",{href:"mailto:[email protected]",className:"block w-full",children:e.jsx("img",{src:"/airo-assets/images/pages/advertise/sidebar-thc-promo",alt:"Total Horse Channel — Where the industry meets the viewers! Contact us to advertise.",width:500,height:750,className:"w-full h-auto block",loading:"lazy"})})]})]})})})]})}const Sx="https://totalhorsechannel.com",gm=`${Sx}/breedsdisciplines`,HH={"@context":"https://schema.org","@type":"WebPage","@id":`${gm}#webpage`,name:"Breeds & Disciplines – Total Horse Channel",url:gm,isPartOf:{"@id":`${Sx}/#website`},about:{"@id":`${Sx}/#organization`}},Cx=[{slug:"western-dressage",label:"Western Dressage",title:"Western Dressage Category Icon Photo Contest",prize:"$150 Visa gift card",submissionDates:"September 14 – 19, 2026",votingDates:"September 20–25",status:"closed",winner:"Alex Maximus",contestAnchor:"#western-dressage-icon"},{slug:"reining",label:"Reining",title:"Reining Category Icon Photo Contest",prize:"$150 Visa gift card",submissionDates:"October 2 – 10, 2026",votingDates:"week of October 11",status:"upcoming",opensLabel:"October 2",contestAnchor:"#reining-icon"},{slug:"miniature-horse",label:"Miniature Horse",title:"Miniature Horse Category Icon Photo Contest",prize:"$150 Visa gift card",submissionDates:"September 25 – October 3, 2026",votingDates:"week of October 4",status:"current",opensLabel:"September 25",contestAnchor:"#miniature-horse-icon"}],zH={"akhal-teke":"/airo-assets/images/breeds/akhal-teke","american-quarter-horse":"/airo-assets/images/breeds/american-quarter-horse","american-saddlebred":"/airo-assets/images/breeds/american-saddlebred",andalusian:"/airo-assets/images/breeds/andalusian","anglo-arab":"/airo-assets/images/breeds/anglo-arab",appaloosa:"/airo-assets/images/breeds/appaloosa",arabian:"/airo-assets/images/breeds/arabian","belgian-draft":"/airo-assets/images/breeds/belgian-draft",campolina:"/airo-assets/images/breeds/campolina","cavalo-crioulo":"/airo-assets/images/breeds/cavalo-crioulo",clydesdale:"/airo-assets/images/breeds/clydesdale",connemara:"/airo-assets/images/breeds/connemara","draft
640-horse":"/airo-assets/images/breeds/draft-horse",fjord:"/airo-assets/images/breeds/fjord",friesian:"/airo-assets/images/breeds/friesian","gypsy-vanner":"/airo-assets/images/breeds/gypsy-vanner",hackney:"/airo-assets/images/breeds/hackney",haflinger:"/airo-assets/images/breeds/haflinger",hanoverian:"/airo-assets/images/breeds/hanoverian",icelandic:"/airo-assets/images/breeds/icelandic","irish-sport-horse":"/airo-assets/images/breeds/irish-sport-horse","kentucky-mountain-saddle-horse":"/airo-assets/images/breeds/kentucky-mountain-saddle-horse",lipizzan:"/airo-assets/images/breeds/lipizzan",lusitano:"/airo-assets/images/breeds/lusitano","mangalarga-marchador":"/airo-assets/images/breeds/mangalarga-marchador","miniature-horse":"/airo-assets/images/breeds/miniature-horse","missouri-fox-trotter":"/airo-assets/images/breeds/missouri-fox-trotter",morgan:"/airo-assets/images/breeds/morgan",mustang:"/airo-assets/images/breeds/mustang","paint-horse":"/airo-assets/images/breeds/paint-horse","paso-fino":"/airo-assets/images/breeds/paso-fino",percheron:"/airo-assets/images/breeds/percheron","peruvian-paso":"/airo-assets/images/breeds/peruvian-paso",pinto:"/airo-assets/images/breeds/pinto",pony:"/airo-assets/images/breeds/pony","rocky-mountain-horse":"/airo-assets/images/breeds/rocky-mountain-horse","shetland-pony":"/airo-assets/images/breeds/shetland-pony",shire:"/airo-assets/images/breeds/shire",standardbred:"/airo-assets/images/breeds/standardbred","straight-egyptian-arabian":"/airo-assets/images/breeds/straight-egyptian-arabian","tennessee-walking-horse":"/airo-assets/images/breeds/tennessee-walking-horse",thoroughbred:"/airo-assets/images/breeds/thoroughbred",trakehner:"/airo-assets/images/breeds/trakehner",warmblood:"/airo-assets/images/breeds/warmblood","welsh-pony":"/airo-assets/images/breeds/welsh-pony"},RH={"barrel-racing":"/airo-assets/images/disciplines/barrel-racing",campdraft:"/airo-assets/images/disciplines/campdraft","cowboy-dressage":"/airo-assets/images/disciplines/dressage","cross-country":"/airo-assets/images/disciplines/cross-country",cutting:"/airo-assets/images/disciplines/cutting",dressage:"/airo-assets/images/disciplines/dressage","dressage-to-music-freestyle":"/airo-assets/images/disciplines/dressage-freestyle",driving:"/airo-assets/images/disciplines/driving",endurance:"/airo-assets/images/disciplines/endurance",eventing:"/airo-assets/images/disciplines/eventing",farms:"/airo-assets/images/disciplines/farms",foals:"/airo-assets/images/disciplines/foals","4-h":"/airo-assets/images/disciplines/horse-show",halter:"/airo-assets/images/disciplines/halter","harness-racing":"/airo-assets/images/disciplines/harness-racing","horse-racing":"/airo-assets/images/disciplines/horse-racing","horse-for-sale":"/airo-assets/images/disciplines/horse-for-sale","horse-sale":"/airo-assets/images/disciplines/horse-sale","horse-show":"/airo-assets/images/disciplines/horse-show",hunter:"/airo-assets/images/disciplines/hunter","mounted-archery":"/airo-assets/images/disciplines/mounted-archery","mounted-s
640hooting":"/airo-assets/images/disciplines/mounted-shooting","horse-music-videos":"/airo-assets/images/disciplines/dressage",polo:"/airo-assets/images/disciplines/polo","ranch-riding":"/airo-assets/images/disciplines/ranch-riding","reined-cow-horse":"/airo-assets/images/disciplines/reining",reining:"/airo-assets/images/disciplines/reining",rodeo:"/airo-assets/images/disciplines/rodeo",roping:"/airo-assets/images/disciplines/roping","show-jumping":"/airo-assets/images/disciplines/show-jumping",sporthorse:"/airo-assets/images/disciplines/sporthorse",trail:"/airo-assets/images/disciplines/trail",vaulting:"/airo-assets/images/disciplines/vaulting","western-dressage":"/airo-assets/images/disciplines/western-dressage","western-pleasure":"/airo-assets/images/disciplines/western-pleasure","other-general":"/airo-assets/images/disciplines/trail"};function _H(){return e.jsxs("a",{href:"/category/western-dressage",className:"flex border border-border rounded-sm overflow-hidden bg-card hover:border-primary transition-colors",style:{textDecoration:"none",minHeight:"90px"},children:[e.jsx("div",{className:"shrink-0",style:{width:"80px"},children:e.jsx("img",{src:"/airo-assets/images/disciplines/western-dressage",alt:"Alex Maximus — Western Dressage Icon Contest Winner",className:"w-full h-full object-cover",style:{display:"block"}})}),e.jsxs("div",{className:"flex flex-col justify-center px-3 py-2 gap-0.5",children:[e.jsxs("div",{className:"flex items-center gap-1.5 mb-0.5",children:[e.jsx(Xs,{size:11,className:"text-primary shrink-0"}),e.jsx("span",{className:"text-primary font-bold uppercase",style:{fontSize:"10px",letterSpacing:"0.04em"},children:"Western Dressage"}),e.jsx("span",{className:"ml-auto bg-primary text-white font-bold rounded-sm px-1.5 py-0.5",style:{fontSize:"9px"},children:"WINNER"})]}),e.jsx("p",{className:"text-foreground font-bold",style:{fontSize:"12px",lineHeight:"1.3"},children:"Alex Maximus"}),e.jsx("p",{className:"text-muted-foreground",style:{fontSize:"11px"},children:"Pete Lichau"}),e.jsx("p",{className:"text-muted-foreground",style:{fontSize:"10px",lineHeight:"1.3",marginTop:"2px"},children:"Category icon for one year · $150 Visa gift card"})]})]})}function LH({contest:t}){return e.jsxs("a",{href:`/contests${t.contestAnchor}`,className:"flex border border-border rounded-sm overflow-hidden bg-card hover:border-primary transition-colors",style:{textDecoration:"none",minHeight:"90px"},children:[e.jsx("div",{className:"shrink-0 bg-muted flex items-center justify-center",style:{width:"80px"},children:e.jsx("img",{src:`/airo-assets/images/breeds/${t.slug}`,alt:t.label,className:"w-full h-full object-cover",style:{display:"block"},onError:a=>{a.currentTarget.style.display="none"}})}),e.jsxs("div",{className:"flex flex-col justify-center px-3 py-2 gap-0.5",children:[e.jsxs("div",{className:"flex items-center gap-1.5 mb-0.5",children:[e.jsx(Xs,{size:11,className:"text-primary shrink-0"}),e.jsx("span",{className:"text-primary font-bold uppercase",style:{fontSize:"10px",letterSpacing:"0.04em"},children:e.jsx(_,{devId:"6f8f0e",guard:{file:"src/pages/breedsdisciplines.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:42c81aabc3b3bb7e133b155be11c01e30ed4b32777ae60d86e7652b65471df6e"},children:t.label})}),e.jsx("span",{className:"ml-auto bg-green-600 text-white font-bold rounded-sm px-1.5 py-0.5",style:{fontSize:"9px"},children:"ENTRIES OPEN"})]}),e.jsx("p",{className:"text-foreground font-bold",style:{fontSize:"12px",lineHeight:"1.3"},children:"Category Icon Photo Contest"}),e.jsxs("p",{className:"text-muted-foreground",style:{fontSize:"10px",lineHeight:"1.3",marginTop:"2px"},children:["Submissions: ",e.jsx("strong",{children:t.submissionDates})]}),e.jsxs("p",{className:"text-muted-foreground",style:{fontSize:"10px"},children:["Prize: ",e.jsx("strong",{children:t.prize})]})]})]})}function DH(){const t=Cx.filter(a=>a.status==="current");return e.jsxs("div",{id:"contest",className:"mb-6",children:[e.jsx("p",{className:"text-xs font-semibold text-muted-foreground uppercase tracking-wide mb-2",children:"Icon Photo Contests"}),e.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-2 gap-3",children:[e.jsx(_H,{}),t.map(a=>e.jsx(LH,{contest:a},a.slug))]})]})}function OH(){return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Breeds & Disciplines – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Find horse videos by breed or riding discipline. Browse American Quarter Horse, Arabian, Friesian, Dressage, Reining, Show Jumping and more on Total Horse Channel."}),e.jsx("link",{rel:"canonical",href:gm}),e.jsx("meta",{property:"og:title",content:"Breeds & Disciplines – Total Horse Channel"}),e.jsx("meta",{property:"og:description",content:"Find horse videos by breed or riding discipline on Total Horse Channel."}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{property:"og:url",content:gm}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify(HH)})]}),e.jsx("main",{children:e.jsxs("div",{className:"max-w-[1280px] mx-auto px-4 py-6",children:[e.jsxs("div",{className:"text-center mb-6",children:[e.jsx("h1",{className:"text-primary font-bold italic",style:{whiteSpace:"pre-line",fontSize:"26px"},children:e.jsx(_,{devId:"33d418",guard:{file:"src/pages/breedsdisciplines.tsx",tagName:"h1",sourceKind:"content-key",contentKey:"breeds_disciplines.pageTitle",contentKeyTemplate:null,expressionH
640ash:null},children:jf.pageTitle})}),e.jsx("p",{className:"text-foreground mt-1",style:{fontSize:"15px"},children:"Find videos by breed or discipline."})]}),e.jsxs("div",{className:"flex items-start gap-3 bg-muted border border-border rounded-sm px-5 py-4 mb-6",children:[e.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",className:"shrink-0 mt-0.5",width:"18",height:"18",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",style:{color:"hsl(var(--primary))"},children:[e.jsx("circle",{cx:"12",cy:"12",r:"10"}),e.jsx("line",{x1:"12",y1:"8",x2:"12",y2:"12"}),e.jsx("line",{x1:"12",y1:"16",x2:"12.01",y2:"16"})]}),e.jsxs("p",{className:"text-muted-foreground",style:{fontSize:"14px",lineHeight:"1.6"},children:[e.jsx("span",{className:"font-semibold text-foreground",children:"We're still building!"})," Some breed and discipline images are placeholders while we source the perfect photos for each category. We appreciate your patience — accurate images are on the way shortly."]})]}),e.jsx(DH,{}),e.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-8",children:[e.jsxs("div",{children:[e.jsx("div",{className:"bg-primary px-4 py-2 mb-3",children:e.jsx("h2",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Breeds"})}),e.jsx("div",{className:"grid gap-2",style:{gridTemplateColumns:"repeat(auto-fill, minmax(110px, 1fr))"},children:jf.breeds.map(t=>{const a=Cx.find(o=>o.slug===t.slug),r=(a==null?void 0:a.status)==="current";return e.jsxs("a",{href:`/category/${t.slug}`,className:"flex flex-col group",style:{textDecoration:"none"},children:[e.jsxs("div",{className:`w-full overflow-hidden bg-black relative ${a?"border-4 border-yellow-400":"border-2 border-border"}`,style:{aspectRatio:"1/1"},children:[e.jsx("img",{src:zH[t.slug]??"/airo-assets/images/breeds/american-quarter-horse",alt:t.name,width:200,height:200,loading:"lazy",className:"w-full h-full object-cover group-hover:opacity-80 transition-opacity"}),a&&e.jsx("div",{className:"absolute top-0 right-0 z-10 pointer-events-none",children:e.jsx("div",{className:`font-bold leading-none text-center text-white ${r?"bg-primary":"bg-secondary"}`,style:{fontSize:"8px",padding:"3px 5px",letterSpacing:"0.03em"},children:r?"CONTEST":"UPCOMING"})})]}),e.jsx("div",{className:"w-full bg-secondary group-hover:bg-primary transition-colors px-1 py-1 text-center flex items-center justify-center",style:{minHeight:"36px"},children:e.jsx("span",{className:"text-white font-semibold leading-tight",style:{whiteSpace:"pre-line",fontSize:"11px",lineHeight:"14px"},children:t.name})}),a&&e.jsx("a",{href:`/contests${a.contestAnchor}`,onClick:o=>o.stopPropagation(),className:"block text-center font-semibold text-primary hover:underline py-1 bg-card border-x border-b border-border",style:{textDecoration:"none",fontSize:"10px"},children:r?"Enter contest →":`Contest opens ${a.opensLabel} →`})]},t.id)})})]}),e.jsxs("div",{children:[e.jsx("div",{className:"bg-primary px-4 py-2 mb-3",children:e.jsx("h2",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Disciplines"})}),e.jsxs("div",{className:"grid grid-cols-4 gap-2",children:[jf.disciplines.map(t=>{const a=Cx.find(d=>d.slug===t.slug),r=(a==null?void 0:a.status)==="current",o=(a==null?void 0:a.status)==="closed",l=t.slug==="horse-music-videos";return e.jsxs("a",{id:t.slug==="western-dressage"?"discipline-western-dressage":void 0,href:`/category/${t.slug}`,className:"flex flex-col group",style:{textDecoration:"none"},children:[e.jsxs("div",{className:`w-full overflow-hidden bg-black relative ${a?"border-4 border-yellow-400":"border-2 border-border"}`,style:{aspectRatio:"1/1"},children:[e.jsx("img",{src:RH[t.slug]??"/airo-assets/images/disciplines/dressage",alt:t.name,width:200,height:200,loading:"lazy",className:"w-full h-full object-cover group-hover:opacity-80 transition-opacity"}),a&&e.jsx("div",{className:"absolute top-0 right-0 z-10 pointer-events-none",children:e.jsx("div",{className:`font-bold leading-none text-center text-white ${o||r?"bg-primary":"bg-secondary"}`,style:{fontSize:"8px",padding:"3px 5px",letterSpacing:"0.03em"},children:o?"WINNER":r?"CONTEST":"UPCOMING"})}),l&&e.jsx("div",{className:"absolute top-0 right-0 z-10 pointer-events-none",children:e.jsx("div",{className:"bg-primary text-white font-bold leading-none text-center",style:{fontSize:"8px",padding:"3px 5px",letterSpacing:"0.03em"},children:"CONTEST"})})]}),e.jsx("div",{className:"w-full bg-secondary group-hover:bg-primary transition-colors px-1 py-1 text-center flex items-center justify-center",style:{minHeight:"36px"},children:e.jsx("span",{className:"text-white font-semibold leading-tight",style:{whiteSpace:"pre-line",fontSize:"11px",lineHeight:"14px"},children:t.name})}),a&&!o&&e.jsx("a",{href:`/contests${a.contestAnchor}`,onClick:d=>d.stopPropagation(),className:"block text-center font-semibold text-primary hover:underline py-1 bg-card border-x border-b border-border",style:{textDecoration:"none",fontSize:"10px"},children:r?"Enter contest →":`Contest opens ${a.opensLabel} →`}),l&&e.jsx("a",{href:"/contests#horse-music-video",onClick:d=>d.stopPropagation(),className:"block text-center font-semibold text-primary hover:underline py-1 bg-card border-x border-b border-border",style:{textDecoration:"none",fontSize:"10px"},children:"Enter contest →"})]},t.id)}),e.jsx("div",{"aria-hidden":"true"}),e.jsx("div",{"aria-hidden":"true"})]})]})]})]})})]})}const kx="https://totalhorsechannel.com",bm=`${kx}/puzzles`,MH={"@context":"https://schema.org","@type":"WebPage","@id":`${bm}#webpage`,name:"Horse Puzzles – Total Horse Channel",url:bm,isPartOf:{"@id":`${kx}/#website`},about:{"@id":`${kx}/#organization`}};function UH(){return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Horse Puzzles – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Play free jigsaw puzzles made from Total Horse Channel photos. Western Dressage, Arabians, Gypsy Vanners, and more — pick a picture and play on JSPuzzles."}),e.jsx("link",{rel:"canonical",href:bm}),e.jsx("meta",{property:"og:title",content:"Horse Puzzles – Total Horse Channel"}),e.jsx("meta",{property:"og:description",content:"Free jigsaw puzzles from Total Horse Channel photos. Play now on JSPuzzles."}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{property:"og:url",content:bm}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify(MH)})]}),e.jsxs("main",{children:[e.jsxs("div",{className:"bg-secondary py-8 px-4 text-center",children:[e.jsx("h1",{className:"text-white font-bold",style:{whiteSpace:"pre-line",fontSize:"30px"},children:e.jsx(_,{devId:"2d4715",guard:{file:"src/pages/puzzles.tsx",tagName:"h1",sourceKind:"content-key",contentKey:"puzzles.pageTitle",contentKeyTemplate:null,expressionH
640ash:null},children:$o.pageTitle})}),e.jsx("p",{className:"text-white mt-2 max-w-xl mx-auto",style:{whiteSpace:"pre-line",fontSize:"15px",opacity:.9},children:e.jsx(_,{devId:"7d9e8c",guard:{file:"src/pages/puzzles.tsx",tagName:"p",sourceKind:"content-key",contentKey:"puzzles.intro",contentKeyTemplate:null,expressionHash:null},children:$o.intro})}),e.jsx("a",{href:$o.playAllUrl,target:"_blank",rel:"noopener noreferrer",className:"inline-block mt-5 px-6 py-3 bg-primary text-white font-bold rounded-sm hover:opacity-90 transition-opacity",style:{fontSize:"15px",textDecoration:"none"},children:"Play All Puzzles on JSPuzzles"})]}),e.jsxs("div",{className:"max-w-[1100px] mx-auto px-4 py-8",children:[e.jsx("div",{className:"grid grid-cols-2 md:grid-cols-3 lg:grid-cols-4 gap-4",children:$o.puzzles.map(t=>e.jsxs("div",{className:"flex flex-col border border-border bg-card overflow-hidden",children:[e.jsx("div",{className:"w-full bg-black overflow-hidden",style:{aspectRatio:"4/3"},children:e.jsx("img",{src:t.image,alt:t.title,width:400,height:300,loading:"lazy",className:"w-full h-full object-cover"})}),e.jsxs("div",{className:"flex flex-col flex-1 p-3 gap-3",children:[e.jsx("p",{className:"text-foreground font-semibold leading-snug flex-1",style:{whiteSpace:"pre-line",fontSize:"13px"},children:t.title}),e.jsx("a",{href:t.playUrl,target:"_blank",rel:"noopener noreferrer",className:"block text-center bg-primary text-white font-bold py-2 px-3 rounded-sm hover:opacity-90 transition-opacity",style:{fontSize:"13px",textDecoration:"none"},children:"Play"})]})]},t.id))}),e.jsx("div",{className:"text-center mt-8 pb-2",children:e.jsxs("a",{href:$o.playAllUrl,target:"_blank",rel:"noopener noreferrer",className:"text-primary font-semibold hover:underline",style:{fontSize:"14px"},children:[$o.footerLinkText," →"]})})]})]})]})}const Tx="https://totalhorsechannel.com",ym=`${Tx}/become-member`,PH={"@context":"https://schema.org","@type":"WebPage","@id":`${ym}#webpage`,name:"Create Your Free Account – Total Horse Channel",url:ym,isPartOf:{"@id":`${Tx}/#website`},about:{"@id":`${Tx}/#organization`}},KH={bell:e.jsx(Q1,{size:32,strokeWidth:1.5}),video:e.jsx(Vs,{size:32,strokeWidth:1.5}),film:e.jsx(Yn,{size:32,strokeWidth:1.5})},qi="w-full border border-border rounded-sm px-3 py-2 text-sm bg-background text-foreground focus:outline-none focus:ring-2 focus:ring-primary placeholder:text-muted-foreground",IH={horse_lover:null,farm_trainer_business:{name:"Business name",namePlaceholder:"Your farm, stable, or business name"},event_show:{name:"Event name",namePlaceholder:"Your event or show name"},association_org:{name:"Organization name",namePlaceholder:"Your association or organization name"}};function BH(){const{isAuthenticated:t,isPending:a}=Us(),r=ga(),[o,l]=g.useState(""),[d,u]=g.useState(""),[m,p]=g.useState(""),[x,b]=g.useState(""),[y,v]=g.useState(""),[w,C]=g.useState(!1),[A,S]=g.useState(!1),[z,T]=g.useState("horse_lover"),[M,P]=g.useState(""),[E,U]=g.useState(""),[q,H]=g.useState(""),[J,B]=g.useState(!1),[Y,$]=g.useState(!1),[D,W]=g.useState(!1),I=/^[a-zA-Z0-9_]{3,20}$/.test(o),k=o.length>0&&!I?o.length<3?"Username must be at least 3 characters.":o.length>20?"Username must be 20 characters or fewer.":"Only letters, numbers, and underscores allowed.":"",K=IH[z],L=K!==null;if(!a&&t)return e.jsx(yi,{to:"/",replace:!0});async function se(X){if(X.preventDefault(),H(""),!I){H("Please enter a valid username (3–20 characters, letters, numbers, underscores only).");return}if(x!==y){H("Passwords do not match.");return}if(x.length<8){H("Password must be at least 8 characters.");return}if(!w){H("You must agree to the Terms of Service and Privacy Policy.");return}if(L&&!M.trim()){H(`${K.name} is required.`);return}B(!0);try{const le=await _T.email({email:m,password:x,name:d||o,username:o,accountType:z,businessName:L?M.trim():"",website:L?E.trim():""});if(le.error){H(le.error.message||"Registration failed. Please try again.");return}r("/",{replace:!0})}catch{H("An unexpected error occurred. Please try again.")}finally{B(!1)}}return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Register – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Create a free Total Horse Channel account to follow live events, enter photo contests, and share videos."}),e.jsx("link",{rel:"canonical",href:ym}),e.jsx("meta",{property:"og:title",content:"Register – Total Horse Channel"}),e.jsx("meta",{property:"og:description",content:"Create a free account to follow live events, enter contests, and share videos on Total Horse Channel."}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{property:"og:url",content:ym}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify(PH)})]}),e.jsx("main",{children:e.jsxs("div",{className:"max-w-[560px] mx-auto px-4 py-10",children:[e.jsxs("div",{className:"text-center mb-8",children:[e.jsx("h1",{className:"text-foreground font-bold",style:{whiteSpace:"pre-line",fontSize:"26px"},children:e.jsx(_,{devId:"f5c31c",guard:{file:"src/pages/become-member.tsx",tagName:"h1",sourceKind:"content-key",contentKey:"become_member.pageTitle",contentKeyTemplate:null,expressionH
640ash:null},children:ti.pageTitle})}),e.jsx("p",{className:"text-muted-foreground mt-2",style:{whiteSpace:"pre-line",fontSize:"15px",lineHeight:"1.6"},children:e.jsx(_,{devId:"9335b3",guard:{file:"src/pages/become-member.tsx",tagName:"p",sourceKind:"content-key",contentKey:"become_member.subhead",contentKeyTemplate:null,expressionHash:null},children:ti.subhead})})]}),e.jsxs("div",{className:"border border-border rounded-sm bg-card overflow-hidden",children:[e.jsx("div",{className:"bg-primary px-5 py-3",children:e.jsx("span",{className:"text-white font-bold",style:{fontSize:"15px"},children:"Free membership — no credit card required"})}),e.jsxs("form",{className:"px-6 py-6 flex flex-col gap-4",onSubmit:se,"aria-label":"Create account form",children:[q&&e.jsx("div",{className:"bg-red-50 border border-red-200 text-red-700 rounded-sm px-4 py-3 text-sm",children:q}),e.jsxs("fieldset",{className:"flex flex-col gap-2",children:[e.jsxs("legend",{className:"text-sm font-semibold text-foreground mb-1",children:["Account type ",e.jsx("span",{className:"text-primary","aria-hidden":"true",children:"*"})]}),e.jsx("div",{className:"grid grid-cols-1 sm:grid-cols-2 gap-2",children:ti.ACCOUNT_TYPE_OPTIONS.map(X=>e.jsxs("label",{className:`flex items-start gap-2 px-3 py-2.5 border rounded-sm cursor-pointer text-sm transition-colors ${z===X.value?"border-primary bg-red-50 text-foreground font-medium":"border-border bg-background text-foreground hover:border-primary/50"}`,children:[e.jsx("input",{type:"radio",name:"accountType",value:X.value,checked:z===X.value,onChange:()=>{T(X.value),P(""),U("")},className:"accent-primary shrink-0 mt-0.5",disabled:J}),e.jsxs("span",{className:"flex flex-col",children:[e.jsx("span",{style:{whiteSpace:"pre-line"},children:X.label}),X.helper&&e.jsx("span",{className:"text-xs text-muted-foreground font-normal mt-0.5",style:{whiteSpace:"pre-line"},children:X.helper})]})]},X.value))})]}),L&&e.jsxs(e.Fragment,{children:[e.jsxs("div",{className:"flex flex-col gap-1",children:[e.jsxs("label",{htmlFor:"reg-extra-name",className:"text-sm font-semibold text-foreground",children:[K.name," ",e.jsx("span",{className:"text-primary","aria-hidden":"true",children:"*"})]}),e.jsx("input",{id:"reg-extra-name",type:"text",required:!0,className:qi,placeholder:K.namePlaceholder,value:M,onChange:X=>P(X.target.value),disabled:J})]}),e.jsxs("div",{className:"flex flex-col gap-1",children:[e.jsx("label",{htmlFor:"reg-extra-website",className:"text-sm font-semibold text-foreground",children:"Website"}),e.jsx("input",{id:"reg-extra-website",type:"url",className:qi,placeholder:"https://yourwebsite.com",value:E,onChange:X=>U(X.target.value),disabled:J})]})]}),e.jsxs("div",{className:"flex flex-col gap-1",children:[e.jsxs("label",{htmlFor:"reg-username",className:"text-sm font-semibold text-foreground",children:["Username ",e.jsx("span",{className:"text-primary","aria-hidden":"true",children:"*"})]}),e.jsx("input",{id:"reg-username",type:"text",required:!0,autoComplete:"username",className:qi,placeholder:"e.g. horse_lover42",value:o,onChange:X=>l(X.target.value.replace(/\s/g,"")),disabled:J,maxLength:20}),k?e.jsx("p",{className:"text-xs text-red-600 mt-0.5",children:e.jsx(_,{devId:"157110",guard:{file:"src/pages/become-member.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:88a01da711933a2ad75a581fc9b9f4a57aa4c65332814d261bcaca34168acdf0"},children:k})}):o.length>=3&&I?e.jsxs("p",{className:"text-xs text-muted-foreground mt-0.5",children:["Your public profile will be at"," ",e.jsxs("span",{className:"font-medium text-foreground",children:["totalhorsechannel.com/u/",o]})]}):e.jsx("p",{className:"text-xs text-muted-foreground mt-0.5",children:"3–20 characters. Letters, numbers, and underscores only."})]}),e.jsxs("div",{className:"flex flex-col gap-1",children:[e.jsxs("label",{htmlFor:"reg-display-name",className:"text-sm font-semibold text-foreground",children:["Display name ",e.jsx("span",{className:"text-primary","aria-hidden":"true",children:"*"})]}),e.jsx("input",{id:"reg-display-name",type:"text",required:!0,autoComplete:"name",className:qi,placeholder:"Your full name or nickname",value:d,onChange:X=>u(X.target.value),disabled:J}),e.jsx("p",{className:"text-xs text-muted-foreground mt-0.5",children:"Shown publicly on your profile and comments."})]}),e.jsxs("div",{className:"flex flex-col gap-1",children:[e.jsxs("label",{htmlFor:"reg-email",className:"text-sm font-semibold text-foreground",children:["Email ",e.jsx("span",{className:"text-primary","aria-hidden":"true",children:"*"})]}),e.jsx("input",{id:"reg-email",type:"email",required:!0,autoComplete:"email",className:qi,placeholder:"[email protected]",value:m,onChange:X=>p(X.target.value),disabled:J})]}),e.jsxs("div",{className:"flex flex-col gap-1",children:[e.jsxs("label",{htmlFor:"reg-password",className:"text-sm font-semibold text-foreground",children:["Password ",e.jsx("span",{className:"text-primary","aria-hidden":"true",children:"*"})]}),e.jsxs("div",{className:"relative",children:[e.jsx("input",{id:"reg-password",type:Y?"text":"password",required:!0,autoComplete:"new-password",className:qi+" pr-10",placeholder:"Create a password (min 8 characters)",value:x,onChange:X=>b(X.target.value),disabled:J}),e.jsx("button",{type:"button",onClick:()=>$(X=>!X),className:"absolute inset-y-0 right-0 flex items-center px-3 text-muted-foreground hover:text-foreground transition-colors","aria-label":Y?"Hide password":"Show password",tabIndex:-1,
640children:e.jsx(_,{devId:"ec5fb3",guard:{file:"src/pages/become-member.tsx",tagName:"button",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:6313602b5ed2f8a3ba853ff2c503a34229c78c78279f6bc463586a0a0f851261"},children:Y?e.jsx(to,{size:16}):e.jsx(xa,{size:16})})})]})]}),e.jsxs("div",{className:"flex flex-col gap-1",children:[e.jsxs("label",{htmlFor:"reg-confirm-password",className:"text-sm font-semibold text-foreground",children:["Confirm password ",e.jsx("span",{className:"text-primary","aria-hidden":"true",children:"*"})]}),e.jsxs("div",{className:"relative",children:[e.jsx("input",{id:"reg-confirm-password",type:D?"text":"password",required:!0,autoComplete:"new-password",className:qi+" pr-10",placeholder:"Re-enter your password",value:y,onChange:X=>v(X.target.value),disabled:J}),e.jsx("button",{type:"button",onClick:()=>W(X=>!X),className:"absolute inset-y-0 right-0 flex items-center px-3 text-muted-foreground hover:text-foreground transition-colors","aria-label":D?"Hide confirm password":"Show confirm password",tabIndex:-1,children:e.jsx(_,{devId:"218594",guard:{file:"src/pages/become-member.tsx",tagName:"button",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:28a4e8f7a0e763e5284e007c32174c0a0b3e1e8e6bd12ab118e515ac8988a9e8"},children:D?e.jsx(to,{size:16}):e.jsx(xa,{size:16})})})]})]}),e.jsxs("div",{className:"flex flex-col gap-3 pt-1",children:[e.jsxs("label",{className:"flex items-start gap-3 cursor-pointer",children:[e.jsx("input",{type:"checkbox",className:"mt-0.5 accent-primary w-4 h-4 shrink-0",checked:A,onChange:X=>S(X.target.checked),disabled:J}),e.jsx("span",{className:"text-sm text-foreground leading-snug",children:"Email me about live events and new videos"})]}),e.jsxs("label",{className:"flex items-start gap-3 cursor-pointer",children:[e.jsx("input",{type:"checkbox",required:!0,className:"mt-0.5 accent-primary w-4 h-4 shrink-0",checked:w,onChange:X=>C(X.target.checked),disabled:J}),e.jsxs("span",{className:"text-sm text-foreground leading-snug",children:["I agree to the"," ",e.jsx("a",{href:"/#terms",className:"text-primary hover:underline font-medium",children:"Terms of Service"})," ","and"," ",e.jsx("a",{href:"/#privacy",className:"text-primary hover:underline font-medium",children:"Privacy Policy"})," ",e.jsx("span",{className:"text-primary","aria-hidden":"true",children:"*"})]})]})]}),e.jsx("button",{type:"submit",disabled:J,className:"w-full bg-primary text-white font-bold py-3 rounded-sm hover:opacity-90 transition-opacity mt-1 disabled:opacity-60 disabled:cursor-not-allowed",style:{fontSize:"15px"},children:e.jsx(_,{devId:"231cc5",guard:{file:"src/pages/become-member.tsx",tagName:"button",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:d1d3dc3e87b1e1b9763e5d930900e89afbc8550be317f580d793c84356b29016"},children:J?"Creating account…":ti.ctaLabel})}),e.jsxs("p",{className:"text-center text-sm text-foreground border-t border-border pt-4",children:[e.jsxs("span",{style:{whiteSpace:"pre-line"},children:[e.jsx(_,{devId:"6ba27c",guard:{file:"src/pages/become-member.tsx",tagName:"span",sourceKind:"content-key",contentKey:"become_member.loginPrompt",contentKeyTemplate:null,expressionHash:null},children:ti.loginPrompt})," "]}),e.jsx("a",{href:ti.loginHref,className:"text-primary font-semibold hover:underline",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"b3490b",guard:{file:"src/pages/become-member.tsx",tagName:"a",sourceKind:"content-key",contentKey:"become_member.loginLinkLabel",contentKeyTemplate:null,expressionHash:null},children:ti.loginLinkLabel})})]})]})]}),e.jsxs("p",{className:"text-center text-sm text-foreground mt-5",children:["All accounts start as Rookie (free)."," ",e.jsx("a",{href:"/membership",className:"text-primary hover:underline font-semibold",children:"See membership tiers →"})]}),e.jsx("div",{className:"grid grid-cols-1 sm:grid-cols-3 gap-4 mt-10",children:ti.nextSteps.map(X=>e.jsxs("div",{className:"flex flex-col items-center text-center px-4 py-5 border border-border rounded-sm bg-card",children:[e.jsx("div",{className:"text-primary mb-3",children:KH[X.icon]??e.jsx(Q1,{size:32,strokeWidth:1.5})}),e.jsx("h2",{className:"font-bold text-foreground mb-2",style:{whiteSpace:"pre-line",fontSize:"14px"},children:X.title}),e.jsx("p",{className:"text-muted-foreground",style:{whiteSpace:"pre-line",fontSize:"13px",lineHeight:"1.5"},children:X.body})]},X.id))})]})})]})}const Fc="https://totalhorsechannel.com",vm=`${Fc}/membership`,$H={"@context":"https://schema.org","@type":"WebPage","@id":`${vm}#webpage`,name:"Membership Tiers – Total Horse Channel",url:vm,isPartOf:{"@id":`${Fc}/#website`},about:{"@id":`${Fc}/#organization`}};function VH({count:t,active:a}){return e.jsx("div",{className:"flex items-center gap-1 justify-center mb-3",children:Array.from({length:5}).map((r,o)=>e.jsx(Xs,{size:18,className:o<t?a?"text-yellow-500 fill-yellow-400":"text-gray-400 fill-gray-300":"text-gray-200 fill-gray-100"},o))})}function FH(){return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Membership Tiers – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Explore Total Horse Channel membership tiers — Rookie, Maiden, Grand Prix, Invitational, and Championship. Free to join."}),e.jsx("link",{rel:"canonical",href:vm}),e.jsx("meta",{property:"og:title",content:"Membership Tiers – Total Horse Channel"}),e.jsx("meta",{property:"og:description",content:"Explore membership tiers on Total Horse Channel. Free to join — watch, comment, submit events, enter contests, and more."}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{property:"og:url",content:vm}),e.jsx("meta",{property:"og:image",content:`${Fc}/airo-assets/images/disciplines/western-dressage`}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("meta",{name:"twitter:title",content:"Membership Tiers – Total Horse Channel"}),e.jsx("meta",{name:"twitter:description",content:"Explore membership tiers on Total Horse Channel. Free to join."}),e.jsx("meta",{name:"twitter:image",content:`${Fc}/airo-assets/images/disciplines/western-dressage`}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify($H)})]}),e.jsx("main",{children:e.jsxs("div",{className:"max-w-[1100px] mx-auto px-4 py-10",children:[e.jsxs("div",{className:"text-center mb-10",children:[e.jsxs("div",{className:"inline-flex items-center gap-2 bg-primary/10 text-primary text-xs font-semibold px-3 py-1 rounded-full mb-3 uppercase tracking-wide",children:[e.jsx(Xs,{size:13}),"Membership Tiers"]}),e.jsx("h1",{className:"text-foreground font-bold text-3xl md:text-4xl leading-tight mb-3",children:"Total Horse Channel Membership Tiers"}),e.jsx("p",{className:"text-muted-foreground text-base max-w-xl mx-auto leading-relaxed",children:"Create a free Rookie account to get started. Higher tiers can be assigned by Total Horse Channel. Paid upgrades coming soon."})]}),e.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-5 mb-8",children:pA.TIERS.map(t=>e.jsxs("div",{className:["flex flex-col border rounded-sm overflow-hidden",t.available?"border-border bg-card":"border-gray-200 bg-gray-50 opacity-75"].join(" "),children:[e.jsxs("div",{className:["px-5 pt-5 pb-4 text-center",t.available?"bg-card":"bg-gray-50"].join(" "),children:[e.jsx(VH,{count:t.trophies,active:t.available}),e.jsxs("div",{className:"flex items-center justify-center gap-2 mb-1",children:[e.jsx("h2",{className:`font-bold text-xl ${t.available?"text-foreground":"text-gray-400"}`,children:t.name}),t.comingSoon&&e.jsxs("span",{className:"inline-flex items-center gap-1 text-xs bg-gray-200 text-gray-500 px-2 py-0.5 rounded-full font-medium",children:[e.jsx(so,{size:10}),"Coming soon"]}),t.available&&e.jsx("span",{className:"inline-flex items-center gap-1 text-xs bg-green-100 text-green-700 px-2 py-0.5 rounded-full font-medium",children:"Available"})]}),t.key==="rookie"&&e.jsx("div",{className:"mb-1",children:e.jsx("span",{className:"inline-flex items-center text-xs font-bold bg-primary text-white px-2.5 py-0.5 rounded-full uppercase tracking-wide",children:"Free"})}),(t.key==="maiden"||t.key==="grand_prix")&&e.jsx("div",{className:"mb-1",children:e.jsx("span",{className:"inline-flex items-center text-xs text-muted-foreground italic",children:"Price coming soon"})}),e.jsx("p",{className:`text-sm ${t.available?"text-muted-foreground":"text-gray-400"}`,children:t.tagline})]}),e.jsx("div",{className:"border-t border-border"}),e.jsxs("div",{className:"px-5 py-4 flex-1",children:[e.jsx("ul",{className:"space-y-2",children:t.features.map((a,r)=>
640e.jsx("li",{className:"flex items-start gap-2 text-sm",children:a.endsWith(":")?e.jsx("span",{className:"font-semibold text-foreground",children:a}):e.jsxs(e.Fragment,{children:[e.jsx(kn,{size:14,className:`shrink-0 mt-0.5 ${t.available?"text-green-600":"text-gray-300"}`}),e.jsx("span",{className:t.available?"text-foreground":"text-gray-400",children:a})]})},r))}),t.note&&e.jsx("p",{className:"mt-4 text-xs text-muted-foreground italic border-t border-border pt-3",children:t.note})]}),t.cta.label&&e.jsx("div",{className:"px-5 pb-5",children:e.jsxs(O,{to:t.cta.href,className:"flex items-center justify-center gap-2 w-full bg-primary text-white text-sm font-semibold py-2.5 px-4 rounded-sm hover:bg-primary/90 transition-colors",children:[t.cta.label,e.jsx(Lt,{size:14})]})})]},t.key))}),e.jsx("p",{className:"text-sm text-muted-foreground text-center max-w-2xl mx-auto mb-8 leading-relaxed",children:"You can move up or down as your year changes. A track or show that only needs tools for part of the season does not have to stay on a higher tier all year. Paid tiers are not billed yet. When they launch, you choose the level that matches that season."}),e.jsxs("div",{className:"bg-muted border border-border rounded-sm px-5 py-4 text-sm text-muted-foreground max-w-2xl mx-auto",children:[e.jsx("p",{className:"font-semibold text-foreground mb-2",children:"A few things to know:"}),e.jsxs("ul",{className:"space-y-1.5 list-disc list-inside",children:[e.jsx("li",{children:"Viewing Events is public — no account required."}),e.jsx("li",{children:"Submitting or editing an Event requires Maiden tier or higher (or admin)."}),e.jsx("li",{children:"Partner accounts may be assigned a higher tier by Total Horse Channel."})]})]}),e.jsxs("div",{className:"text-center mt-10",children:[e.jsx("p",{className:"text-muted-foreground text-sm mb-4",children:"Already have an account?"}),e.jsxs("div",{className:"flex flex-wrap items-center justify-center gap-3",children:[e.jsx(O,{to:"/login",className:"inline-flex items-center gap-2 border border-border text-foreground text-sm font-semibold px-5 py-2.5 rounded-sm hover:bg-muted transition-colors",children:"Log in"}),e.jsxs(O,{to:"/become-member",className:"inline-flex items-center gap-2 bg-primary text-white text-sm font-semibold px-5 py-2.5 rounded-sm hover:bg-primary/90 transition-colors",children:["Create free account",e.jsx(Lt,{size:14})]})]})]})]})})]})}const Ax="https://totalhorsechannel.com",jm=`${Ax}/login`,WH={"@context":"https://schema.org","@type":"WebPage","@id":`${jm}#webpage`,name:"Log In – Total Horse Channel",url:jm,isPartOf:{"@id":`${Ax}/#website`},about:{"@id":`${Ax}/#organization`}},Xj="w-full border border-border rounded-sm px-3 py-2 text-sm bg-background text-foreground focus:outline-none focus:ring-2 focus:ring-primary placeholder:text-muted-foreground";function qH(){var S,z;const{isAuthenticated:t,isPending:a}=Us(),r=ga(),l=((z=(S=la().state)==null?void 0:S.from)==null?void 0:z.pathname)||"/",[d,u]=g.useState(""),[m,p]=g.useState(""),[x,b]=g.useState(""),[y,v]=g.useState(!1),[w,C]=g.useState(!1);if(!a&&t)return e.jsx(yi,{to:l,replace:!0});async function A(T){T.preventDefault(),b(""),v(!0);try{const M=await RT.email({email:d,password:m});if(M.error){b(M.error.message||"Invalid email or password.");return}r(l,{replace:!0})}catch{b("An unexpected error occurred. Please try again.")}finally{v(!1)}}return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Log In – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Log in to your Total Horse Channel account to follow live events, enter contests, and manage your content."}),e.jsx("link",{rel:"canonical",href:jm}),e.jsx("meta",{property:"og:title",content:"Log In – Total Horse Channel"}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{property:"og:url",content:jm}),e.jsx("meta",{name:"robots",content:"noindex"}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify(WH)})]}),e.jsx("main",{children:e.jsxs("div",{className:"max-w-[420px] mx-auto px-4 py-12",children:[e.jsx("div",{className:"text-center mb-8",children:e.jsx("h1",{className:"text-foreground font-bold",style:{whiteSpace:"pre-line",fontSize:"26px"},children:e.jsx(_,{devId:"b084e5",guard:{file:"src/pages/login.tsx",tagName:"h1",sourceKind:"content-key",contentKey:"login.pageTitle",contentKeyTemplate:null,expressionH
640ash:null},children:Wi.pageTitle})})}),e.jsxs("div",{className:"border border-border rounded-sm bg-card overflow-hidden",children:[e.jsx("div",{className:"bg-primary px-5 py-3",children:e.jsx("span",{className:"text-white font-bold",style:{fontSize:"15px"},children:"Member login"})}),e.jsxs("form",{className:"px-6 py-6 flex flex-col gap-4",onSubmit:A,"aria-label":"Log in form",children:[x&&e.jsx("div",{className:"bg-red-50 border border-red-200 text-red-700 rounded-sm px-4 py-3 text-sm",children:x}),e.jsxs("div",{className:"flex flex-col gap-1",children:[e.jsx("label",{htmlFor:"login-email",className:"text-sm font-semibold text-foreground",children:"Email"}),e.jsx("input",{id:"login-email",type:"email",required:!0,autoComplete:"email",className:Xj,placeholder:"[email protected]",value:d,onChange:T=>u(T.target.value),disabled:y})]}),e.jsxs("div",{className:"flex flex-col gap-1",children:[e.jsxs("div",{className:"flex items-center justify-between",children:[e.jsx("label",{htmlFor:"login-password",className:"text-sm font-semibold text-foreground",children:"Password"}),e.jsx("a",{href:Wi.forgotHref,className:"text-xs text-primary hover:underline",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"7cdf1d",guard:{file:"src/pages/login.tsx",tagName:"a",sourceKind:"content-key",contentKey:"login.forgotLabel",contentKeyTemplate:null,expressionHash:null},children:Wi.forgotLabel})})]}),e.jsxs("div",{className:"relative",children:[e.jsx("input",{id:"login-password",type:w?"text":"password",required:!0,autoComplete:"current-password",className:Xj+" pr-10",placeholder:"Your password",value:m,onChange:T=>p(T.target.value),disabled:y}),e.jsx("button",{type:"button",onClick:()=>C(T=>!T),className:"absolute inset-y-0 right-0 flex items-center px-3 text-muted-foreground hover:text-foreground transition-colors","aria-label":w?"Hide password":"Show password",tabIndex:-1,children:e.jsx(_,{devId:"8a50f9",guard:{file:"src/pages/login.tsx",tagName:"button",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:6313602b5ed2f8a3ba853ff2c503a34229c78c78279f6bc463586a0a0f851261"},children:w?e.jsx(to,{size:16}):e.jsx(xa,{size:16})})})]})]}),e.jsx("button",{type:"submit",disabled:y,className:"w-full bg-primary text-white font-bold py-3 rounded-sm hover:opacity-90 transition-opacity mt-1 disabled:opacity-60 disabled:cursor-not-allowed",style:{fontSize:"15px"},children:e.jsx(_,{devId:"178eee",guard:{file:"src/pages/login.tsx",tagName:"button",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:8e324b1f9037bdb514d401d5df4e82d8c65042657c077035f7b48398b0a5fe23"},children:y?"Signing in…":Wi.ctaLabel})}),e.jsxs("p",{className:"text-center text-sm text-foreground border-t border-border pt-4",children:[e.jsxs("span",{style:{whiteSpace:"pre-line"},children:[e.jsx(_,{devId:"4542e5",guard:{file:"src/pages/login.tsx",tagName:"span",sourceKind:"content-key",contentKey:"login.registerPrompt",contentKeyTemplate:null,expressionHash:null},children:Wi.registerPrompt})," "]}),e.jsx("a",{href:Wi.registerHref,className:"text-primary font-semibold hover:underline",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"5d9a14",guard:{file:"src/pages/login.tsx",tagName:"a",sourceKind:"content-key",contentKey:"login.registerLinkLabel",contentKeyTemplate:null,expressionHash:null},children:Wi.registerLinkLabel})})]})]})]})]})})]})}function YH(){return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Create a Free Account – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Create your free Total Horse Channel account to follow live events, enter contests, and connect with the horse community."}),e.jsx("link",{rel:"canonical",href:"https://totalhorsechannel.com/become-member"}),e.jsx("meta",{name:"robots",content:"noindex, follow"})]}),e.jsx("h1",{className:"sr-only",children:"Create a Free Account"}),e.jsx(yi,{to:"/become-member",replace:!0})]})}function GH(){const[t,a]=g.useState(""),[r,o]=g.useState(!1),[l,d]=g.useState(!1),[u,m]=g.useState("");async function p(x){x.preventDefault(),m(""),o(!0);try{const b=await fetch("/api/auth/forget-password",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({email:t,redirectTo:"/reset-password"})}),y=await b.json().catch(()=>({}));b.ok?d(!0):m(y.message||"Something went wrong. Please try again.")}catch{m("Network error. Please try again.")}finally{o(!1)}}return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Forgot Password – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Reset your Total Horse Channel password."}),e.jsx("link",{rel:"canonical",href:"https://totalhorsechannel.com/forgot-password"}),e.jsx("meta",{name:"robots",content:"noindex"})]}),e.jsx("main",{className:"min-h-[60vh] flex items-center justify-center px-4 py-16",children:e.jsx("div",{className:"w-full max-w-md",children:e.jsxs("div",{className:"border border-border rounded-sm bg-card overflow-hidden shadow-sm",children:[e.jsx("div",{className:"bg-primary px-6 py-4",children:e.jsx("h1",{className:"text-primary-foreground font-bold text-base",children:"Forgot Password"})}),e.jsx("div",{className:"px-6 py-8",children:l?e.jsxs("div",{className:"flex flex-col items-center gap-4 text-center",children:[e.jsx(eo,{className:"text-green-600",size:48}),e.jsx("h2",{className:"font-bold text-lg text-foreground",children:"Check your email"}),e.jsxs("p",{className:"text-sm text-muted-foreground leading-relaxed",children:["We sent a password reset link to ",e.jsx("strong",{children:t}),". Check your inbox (and spam folder) and click the link to set a new password."]}),e.jsx("p",{className:"text-xs text-muted-foreground",children:"The link expires in 1 hour."}),e.jsx(O,{to:"/login",className:"text-sm text-primary hover:underline mt-2",children:"Back to login"})]}):e.jsxs("form",{onSubmit:p,className:"flex flex-col gap-5",children:[e.jsx("p",{className:"text-sm text-muted-foreground leading-relaxed",children:"Enter the email address for your account and we'll send you a link to reset your password."}),e.jsxs("div",{className:"flex flex-col gap-1.5",children:[e.jsx("label",{htmlFor:"fp-email",className:"text-sm font-semibold text-foreground",children:"Email address"}),e.jsx("input",{id:"fp-email",type:"email",required:!0,autoComplete:"email",value:t,onChange:x=>a(x.target.value),placeholder:"[email protected]",disabled:r,className:"border border-border rounded-sm px-3 py-2.5 text-sm bg-background focus:outline-none focus:ring-2 focus:ring-primary/40 focu
640s:border-primary disabled:opacity-60"})]}),u&&e.jsx("p",{className:"text-sm text-destructive bg-destructive/10 border border-destructive/20 rounded-sm px-3 py-2",children:e.jsx(_,{devId:"1247af",guard:{file:"src/pages/forgot-password.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:ca00fccfb408989eddc401062c4d1219a6aceb6b9b55412357f1790862e8f178"},children:u})}),e.jsx("button",{type:"submit",disabled:r,className:"w-full bg-primary text-white font-bold py-3 rounded-sm hover:opacity-90 transition-opacity disabled:opacity-60 disabled:cursor-not-allowed text-sm",children:e.jsx(_,{devId:"16b1da",guard:{file:"src/pages/forgot-password.tsx",tagName:"button",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:fd62779e14f19edcef66519ad8d0f94be030a9a7a13a1fa65fcb5d69b0045e21"},children:r?"Sending…":"Send reset link"})}),e.jsxs("p",{className:"text-center text-sm text-muted-foreground",children:["Remember your password?"," ",e.jsx(O,{to:"/login",className:"text-primary hover:underline font-medium",children:"Sign in"})]})]})})]})})})]})}function ZH(){const[t]=Bm(),a=ga(),r=t.get("token")??"",[o,l]=g.useState(""),[d,u]=g.useState(""),[m,p]=g.useState(!1),[x,b]=g.useState(!1),[y,v]=g.useState(!1),[w,C]=g.useState("");g.useEffect(()=>{if(y){const S=setTimeout(()=>a("/login"),3e3);return()=>clearTimeout(S)}},[y,a]);async function A(S){if(S.preventDefault(),C(""),o!==d){C("Passwords do not match.");return}if(o.length<8){C("Password must be at least 8 characters.");return}if(!r){C("Invalid or missing reset token. Please request a new reset link.");return}b(!0);try{const{error:z}=await zT.resetPassword({newPassword:o,token:r});z?C(z.message||"Reset failed. The link may have expired — please request a new one."):v(!0)}catch{C("Network error. Please try again.")}finally{b(!1)}}return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Reset Password – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Set a new password for your Total Horse Channel account."}),e.jsx("link",{rel:"canonical",href:"https://totalhorsechannel.com/reset-password"}),e.jsx("meta",{name:"robots",content:"noindex"})]}),e.jsx("main",{className:"min-h-[60vh] flex items-center justify-center px-4 py-16",children:e.jsx("div",{className:"w-full max-w-md",children:e.jsxs("div",{className:"border border-border rounded-sm bg-card overflow-hidden shadow-sm",children:[e.jsx("div",{className:"bg-primary px-6 py-4",children:e.jsx("h1",{className:"text-primary-foreground font-bold text-base",children:"Set New Password"})}),e.jsx("div",{className:"px-6 py-8",children:y?e.jsxs("div",{className:"flex flex-col items-center gap-4 text-center",children:[e.jsx(eo,{className:"text-green-600",size:48}),e.jsx("h2",{className:"font-bold text-lg text-foreground",children:"Password updated!"}),e.jsx("p",{className:"text-sm text-muted-foreground",children:"Your password has been changed. Redirecting you to login…"}),e.jsx(O,{to:"/login",className:"text-sm text-primary hover:underline mt-1",children:"Go to login now"})]}):r?e.jsxs("form",{onSubmit:A,className:"flex flex-col gap-5",children:[e.jsx("p",{className:"text-sm text-muted-foreground",children:"Choose a new password for your account."}),e.jsxs("div",{className:"flex flex-col gap-1.5",children:[e.jsx("label",{htmlFor:"rp-password",className:"text-sm font-semibold text-foreground",children:"New password"}),e.jsxs("div",{className:"relative",children:[e.jsx("input",{id:"rp-password",type:m?"text":"password",required:!0,minLength:8,autoComplete:"new-password",value:o,onChange:S=>l(S.target.value),placeholder:"At least 8 characters",disabled:x,className:"w-full border border-border rounded-sm px-3 py-2.5 pr-10 text-sm bg-background focus:outline-none focus:ring-2 focus:ring-primary/40 focus:border-primary disabled:opacity-60"}),e.jsx("button",{type:"button",onClick:()=>p(S=>!S),className:"absolute inset-y-0 right-0 flex items-center px-3 text-muted-foreground hover:text-foreground","aria-label":m?"Hide password":"Show password",tabIndex:-1,
640children:e.jsx(_,{devId:"4ed454",guard:{file:"src/pages/reset-password.tsx",tagName:"button",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:c4e1c6befb9aa67b5170188c3680f5f23a8ae9c3d7eb84f94ded72e44221669e"},children:m?e.jsx(to,{size:16}):e.jsx(xa,{size:16})})})]})]}),e.jsxs("div",{className:"flex flex-col gap-1.5",children:[e.jsx("label",{htmlFor:"rp-confirm",className:"text-sm font-semibold text-foreground",children:"Confirm new password"}),e.jsx("input",{id:"rp-confirm",type:m?"text":"password",required:!0,autoComplete:"new-password",value:d,onChange:S=>u(S.target.value),placeholder:"Repeat your new password",disabled:x,className:"w-full border border-border rounded-sm px-3 py-2.5 text-sm bg-background focus:outline-none focus:ring-2 focus:ring-primary/40 focus:border-primary disabled:opacity-60"})]}),w&&e.jsx("p",{className:"text-sm text-destructive bg-destructive/10 border border-destructive/20 rounded-sm px-3 py-2",children:e.jsx(_,{devId:"65bcc1",guard:{file:"src/pages/reset-password.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:ca00fccfb408989eddc401062c4d1219a6aceb6b9b55412357f1790862e8f178"},children:w})}),e.jsx("button",{type:"submit",disabled:x,className:"w-full bg-primary text-white font-bold py-3 rounded-sm hover:opacity-90 transition-opacity disabled:opacity-60 disabled:cursor-not-allowed text-sm",children:e.jsx(_,{devId:"d8222c",guard:{file:"src/pages/reset-password.tsx",tagName:"button",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:def7a42cc13f613238fb63c18625d5a8da12f711b19193b7e1f5fc16adb8d9ac"},children:x?"Saving…":"Set new password"})}),e.jsx("p",{className:"text-center text-sm text-muted-foreground",children:e.jsx(O,{to:"/forgot-password",className:"text-primary hover:underline",children:"Request a new reset link"})})]}):e.jsxs("div",{className:"flex flex-col gap-4 text-center",children:[e.jsx("p",{className:"text-sm text-destructive",children:"This reset link is invalid or has expired."}),e.jsx(O,{to:"/forgot-password",className:"text-sm text-primary hover:underline",children:"Request a new reset link"})]})})]})})})]})}function B2(t){try{return R2(new Date(t),{addSuffix:!0})}catch{return""}}const JH={wdaa_icon:"WD Icon Contest",horse_music_video:"Horse Music Video",reining:"Reining Contest",miniature_horse:"Miniature Horse Contest"};function XH(t){return t?JH[t]??"Contest Entry":""}function QH({images:t,postId:a}){const[r,o]=g.useState(0);if(t.length===0)return null;const l=u=>{u.preventDefault(),o(m=>(m-1+t.length)%t.length)},d=u=>{u.preventDefault(),o(m=>(m+1)%t.length)};return e.jsxs("div",{className:"relative w-full aspect-[4/3] bg-muted rounded overflow-hidden",children:[e.jsx("img",{src:t[r],alt:`Post photo ${r+1}`,className:"w-full h-full object-cover",loading:"lazy"}),t.length>1&&e.jsxs(e.Fragment,{children:[e.jsx("button",{type:"button",onClick:l,"aria-label":"Previous photo",className:"absolute left-1 top-1/2 -translate-y-1/2 bg-black/50 text-white rounded-full p-0.5 hover:bg-black/70 transition-colors",children:e.jsx(En,{size:16})}),e.jsx("button",{type:"button",onClick:d,"aria-label":"Next photo",className:"absolute right-1 top-1/2 -translate-y-1/2 bg-black/50 text-white rounded-full p-0.5 hover:bg-black/70 transition-colors",children:e.jsx(Lt,{size:16})}),e.jsxs("span",{className:"absolute bottom-1 right-2 text-[10px] text-white bg-black/50 rounded px-1.5 py-0.5",children:[r+1,"/",t.length]})]})]})}function ez({item:t}){const a=t.name||t.username||"Member",r=t.contestSourceType?XH(t.contestSourceType):null;return e.jsxs("article",{className:"border border-border rounded-sm bg-card overflow-hidden",children:[e.jsxs("div",{className:"flex items-center gap-2.5 px-3 pt-3 pb-2",children:[e.jsx(O,{to:`/u/${t.username}`,className:"shrink-0 w-8 h-8 rounded-full bg-muted overflow-hidden flex items-center justify-center","aria-label":`${a}'s profile`,children:t.avatarUrl?e.jsx("img",{src:t.avatarUrl,alt:"",className:"w-full h-full object-cover",loading:"lazy"}):e.jsx(Ha,{size:16,className:"text-muted-foreground"})}),e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsxs("div",{className:"flex items-center gap-1.5 flex-wrap",children:[e.jsx(O,{to:`/u/${t.username}`,className:"text-sm font-semibold text-foreground hover:text-primary transition-colors truncate",children:a}),r&&e.jsxs("span",{className:"inline-flex items-center gap-1 text-[10px] font-semibold px-1.5 py-0.5 rounded border bg-yellow-50 text-yellow-700 border-yellow-200 shrink-0",children:[e.jsx(Xs,{size:9}),r]})]}),e.jsx("time",{dateTime:t.createdAt,className:"text-[11px] text-muted-foreground",children:B2(t.createdAt)})]})]}),t.body&&e.jsx("p",{className:"px-3 pb-2 text-sm text-foreground whitespace-pre-wrap break-words line-clamp-4",children:e.jsx(_,{devId:"a634b8",guard:{file:"src/components/profile/ProfileTimeline.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionH
640ash:"sha256:15afa4c0cffa6cb1ed5b0e16cb534fb3278962def6f554b65d9452608d252fcc"},children:t.body})}),t.images.length>0&&e.jsx("div",{className:"px-3 pb-2",children:e.jsx(QH,{images:t.images,postId:t.id})}),e.jsxs("div",{className:"flex items-center gap-3 px-3 pb-2.5 pt-1 border-t border-border mt-1",children:[e.jsxs("span",{className:"flex items-center gap-1 text-xs text-muted-foreground",children:[e.jsx(_c,{size:12}),t.likeCount]}),e.jsxs("span",{className:"flex items-center gap-1 text-xs text-muted-foreground",children:[e.jsx(ig,{size:12}),t.commentCount]}),e.jsx(O,{to:`/community/p/${t.id}`,className:"ml-auto text-[11px] text-primary hover:underline font-medium",children:"View post →"})]})]})}function tz({item:t}){return e.jsxs("article",{className:"border border-border rounded-sm bg-card overflow-hidden",children:[e.jsxs("div",{className:"flex items-center gap-2 px-3 pt-3 pb-2",children:[e.jsxs("span",{className:"inline-flex items-center gap-1 text-[11px] font-semibold px-2 py-0.5 rounded border bg-yellow-50 text-yellow-700 border-yellow-300",children:[e.jsx(Xs,{size:10}),t.contestLabel]}),e.jsx("time",{dateTime:t.createdAt,className:"ml-auto text-[11px] text-muted-foreground",children:B2(t.createdAt)})]}),e.jsx("div",{className:"px-3 pb-2",children:e.jsx("div",{className:"w-full aspect-[4/3] bg-muted rounded overflow-hidden",children:e.jsx("img",{src:t.imageUrl,alt:t.horseName,className:"w-full h-full object-cover",loading:"lazy"})})}),e.jsxs("div",{className:"px-3 pb-3",children:[e.jsx("p",{className:"text-sm font-semibold text-foreground",children:e.jsx(_,{devId:"419cce",guard:{file:"src/components/profile/ProfileTimeline.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:dcca91f903a87e16d9c273c030de9af39f757bccc7a0a7fa1e42f999b3edf835"},children:t.horseName})}),t.ownerRider&&e.jsx("p",{className:"text-xs text-muted-foreground",children:e.jsx(_,{devId:"419ccf",guard:{file:"src/components/profile/ProfileTimeline.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:7a967c1d4e9ae2ebbf0ccda0b491e79ddfb30ecc9564050264ee4c5b3f25ebb1"},children:t.ownerRider})}),e.jsxs("p",{className:"text-xs text-muted-foreground mt-1 flex items-center gap-1",children:[e.jsx(_c,{size:11}),t.voteCount," ",t.voteCount===1?"vote":"votes"]})]})]})}function sz({username:t,onEmpty:a}){const[r,o]=g.useState([]),[l,d]=g.useState(!0),[u,m]=g.useState(""),p=g.useCallback(async()=>{d(!0),m("");try{const x=await fetch(`/api/users/${encodeURIComponent(t)}/timeline?limit=30`);if(!x.ok)throw new Error("Failed to load");const y=(await x.json()).items??[];o(y),y.length===0&&(a==null||a())}catch{m("Could not load activity.")}finally{d(!1)}},[t]);return g.useEffect(()=>{p()},[p]),l?e.jsx("div",{className:"flex items-center justify-center py-10 text-muted-foreground",children:e.jsx(Rt,{size:20,className:"animate-spin"})}):u?e.jsx("p",{className:"text-sm text-muted-foreground py-6 text-center",children:e.jsx(_,{devId:"70c583",guard:{file:"src/components/profile/ProfileTimeline.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:ca00fccfb408989eddc401062c4d1219a6aceb6b9b55412357f1790862e8f178"},children:u})}):r.length===0?e.jsxs("div",{className:"flex flex-col items-center gap-2 py-10 text-muted-foreground",children:[e.jsx(EC,{size:28,strokeWidth:1.5}),e.jsx("p",{className:"text-sm",children:"No activity yet."})]}):e.jsx("div",{className:"flex flex-col gap-3",children:r.map(x=>x.kind==="post"?e.jsx(ez,{item:x},`post-${x.id}`):e.jsx(tz,{item:x},`entry-${x.id}`))})}const az="https://totalhorsechannel.com",nz=new Set(["grand_prix","invitational","championship"]),rz=new Set(["grand_prix","invitational","championship"]),Qj=new Set(["grand_prix","invitational","championship"]),ew={rookie:"bg-gray-100 text-gray-700 border-gray-300",maiden:"bg-blue-50 text-blue-700 border-blue-300",grand_prix:"bg-yellow-50 text-yellow-700 border-yellow-400",invitational:"bg-purple-50 text-purple-700 border-purple-300",championship:"bg-amber-50 text-amber-700 border-amber-400"},iz={rookie:"Rookie",maiden:"Maiden",grand_prix:"Grand Prix",invitational:"Invitational",championship:"Championship"},oz={horse_lover:"Horse Enthusiast",farm_trainer_business:"Trainer",business:"Business",event_show:"Show",association_org:"Organization",videographer:"Videographer",photographer:"Photographer",media_company:"Media Company"},lz=new Set(["videographer","photographer","media_company"]),cz=ne
640w Set(["grand_prix","invitational","championship"]);function dz(t){try{return new Date(t).toLocaleDateString("en-US",{month:"long",year:"numeric"})}catch{return"—"}}function tw(t){try{return new URL(t.startsWith("http")?t:`https://${t}`).hostname.replace(/^www\./,"")}catch{return t}}const sw=new Set(["grand_prix","invitational","championship"]),qo=20;function uz(){var id,Si;const{username:t}=W1(),r=Us().session,o=ga(),[l,d]=g.useState(null),[u,m]=g.useState(!0),[p,x]=g.useState(!1),[b,y]=g.useState(!1),[v,w]=g.useState(""),C=g.useRef(null),[A,S]=g.useState(!1),[z,T]=g.useState(""),M=g.useRef(null),[P,E]=g.useState(void 0),[U,q]=g.useState(!1),[H,J]=g.useState(!1),[B,Y]=g.useState(""),[$,D]=g.useState([]),[W,I]=g.useState(!1),[k,K]=g.useState(!1),[L,se]=g.useState(""),[X,le]=g.useState(null),[ge,Se]=g.useState(null),[Me,st]=g.useState(!1),We=g.useRef(null),[Ye,te]=g.useState(!1),[me,Le]=g.useState(""),[Ie,ve]=g.useState(""),[ze,Ue]=g.useState(""),[ct,Ot]=g.useState(""),[Et,Zt]=g.useState(!1),[as,Jt]=g.useState(""),[vs,js]=g.useState(!1),[Ws,Mt]=g.useState(!1),[jt,ps]=g.useState(!1),[Wt,ws]=g.useState(""),[os,qt]=g.useState(!1),[je,gt]=g.useState(""),[et,Xe]=g.useState(0),[Ae,De]=g.useState(!1),[ft,Yt]=g.useState(0),[ls,qs]=g.useState(0),[ue,be]=g.useState(!1),[_t,ns]=g.useState(null),[Ct,Ut]=g.useState([]),[Qs,Is]=g.useState(!1),[ba,Tr]=g.useState(""),[wi,Jn]=g.useState([]),[V,G]=g.useState(!1),[ee,fe]=g.useState(null),[xe,Re]=g.useState(""),[Ee,He]=g.useState(""),[ke,$e]=g.useState(""),[Ze,qe]=g.useState(null),[Qe,wt]=g.useState(""),[kt,Gt]=g.useState(!1),[nt,ea]=g.useState(""),[Tt,bt]=g.useState("video"),[ca,ya]=g.useState(!1),[da,fs]=g.useState(""),[un,Ra]=g.useState(!1),[Wa,mn]=g.useState(""),[hn,_a]=g.useState(null),[at,Ht]=g.useState(!1),zt=!!r&&!!t&&((id=r.user.username)==null?void 0:id.toLowerCase())===t.toLowerCase(),pn=!!((Si=r==null?void 0:r.user)!=null&&Si.isAdmin),fn=zt||pn,Bt=zt,ua=!!(r!=null&&r.user);function oo(){t&&(m(!0),x(!1),fetch(`/api/users/${encodeURIComponent(t)}`,{credentials:"include"}).then(async re=>{if(re.status===404){x(!0);return}if(!re.ok)throw new Error("Failed");const Ne=await re.json();d(Ne),De(Ne.viewerFollowing),Yt(Ne.followCount),qs(Ne.followingCount),Xe(Ne.nameChangeCount??0)}).catch(()=>x(!0)).finally(()=>m(!1)))}g.useEffect(oo,[t]),g.useEffect(()=>{if(!(!l||!t)){if(!Qj.has(l.plan)){E(null);return}fetch(`/api/users/${encodeURIComponent(t)}/featured-video`).then(async re=>{if(re.status===404){E(null);return}if(!re.ok){E(null);return}const Ne=await re.json();E(Ne.event)}).catch(()=>E(null))}},[l==null?void 0:l.plan,t]),g.useEffect(()=>{if(!(!l||!t)){if(!sw.has(l.plan)){D([]),I(!0);return}fetch(`/api/users/${encodeURIComponent(t)}/photos`).then(async re=>{if(!re.ok){I(!0);return}const Ne=await re.json();D(Ne.photos??[]),I(!0)}).catch(()=>I(!0))}},[l==null?void 0:l.plan,t]),g.useEffect(()=>{!zt||V||fetch("/api/member/my-videos",{credentials:"include"}).then(re=>re.ok?re.json():{events:[]}).then(re=>{Jn(re.events??[]),G(!0)}).catch(()=>G(!0))},[zt,V]);const ta=g.useCallback(async re=>{if(t){ns(re),Ut([]),Tr(""),Is(!0);try{const Ne=await fetch(`/api/users/${encodeURIComponent(t)}/${re}`);if(!Ne.ok)throw new Error("Failed");const Pe=await Ne.json();Ut(Pe)}catch{Tr("Could not load the list. Please try again.")}finally{Is(!1)}}},[t]);function Ni(){ns(null),Ut([]),Tr("")}async function ad(){if(!ua){o("/signup");return}if(ue)return;be(!0);const re=Ae;De(!re),Yt(Ne=>re?Ne-1:Ne+1);try{const Ne=await fetch(`/api/users/${encodeURIComponent(t)}/follow`,{method:"POST",credentials:"include"});if(!Ne.ok)De(re),Yt(Pe=>re?Pe+1:Pe-1);else{const Pe=await Ne.json();De(Pe.following),Yt(rt=>Pe.following?re?rt:rt+1:re?rt-1:rt)}}catch{De(re),Yt(Ne=>re?Ne+1:Ne-1)}finally{be(!1)}}async function fl(re){var Pe;const Ne=(Pe=re.target.files)==null?void 0:Pe[0];if(!(!Ne||!t)){if(w(""),!["image/jpeg","image/png"].includes(Ne.type)){w("Only JPG and PNG images are allowed.");return}if(Ne.size>2*1024*1024){w("Image must be 2 MB or smaller.");return}y(!0);try{const rt=await new Promise((cs,Ys)=>{const Ts=new FileReader;Ts.onload=()=>cs(Ts.result),Ts.onerror=Ys,Ts.readAsDataURL(Ne)}),ks=await fetch(`/api/users/${encodeURIComponent(t)}/avatar`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({dataUrl:rt}),credentials:"include"});if(!ks.ok){const cs=await ks.json().catch(()=>({}));w(cs.error||"Upload failed.");return}const{avatarUrl:ja}=await ks.json();d(cs=>cs&&{...cs,avatarUrl:ja})}catch{w("Upload failed. Please try again.")}finally{y(!1),C.current&&(C.current.value="")}}}async function Ar(re){var Pe;const Ne=(Pe=re.target.files)==null?void 0:Pe[0];if(!(!Ne||!t)){if(T(""),!["image/jpeg","image/png"].includes(Ne.type)){T("Only JPG and PNG images are allowed.");return}if(Ne.size>5*1024*1024){T("Image must be 5 MB or smaller.");return}S(!0);try{const rt=await new Promise((cs,Ys)=>{const Ts=new FileReader;Ts.onload=()=>cs(Ts.result),Ts.onerror=Ys,Ts.readAsDataURL(Ne)}),ks=await fetch(`/api/users/${encodeURIComponent(t)}/cover-banner`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({dataUrl:rt}),credentials:"include"});if(!ks.ok){const cs=await ks.json().catch(()=>({}));T(cs.error||"Upload failed.");return}const{coverBannerUrl:ja}=await ks.json();d(cs=>cs&&{...cs,coverBannerUrl:ja})}catch{T("Upload failed. Please try again.")}finally{S(!1),M.current&&(M.current.value="")}}}
640async function nd(re){if(t){J(!0),Y("");try{const Ne=await fetch(`/api/users/${encodeURIComponent(t)}/featured-video`,{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify({slug:re}),credentials:"include"});if(!Ne.ok){const Pe=await Ne.json().catch(()=>({}));Y(Pe.error||"Failed to update.");return}if(!re)E(null);else{const Pe=await fetch(`/api/users/${encodeURIComponent(t)}/featured-video`);if(Pe.ok){const rt=await Pe.json();E(rt.event)}}q(!1)}catch{Y("Failed to update. Please try again.")}finally{J(!1)}}}async function xl(re){const Ne=Array.from(re.target.files??[]);if(!Ne.length||!t)return;se("");const Pe=qo-$.length,rt=Ne.slice(0,Pe);if(rt.length===0){se(`Photo limit reached (${qo} maximum).`),We.current&&(We.current.value="");return}K(!0);const ks=[];for(const ja of rt){if(!["image/jpeg","image/png","image/webp"].includes(ja.type)){se("Only JPG, PNG, and WEBP images are allowed.");continue}if(ja.size>10*1024*1024){se("Each photo must be 10 MB or smaller.");continue}try{const cs=await new Promise((La,yl)=>{const Hn=new FileReader;Hn.onload=()=>La(Hn.result),Hn.onerror=yl,Hn.readAsDataURL(ja)}),Ys=await fetch(`/api/users/${encodeURIComponent(t)}/photos`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({dataUrl:cs}),credentials:"include"});if(!Ys.ok){const La=await Ys.json().catch(()=>({}));se(La.error||"Upload failed.");break}const{photo:Ts}=await Ys.json();ks.push(Ts)}catch{se("Upload failed. Please try again.");break}}ks.length>0&&D(ja=>[...ja,...ks]),K(!1),We.current&&(We.current.value="")}async function Er(re){if(!(!t||Me)){st(!0);try{const Ne=await fetch(`/api/users/${encodeURIComponent(t)}/photos/${encodeURIComponent(re)}`,{method:"DELETE",credentials:"include"});if(!Ne.ok){const Pe=await Ne.json().catch(()=>({}));se(Pe.error||"Delete failed.");return}D(Pe=>Pe.filter(rt=>rt.id!==re)),le(Pe=>{if(Pe===null)return null;const rt=$.length-1;return rt===0?null:Math.min(Pe,rt-1)})}catch{se("Delete failed. Please try again.")}finally{st(!1),Se(null)}}}async function Zm(){if(t){Zt(!0),Jt("");try{const re=await fetch(`/api/users/${encodeURIComponent(t)}/bio`,{method:"PATCH",headers:{"Content-Type":"application/json"},credentials:"include",body:JSON.stringify({bio:me,website:Ie,location:ze,accolades:ct})});if(!re.ok){const Pe=await re.json().catch(()=>({}));Jt(Pe.error??"Save failed.");return}const Ne=await re.json();d(Pe=>Pe&&{...Pe,bio:Ne.bio,website:Ne.website,location:Ne.location,accolades:Ne.accolades}),te(!1)}catch{Jt("Network error. Please try again.")}finally{Zt(!1)}}}async function gl(){if(!t)return;const re=Wt.trim();if(!re){gt("Name cannot be blank.");return}qt(!0),gt("");try{const Ne=await fetch(`/api/users/${encodeURIComponent(t)}/display-name`,{method:"PATCH",headers:{"Content-Type":"application/json"},credentials:"include",body:JSON.stringify({name:re})}),Pe=await Ne.json();if(!Ne.ok){gt(Pe.error??"Save failed.");return}d(rt=>rt&&{...rt,name:Pe.name??rt.name}),Xe(Pe.nameChangeCount??et),ps(!1)}catch{gt("Network error. Please try again.")}finally{qt(!1)}}if(!t)return e.jsx(yi,{to:"/",replace:!0});const lo=(l==null?void 0:l.name)??t,bl=`${lo} (@${t}) – Total Horse Channel`,rd=(l==null?void 0:l.accountType)??"horse_lover";return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:bl}),e.jsx("meta",{name:"description",content:`View ${lo}'s profile on Total Horse Channel.`}),e.jsx("link",{rel:"canonical",href:`${az}/u/${t}`}),e.jsx("meta",{name:"robots",content:"noindex"})]}),e.jsx("main",{children:e.jsx("div",{className:"max-w-[1280px] mx-auto px-4 py-6",children:e.jsxs("div",{className:"flex flex-col lg:flex-row gap-6",children:[e.jsx("div",{className:"flex-1 min-w-0",children:e.jsxs("div",{className:"max-w-[900px]",children:[u&&e.jsxs("div",{className:"flex flex-col items-center gap-4 py-20 text-muted-foreground",children:[e.jsx("div",{className:"w-8 h-8 border-2 border-primary border-t-transparent rounded-full animate-spin"}),e.jsx("span",{className:"text-sm",children:"Loading profile…"})]}),!u&&p&&e.jsxs("div",{className:"text-center py-20",children:[e.jsx(Ha,{size:48,strokeWidth:1,className:"mx-auto text-muted-foreground mb-4"}),e.jsx("h1",{className:"text-xl font-bold text-foreground mb-2",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"461386",guard:{file:"src/pages/user-profile.tsx",tagName:"h1",sourceKind:"content-key",contentKey:"user_profile.notFoundTitle",contentKeyTemplate:null,expressionH
640ash:null},children:hc.notFoundTitle})}),e.jsx("p",{className:"text-muted-foreground text-sm",children:e.jsx("span",{style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"349f20",guard:{file:"src/pages/user-profile.tsx",tagName:"span",sourceKind:"content-key",contentKey:"user_profile.notFoundBody",contentKeyTemplate:null,expressionHash:null},children:hc.notFoundBody})})})]}),!u&&l&&e.jsxs("div",{className:"border border-border rounded-sm bg-card overflow-hidden mb-6",children:[rz.has(l.plan)&&(l.coverBannerUrl||zt)&&e.jsxs("div",{className:"relative w-full",style:{aspectRatio:"3 / 1",minHeight:"140px",maxHeight:"320px"},children:[l.coverBannerUrl?e.jsx("img",{src:l.coverBannerUrl,alt:"Cover banner",className:"absolute inset-0 w-full h-full object-cover",width:1500,height:500}):zt&&e.jsx("div",{className:"w-full h-full bg-muted flex items-center justify-center",children:e.jsx("span",{className:"text-xs text-muted-foreground",children:"Add a cover photo"})}),zt&&e.jsxs(e.Fragment,{children:[e.jsxs("button",{type:"button",onClick:()=>{var re;return(re=M.current)==null?void 0:re.click()},disabled:A,className:"absolute bottom-2 right-2 flex items-center gap-1.5 px-2.5 py-1.5 rounded text-xs font-semibold bg-black/60 text-white hover:bg-black/80 transition-colors disabled:opacity-60",title:"Upload cover photo (1500×500 px recommended, JPG or PNG, max 5 MB)",children:[A?e.jsx("div",{className:"w-3 h-3 border border-white border-t-transparent rounded-full animate-spin"}):e.jsx(Jf,{size:13}),A?"Uploading…":l.coverBannerUrl?"Change cover":"Add cover photo"]}),e.jsx("input",{ref:M,type:"file",accept:"image/jpeg,image/png",className:"sr-only",onChange:Ar,"aria-label":"Upload cover photo"})]})]}),z&&e.jsx("p",{className:"text-xs text-red-600 px-5 pt-2",children:e.jsx(_,{devId:"98395e",guard:{file:"src/pages/user-profile.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:c857035eb25a8c048868f33f4f77723cd3b6603a2be7b472dbc95744008eed4c"},children:z})}),e.jsx("div",{className:"bg-primary px-5 py-3",children:e.jsx("span",{className:"text-white font-bold",style:{whiteSpace:"pre-line",fontSize:"15px"},children:e.jsx(_,{devId:"396c75",guard:{file:"src/pages/user-profile.tsx",tagName:"span",sourceKind:"content-key",contentKey:"user_profile.headerBar",contentKeyTemplate:null,expressionHash:null},children:hc.headerBar})})}),e.jsxs("div",{className:"px-6 py-6 flex flex-col gap-5",children:[e.jsxs("div",{className:"flex items-start gap-5",children:[e.jsxs("div",{className:"relative shrink-0",children:[e.jsx("div",{className:"w-20 h-20 rounded-full bg-muted overflow-hidden border border-border flex items-center justify-center",children:l.avatarUrl?e.jsx("img",{src:l.avatarUrl,alt:`${lo} avatar`,className:"w-full h-full object-cover",width:80,height:80}):e.jsx(Ha,{size:36,className:"text-muted-foreground",strokeWidth:1.5})}),zt&&e.jsxs(e.Fragment,{children:[e.jsx("button",{type:"button",onClick:()=>{var re;return(re=C.current)==null?void 0:re.click()},disabled:b,className:"absolute -bottom-1 -right-1 w-7 h-7 rounded-full bg-primary text-white flex items-center justify-center shadow hover:opacity-90 transition-opacity disabled:opacity-60","aria-label":"Change profile photo",title:"Change profile photo",children:e.jsx(_,{devId:"8d2c08",guard:{file:"src/pages/user-profile.tsx",tagName:"button",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:7cd2e2716ef02b474542ad117d0d6fe77b8416fea35769567798caffa3ee7522"},children:b?e.jsx("div",{className:"w-3 h-3 border border-white border-t-transparent rounded-full animate-spin"}):e.jsx(zc,{size:13})})}),e.jsx("input",{ref:C,type:"file",accept:"image/jpeg,image/png",className:"sr-only",onChange:fl,"aria-label":"Upload profile photo"})]})]}),e.jsxs("div",{className:"min-w-0 flex-1 pt-1",children:[zt&&jt?e.jsxs("div",{className:"flex flex-col gap-1.5 mb-1",children:[e.jsxs("div",{className:"flex items-center gap-1.5",children:[e.jsx("input",{type:"text",value:Wt,onChange:re=>ws(re.target.value.slice(0,100)),maxLength:100,autoFocus:!0,className:"flex-1 min-w-0 rounded border border-input bg-background px-2 py-1 text-sm font-bold focus:outline-none focus:ring-2 focus:ring-primary",placeholder:"Display name",onKeyDown:re=>{re.key==="Enter"&&gl(),re.key==="Escape"&&ps(!1)}}),e.jsxs("button",{type:"button",onClick:gl,disabled:os,className:"shrink-0 flex items-center gap-1 px-2 py-1 text-xs font-semibold bg-primary text-white rounded hover:opacity-90 disabled:opacity-60",children:[e.jsx(Ea,{size:11}),os?"Saving…":"Save"]}),e.jsx("button",{type:"button",onClick:()=>{ps(!1),gt("")},className:"shrink-0 px-2 py-1 text-xs border border-border rounded hover:bg-muted transition-colors",children:"Cancel"})]}),je&&e.jsx("p",{className:"text-xs text-destructive",children:e.jsx(_,{devId:"e7d471",guard:{file:"src/pages/user-profile.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionH
640ash:"sha256:0d2496c042cfc5d6f0213a432401a065ebf7b6a581af0814273afebd55a915b7"},children:je})}),e.jsxs("p",{className:"text-xs text-muted-foreground",children:[2-et," change",2-et===1?"":"s"," remaining"]})]}):e.jsxs("div",{className:"flex items-center gap-1.5 mb-0.5",children:[e.jsx("h1",{className:"font-bold text-foreground truncate",style:{fontSize:"20px"},children:e.jsx(_,{devId:"33623b",guard:{file:"src/pages/user-profile.tsx",tagName:"h1",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:6ac816a153ab4d9498ba15028dace64be0c5b763c3a03f81f5c2583a363804e3"},children:l.name??t})}),zt&&et<2&&e.jsx("button",{type:"button",onClick:()=>{ws(l.name??""),ps(!0),gt("")},className:"shrink-0 text-muted-foreground hover:text-primary transition-colors","aria-label":"Edit display name",title:`Edit display name (${2-et} change${2-et===1?"":"s"} remaining)`,children:e.jsx(Vn,{size:13})})]}),e.jsxs("p",{className:"text-muted-foreground text-sm mt-0.5",children:["@",l.username??t]}),e.jsx("span",{className:"inline-block mt-1.5 text-xs px-2 py-0.5 rounded border border-border bg-muted text-muted-foreground",children:e.jsx(_,{devId:"85cc5f",guard:{file:"src/pages/user-profile.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:c11611ff4f81fe0c5c52f5445f4d18270c040cd9284c0adcf4dd09d8f4153687"},children:oz[rd]??rd})}),(t==null?void 0:t.toLowerCase())==="vlemaster"&&e.jsxs("span",{className:"inline-flex items-center gap-1.5 mt-1.5 text-xs font-semibold px-2 py-0.5 rounded border border-primary bg-primary text-white",children:[e.jsx(zc,{size:11,className:"shrink-0"}),"Official Photographer — 2026 WDAA World Championship Show"]}),(t==null?void 0:t.toLowerCase())==="rosegatefarm"&&e.jsxs("span",{className:"inline-flex items-center gap-1.5 mt-1.5 text-xs font-semibold px-2 py-0.5 rounded border bg-card text-foreground",style:{borderColor:"hsl(var(--trophy-gold))",color:"hsl(var(--trophy-gold))"},children:[e.jsx(Xs,{size:11,className:"shrink-0",style:{color:"hsl(var(--trophy-gold))"}}),"Western Dressage Icon Photo Contest Winner — 2026"]})]})]}),v&&e.jsx("p",{className:"text-xs text-red-600 -mt-2",children:e.jsx(_,{devId:"ea05f4",guard:{file:"src/pages/user-profile.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:5e6cbb757e08ffedffefd657a9d580cfa0c35748bf999d613caa2e3560651633"},children:v})}),e.jsxs("div",{children:[zt&&!Ye&&e.jsxs("div",{className:"flex items-start gap-2 group",children:[e.jsx("p",{className:`text-sm flex-1 ${l.bio?"text-foreground":"text-muted-foreground italic"}`,children:e.jsx(_,{devId:"96e25d",guard:{file:"src/pages/user-profile.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:29870591123d924037ccdc37098e337d8e70e811480af41de3fbcde466958c6f"},children:l.bio??"Add a short bio…"})}),e.jsx("button",{type:"button",onClick:()=>{Le(l.bio??""),ve(l.website??""),Ue(l.location??""),Ot(l.accolades??""),te(!0),Jt("")},className:"shrink-0 text-muted-foreground hover:text-primary transition-colors mt-0.5","aria-label":"Edit bio and profile details",title:"Edit bio and profile details",children:e.jsx(Vn,{size:13})})]}),zt&&Ye&&e.jsxs("div",{className:"flex flex-col gap-3",children:[e.jsxs("div",{className:"flex flex-col gap-1",children:[e.jsx("label",{className:"text-xs text-muted-foreground font-medium",children:"Bio"}),e.jsx("textarea",{value:me,onChange:re=>Le(re.target.value.slice(0,300)),rows:3,maxLength:300,placeholder:"Write a short bio…",className:"w-full resize-none rounded border border-input bg-background px-3 py-2 text-sm focus:outline-none focus:ring-2 focus:ring-primary"}),e.jsxs("span",{className:"text-xs text-muted-foreground self-end",children:[me.length,"/300"]})]}),e.jsxs("div",{className:"flex flex-col gap-1",children:[e.jsx("label",{className:"text-xs text-muted-foreground font-medium",children:"Website"}),e.jsx("input",{type:"text",value:Ie,onChange:re=>ve(re.target.value.slice(0,500)),placeholder:"https://yoursite.com",className:"w-full rounded border border-input bg-background px-3 py-2 text-sm focus:outline-none focus:ring-2 focus:ring-primary"})]}),e.jsxs("div",{className:"flex flex-col gap-1",children:[e.jsx("label",{className:"text-xs text-muted-foreground font-medium",children:"Location"}),e.jsx("input",{type:"text",value:ze,onChange:re=>Ue(re.target.value.slice(0,200)),placeholder:"City, State",className:"w-full rounded border border-input bg-background px-3 py-2 text-sm focus:outline-none focus:ring-2 focus:ring-primary"})]}),e.jsxs("div",{className:"flex flex-col gap-1",children:[e.jsx("label",{className:"text-xs text-muted-foreground font-medium",children:"Accolades"}),e.jsx("input",{type:"text",value:ct,onChange:re=>Ot(re.target.value.slice(0,500)),placeholder:"e.g. U.S. National Champion · Arabians & Saddlebreds",className:"w-full rounded border border-input bg-background px-3 py-2 text-sm focus:outline-none focus:ring-2 focus:ring-primary"}),e.jsx("span",{className:"text-xs text-muted-foreground",children:"Shown publicly under your bio. Use · to separate items."})]}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsxs("button",{type:"button",onClick:Zm,disabled:Et,className:"flex items-center gap-1 px-3 py-1 text-xs font-semibold bg-primary text-white rounded hover:opacity-90 disabled:opacity-60",children:[e.jsx(Ea,{size:12}),Et?"Saving…":"Save"]}),e.jsx("button",{type:"button",onClick:()=>te(!1),className:"px-3 py-1 text-xs border border-border rounded hover:bg-muted transition-colors",children:"Cancel"})]}),as&&e.jsx("p",{className:"text-xs text-destructive",children:e.jsx(_,{devId:"a8fade",guard:{file:"src/pages/user-profile.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionH
640ash:"sha256:ac2051bb7f556f7de6325c4e40f0e15f9b1e7af34fc2c10f184a357e4485be86"},children:as})})]}),!zt&&l.bio&&e.jsx("p",{className:"text-sm text-foreground",children:e.jsx(_,{devId:"f25289",guard:{file:"src/pages/user-profile.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:c2dbbf47f1bf6a3ab744c88d16d7456ad1e7faa1462df2306656226c12580d08"},children:l.bio})})]}),!Ye&&l.website&&e.jsxs("div",{className:"flex items-center gap-2 text-sm",children:[e.jsx(Ku,{size:14,className:"text-primary shrink-0",strokeWidth:1.5}),e.jsx("a",{href:l.website.startsWith("http")?l.website:`https://${l.website}`,target:"_blank",rel:"noopener noreferrer",className:"text-primary hover:underline truncate",children:e.jsx(_,{devId:"042b3b",guard:{file:"src/pages/user-profile.tsx",tagName:"a",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:3f6627b9162d72cc21962637ceedead239914d15acd7e9888eadcb26f1201315"},children:tw(l.website)})})]}),!Ye&&l.location&&e.jsxs("div",{className:"flex items-center gap-2 text-sm text-muted-foreground",children:[e.jsx(ul,{size:14,className:"text-primary shrink-0",strokeWidth:1.5}),e.jsx("span",{children:e.jsx(_,{devId:"056b8d",guard:{file:"src/pages/user-profile.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:7ce89c7e03ca41aa866ef9143fa701e20ac3d54007ad2cb6839e515862af077c"},children:l.location})})]}),!Ye&&l.accolades&&e.jsxs("div",{className:"flex items-start gap-2 text-sm",children:[e.jsx(SC,{size:14,className:"text-primary shrink-0 mt-0.5",strokeWidth:1.5}),e.jsx("span",{className:"text-foreground leading-snug",children:e.jsx(_,{devId:"47406e",guard:{file:"src/pages/user-profile.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:dc8302e6ca4226b9abc078b7a6a1bb16bd6b094bb3cc2cc9f1bfca252c956f3e"},children:l.accolades})})]}),e.jsxs("div",{className:"flex items-center gap-4 text-sm",children:[e.jsxs("button",{type:"button",onClick:()=>ta("followers"),className:"flex flex-col items-center hover:text-primary transition-colors",children:[e.jsx("span",{className:"font-bold text-foreground text-base leading-tight",children:e.jsx(_,{devId:"8644dc",guard:{file:"src/pages/user-profile.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:4583eb3abc5c33eab87fd103aedf1820ca1907f1e628aea9f724b348711bcf5c"},children:ft})}),e.jsx("span",{className:"text-xs text-muted-foreground",children:"Followers"})]}),e.jsxs("button",{type:"button",onClick:()=>ta("following"),className:"flex flex-col items-center hover:text-primary transition-colors",children:[e.jsx("span",{className:"font-bold text-foreground text-base leading-tight",children:e.jsx(_,{devId:"c819bd",guard:{file:"src/pages/user-profile.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:ded583478e36607c18279f5058b1fd79e4573e245e35d27bb5c3bd436370d01e"},children:ls})}),e.jsx("span",{className:"text-xs text-muted-foreground",children:"Following"})]})]}),!zt&&ua&&e.jsx("div",{children:e.jsx("button",{type:"button",onClick:ad,disabled:ue,className:`flex items-center gap-1.5 px-5 py-1.5 rounded-sm text-sm font-semibold border transition-colors disabled:opacity-60 ${Ae?"bg-muted border-border text-foreground hover:bg-red-50 hover:border-primary hover:text-primary":"bg-primary border-primary text-white hover:opacity-90"}`,children:e.jsx(_,{devId:"9b933a",guard:{file:"src/pages/user-profile.tsx",tagName:"button",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:448c33f56ad4e08ac859c593b040dea83f5b75cecbbd8e3057827579390caf26"},children:Ae?e.jsxs(e.Fragment,{children:[e.jsx(DC,{size:14}),e.jsx("span",{children:"Following"})]}):e.jsxs(e.Fragment,{children:[e.jsx(Dc,{size:14}),e.jsx("span",{children:"Follow"})]})})})}),!zt&&!ua&&e.jsxs("p",{className:"text-xs text-muted-foreground",children:[e.jsx(O,{to:"/signup",className:"text-primary hover:underline",children:"Create a free account"})," ","or"," ",e.jsx(O,{to:"/login",className:"text-primary hover:underline",children:"log in"})," ","to follow."]}),(()=>{const re={showtimetrainingcent:"[email protected]"},Ne=l.contactEmail??re[(t==null?void 0:t.toLowerCase())??""]??null;if(zt||!Ne)return null;const Pe=lz.has(l.accountType)&&cz.has(l.plan);return e.jsx("div",{children:e.jsxs("button",{type:"button",onClick:()=>js(!0),className:"inline-flex items-center gap-2 px-5 py-1.5 rounded-sm text-sm font-semibold border border-primary bg-primary text-white hover:opacity-90 transition-opacity","data-contact-email":Ne,children:[e.jsx(nn,{size:14}),Pe?"For Hire / Contact":"Contact Us"]})})})(),zt&&e.jsxs("div",{className:"flex flex-wrap gap-2",children:[e.jsxs(O,{to:"/add-video-live",className:"inline-flex items-center gap-2 bg-primary text-primary-foreground font-semibold px-4 py-2 text-sm hover:bg-primary/90 transition-colors",children:[e.jsx(Vs,{size:15}),"Add Video / Live"]}),e.jsxs(O,{to:"/add-event",className:"inline-flex items-center gap-2 border border-primary text-primary font-semibold px-4 py-2 text-sm hover:bg-primary/10 transition-colors",children:[e.jsx(ys,{size:15}),"Add Event"]})]}),zt&&e.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-2 gap-4",children:[e.jsxs("div",{className:"flex items-start gap-3 border border-border rounded-sm px-4 py-3",children:[e.jsx(Xs,{size:18,className:"text-primary mt-0.5 shrink-0",strokeWidth:1.5}),e.jsxs("div",{children:[e.jsx("p",{className:"text-xs text-muted-foreground uppercase tracking-wide mb-1",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"341139",guard:{file:"src/pages/user-profile.tsx",tagName:"p",sourceKind:"content-key",contentKey:"user_profile.planLabel",contentKeyTemplate:null,expressionH
640ash:null},children:hc.planLabel})}),e.jsx("span",{className:`inline-block text-sm font-semibold px-2 py-0.5 rounded border ${ew[l.plan]??ew.rookie}`,children:e.jsx(_,{devId:"b3427b",guard:{file:"src/pages/user-profile.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:09bdcb4d2c82ab0aa4fbbb3008a69a764610ededb8edb77a68a5521e5a07308c"},children:iz[l.plan]??l.plan})})]})]}),e.jsxs("div",{className:"flex items-start gap-3 border border-border rounded-sm px-4 py-3",children:[e.jsx(ys,{size:18,className:"text-primary mt-0.5 shrink-0",strokeWidth:1.5}),e.jsxs("div",{children:[e.jsx("p",{className:"text-xs text-muted-foreground uppercase tracking-wide mb-1",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"90c67a",guard:{file:"src/pages/user-profile.tsx",tagName:"p",sourceKind:"content-key",contentKey:"user_profile.memberSinceLabel",contentKeyTemplate:null,expressionHash:null},children:hc.memberSinceLabel})}),e.jsx("p",{className:"text-sm font-semibold text-foreground",children:e.jsx(_,{devId:"90c67b",guard:{file:"src/pages/user-profile.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:b9901332538fb25cef47bd2e4b81f0bed5b17d9625593c6527f386a4d90b0811"},children:dz(l.createdAt)})})]})]})]}),zt&&e.jsx("div",{className:"pt-1 border-t border-border",children:e.jsxs(O,{to:"/#account",className:"inline-flex items-center gap-1.5 text-xs text-muted-foreground hover:text-primary transition-colors",children:[e.jsx(Vn,{size:12}),"Account settings"]})})]})]}),!u&&l&&Qj.has(l.plan)&&e.jsxs(e.Fragment,{children:[P&&e.jsxs("div",{className:"border border-border rounded-sm bg-card overflow-hidden mb-4",children:[e.jsxs("div",{className:"bg-primary px-4 py-2 flex items-center justify-between gap-2",children:[e.jsxs("span",{className:"flex items-center gap-2 text-white font-bold text-sm",children:[e.jsx(Rc,{size:15}),"Featured Video"]}),fn&&e.jsxs("button",{type:"button",onClick:()=>q(re=>!re),className:"text-white/80 hover:text-white text-xs flex items-center gap-1 transition-colors",children:["Change ",e.jsx($n,{size:12})]})]}),e.jsx("div",{className:"w-full",style:{aspectRatio:"16/9"},dangerouslySetInnerHTML:{__html:P.embedHtml}}),e.jsx("div",{className:"px-4 py-2 border-t border-border",children:e.jsx(O,{to:`/live/${P.slug}`,className:"text-sm font-semibold text-foreground hover:text-primary transition-colors line-clamp-1",children:P.title})})]}),!P&&P!==void 0&&fn&&e.jsxs("div",{className:"border border-dashed border-border rounded-sm bg-card px-4 py-3 mb-4 flex items-center justify-between gap-3",children:[e.jsxs("span",{className:"text-sm text-muted-foreground flex items-center gap-2",children:[e.jsx(Rc,{size:15,className:"text-primary shrink-0"}),"No featured video set"]}),e.jsx("button",{type:"button",onClick:()=>q(re=>!re),className:"text-xs font-semibold text-primary hover:underline shrink-0",children:"Set featured video"})]}),fn&&U&&e.jsx(mz,{username:t,isAdmin:pn,currentSlug:(P==null?void 0:P.slug)??null,saving:H,error:B,onSelect:nd,onClose:()=>{q(!1),Y("")}})]}),!u&&l&&sw.has(l.plan)&&W&&($.length>0||Bt)&&e.jsxs("div",{className:"border border-border rounded-sm bg-card overflow-hidden mb-4",children:[e.jsxs("div",{className:"bg-muted border-b border-border px-4 py-2.5 flex items-center justify-between gap-2",children:[e.jsxs("span",{className:"flex items-center gap-2 text-sm font-bold text-foreground",children:[e.jsx(Jf,{size:14,className:"text-primary"}),"Photos",$.length>0&&e.jsxs("span",{className:"text-xs font-normal text-muted-foreground",children:["(",$.length,")"]})]}),Bt&&$.length<qo&&e.jsxs("label",{className:"cursor-pointer text-xs font-semibold text-primary hover:underline flex items-center gap-1",children:[k?"Uploading…":"+ Add Photos",e.jsx("input",{ref:We,type:"file",accept:"image/jpeg,image/png,image/webp",multiple:!0,className:"sr-only",disabled:k,onChange:xl})]}),Bt&&$.length>=qo&&e.jsxs("span",{className:"text-xs text-muted-foreground",children:[qo,"/",qo," photos"]})]}),L&&e.jsxs("div",{className:"px-4 py-2 bg-destructive/10 border-b border-destructive/20 flex items-center justify-between gap-2",children:[e.jsx("span",{className:"text-xs text-destructive",children:e.jsx(_,{devId:"fa1958",guard:{file:"src/pages/user-profile.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionH
640ash:"sha256:27a76c8d67ff3e94725f6c3992fc779f3db8f3b6cf22a0a3c499bd8159f69d4f"},children:L})}),e.jsx("button",{type:"button",onClick:()=>se(""),className:"text-destructive hover:opacity-70",children:e.jsx(Vt,{size:12})})]}),k&&e.jsx("div",{className:"px-4 py-3 text-xs text-muted-foreground border-b border-border",children:"Uploading photos…"}),!k&&$.length===0&&Bt&&e.jsxs("div",{className:"px-4 py-6 text-center",children:[e.jsx("p",{className:"text-sm text-muted-foreground mb-2",children:"No photos yet."}),e.jsxs("label",{className:"cursor-pointer inline-flex items-center gap-1.5 text-xs font-semibold text-primary hover:underline",children:[e.jsx(ln,{size:13})," Upload your first photo",e.jsx("input",{type:"file",accept:"image/jpeg,image/png,image/webp",multiple:!0,className:"sr-only",disabled:k,onChange:xl})]})]}),$.length>0&&e.jsx("div",{className:"p-3 grid grid-cols-3 gap-2",children:$.map((re,Ne)=>e.jsxs("div",{className:"relative group aspect-square",children:[e.jsx("button",{type:"button",className:"w-full h-full block overflow-hidden rounded focus:outline-none focus-visible:ring-2 focus-visible:ring-primary",onClick:()=>le(Ne),"aria-label":re.caption??`Photo ${Ne+1}`,children:e.jsx("img",{src:re.url,alt:re.caption??`Photo ${Ne+1}`,className:"w-full h-full object-cover rounded transition-opacity group-hover:opacity-90",loading:"lazy"})}),Bt&&e.jsx("button",{type:"button",onClick:()=>Se(re.id),className:"absolute top-1 right-1 bg-black/60 hover:bg-black/80 text-white rounded-full w-5 h-5 flex items-center justify-center opacity-0 group-hover:opacity-100 transition-opacity focus:opacity-100","aria-label":"Delete photo",children:e.jsx(Vt,{size:10})})]},re.id))})]}),vs&&(()=>{const re={showtimetrainingcent:"[email protected]"},Ne=(l==null?void 0:l.contactEmail)??re[(t==null?void 0:t.toLowerCase())??""]??null;return Ne?e.jsx("div",{className:"fixed inset-0 z-50 flex items-center justify-center bg-black/60 p-4",onClick:()=>js(!1),children:e.jsxs("div",{className:"bg-card border border-border rounded-sm shadow-xl p-6 max-w-sm w-full",onClick:Pe=>Pe.stopPropagation(),children:[e.jsxs("div",{className:"flex items-center justify-between mb-4",children:[e.jsxs("h2",{className:"text-base font-bold text-foreground",children:["Contact ",(l==null?void 0:l.name)??(l==null?void 0:l.username)]}),e.jsx("button",{type:"button",onClick:()=>js(!1),className:"text-muted-foreground hover:text-foreground transition-colors","aria-label":"Close",children:e.jsx(Vt,{size:16})})]}),e.jsxs("div",{className:"flex flex-col gap-3",children:[e.jsxs("a",{href:`mailto:${Ne}`,className:"flex items-center gap-3 px-4 py-3 rounded border border-border hover:bg-muted transition-colors text-sm font-medium text-foreground",children:[e.jsx(nn,{size:16,className:"text-primary shrink-0"}),Ne]}),(l==null?void 0:l.website)&&e.jsxs("a",{href:l.website.startsWith("http")?l.website:`https://${l.website}`,target:"_blank",rel:"noopener noreferrer",className:"flex items-center gap-3 px-4 py-3 rounded border border-border hover:bg-muted transition-colors text-sm font-medium text-foreground",children:[e.jsx(Ku,{size:16,className:"text-primary shrink-0"}),tw(l.website)]})]})]})}):null})(),ge&&e.jsx("div",{className:"fixed inset-0 z-50 flex items-center justify-center bg-black/60 p-4",onClick:()=>Se(null),children:e.jsxs("div",{className:"bg-card border border-border rounded-sm shadow-xl p-6 max-w-sm w-full",onClick:re=>re.stopPropagation(),children:[e.jsx("p",{className:"text-sm font-semibold text-foreground mb-1",children:"Delete this photo?"}),e.jsx("p",{className:"text-xs text-muted-foreground mb-4",children:"This cannot be undone."}),e.jsxs("div",{className:"flex gap-2 justify-end",children:[e.jsx("button",{type:"button",onClick:()=>Se(null),className:"px-3 py-1.5 text-xs border border-border rounded hover:bg-muted transition-colors",children:"Cancel"}),e.jsx("button",{type:"button",disabled:Me,onClick:()=>Er(ge),className:"px-3 py-1.5 text-xs bg-destructive text-white rounded hover:opacity-90 disabled:opacity-60 transition-opacity",children:e.jsx(_,{devId:"4f55d8",guard:{file:"src/pages/user-profile.tsx",tagName:"button",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionH
640ash:"sha256:3490801335c0d759dc8d0680a81c1d788557f53e3be831ce20ed4cdbc51fcda2"},children:Me?"Deleting…":"Delete"})})]})]})}),X!==null&&$.length>0&&e.jsxs("div",{className:"fixed inset-0 z-50 flex items-center justify-center bg-black/90 p-4",onClick:()=>le(null),children:[e.jsx("button",{type:"button",className:"absolute top-4 right-4 text-white/80 hover:text-white bg-black/40 rounded-full w-9 h-9 flex items-center justify-center z-10",onClick:()=>le(null),"aria-label":"Close",children:e.jsx(Vt,{size:18})}),$.length>1&&e.jsx("button",{type:"button",className:"absolute left-3 top-1/2 -translate-y-1/2 text-white/80 hover:text-white bg-black/40 rounded-full w-10 h-10 flex items-center justify-center z-10 text-xl font-bold",onClick:re=>{re.stopPropagation(),le(Ne=>Ne===null?0:(Ne-1+$.length)%$.length)},"aria-label":"Previous photo",children:"‹"}),e.jsxs("div",{className:"max-w-4xl max-h-full flex flex-col items-center gap-3",onClick:re=>re.stopPropagation(),children:[e.jsx("img",{src:$[X].url,alt:$[X].caption??`Photo ${X+1}`,className:"max-h-[80vh] max-w-full object-contain rounded shadow-2xl"}),$[X].caption&&e.jsx("p",{className:"text-white/80 text-sm text-center",children:e.jsx(_,{devId:"f21478",guard:{file:"src/pages/user-profile.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:1bb5997d9b4928d02839e05ba286b057e181d68dc1a502d3450231574a5f4fdf"},children:$[X].caption})}),e.jsxs("p",{className:"text-white/50 text-xs",children:[X+1," / ",$.length]})]}),$.length>1&&e.jsx("button",{type:"button",className:"absolute right-3 top-1/2 -translate-y-1/2 text-white/80 hover:text-white bg-black/40 rounded-full w-10 h-10 flex items-center justify-center z-10 text-xl font-bold",onClick:re=>{re.stopPropagation(),le(Ne=>Ne===null?0:(Ne+1)%$.length)},"aria-label":"Next photo",children:"›"})]}),!u&&l&&e.jsxs("div",{className:"flex flex-col lg:flex-row gap-6",children:[(zt||!Ws)&&e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("div",{className:"flex items-center gap-2 mb-3 border-b border-border pb-2",children:e.jsx("span",{className:"text-sm font-bold text-foreground uppercase tracking-wide",children:"Activity"})}),e.jsx(sz,{username:t,onEmpty:()=>Mt(!0)})]}),e.jsxs("div",{className:"w-full lg:w-[340px] shrink-0",children:[e.jsx("div",{className:"flex items-center gap-2 mb-3 border-b border-border pb-2",children:e.jsx("span",{className:"text-sm font-bold text-foreground uppercase tracking-wide",children:"Videos / Lives"})}),zt?e.jsxs("div",{className:"border border-border rounded-sm overflow-hidden",children:[e.jsxs("div",{className:"flex items-center justify-between px-4 py-3 bg-muted border-b border-border",children:[e.jsxs("span",{className:"flex items-center gap-2 text-sm font-semibold text-foreground",children:[e.jsx(Vs,{size:15,className:"text-primary"}),"My Videos / Lives"]}),e.jsx(O,{to:"/add-video-live",className:"text-xs text-primary hover:underline font-medium",children:"+ Add Video / Live"})]}),V?wi.length===0?e.jsxs("p",{className:"px-4 py-3 text-xs text-muted-foreground",children:["You haven't submitted any videos yet."," ",e.jsx(O,{to:"/add-video-live",className:"text-primary hover:underline",children:"Add one now."})]}):e.jsx("ul",{className:"divide-y divide-border",children:wi.map(re=>e.jsx("li",{className:"px-4 py-3",children:ee!==re.id?e.jsxs("div",{className:"flex flex-col gap-2",children:[e.jsxs("div",{className:"flex items-start gap-3",children:[re.thumbnailUrl?e.jsx("img",{src:re.thumbnailUrl,alt:"",className:"w-16 h-10 object-cover rounded shrink-0 bg-muted mt-0.5",loading:"lazy"}):e.jsx("div",{className:"w-16 h-10 bg-muted rounded shrink-0 flex items-center justify-center mt-0.5",children:e.jsx(Vs,{size:16,className:"text-muted-foreground"})}),e.jsxs("div",{className:"flex-1 min-w-0",children:[re.published?e.jsx(O,{to:`/live/${re.slug}`,className:"text-sm font-medium text-foreground hover:text-primary transition-colors line-clamp-1",children:re.title}):e.jsx("span",{className:"text-sm font-medium text-foreground line-clamp-1",children:re.title}),e.jsxs("div",{className:"flex flex-wrap items-center gap-x-2 gap-y-0.5 mt-1",children:[re.published?e.jsx("span",{className:`inline-flex items-center gap-1 text-xs font-semibold px-1.5 py-0.5 rounded border ${re.videoType==="live"?"bg-red-50 text-red-700 border-red-200":re.videoType==="upcoming"?"bg-orange-50 text-orange-700 border-orange-200":"bg-blue-50 text-blue-700 border-blue-200"}`,children:re.videoType==="live"?e.jsxs(e.Fragment,{children:[e.jsx(Ft,{size:10}),"Live"]}):re.videoType==="upcoming"?e.jsxs(e.Fragment,{children:[e.jsx(ys,{size:10}),"Upcoming"]}):e.jsxs(e.Fragment,{children:[e.jsx(Yn,{size:10}),"Video"]})}):e.jsx("span",{className:"inline-flex items-center gap-1 text-xs font-semibold px-1.5 py-0.5 rounded border bg-yellow-50 text-yellow-700 border-yellow-200",children:"Draft"}),re.published&&re.videoType==="live"&&e.jsx("span",{className:`inline-flex items-center text-xs font-medium px-1.5 py-0.5 rounded border ${re.isArchived?"bg-gray-50 text-gray-600 border-gray-200":"bg-green-50 text-green-700 border-green-200"}`,children:re.isArchived?"Archive":"Current"}),re.published&&e.jsxs("span",{className:"text-xs text-muted-foreground flex items-center gap-1",children:[e.jsx(xa,{size:11}
640),re.viewCount.toLocaleString()]})]})]})]}),e.jsxs("div",{className:"flex flex-wrap items-center gap-2 pl-[76px]",children:[re.published?e.jsx("button",{type:"button",onClick:()=>{if(fe(re.id),Re(re.title),He(re.category??""),$e(re.thumbnailUrl??""),qe(null),wt(""),Gt(!1),ea(""),bt(re.videoType==="upcoming"?"upcoming":re.videoType==="live"?"live":"video"),ya(re.isArchived),re.startAt){const Ne=new Date(re.startAt),Pe=rt=>String(rt).padStart(2,"0");fs(`${Ne.getFullYear()}-${Pe(Ne.getMonth()+1)}-${Pe(Ne.getDate())}T${Pe(Ne.getHours())}:${Pe(Ne.getMinutes())}`)}else fs("");mn("")},className:"text-xs text-primary hover:underline font-medium",children:"Edit"}):e.jsx(O,{to:`/add-video-live?edit=${re.id}`,className:"text-xs text-primary hover:underline font-medium",children:"Edit draft"}),l&&nz.has(l.plan)&&e.jsxs(O,{to:`/add-video-live?dupe=${re.id}`,className:"text-xs text-accent hover:underline font-medium flex items-center gap-1",title:"Duplicate this entry — opens a pre-filled form with title, date, and video URL cleared",children:[e.jsx(Qo,{size:11}),"Duplicate"]}),re.published&&re.videoType==="live"&&!re.isArchived&&e.jsxs("button",{type:"button",onClick:async()=>{(await fetch(`/api/member/my-videos/${re.id}/status`,{method:"PATCH",credentials:"include",headers:{"Content-Type":"application/json"},body:JSON.stringify({isArchived:!0})})).ok&&Jn(Pe=>Pe.map(rt=>rt.id===re.id?{...rt,isArchived:!0}:rt))},className:"text-xs text-muted-foreground hover:text-foreground hover:underline font-medium flex items-center gap-1",children:[e.jsx(Qi,{size:11}),"Move to Archive"]}),hn===re.id?e.jsxs("span",{className:"flex items-center gap-1 text-xs",children:[e.jsx("span",{className:"text-muted-foreground",children:"Delete?"}),e.jsx("button",{type:"button",disabled:at,onClick:async()=>{Ht(!0);const Ne=await fetch(`/api/member/my-videos/${re.id}`,{method:"DELETE",credentials:"include"});Ht(!1),_a(null),Ne.ok&&Jn(Pe=>Pe.filter(rt=>rt.id!==re.id))},className:"text-red-600 hover:underline font-semibold",children:at?"Deleting…":"Yes"}),e.jsx("button",{type:"button",onClick:()=>_a(null),className:"text-muted-foreground hover:underline",children:"No"})]}):e.jsx("button",{type:"button",onClick:()=>_a(re.id),className:"text-xs text-red-600 hover:underline font-medium",children:"Delete"})]})]}):e.jsxs("form",{onSubmit:async Ne=>{Ne.preventDefault(),Ra(!0),mn("");let Pe=ke;if(Ze){Gt(!0);const cs=new FormData;cs.append("file",Ze);const Ys=await fetch("/api/live-events/upload-thumbnail",{method:"POST",body:cs}),Ts=await Ys.json();if(Gt(!1),!Ys.ok||!Ts.url){mn(Ts.error??"Thumbnail upload failed."),Ra(!1);return}Pe=Ts.url,$e(Pe),qe(null),wt("")}const rt=da?new Date(da).toISOString():void 0,ks=await fetch(`/api/member/my-videos/${re.id}`,{method:"PATCH",credentials:"include",headers:{"Content-Type":"application/json"},body:JSON.stringify({title:xe,category:Ee,thumbnailUrl:Pe,videoType:Tt,isArchived:ca,...rt!==void 0?{startAt:rt}:{},...nt?{description:nt}:{}})}),ja=await ks.json();if(Ra(!1),!ks.ok){mn(ja.error??"Save failed.");return}Jn(cs=>cs.map(Ys=>Ys.id===re.id?{...Ys,title:xe,category:Ee||null,thumbnailUrl:Pe||null,videoType:Tt==="upcoming"?"upcoming":Tt==="live"?"live":"video",isArchived:ca,startAt:rt??Ys.startAt}:Ys)),fe(null)},className:"flex flex-col gap-2",children:[e.jsx("p",{className:"text-xs font-semibold text-foreground mb-1",children:"Edit"}),e.jsxs("div",{children:[e.jsx("label",{className:"text-xs text-muted-foreground",children:"Title"}),e.jsx("input",{type:"text",value:xe,onChange:Ne=>Re(Ne.target.value),onBlur:Ne=>Re(Ne.target.value.trim()),required:!0,className:"w-full border border-border rounded-sm px-2 py-1.5 text-sm bg-background focus:outline-none focus:ring-1 focus:ring-primary mt-0.5"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"text-xs text-muted-foreground block mb-1",children:"Type"}),e.jsxs("div",{className:"flex flex-wrap gap-2",children:[e.jsxs("label",{className:`flex items-center gap-1.5 border rounded px-3 py-1.5 cursor-pointer text-xs font-medium transition-colors ${Tt==="upcoming"?"border-orange-400 bg-orange-50 text-orange-700":"border-border text-muted-foreground hover:bg-muted"}`,children:[e.jsx("input",{type:"radio",name:`edit-type-${re.id}
640`,value:"upcoming",checked:Tt==="upcoming",onChange:()=>{bt("upcoming"),ya(!1)},className:"sr-only"}),e.jsx(ys,{size:11}),"Upcoming"]}),e.jsxs("label",{className:`flex items-center gap-1.5 border rounded px-3 py-1.5 cursor-pointer text-xs font-medium transition-colors ${Tt==="live"?"border-primary bg-primary/5 text-primary":"border-border text-muted-foreground hover:bg-muted"}`,children:[e.jsx("input",{type:"radio",name:`edit-type-${re.id}`,value:"live",checked:Tt==="live",onChange:()=>{bt("live"),ya(!1)},className:"sr-only"}),e.jsx(Ft,{size:11}),"Current Live"]}),e.jsxs("label",{className:`flex items-center gap-1.5 border rounded px-3 py-1.5 cursor-pointer text-xs font-medium transition-colors ${Tt==="video"?"border-primary bg-primary/5 text-primary":"border-border text-muted-foreground hover:bg-muted"}`,children:[e.jsx("input",{type:"radio",name:`edit-type-${re.id}`,value:"video",checked:Tt==="video",onChange:()=>{bt("video"),ya(!1)},className:"sr-only"}),e.jsx(Yn,{size:11}),"Video"]}),e.jsxs("label",{className:`flex items-center gap-1.5 border rounded px-3 py-1.5 cursor-pointer text-xs font-medium transition-colors ${ca?"border-gray-400 bg-gray-50 text-gray-600":"border-border text-muted-foreground hover:bg-muted"}`,children:[e.jsx("input",{type:"radio",name:`edit-type-${re.id}`,value:"archive",checked:ca,onChange:()=>{bt("video"),ya(!0)},className:"sr-only"}),e.jsx(Qi,{size:11}),"Archive"]})]})]}),(Tt==="upcoming"||Tt==="live")&&e.jsxs("div",{children:[e.jsx("label",{className:"text-xs text-muted-foreground block mb-0.5",children:Tt==="upcoming"?"Scheduled date & time":"Start date & time"}),e.jsx("input",{type:"datetime-local",value:da,onChange:Ne=>fs(Ne.target.value),className:"border border-border rounded-sm px-2 py-1.5 text-sm bg-background focus:outline-none focus:ring-1 focus:ring-primary w-full"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"text-xs text-muted-foreground",children:"Category"}),e.jsxs("select",{value:Ee,onChange:Ne=>He(Ne.target.value),className:"w-full border border-border rounded-sm px-2 py-1.5 text-sm bg-background focus:outline-none focus:ring-1 focus:ring-primary mt-0.5",children:[e.jsx("option",{value:"",children:"— Select —"}),e.jsx("option",{value:"Cutting Horse",children:"Cutting Horse"}),e.jsx("option",{value:"Eventing",children:"Eventing"}),e.jsx("option",{value:"Harness Racing",children:"Harness Racing"}),e.jsx("option",{value:"Horse Health",children:"Horse Health"}),e.jsx("option",{value:"Horse Racing",children:"Horse Racing"}),e.jsx("option",{value:"How To Videos",children:"How To Videos"}),e.jsx("option",{value:"Quarter Horse",children:"Quarter Horse"}),e.jsx("option",{value:"Reined Cow Horse",children:"Reined Cow Horse"}),e.jsx("option",{value:"Reining",children:"Reining"}),e.jsx("option",{value:"Show Jumping",children:"Show Jumping"}),e.jsx("option",{value:"Western Dressage",children:"Western Dressage"}),e.jsxs("optgroup",{label:"Disciplines",children:[e.jsx("option",{value:"Barrel Racing",children:"Barrel Racing"}),e.jsx("option",{value:"Cowboy Dressage",children:"Cowboy Dressage"}),e.jsx("option",{value:"Cross Country",children:"Cross Country"}),e.jsx("option",{value:"Dressage",children:"Dressage"}),e.jsx("option",{value:"Driving",children:"Driving"}),e.jsx("option",{value:"Endurance",children:"Endurance"}),e.jsx("option",{value:"Halter",children:"Halter"}),e.jsx("option",{value:"Hunter/Jumper",children:"Hunter/Jumper"}),e.jsx("option",{value:"Mounted Archery",children:"Mounted Archery"}),e.jsx("option",{value:"Mounted Shooting",children:"Mounted Shooting"}),e.jsx("option",{value:"Polo",children:"Polo"}),e.jsx("option",{value:"Ranch Riding",children:"Ranch Riding"}),e.jsx("option",{value:"Rodeo",children:"Rodeo"}),e.jsx("option",{value:"Roping",children:"Roping"}),e.jsx("option",{value:"Trail",children:"Trail"}),e.jsx("option",{value:"Vaulting",children:"Vaulting"}),e.jsx("option",{value:"Western Pleasure",children:"Western Pleasure"})]})]})]}),e.jsxs("div",{children:[e.jsx("label",{className:"text-xs text-muted-foreground block",children:"Thumbnail"}),e.jsx("p",{className:"text-[10px] text-muted-foreground mb-1",children:"Your thumbnail is your brand. Make it count."}),Qe?e.jsxs("div",{className:"relative w-32 mb-1",children:[e.jsx("img",{src:Qe,alt:"New thumbnail preview",className:"w-32 h-auto border border-border rounded"}),e.jsx("button",{type:"button",onClick:()=>{qe(null),wt("")},className:"absolute -top-1.5 -right-1.5 bg-white border border-border rounded-full p-0.5 hover:bg-red-50 transition-colors",title:"Remove",children:e.jsx(Vt,{size:11,className:"text-red-600"})})]}):e.jsxs("label",{className:"flex items-center gap-2 cursor-pointer border border-dashed border-border px-3 py-2 rounded hover:bg-muted transition-colors w-fit mb-1",children:[e.jsx(ln,{size:13,className:"text-muted-foreground"}),e.jsx("span",{className:"text-xs text-muted-foreground",children:"Upload new image"}),e.jsx("input",{type:"file",accept:"image/jpeg,image/png,image/webp",className:"sr-only",onChange:Ne=>{var rt;const Pe=(rt=Ne.target.files)==null?void 0:rt[0];Pe&&(qe(Pe),wt(URL.createObjectURL(Pe)))}})]}),!Ze&&e.jsx("input",{type:"text",value:ke,onChange:Ne=>$e(Ne.target.value),onBlur:Ne=>$e(Ne.target.value.trim()),placeholder:"https://… or /airo-assets/uploads/…",className:"w-full border border-border rounded-sm px-2 py-1.5 text-sm bg-background focus:outline-none focus:ring-1 focus:ring-primary mt-0.5"})]}),Wa&&e.jsx("p",{className:"text-xs text-red-600",children:Wa}),e.jsxs("div",{className:"flex gap-2 mt-1",children:[e.jsx("button",{type:"submit",disabled:un||kt,className:"px-3 py-1.5 text-xs font-semibold bg-primary text-white rounded-sm hover:bg-primary/90 transition-colors disabled:opacity-60",children:kt?"Uploading…":un?"Saving…":"Save"}),e.jsx("button",{type:"button",onClick:()=>fe(null),className:"px-3 py-1.5 text-xs font-medium border border-border rounded-sm hover:bg-muted transition-colors",children:"Cancel"})]})]})},re.id))}):e.jsx("p",{className:"px-4 py-3 text-xs text-muted-foreground",children:"Loading…"})]}):e.jsx(hz,{username:t})]})]})]})}),e.jsxs("div",{className:"w-full lg:w-[300px] shrink-0 flex flex-col gap-4",children:[e.jsx(zs,{placement:"sidebar-profile"}),e.jsx(O,{to:"/watch-live-events",className:"block w-full text-center text-white font-bold uppercase py-3 text-base bg-primary hover:bg-primary/90 transition-colors",children:"WATCH LIVE EVENTS"}),e.jsx(Cr,{placement:"sidebar-profile-220"})]})]})})}),_t&&e.jsx("div",{className:"fixed inset-0 z-50 flex items-center justify-center p-4 bg-foreground
640/50",onClick:re=>{re.target===re.currentTarget&&Ni()},children:e.jsxs("div",{className:"bg-card border border-border rounded-sm w-full max-w-sm shadow-xl flex flex-col max-h-[80vh]",children:[e.jsxs("div",{className:"flex items-center justify-between px-4 py-3 border-b border-border bg-primary rounded-t-sm",children:[e.jsx("span",{className:"text-primary-foreground font-bold text-sm",children:e.jsx(_,{devId:"c68260",guard:{file:"src/pages/user-profile.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:e72ae4523c6527ab59c45244dd94f9aacd087b2bfbe1ef4a8b7b92f24afe8f9f"},children:_t==="followers"?"Followers":"Following"})}),e.jsx("button",{type:"button",onClick:Ni,className:"text-primary-foreground/80 hover:text-primary-foreground transition-colors","aria-label":"Close",children:e.jsx(Vt,{size:16})})]}),e.jsxs("div",{className:"overflow-y-auto flex-1 py-2",children:[Qs&&e.jsx("div",{className:"flex justify-center py-10",children:e.jsx("div",{className:"w-6 h-6 border-2 border-primary border-t-transparent rounded-full animate-spin"})}),ba&&e.jsx("p",{className:"text-center text-sm text-destructive py-8 px-4",children:e.jsx(_,{devId:"55ebbf",guard:{file:"src/pages/user-profile.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:299075b64104c2fbfb904d05b043c63b628a892bdf6b3ab88746abb4cc1e43e0"},children:ba})}),!Qs&&!ba&&Ct.length===0&&e.jsx("p",{className:"text-center text-sm text-muted-foreground py-8 px-4",children:e.jsx(_,{devId:"55ebc0",guard:{file:"src/pages/user-profile.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:599680d6c8de760eabc0714f9f49bd065489fda3ee059c0690c4447db9eb7583"},children:_t==="followers"?"No followers yet.":"Not following anyone yet."})}),!Qs&&!ba&&Ct.map(re=>e.jsxs(O,{to:`/u/${re.username}`,onClick:Ni,className:"flex items-center gap-3 px-4 py-2.5 hover:bg-muted transition-colors",children:[e.jsx("div",{className:"w-9 h-9 rounded-full bg-muted border border-border overflow-hidden shrink-0 flex items-center justify-center",children:re.avatarUrl?e.jsx("img",{src:re.avatarUrl,alt:re.name??re.username,className:"w-full h-full object-cover",width:36,height:36}):e.jsx(Ha,{size:18,className:"text-muted-foreground",strokeWidth:1.5})}),e.jsxs("div",{className:"min-w-0",children:[e.jsx("p",{className:"text-sm font-semibold text-foreground truncate leading-tight",children:re.name??re.username}),e.jsxs("p",{className:"text-xs text-muted-foreground truncate",children:["@",re.username]})]})]},re.username))]})]})})]})}function mz({username:t,isAdmin:a,currentSlug:r,saving:o,error:l,onSelect:d,onClose:u}){const[m,p]=g.useState([]),[x,b]=g.useState(!1);return g.useEffect(()=>{const y=a?`/api/users/${encodeURIComponent(t)}/videos`:"/api/member/my-videos";fetch(y,{credentials:"include"}).then(v=>v.ok?v.json():{}).then(v=>{p((v.events??v.videos??[]).filter(w=>w.published)),b(!0)}).catch(()=>b(!0))},[t,a]),e.jsxs("div",{className:"border border-border rounded-sm bg-card mb-4 overflow-hidden shadow-sm",children:[e.jsxs("div",{className:"flex items-center justify-between px-4 py-2.5 bg-muted border-b border-border",children:[e.jsx("span",{className:"text-sm font-semibold text-foreground",children:"Choose featured video"}),e.jsx("button",{type:"button",onClick:u,className:"text-muted-foreground hover:text-foreground transition-colors","aria-label":"Close picker",children:e.jsx(Vt,{size:15})})]}),e.jsxs("div",{className:"max-h-72 overflow-y-auto",children:[!x&&e.jsx("p",{className:"px-4 py-3 text-xs text-muted-foreground",children:"Loading…"}),x&&m.length===0&&e.jsx("p",{className:"px-4 py-3 text-xs text-muted-foreground",children:"No published videos found."}),x&&m.map(y=>e.jsxs("button",{type:"button",disabled:o,onClick:()=>d(y.slug),className:`w-full flex items-center gap-3 px-4 py-2.5 text-left hover:bg-muted transition-colors border-b border-border last:border-0 ${y.slug===r?"bg-primary/5":""}`,children:[y.thumbnailUrl?e.jsx("img",{src:y.thumbnailUrl,alt:"",className:"w-16 h-10 object-cover rounded shrink-0 bg-muted",loading:"lazy"}):e.jsx("div",{className:"w-16 h-10 bg-muted rounded shrink-0 flex items-center justify-center",children:e.jsx(Vs,{size:14,className:"text-muted-foreground"})}),e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("p",{className:"text-sm font-medium text-foreground line-clamp-1",children:y.title}),e.jsx("span",{className:`inline-flex items-center gap-1 text-xs font-semibold px-1.5 py-0.5 rounded border mt-0.5 ${y.videoType==="live"?"bg-red-50 text-red-700 border-red-200":y.videoType==="upcoming"?"bg-orange-50 text-orange-700 border-orange-200":"bg-blue-50 text-blue-700 border-blue-200"}`,children:y.videoType==="live"?e.jsxs(e.Fragment,{children:[e.jsx(Ft,{size:9}),"Live"]}):y.videoType==="upcoming"?e.jsxs(e.Fragment,{children:[e.jsx(ys,{size:9}),"Upcoming"]}):e.jsxs(e.Fragment,{children:[e.jsx(Yn,{size:9}),"Video"]})})]}),y.slug===r&&e.jsx(Ea,{size:14,className:"text-primary shrink-0"})]},y.id))]}),r&&e.jsx("div",{className:"px-4 py-2.5 border-t border-border bg-muted/50",children:e.jsx("button",{type:"button",disabled:o,onClick:()=>d(null),className:"text-xs text-destructive hover:underline disabled:opacity-60",children:"Remove featured video"})}),l&&e.jsx("p",{className:"px-4 pb-2 text-xs text-destructive",children:e.jsx(_,{devId:"67e916",guard:{file:"src/pages/user-profile.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionH
640ash:"sha256:ca00fccfb408989eddc401062c4d1219a6aceb6b9b55412357f1790862e8f178"},children:l})})]})}function hz({username:t}){const[a,r]=g.useState([]),[o,l]=g.useState(!1);return g.useEffect(()=>{fetch(`/api/users/${encodeURIComponent(t)}/videos`).then(d=>d.ok?d.json():{videos:[]}).then(d=>{r(d.videos??[]),l(!0)}).catch(()=>l(!0))},[t]),o?a.length===0?e.jsx("p",{className:"text-sm text-muted-foreground py-4",children:"No videos yet."}):e.jsx("ul",{className:"flex flex-col gap-3",children:a.map(d=>e.jsx("li",{children:e.jsxs(O,{to:`/live/${d.slug}`,className:"flex items-start gap-3 group",children:[d.thumbnailUrl?e.jsx("img",{src:d.thumbnailUrl,alt:"",className:"w-24 h-14 object-cover rounded shrink-0 bg-muted",loading:"lazy"}):e.jsx("div",{className:"w-24 h-14 bg-muted rounded shrink-0 flex items-center justify-center",children:e.jsx(Vs,{size:20,className:"text-muted-foreground"})}),e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("p",{className:"text-sm font-medium text-foreground group-hover:text-primary transition-colors line-clamp-2 leading-snug",children:d.title}),e.jsxs("div",{className:"flex flex-wrap items-center gap-x-2 gap-y-0.5 mt-1",children:[e.jsx("span",{className:`inline-flex items-center gap-1 text-xs font-semibold px-1.5 py-0.5 rounded border ${d.videoType==="live"?"bg-red-50 text-red-700 border-red-200":d.videoType==="upcoming"?"bg-orange-50 text-orange-700 border-orange-200":"bg-blue-50 text-blue-700 border-blue-200"}`,children:d.videoType==="live"?e.jsxs(e.Fragment,{children:[e.jsx(Ft,{size:10}),"Live"]}):d.videoType==="upcoming"?e.jsxs(e.Fragment,{children:[e.jsx(ys,{size:10}),"Upcoming"]}):e.jsxs(e.Fragment,{children:[e.jsx(Yn,{size:10}),"Video"]})}),d.videoType==="live"&&e.jsx("span",{className:`inline-flex items-center text-xs font-medium px-1.5 py-0.5 rounded border ${d.isArchived?"bg-gray-50 text-gray-600 border-gray-200":"bg-green-50 text-green-700 border-green-200"}`,children:d.isArchived?"Archive":"Current"}),d.category&&e.jsx("span",{className:"text-xs text-muted-foreground",children:d.category}),e.jsxs("span",{className:"text-xs text-muted-foreground flex items-center gap-1",children:[e.jsx(xa,{size:11}),d.viewCount.toLocaleString()]})]})]})]})},d.id))}):e.jsx("p",{className:"text-xs text-muted-foreground py-4",children:"Loading…"})}const Wc="https://totalhorsechannel.com",wm=`${Wc}/link-to-totalhorsechannel-com`,pz={"@context":"https://schema.org","@type":"WebPage","@id":`${wm}#webpage`,name:Hs.pageTitle+" – Total Horse Channel",url:wm,isPartOf:{"@id":`${Wc}/#website`},about:{"@id":`${Wc}/#organization`}};function fz(){const t=g.useRef(Wm({delay:6500,stopOnInteraction:!1})),[a,r]=g.useState(!1),[o,l]=g.useState(!1),[d,u]=g.useState(!1);function m(p,x){navigator.clipboard.writeText(p).then(()=>{x(!0),setTimeout(()=>x(!1),2e3)})}return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsxs("title",{children:[Hs.pageTitle," – Total Horse Channel"]}),e.jsx("meta",{name:"description",content:Hs.metaDescription}),e.jsx("link",{rel:"canonical",href:wm}),e.jsx("meta",{property:"og:title",content:`${Hs.pageTitle} – Total Horse Channel`}),e.jsx("meta",{property:"og:description",content:Hs.metaDescription}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{property:"og:url",content:wm}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify(pz)})]}),e.jsx("main",{children:e.jsx("div",{className:"max-w-[1280px] mx-auto px-4 py-4",children:e.jsxs("div",{className:"flex flex-col lg:flex-row gap-6",children:[e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("div",{className:"bg-primary px-3 py-2 mb-4",children:e.jsx("h1",{className:"text-white font-bold uppercase text-sm tracking-wide",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"b20e72",guard:{file:"src/pages/link-to.tsx",tagName:"h1",sourceKind:"content-key",contentKey:"link_to.pageTitle",contentKeyTemplate:null,expressionHash:null},children:Hs.pageTitle})})}),e.jsx("p",{className:"text-sm text-foreground mb-6",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"745d75",guard:{file:"src/pages/link-to.tsx",tagName:"p",sourceKind:"content-key",contentKey:"link_to.intro",contentKeyTemplate:null,expressionH
640ash:null},children:Hs.intro})}),e.jsxs("section",{className:"mb-8","aria-labelledby":"text-link-heading",children:[e.jsx("h2",{id:"text-link-heading",className:"font-bold text-foreground border-b border-border pb-2 mb-4",style:{whiteSpace:"pre-line",fontSize:"18px"},children:e.jsx(_,{devId:"368185",guard:{file:"src/pages/link-to.tsx",tagName:"h2",sourceKind:"content-key",contentKey:"link_to.textLinkSection.heading",contentKeyTemplate:null,expressionHash:null},children:Hs.textLinkSection.heading})}),e.jsx("p",{className:"text-sm text-foreground mb-3",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"114adb",guard:{file:"src/pages/link-to.tsx",tagName:"p",sourceKind:"content-key",contentKey:"link_to.textLinkSection.description",contentKeyTemplate:null,expressionHash:null},children:Hs.textLinkSection.description})}),e.jsxs("div",{className:"border border-border rounded bg-card px-4 py-3 mb-3",children:[e.jsx("p",{className:"text-xs text-muted-foreground mb-2 font-semibold uppercase tracking-wide",children:"Preview"}),e.jsx("a",{href:Hs.textLinkSection.linkUrl,target:"_blank",rel:"noopener noreferrer",className:"text-accent hover:underline font-medium text-sm",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"371060",guard:{file:"src/pages/link-to.tsx",tagName:"a",sourceKind:"content-key",contentKey:"link_to.textLinkSection.linkLabel",contentKeyTemplate:null,expressionHash:null},children:Hs.textLinkSection.linkLabel})})]}),e.jsx("p",{className:"text-xs font-semibold text-muted-foreground uppercase tracking-wide mb-1",children:"HTML"}),e.jsxs("div",{className:"flex items-stretch border border-border rounded overflow-hidden bg-muted",children:[e.jsx("pre",{className:"flex-1 px-3 py-2.5 text-xs text-foreground font-mono overflow-x-auto whitespace-pre-wrap break-all leading-relaxed",children:Hs.textLinkSection.code}),e.jsx("button",{type:"button",onClick:()=>m(Hs.textLinkSection.code,r),className:"shrink-0 px-3 border-l border-border bg-background hover:bg-muted transition-colors flex items-center gap-1.5 text-xs font-medium text-foreground","aria-label":"Copy text link HTML",children:e.jsx(_,{devId:"94c41c",guard:{file:"src/pages/link-to.tsx",tagName:"button",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:07fb5c96b5c018b999006381d20e1b6bbd21df4f3f04e54a4fc603b351a56f0f"},children:a?e.jsxs(e.Fragment,{children:[e.jsx(Ea,{size:13,className:"text-green-600"}),e.jsx("span",{className:"text-green-600",children:"Copied"})]}):e.jsxs(e.Fragment,{children:[e.jsx(Qo,{size:13}),e.jsx("span",{children:"Copy"})]})})})]})]}),e.jsxs("section",{"aria-labelledby":"logo-link-heading",children:[e.jsx("h2",{id:"logo-link-heading",className:"font-bold text-foreground border-b border-border pb-2 mb-4",style:{whiteSpace:"pre-line",fontSize:"18px"},children:e.jsx(_,{devId:"8baa26",guard:{file:"src/pages/link-to.tsx",tagName:"h2",sourceKind:"content-key",contentKey:"link_to.logoLinkSection.heading",contentKeyTemplate:null,expressionHash:null},children:Hs.logoLinkSection.heading})}),e.jsx("p",{className:"text-sm text-foreground mb-5",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"23635c",guard:{file:"src/pages/link-to.tsx",tagName:"p",sourceKind:"content-key",contentKey:"link_to.logoLinkSection.description",contentKeyTemplate:null,expressionHash:null},children:Hs.logoLinkSection.description})}),e.jsxs("div",{className:"flex flex-col gap-8",children:[e.jsxs("div",{children:[e.jsx("p",{className:"text-sm font-semibold text-foreground mb-3",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"02e684",guard:{file:"src/pages/link-to.tsx",tagName:"p",sourceKind:"content-key",contentKey:"link_to.logoLinkSection.lightVariantLabel",contentKeyTemplate:null,expressionHash:null},children:Hs.logoLinkSection.lightVariantLabel})}),e.jsx("div",{className:"border border-border rounded bg-white px-6 py-5 flex items-center justify-center mb-3",style:{minHeight:"100px"},children:e.jsx("a",{href:Wc,target:"_blank",rel:"noopener noreferrer",children:e.jsx("img",{src:"/airo-assets/images/logo/horizontal/light",alt:"Total Horse Channel",width:220,height:60,className:"h-auto max-h-14 w-auto object-contain",loading:"eager",fetchPriority:"high"})})}),e.jsx("p",{className:"text-xs font-semibold text-muted-foreground uppercase tracking-wide mb-1",children:"HTML"}),e.jsxs("div",{className:"flex items-stretch border border-border rounded overflow-hidden bg-muted",children:[e.jsx("pre",{className:"flex-1 px-3 py-2.5 text-xs text-foreground font-mono overflow-x-auto whitespace-pre-wrap break-all leading-relaxed",children:Hs.logoLinkSection.lightCode}),e.jsx("button",{type:"button",onClick:()=>m(Hs.logoLinkSection.lightCode,l),className:"shrink-0 px-3 border-l border-border bg-background hover:bg-muted transition-colors flex items-center gap-1.5 text-xs font-medium text-foreground","aria-label":"Copy color logo HTML",children:e.jsx(_,{devId:"182425",guard:{file:"src/pages/link-to.tsx",tagName:"button",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionH
640ash:"sha256:9c6f0359855954a5a6527dd678e804bf26161832b0e2697c1520f1bec1550733"},children:o?e.jsxs(e.Fragment,{children:[e.jsx(Ea,{size:13,className:"text-green-600"}),e.jsx("span",{className:"text-green-600",children:"Copied"})]}):e.jsxs(e.Fragment,{children:[e.jsx(Qo,{size:13}),e.jsx("span",{children:"Copy"})]})})})]}),e.jsx("div",{className:"mt-2",children:e.jsxs("a",{href:"/#light",download:"totalhorsechannel-logo-color.png",target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-1.5 text-xs text-accent hover:underline font-medium",children:[e.jsx(I0,{size:12}),e.jsx("span",{children:"Download color logo"})]})})]}),e.jsxs("div",{children:[e.jsx("p",{className:"text-sm font-semibold text-foreground mb-3",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"14ff05",guard:{file:"src/pages/link-to.tsx",tagName:"p",sourceKind:"content-key",contentKey:"link_to.logoLinkSection.darkVariantLabel",contentKeyTemplate:null,expressionHash:null},children:Hs.logoLinkSection.darkVariantLabel})}),e.jsx("div",{className:"border border-border rounded px-6 py-5 flex items-center justify-center mb-3 bg-secondary",style:{minHeight:"100px"},children:e.jsx("a",{href:Wc,target:"_blank",rel:"noopener noreferrer",children:e.jsx("img",{src:"/airo-assets/images/logo/horizontal/dark",alt:"Total Horse Channel",width:220,height:60,className:"h-auto max-h-14 w-auto object-contain",loading:"lazy"})})}),e.jsx("p",{className:"text-xs font-semibold text-muted-foreground uppercase tracking-wide mb-1",children:"HTML"}),e.jsxs("div",{className:"flex items-stretch border border-border rounded overflow-hidden bg-muted",children:[e.jsx("pre",{className:"flex-1 px-3 py-2.5 text-xs text-foreground font-mono overflow-x-auto whitespace-pre-wrap break-all leading-relaxed",children:Hs.logoLinkSection.darkCode}),e.jsx("button",{type:"button",onClick:()=>m(Hs.logoLinkSection.darkCode,u),className:"shrink-0 px-3 border-l border-border bg-background hover:bg-muted transition-colors flex items-center gap-1.5 text-xs font-medium text-foreground","aria-label":"Copy white logo HTML",children:e.jsx(_,{devId:"4d4a06",guard:{file:"src/pages/link-to.tsx",tagName:"button",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:c5e3fd66570a490f3f99c5a5cdd42ee07feafac706147cba418c45043255b939"},children:d?e.jsxs(e.Fragment,{children:[e.jsx(Ea,{size:13,className:"text-green-600"}),e.jsx("span",{className:"text-green-600",children:"Copied"})]}):e.jsxs(e.Fragment,{children:[e.jsx(Qo,{size:13}),e.jsx("span",{children:"Copy"})]})})})]}),e.jsx("div",{className:"mt-2",children:e.jsxs("a",{href:"/#dark",download:"totalhorsechannel-logo-white.png",target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-1.5 text-xs text-accent hover:underline font-medium",children:[e.jsx(I0,{size:12}),e.jsx("span",{children:"Download white logo"})]})})]})]})]})]}),e.jsxs("aside",{className:"w-full lg:w-[340px] shrink-0 flex flex-col gap-4",children:[e.jsx(yg,{opts:{loop:!0},plugins:[t.current],children:e.jsxs(vg,{children:[e.jsx(Gu,{children:e.jsx("a",{href:"/advertise",children:e.jsx("img",{src:"/airo-assets/images/sidebar/wdaa-banner",alt:"WDAA Western Dressage",width:340,height:340,className:"w-full aspect-square object-cover",loading:"lazy"})})}),e.jsx(Gu,{children:e.jsx("a",{href:"/sponsors-partners",children:e.jsx("img",{src:"/airo-assets/images/sidebar/debbie-brooks-custom-cuff",alt:"Debbie Brooks Custom Cuffs",width:340,height:340,className:"w-full aspect-square object-cover",loading:"lazy"})})})]})}),e.jsx(O,{to:"/watch-live-events",className:"block bg-primary text-white text-center font-bold uppercase py-3 px-4 text-sm tracking-wide hover:bg-primary/90 transition-colors",children:"Watch Live Events"}),e.jsx(O,{to:"/",className:"block bg-secondary text-white text-center font-bold uppercase py-3 px-4 text-sm tracking-wide hover:opacity-90 transition-opacity",children:"← Back to Home"}),e.jsx(O,{to:"/mission",className:"block w-full text-center font-bold uppercase py-2 text-sm bg-gray-200 text-gray-800 hover:bg-gray-300 transition-colors",children:"Our Mission"}),e.jsxs("div",{className:"border border-border p-4 text-center",children:[e.jsx("p",{className:"font-bold text-foreground mb-1",style:{fontSize:"14px"},children:"Advertise With Us"}),e.jsx("p",{className:"text-muted-foreground text-xs mb-3",children:"Reach thousands of horse enthusiasts. Request our media kit today."}),e.jsx(O,{to:"/advertise",className:"inline-block bg-primary text-white text-xs font-bold uppercase px-4 py-2 hover:bg-primary/90 transition-colors",children:"Learn More"})]})]})]})})})]})}const Ex="https://totalhorsechannel.com",Nm=`${Ex}/aha-media-partner`,xz={"@context":"https://schema.org","@type":"WebPage","@id":`${Nm}#webpage`,name:Mn.pageTitle+" – Total Horse Channel",url:Nm,isPartOf:{"@id":`${Ex}/#website`},about:{"@id":`${Ex}/#organization`}};function gz(){return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsxs("title",{children:[Mn.pageTitle," – Total Horse Channel"]}),e.jsx("meta",{name:"description",content:Mn.metaDescription}),e.jsx("link",{rel:"canonical",href:Nm}),e.jsx("meta",{property:"og:title",content:`${Mn.pageTitle} – Total Horse Channel`}),e.jsx("meta",{property:"og:description",content:Mn.metaDescription}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{property:"og:url",content:Nm}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify(xz)})]}),e.jsx("main",{children:e.jsxs("div",{className:"max-w-[1280px] mx-auto px-4 py-4",children:[e.jsx("div",{className:"bg-primary px-3 py-2 mb-6",children:e.jsx("h1",{className:"text-white font-bold uppercase text-sm tracking-wide",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"278fbf",guard:{file:"src/pages/aha-partner.tsx",tagName:"h1",sourceKind:"content-key",contentKey:"aha_partner.pageTitle",contentKeyTemplate:null,expressionH
640ash:null},children:Mn.pageTitle})})}),e.jsxs("div",{className:"max-w-[680px]",children:[e.jsx("div",{className:"mb-6",children:e.jsx("a",{href:"https://www.arabianhorses.org",target:"_blank",rel:"noopener noreferrer","aria-label":"Visit Arabian Horse Association",children:e.jsx("img",{src:"/airo-assets/images/pages/aha-partner/taryl-photo",alt:"Arabian Horse Association – Official Media Partner of Total Horse Channel",width:480,height:480,className:"w-full max-w-[480px] h-auto object-contain",loading:"eager",fetchPriority:"high"})})}),e.jsx("h2",{className:"font-bold text-foreground mb-4",style:{whiteSpace:"pre-line",fontSize:"22px"},children:e.jsx(_,{devId:"7cbca1",guard:{file:"src/pages/aha-partner.tsx",tagName:"h2",sourceKind:"content-key",contentKey:"aha_partner.headline",contentKeyTemplate:null,expressionHash:null},children:Mn.headline})}),e.jsx("p",{className:"text-sm text-foreground leading-relaxed mb-6",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"ae9277",guard:{file:"src/pages/aha-partner.tsx",tagName:"p",sourceKind:"content-key",contentKey:"aha_partner.body",contentKeyTemplate:null,expressionHash:null},children:Mn.body})}),e.jsxs("a",{href:Mn.ctaHref,target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-2 bg-primary text-white font-semibold px-5 py-2.5 text-sm hover:bg-primary/90 transition-colors rounded-sm",children:[e.jsx("span",{style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"4f7e8b",guard:{file:"src/pages/aha-partner.tsx",tagName:"span",sourceKind:"content-key",contentKey:"aha_partner.ctaLabel",contentKeyTemplate:null,expressionHash:null},children:Mn.ctaLabel})}),e.jsx(dt,{size:14})]})]})]})})]})}function _f(t){var a,r;try{const o=new URL(t);return o.hostname==="youtu.be"?o.pathname.slice(1).split("?")[0]:o.pathname.startsWith("/live/")?((a=o.pathname.split("/live/")[1])==null?void 0:a.split("?")[0])??null:o.pathname.startsWith("/embed/")?((r=o.pathname.split("/embed/")[1])==null?void 0:r.split("?")[0])??null:o.searchParams.get("v")}catch{return null}}function Lf(t){const a=t.match(/rumble\.com\/embed\/([vV][A-Za-z0-9]+)/);if(a)return a[1];const r=t.match(/rumble\.com\/([vV][A-Za-z0-9]+)/);return r?r[1]:null}function aw(t,a){if(!t.trim())return;const r=a.trim()||"00:00";return new Date(`${t}T${r}`).toISOString()}function nw(t){const a=new Date(t);if(isNaN(a.getTime()))return{date:"",time:""};const r=o=>String(o).padStart(2,"0");return{date:`${a.getFullYear()}-${r(a.getMonth()+1)}-${r(a.getDate())}`,time:`${r(a.getHours())}:${r(a.getMinutes())}`}}const bz=[{value:"youtube",label:"YouTube"},{value:"rumble",label:"Rumble"},{value:"vimeo",label:"Vimeo"},{value:"box",label:"Box"},{value:"other",label:"Other"}];function xs(){return"w-full border border-border px-3 py-2 text-sm bg-background focus:outline-none focus:ring-2 focus:ring-primary"}function Yi(t){return t.trim()}function yz(){const{isAuthenticated:t,isPending:a}=Us(),[r]=Bm(),o=r.get("edit")??"",l=r.get("dupe")??"",[d,u]=g.useState(""),[m,p]=g.useState(""),[x,b]=g.useState(""),[y,v]=g.useState(""),[w,C]=g.useState(""),[A,S]=g.useState(""),[z,T]=g.useState(""),[M,P]=g.useState(""),[E,U]=g.useState(""),[q,H]=g.useState(""),[J,B]=g.useState(""),[Y,$]=g.useState(""),[D,W]=g.useState(""),[I,k]=g.useState(""),[K,L]=g.useState(""),[se,X]=g.useState(""),[le,ge]=g.useState("auto"),[Se,Me]=g.useState(null),[st,We]=g.useState(""),[Ye,te]=g.useState(!1),[me,Le]=g.useState(!1),[Ie,ve]=g.useState(!1),[ze,Ue]=g.useState(!1),[ct,Ot]=g.useState(!1),[Et,Zt]=g.useState(""),[as,Jt]=g.useState(""),[vs,js]=g.useState(""),[Ws,Mt]=g.useState(""),[jt,ps]=g.useState(""),[Wt,ws]=g.useState(""),[os,qt]=g.useState(""),[je,gt]=g.useState(""),[et,Xe]=g.useState("idle"),[Ae,De]=g.useState(""),[ft,Yt]=g.useState("");if(g.useEffect(()=>{!o||!t||fetch(`/api/member/my-videos/${o}`,{credentials:"include"}).then(ue=>ue.ok?ue.json():null).then(ue=>{const be=ue==null?void 0:ue.event;if(!be)return;typeof be.title=="string"&&u(be.title),typeof be.source=="string"&&C(be.source),typeof be.videoInput=="string"&&S(be.videoInput??""),typeof be.thumbnailUrl=="string"&&(X(be.thumbnailUrl),ge("url")),typeof be.providedBy=="str
640ing"&&H(be.providedBy??""),typeof be.providerLink=="string"&&B(be.providerLink??""),typeof be.moreInfoUrl=="string"&&$(be.moreInfoUrl??""),typeof be.category=="string"&&T(be.category??"");const _t=be.videoType,ns=!!be.isArchived;if(p(ns?"archive":_t==="live"?"live":_t==="upcoming"?"upcoming":"video"),typeof be.startAt=="string"&&be.startAt){const{date:Ct,time:Ut}=nw(be.startAt);b(Ct),v(Ut)}if(typeof be.location=="string"&&be.location){const Ct=be.location.split(" — ");W(Ct[0]??""),k(Ct[1]??"")}if(typeof be.description=="string"&&be.description){const Ct=be.description.replace(/^Category:[^\n]*\n\n?/,"");L(Ct)}}).catch(()=>{})},[o,t]),g.useEffect(()=>{!l||!t||fetch(`/api/member/my-videos/${l}`,{credentials:"include"}).then(ue=>ue.ok?ue.json():null).then(ue=>{const be=ue==null?void 0:ue.event;if(!be)return;typeof be.source=="string"&&C(be.source),typeof be.thumbnailUrl=="string"&&be.thumbnailUrl&&(X(be.thumbnailUrl),ge("url")),typeof be.providedBy=="string"&&H(be.providedBy??""),typeof be.providerLink=="string"&&B(be.providerLink??""),typeof be.moreInfoUrl=="string"&&$(be.moreInfoUrl??""),typeof be.category=="string"&&T(be.category??"");const _t=be.videoType,ns=!!be.isArchived;if(p(ns?"archive":_t==="live"?"live":_t==="upcoming"?"upcoming":"video"),typeof be.location=="string"&&be.location){const Ct=be.location.split(" — ");W(Ct[0]??""),k(Ct[1]??"")}if(typeof be.description=="string"&&be.description){const Ct=be.description.replace(/^Category:[^\n]*\n\n?/,"");L(Ct)}if(typeof be.startAt=="string"&&be.startAt){const{date:Ct,time:Ut}=nw(be.startAt);b(Ct),v(Ut)}}).catch(()=>{})},[l,t]),a)return null;if(!t)return e.jsxs(e.Fragment,{children:[e.jsx(we,{children:e.jsxs("title",{children:[Cs.pageTitle," – Total Horse Channel"]})}),e.jsxs("main",{className:"max-w-[680px] mx-auto px-4 py-16 text-center",children:[e.jsx(Vs,{size:48,className:"mx-auto mb-4 text-primary"}),e.jsx("h1",{className:"text-2xl font-bold mb-3",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"609d8e",guard:{file:"src/pages/add-video-live.tsx",tagName:"h1",sourceKind:"content-key",contentKey:"add_video_live.loginGate.heading",contentKeyTemplate:null,expressionHash:null},children:Cs.loginGate.heading})}),e.jsx("p",{className:"text-muted-foreground mb-6",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"f389e5",guard:{file:"src/pages/add-video-live.tsx",tagName:"p",sourceKind:"content-key",contentKey:"add_video_live.loginGate.body",contentKeyTemplate:null,expressionHash:null},children:Cs.loginGate.body})}),e.jsx(O,{to:"/login",className:"inline-block bg-primary text-primary-foreground font-semibold px-6 py-3 hover:bg-primary/90 transition-colors",children:Cs.loginGate.cta})]})]});if(et==="not-approved")return e.jsxs(e.Fragment,{children:[e.jsx(we,{children:e.jsxs("title",{children:[Cs.pageTitle," – Total Horse Channel"]})}),e.jsxs("main",{className:"max-w-[680px] mx-auto px-4 py-16 text-center",children:[e.jsx(so,{size:48,className:"mx-auto mb-4 text-muted-foreground"}),e.jsx("h1",{className:"text-2xl font-bold mb-3",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"609d8e",guard:{file:"src/pages/add-video-live.tsx",tagName:"h1",sourceKind:"content-key",contentKey:"add_video_live.notApproved.heading",contentKeyTemplate:null,expressionHash:null},children:Cs.notApproved.heading})}),e.jsx("p",{className:"text-muted-foreground mb-4",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"f389e5",guard:{file:"src/pages/add-video-live.tsx",tagName:"p",sourceKind:"content-key",contentKey:"add_video_live.notApproved.body",contentKeyTemplate:null,expressionHash:null},children:Cs.notApproved.body})}),e.jsx("a",{href:"mailto:[email protected]",className:"inline-block bg-primary text-primary-foreground font-semibold px-6 py-3 hover:bg-primary/90 transition-colors",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"f34a16",guard:{file:"src/pages/add-video-live.tsx",tagName:"a",sourceKind:"content-key",contentKey:"add_video_live.notApproved.cta",contentKeyTemplate:null,expressionHash:null},children:Cs.notApproved.cta})})]})]});if(et==="success")return e.jsxs(e.Fragment,{children:[e.jsx(we,{children:e.jsx("title",{children:"Published – Total Horse Channel"})}),e.jsxs("main",{className:"max-w-[680px] mx-auto px-4 py-16 text-center",children:[e.jsx(kn,{size:52,className:"mx-auto mb-4 text-green-600"}),e.jsx("h1",{className:"text-2xl font-bold mb-3",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"609d8e",guard:{file:"src/pages/add-video-live.tsx",tagName:"h1",sourceKind:"content-key",contentKey:"add_video_live.success.heading",contentKeyTemplate:null,expressionH
640ash:null},children:Cs.success.heading})}),e.jsxs("p",{className:"text-muted-foreground mb-6",children:[e.jsx("span",{children:e.jsx(_,{devId:"608f28",guard:{file:"src/pages/add-video-live.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:e15865558d65eea93737b7b3d8a13fa938fb4df20680394e859a1e68e57e836c"},children:Cs.success.body.split("Watch Live Events")[0]})}),e.jsx(O,{to:"/watch-live-events",className:"text-accent hover:underline",children:"Watch Live Events"}),e.jsx("span",{children:e.jsx(_,{devId:"608f29",guard:{file:"src/pages/add-video-live.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:550592afa7bb2395de87a7ab2423a009b5c53bf00f0557aa70826d614bab5d85"},children:Cs.success.body.split("Watch Live Events")[1]})})]}),e.jsxs("div",{className:"flex flex-wrap justify-center gap-3",children:[ft&&e.jsx(O,{to:`/live/${ft}`,className:"bg-primary text-primary-foreground font-semibold px-5 py-2 hover:bg-primary/90 transition-colors",children:Cs.success.ctaView}),e.jsx("button",{onClick:()=>{u(""),p(""),C(""),S(""),T(""),b(""),v(""),H(""),B(""),$(""),W(""),k(""),L(""),X(""),Me(null),We(""),ge("auto"),Le(!1),ve(!1),Ue(!1),Ot(!1),Zt(""),Jt(""),js(""),Mt(""),ps(""),ws(""),qt(""),gt(""),Xe("idle"),Yt("")},className:"border border-border px-5 py-2 font-semibold hover:bg-muted transition-colors",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"a8b7c5",guard:{file:"src/pages/add-video-live.tsx",tagName:"button",sourceKind:"content-key",contentKey:"add_video_live.success.ctaAnother",contentKeyTemplate:null,expressionHash:null},children:Cs.success.ctaAnother})})]})]})]});if(et==="draft-saved")return e.jsxs(e.Fragment,{children:[e.jsx(we,{children:e.jsx("title",{children:"Draft Saved – Total Horse Channel"})}),e.jsxs("main",{className:"max-w-[680px] mx-auto px-4 py-16 text-center",children:[e.jsx(kn,{size:52,className:"mx-auto mb-4 text-yellow-500"}),e.jsx("h1",{className:"text-2xl font-bold mb-3",children:"Draft saved"}),e.jsx("p",{className:"text-muted-foreground mb-6",children:"Your draft is saved and only visible to you and admins. Come back any time to add the video URL and publish it."}),e.jsxs("div",{className:"flex flex-wrap justify-center gap-3",children:[e.jsx(O,{to:"/u/me",className:"bg-primary text-primary-foreground font-semibold px-5 py-2 hover:bg-primary/90 transition-colors",children:"View my videos"}),e.jsx("button",{onClick:()=>{u(""),p(""),C(""),S(""),T(""),b(""),v(""),H(""),B(""),$(""),W(""),k(""),L(""),X(""),Me(null),We(""),ge("auto"),Le(!1),ve(!1),Ue(!1),Ot(!1),Zt(""),Jt(""),js(""),Mt(""),ps(""),ws(""),qt(""),gt(""),Xe("idle"),Yt("")},className:"border border-border px-5 py-2 font-semibold hover:bg-muted transition-colors",children:"Add another"})]})]})]});async function ls(ue){if(ue.preventDefault(),De(""),!d.trim()){De("Please enter a title before saving a draft."),Xe("error");return}if(!z.trim()){De("Please choose a category before saving a draft."),Xe("error");return}Xe("saving-draft");try{let be=se.trim()||void 0;if(le==="auto"&&w==="youtube"){const Ut=_f(A.trim());Ut&&(be=`https://img.youtube.com/vi/${Ut}/hqdefault.jpg`)}if(le==="auto"&&w==="rumble"){const Ut=Lf(A.trim());Ut&&(be=`https://sp.rmbl.ws/s8/1/${Ut}.jpg`)}if(le==="upload"&&Se){te(!0);const Ut=new FormData;Ut.append("file",Se);const Qs=await fetch("/api/live-events/upload-thumbnail",{method:"POST",body:Ut}),Is=await Qs.json();if(te(!1),!Qs.ok||!Is.url){De(Is.error??"Thumbnail upload failed."),Xe("error");return}be=Is.url}const _t={title:d,source:w,videoInput:A,videoType:m==="upcoming"?"upcoming":m==="archive"?"archive":m||"video",category:z,extraCategories:[M,E].filter(Boolean),providedBy:q,providerLink:J,moreInfoUrl:Y,country:D,city:I,description:K,thumbnailUrl:be,startAt:aw(x,y)};let ns;o?ns=await fetch(`/api/member/my-videos/${o}/draft`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(_t),credentials:"include"}):ns=await fetch("/api/member/submit-video",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({..._t,publishStatus:"draft"})});const Ct=await ns.json();if(ns.status===403&&Ct.notApproved){Xe("not-approved");return}if(!ns.ok){De(Ct.error??"Save failed. Please try again."),Xe("error");return}Xe("draft-saved")}catch{De("Network error. Please try again."),Xe("error")}}async function qs(ue){if(ue.preventDefault(),De(""),!A.trim()){De("Add a video URL or embed before publishing."),Xe("error");return}if(!w){De("Please select a source before publishing."),Xe("error");return}if(!m){De("Please select a type (Upcoming, Live, Video, or Archive) before publishing."),Xe("error");return}if(!z.trim()){De("Please choose a category."),Xe("error");return}if(!D.trim()){De("Country is required before publishing."),Xe("error");return}if(!me||!Ie||!ze){De("Please check all three confirmation boxes before publishing."),Xe("error");return}Xe("submitting");try{let be=se.trim()||void 0;if(le==="auto"&&w==="youtube"){const Ut=_f(A.trim());Ut&&(be=`https://img.youtube.com/vi/${Ut}/hqdefault.jpg`)}if(le==="auto"&&w==="rumble"){const Ut=Lf(A.trim());Ut&&(be=`https://sp.rmbl.ws/s8/1/${Ut}.jpg`)}if(le==="upload"&&Se){te(!0);
640const Ut=new FormData;Ut.append("file",Se);const Qs=await fetch("/api/live-events/upload-thumbnail",{method:"POST",body:Ut}),Is=await Qs.json();if(te(!1),!Qs.ok||!Is.url){De(Is.error??"Thumbnail upload failed."),Xe("error");return}be=Is.url}const _t={title:d,source:w,videoInput:A,videoType:m==="upcoming"?"upcoming":m==="archive"?"archive":m,category:z,extraCategories:[M,E].filter(Boolean),providedBy:q,providerLink:J,moreInfoUrl:Y,country:D,city:I,description:K,thumbnailUrl:be,startAt:aw(x,y),isHorseRelated:me,hasRights:Ie,isAppropriate:ze,createEvent:ct,eventStartDate:Et,eventEndDate:as,eventCityVenue:vs,eventCountry:Ws,eventWebsite:jt,eventProvidedBy:Wt,eventLogoUrl:os,eventButtonLink:je};let ns;o?ns=await fetch(`/api/member/my-videos/${o}/publish`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(_t),credentials:"include"}):ns=await fetch("/api/member/submit-video",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({..._t,publishStatus:"publish"})});const Ct=await ns.json();if(ns.status===403&&Ct.notApproved){Xe("not-approved");return}if(!ns.ok){De(Ct.error??"Submission failed. Please try again."),Xe("error");return}Yt(Ct.slug??""),Xe("success")}catch{De("Network error. Please try again."),Xe("error")}}return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsxs("title",{children:[Cs.pageTitle," – Total Horse Channel"]}),e.jsx("meta",{name:"description",content:Cs.metaDescription}),e.jsx("link",{rel:"canonical",href:"https://totalhorsechannel.com/add-video-live"}),e.jsx("meta",{name:"robots",content:"noindex"}),e.jsx("meta",{property:"og:title",content:`${Cs.pageTitle} – Total Horse Channel`}),e.jsx("meta",{property:"og:description",content:Cs.metaDescription}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{property:"og:url",content:"https://totalhorsechannel.com/add-video-live"}),e.jsx("meta",{property:"og:image",content:"https://totalhorsechannel.com/airo-assets/images/logo/horizontal"}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("meta",{name:"twitter:title",content:`${Cs.pageTitle} – Total Horse Channel`}),e.jsx("meta",{name:"twitter:description",content:Cs.metaDescription}),e.jsx("meta",{name:"twitter:image",content:"https://totalhorsechannel.com/airo-assets/images/logo/horizontal"}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify({"@context":"https://schema.org","@type":"WebPage","@id":"https://totalhorsechannel.com/add-video-live#webpage",name:`${Cs.pageTitle} – Total Horse Channel`,url:"https://totalhorsechannel.com/add-video-live",isPartOf:{"@id":"https://totalhorsechannel.com/#website"}}).replace(/</g,"\\u003c")})]}),e.jsxs("main",{className:"max-w-[760px] mx-auto px-4 py-8",children:[e.jsxs("div",{className:"bg-primary text-primary-foreground px-5 py-4 mb-6 flex items-center gap-3",children:[e.jsx(Vs,{size:22}),e.jsx("h1",{className:"text-xl font-bold",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"b4dce2",guard:{file:"src/pages/add-video-live.tsx",tagName:"h1",sourceKind:"content-key",contentKey:"add_video_live.pageTitle",contentKeyTemplate:null,expressionHash:null},children:Cs.pageTitle})})]}),e.jsx("p",{className:"text-muted-foreground mb-6 text-sm leading-relaxed",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"f389e5",guard:{file:"src/pages/add-video-live.tsx",tagName:"p",sourceKind:"content-key",contentKey:"add_video_live.intro",contentKeyTemplate:null,expressionHash:null},children:Cs.intro})}),et==="error"&&e.jsxs("div",{className:"flex items-start gap-2 bg-red-50 border border-red-200 text-red-700 px-4 py-3 mb-5 text-sm",children:[e.jsx(Xi,{size:16,className:"mt-0.5 shrink-0"}),e.jsx("span",{children:e.jsx(_,{devId:"e144dc",guard:{file:"src/pages/add-video-live.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:1c0238d2a5401216440d3a40ef09cf8a641cbbc703bbdb0cfe4af2625e4564c6"},children:Ae})})]}),e.jsxs("form",{onSubmit:qs,noValidate:!0,className:"flex flex-col gap-5",children:[e.jsxs("div",{children:[e.jsxs("label",{htmlFor:"avl-title",className:"block text-sm font-semibold mb-1",children:["Title ",e.jsx("span",{className:"text-red-500",children:"*"})]}),e.jsx("input",{id:"avl-title",type:"text",required:!0,maxLength:200,value:d,onChange:ue=>u(ue.target.value),onBlur:ue=>u(Yi(ue.target.value)),placeholder:"e.g. 2026 WDAA World Championship – Ring 1 Live",className:xs()})]}),e.jsxs("div",{children:[e.jsxs("label",{className:"block text-sm font-semibold mb-2",children:["Type ",e.jsx("span",{className:"text-red-500",children:"*"})," ",e.jsx("span",{className:"text-xs font-normal text-muted-foreground",children:"(required to publish)"})]}),e.jsxs("div",{className:"flex gap-3 flex-wrap",children:[e.jsxs("label",{className:`flex items-center gap-2.5 border rounded px-4 py-3 cursor-pointer flex-1 min-w-[140px] transition-colors ${m==="upcoming"?"border-blue-500 bg-blue-50":"border-border hover:bg-muted"}`,children:[e.jsx("input",{type:"radio",name:"avl-video-type",value:"upcoming",checked:m==="upcoming",onCh
640ange:()=>p("upcoming"),className:"accent-blue-600"}),e.jsx(Ms,{size:15,className:m==="upcoming"?"text-blue-600":"text-muted-foreground"}),e.jsxs("div",{children:[e.jsx("p",{className:"text-sm font-semibold leading-tight",children:"Upcoming"}),e.jsx("p",{className:"text-xs text-muted-foreground mt-0.5",children:"A scheduled future event. Shows in Upcoming Live Events with start date/time."})]})]}),e.jsxs("label",{className:`flex items-center gap-2.5 border rounded px-4 py-3 cursor-pointer flex-1 min-w-[140px] transition-colors ${m==="live"?"border-primary bg-primary/5":"border-border hover:bg-muted"}`,children:[e.jsx("input",{type:"radio",name:"avl-video-type",value:"live",checked:m==="live",onChange:()=>p("live"),className:"accent-primary"}),e.jsx(Ft,{size:15,className:m==="live"?"text-primary":"text-muted-foreground"}),e.jsxs("div",{children:[e.jsx("p",{className:"text-sm font-semibold leading-tight",children:"Live"}),e.jsx("p",{className:"text-xs text-muted-foreground mt-0.5",children:"A current livestream. Appears under Current Live Events."})]})]}),e.jsxs("label",{className:`flex items-center gap-2.5 border rounded px-4 py-3 cursor-pointer flex-1 min-w-[140px] transition-colors ${m==="video"?"border-primary bg-primary/5":"border-border hover:bg-muted"}`,children:[e.jsx("input",{type:"radio",name:"avl-video-type",value:"video",checked:m==="video",onChange:()=>p("video"),className:"accent-primary"}),e.jsx(Yn,{size:15,className:m==="video"?"text-primary":"text-muted-foreground"}),e.jsxs("div",{children:[e.jsx("p",{className:"text-sm font-semibold leading-tight",children:"Video"}),e.jsx("p",{className:"text-xs text-muted-foreground mt-0.5",children:"A recorded video. Does not appear in Live Now."})]})]}),e.jsxs("label",{className:`flex items-center gap-2.5 border rounded px-4 py-3 cursor-pointer flex-1 min-w-[140px] transition-colors ${m==="archive"?"border-primary bg-primary/5":"border-border hover:bg-muted"}`,children:[e.jsx("input",{type:"radio",name:"avl-video-type",value:"archive",checked:m==="archive",onChange:()=>p("archive"),className:"accent-primary"}),e.jsx(Qi,{size:15,className:m==="archive"?"text-primary":"text-muted-foreground"}),e.jsxs("div",{children:[e.jsx("p",{className:"text-sm font-semibold leading-tight",children:"Archive"}),e.jsx("p",{className:"text-xs text-muted-foreground mt-0.5",children:"A past/ended live. Goes to Live Event Archives only."})]})]})]})]}),(m==="upcoming"||m==="live")&&e.jsxs("div",{className:"border border-blue-200 bg-blue-50 rounded p-4 flex flex-col gap-3",children:[e.jsxs("p",{className:"text-sm font-semibold flex items-center gap-2",children:[e.jsx(ys,{size:15,className:"text-blue-600"}),m==="upcoming"?"Scheduled start date & time":"Start date & time"]}),e.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-2 gap-3",children:[e.jsxs("div",{children:[e.jsxs("label",{htmlFor:"avl-start-date",className:"block text-xs font-semibold mb-1",children:["Date ",e.jsx("span",{className:"text-red-500",children:"*"})]}),e.jsx("input",{id:"avl-start-date",type:"date",value:x,onChange:ue=>b(ue.target.value),className:xs()})]}),e.jsxs("div",{children:[e.jsxs("label",{htmlFor:"avl-start-time",className:"block text-xs font-semibold mb-1",children:["Time ",e.jsx("span",{className:"text-muted-foreground font-normal",children:"(optional — your local time)"})]}),e.jsx("input",{id:"avl-start-time",type:"time",value:y,onChange:ue=>v(ue.target.value),className:xs()})]})]})]}),e.jsxs("div",{className:"flex flex-col gap-2",children:[e.jsxs("div",{children:[e.jsxs("label",{htmlFor:"avl-category",className:"block text-sm font-semibold mb-1",children:["Category ",e.jsx("span",{className:"text-red-500",children:"*"})]}),e.jsxs("select",{id:"avl-category",required:!0,value:z,onChange:ue=>T(ue.target.value),className:xs(),children:[e.jsx("option",{value:"",children:"— Select primary category —"}),Sn.map(ue=>e.jsx("optgroup",{label:ue.group,children:ue.items.map(be=>e.jsx("option",{value:be,children:be},be))},ue.group))]}),e.jsx("p",{className:"text-xs text-muted-foreground mt-1",children:"Primary category — used for homepage rows and Top Categories."})]}),e.jsxs("div",{children:[e.jsxs("label",{htmlFor:"avl-extra-cat-1",className:"block text-sm font-semibold mb-1",children:["Additional category ",e.jsx("span",{className:"text-muted-foreground font-normal",children:"(optional)"})]}),e.jsxs("select",{id:"avl-extra-cat-1",value:M,onChange:ue=>P(ue.target.value),className:xs(),children:[e.jsx("option",{value:"",children:"— None —"}),Sn.map(ue=>e.jsx("optgroup",{label:ue.group,children:ue.items.filter(be=>be!==z&&be!==E).map(be=>e.jsx("option",{value:be,children:be},be))},ue.group))]})]}),M&&e.jsxs("div",{children:[e.jsxs("label",{htmlFor:"avl-extra-cat-2",className:"block text-sm font-semibold mb-1",children:["Additional category 2 ",e.jsx("span",{className:"text-muted-foreground font-normal",children:"(optional)"})]}),e.jsxs("select",{id:"avl-extra-cat-2",value:E,onChange:ue=>U(ue.target.value),className:xs(),children:[e.jsx("option",{value:"",children:"— None —"}),Sn.map(ue=>e.jsx("optgroup",{label:ue.group,children:ue.items.filter(be=>be!==z&&be!==M).map(be=>e.jsx("option",{value:be,children:be},be))},ue.group))]})]})]}),e.jsxs("div",{children:[e.jsxs("label",{htmlFor:"avl-source",className:"block text-sm font-semibold mb-1",children:["Source ",e.jsx("span",{className:"text-red-500",children:"*"})," ",e.jsx("span",{className:"text-xs font-normal text-muted-foreground",children:"(required to publish)"})]}),e.jsxs("select",{id:"avl-source",value:w,onChange:ue=>{C(ue.target.value),ue.target.value!=="youtube"&&ue.target.value!=="rumble"&&le==="auto"&&ge("upload")},className:xs(),children:[e.jsx("option",{value:"",children:"— Select source —"}),bz.map(ue=>e.jsx("option",{value:ue.value,children:ue.label},ue.value))]})]}),e.jsxs("div",{children:[e.jsxs("label",{htmlFor:"avl-video",className:"block text-sm font-semibold mb-1",children:["Video URL or iframe embed ",e.jsx("span",{className:"text-red-500",children:"*"})," ",e.jsx("span",{className:"text-xs font-normal text-muted-foreground",children:"(required to publish)"})]}),e.jsx("textarea",{id:"avl-video",rows:3,value:A,onChange:ue=>S(ue.target.value),onBlur:ue=>S(Yi(ue.target.value)),placeholder:"Paste the YouTube embed <iframe …> or a Rumble/Vimeo/Box URL",className:`${xs()} font-mono resize-y`}),e.jsxs("div",{className:"mt-2 flex flex-col gap-1.5",children:[e.jsxs("div",{className:"flex items-start gap-2 text-xs text-muted-foreground",children:[e.jsx(Xf,{size:13,className:"mt-0.5 shrink-0 text-primary"}),e.jsxs("span",{children:[e.jsx("strong",{children:"YouTube:"})," use ",e.jsx("strong",{children:"Share → Embed"})," to get the"," ",e.jsx("code",{className:"bg-muted px-1 rounded",children:"<iframe>"})," code — do not paste the watch URL (",e.jsx("code",{className:"bg-muted px-1 rounded",children:"youtube.com/watch?v=…"}),"). Watch URLs often cause Error 153."]})]}),m==="live"&&e.jsxs("div",{className:"flex items-start gap-2 text-xs text-muted-foreground",children:[e.jsx(Ft,{size:13,className:"mt-0.5 shrink-0 text-primary"}),e.jsxs("span",{children:[e.jsx("strong",{children:"Livestream:"})," choose ",e.jsx("strong",{children:"Type: Live"})," while it is running. When it ends, an admin can change the type to ",e.jsx("strong",{children:"Archive"})," — it will move to Live Event Archives."]})]}),e.jsxs("div",{className:"flex items-start gap-2 text-xs text-muted-foreground",children:[e.jsx(Xf,{size:13,className:"mt-0.5 shrink-0 text-muted-foreground"}),e.jsxs("span",{children:["Use ",e.jsx("strong",{children:"Unpublish"})," only to remove the item from the public site entirely."]})]})]})]}),e.jsxs("div",{children:[e.jsx("label",{htmlFor:"avl-provided-by",className:"block text-sm font-semibold mb-1",children:"Provided by"}),e.jsx("input",{id:"avl-provided-by",type:"text",maxLength:200,value:q,onChange:ue=>H(ue.target.value),onBlur:ue=>H(Yi(ue.target.value)),placeholder:"e.g. WDAA, Raindancer Video, your name",className:xs()})]}),e.jsxs("div",{children:[e.jsx("label",{htmlFor:"avl-provider-link",className:"block text-sm font-semibold mb-1",children:"Provider link"}),e.jsx("input",{id:"avl-provider-link",type:"url",maxLength:500,value:J,onChange:ue=>B(ue.target.value),placeholder:"https://provider-website.com",className:xs()})]}),e.jsxs("div",{children:[e.jsxs("label",{htmlFor:"avl-more-info-url",className:"block text-sm font-semibold mb-1",children:["Event / website URL ",e.jsx("span",{className:"text-muted-foreground font-normal",children:"(optional)"})]}),e.jsx("input",{id:"avl-more-info-url",type:"url",maxLength:500,value:Y,onChange:ue=>$(ue.target.value),onBlur:ue=>$(Yi(ue.target.value)),placeholder:"https://event-website.com/info",className:xs()}),e.jsx("p",{className:"text-xs text-muted-foreground mt-1",children:"Link to the event page, show website, or more information."})]}),e.jsxs("div",{children:[e.jsxs("label",{htmlFor:"avl-country",className:"block text-sm font-semibold mb-1",children:["Country ",e.jsx("span",{className:"text-red-500",children:"*"})," ",e.jsx("span",{className:"text-xs font-normal text-muted-foreground",children:"(required to publish)"})]}),e.jsx("input",{id:"avl-country",type:"text",maxLength:100,value:D,onChange:ue=>W(ue.target.value),onBlur:ue=>W(Yi(ue.target.value)),placeholder:"e.g. United States",className:xs()})]}),e.jsxs("div",{children:[e.jsxs("label",{htmlFor:"avl-city",className:"block text-sm font-semibold mb-1",children:["City / Venue"," ",e.jsx("span",{className:"text-muted-foreground font-normal",children:"(optional)"})]}
640),e.jsx("input",{id:"avl-city",type:"text",maxLength:200,value:I,onChange:ue=>k(ue.target.value),onBlur:ue=>k(Yi(ue.target.value)),placeholder:"e.g. Lazy E Arena, Guthrie, Oklahoma",className:xs()})]}),e.jsxs("div",{children:[e.jsx("label",{htmlFor:"avl-description",className:"block text-sm font-semibold mb-1",children:"Short description"}),e.jsx("textarea",{id:"avl-description",rows:3,maxLength:1e3,value:K,onChange:ue=>L(ue.target.value),placeholder:"Brief description of the video or event…",className:`${xs()} resize-y`})]}),e.jsxs("div",{children:[e.jsxs("label",{className:"block text-sm font-semibold mb-0.5",children:["Thumbnail ",e.jsx("span",{className:"text-red-500",children:"*"})]}),e.jsx("p",{className:"text-xs text-muted-foreground mb-2",children:"Your thumbnail is your brand. Make it count."}),e.jsxs("div",{className:"flex gap-0 mb-3 border border-border rounded overflow-hidden w-fit text-xs font-semibold",children:[(w==="youtube"||w==="rumble")&&e.jsxs("button",{type:"button",onClick:()=>ge("auto"),className:`px-3 py-1.5 transition-colors ${le==="auto"?"bg-primary text-white":"bg-background hover:bg-muted"}`,children:["Auto (",w==="youtube"?"YouTube":"Rumble",")"]}),e.jsx("button",{type:"button",onClick:()=>ge("upload"),className:`px-3 py-1.5 transition-colors ${le==="upload"?"bg-primary text-white":"bg-background hover:bg-muted"}`,children:"Upload image"}),e.jsx("button",{type:"button",onClick:()=>ge("url"),className:`px-3 py-1.5 transition-colors ${le==="url"?"bg-primary text-white":"bg-background hover:bg-muted"}`,children:"Paste URL"})]}),le==="auto"&&w==="youtube"&&e.jsxs("p",{className:"text-xs text-muted-foreground",children:["The thumbnail will be pulled automatically from YouTube using the video ID.",_f(A.trim())?e.jsx("span",{className:"ml-1 text-green-700 font-medium",children:"✓ YouTube ID detected."}):e.jsx("span",{className:"ml-1 text-amber-600",children:" Enter the YouTube URL above first."})]}),le==="auto"&&w==="rumble"&&e.jsxs("p",{className:"text-xs text-muted-foreground",children:["The thumbnail will be pulled automatically from Rumble using the video ID.",Lf(A.trim())?e.jsx("span",{className:"ml-1 text-green-700 font-medium",children:"✓ Rumble ID detected."}):e.jsx("span",{className:"ml-1 text-amber-600",children:" Enter the Rumble URL or embed code above first."})]}),le==="upload"&&e.jsx("div",{children:st?e.jsxs("div",{className:"relative w-40",children:[e.jsx("img",{src:st,alt:"Thumbnail preview",className:"w-40 h-auto border border-border rounded"}),e.jsx("button",{type:"button",onClick:()=>{Me(null),We("")},className:"absolute -top-2 -right-2 bg-white border border-border rounded-full p-0.5 hover:bg-red-50 transition-colors",title:"Remove",children:e.jsx(Vt,{size:12,className:"text-red-600"})})]}):e.jsxs("label",{className:"flex items-center gap-2 cursor-pointer border border-dashed border-border px-4 py-3 rounded hover:bg-muted transition-colors w-fit",children:[e.jsx(ln,{size:15,className:"text-muted-foreground"}),e.jsx("span",{className:"text-sm text-muted-foreground",children:"Choose JPG or PNG (max 5 MB)"}),e.jsx("input",{type:"file",accept:"image/jpeg,image/png,image/webp",className:"sr-only",onChange:ue=>{var _t;const be=(_t=ue.target.files)==null?void 0:_t[0];be&&(Me(be),We(URL.createObjectURL(be)))}})]})}),le==="url"&&e.jsxs("div",{className:"relative",children:[e.jsx(Lc,{size:14,className:"absolute left-3 top-1/2 -translate-y-1/2 text-muted-foreground pointer-events-none"}),e.jsx("input",{id:"avl-thumb-url",type:"url",maxLength:1e3,value:se,onChange:ue=>X(ue.target.value),onBlur:ue=>X(Yi(ue.target.value)),placeholder:"https://img.youtube.com/vi/VIDEO_ID/hqdefault.jpg",className:`${xs()} pl-8`})]})]}),e.jsxs("div",{className:"border border-border rounded p-4 flex flex-col gap-4",children:[e.jsxs("label",{className:"flex items-start gap-3 cursor-pointer select-none",children:[e.jsx("input",{type:"checkbox",checked:ct,onChange:ue=>Ot(ue.target.checked),className:"mt-0.5 accent-primary shrink-0"}),e.jsxs("div",{children:[e.jsx("p",{className:"text-sm font-semibold",children:"Also list this as an Upcoming Event"}),e.jsx("p",{className:"text-xs text-muted-foreground mt-0.5",children:"Creates a card on the Events page. The button will link to this video page automatically."})]})]}),ct&&e.jsxs("div",{className:"flex flex-col gap-4 pt-1 border-t border-border",children:[e.jsxs("div",{className:"flex items-center gap-2 text-xs text-muted-foreground",children:[e.jsx(ys,{size:13,className:"text-primary shrink-0"}),e.jsx("span",{children:"Event details — these appear on the public Events page."})]}),e.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-2 gap-4",children:[e.jsxs("div",{children:[e.jsxs("label",{className:"block text-sm font-semibold mb-1",children:["Event start date ",e.jsx("span",{className:"text-red-500",children:"*"})]}),e.jsx("input",{type:"date",required:ct,value:Et,onChange:ue=>Zt(ue.target.value),className:xs()})]}),e.jsxs("div",{children:[e.jsxs("label",{className:"block text-sm font-semibold mb-1",children:["Event end date ",e.jsx("span",{className:"text-muted-foreground font-normal",children:"(optional)"})]}),e.jsx("input",{type:"date",value:as,onChange:ue=>Jt(ue.target.value),className:xs()})]})]}),e.jsxs("div",{children:[e.jsxs("label",{className:"block text-sm font-semibold mb-1",children:[e.jsx(ul,{size:12,className:"inline mr-1 text-primary"}),"City / venue"]}),e.jsx("input",{type:"text",maxLength:200,value:vs,onChange:ue=>js(ue.target.value),placeholder:"e.g. Lazy E Arena, Guthrie, Oklahoma",className:xs()}),e.jsx("p",{className:"text-xs text-muted-foreground mt-1",children:"Leave blank to use the City / Venue field above."})]}),e.jsxs("div",{children:[e.jsx("label",{className:"block text-sm font-semibold mb-1",children:"Country"}),e.jsx("input",{type:"text",maxLength:100,value:Ws,onChange:ue=>Mt(ue.target.value),placeholder:"e.g. USA",className:xs()}),e.jsx("p",{className:"text-xs text-muted-foreground mt-1",children:"Leave blank to use the Country field above."})]}),e.jsxs("div",{children:[e.jsx("label",{className:"block text-sm font-semibold mb-1",children:"Event website (optional)"}),e.jsx("input",{type:"text",maxLength:500,value:jt,onChange:ue=>ps(ue.target.value),placeholder:"https://eventwebsite.com",className:xs()})]}),e.jsxs("div",{children:[e.jsx("label",{className:"block text-sm font-semibold mb-1",children:"Provided by (optional)"}
640),e.jsx("input",{type:"text",maxLength:200,value:Wt,onChange:ue=>ws(ue.target.value),placeholder:"e.g. RainDancer Video",className:xs()}),e.jsx("p",{className:"text-xs text-muted-foreground mt-1",children:"Leave blank to use the Provided by field above."})]}),e.jsxs("div",{children:[e.jsx("label",{className:"block text-sm font-semibold mb-1",children:"Event logo URL (optional)"}),e.jsx("input",{type:"text",maxLength:1e3,value:os,onChange:ue=>qt(ue.target.value),placeholder:"https://example.com/logo.png",className:xs()})]}),e.jsxs("div",{children:[e.jsx("label",{className:"block text-sm font-semibold mb-1",children:"Button link (optional)"}),e.jsx("input",{type:"text",maxLength:500,value:je,onChange:ue=>gt(ue.target.value),placeholder:"Leave blank — defaults to this video page",className:xs()}),e.jsx("p",{className:"text-xs text-muted-foreground mt-1",children:`Leave blank and the event card button will link directly to this video page. If you leave this blank and the video page isn't ready yet, the card will show "Link active when the show starts."`})]})]})]}),e.jsxs("div",{className:"border border-border p-4 flex flex-col gap-3",children:[e.jsxs("p",{className:"text-sm font-semibold",children:["Before publishing, please confirm all of the following:"," ",e.jsx("span",{className:"text-red-500",children:"*"})," ",e.jsx("span",{className:"text-xs font-normal text-muted-foreground",children:"(required to publish)"})]}),e.jsxs("label",{className:"flex items-start gap-3 cursor-pointer select-none",children:[e.jsx("input",{type:"checkbox",checked:me,onChange:ue=>Le(ue.target.checked),className:"mt-0.5 accent-primary shrink-0"}),e.jsxs("span",{className:"text-sm",children:["This video is ",e.jsx("strong",{children:"horse-related"})," content."]})]}),e.jsxs("label",{className:"flex items-start gap-3 cursor-pointer select-none",children:[e.jsx("input",{type:"checkbox",checked:Ie,onChange:ue=>ve(ue.target.checked),className:"mt-0.5 accent-primary shrink-0"}),e.jsxs("span",{className:"text-sm",children:["I have the ",e.jsx("strong",{children:"right to share this embed"})," (I own it, or the owner has made it publicly embeddable)."]})]}),e.jsxs("label",{className:"flex items-start gap-3 cursor-pointer select-none",children:[e.jsx("input",{type:"checkbox",checked:ze,onChange:ue=>Ue(ue.target.checked),className:"mt-0.5 accent-primary shrink-0"}),e.jsxs("span",{className:"text-sm",children:["This content is ",e.jsx("strong",{children:"not illegal or adult"})," in nature."]})]})]}),e.jsxs("div",{className:"pt-2 flex flex-wrap gap-3 items-center",children:[e.jsx("button",{type:"submit",disabled:et==="submitting"||et==="saving-draft",className:"bg-primary text-primary-foreground font-bold px-8 py-3 hover:bg-primary/90 transition-colors disabled:opacity-60 disabled:cursor-not-allowed",children:e.jsx(_,{devId:"e6cfc0",guard:{file:"src/pages/add-video-live.tsx",tagName:"button",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:f6dcc9538a36af93a2ff6b4b40a03e68f43d692e733e2cb5ee36eea8c3e6529e"},children:Ye?"Uploading thumbnail…":et==="submitting"?"Publishing…":o?"Publish draft":"Publish Video / Live"})}),e.jsx("button",{type:"button",onClick:ls,disabled:et==="submitting"||et==="saving-draft",className:"border border-border bg-background font-semibold px-6 py-3 hover:bg-muted transition-colors disabled:opacity-60 disabled:cursor-not-allowed text-sm",children:e.jsx(_,{devId:"e6cfc1",guard:{file:"src/pages/add-video-live.tsx",tagName:"button",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:c911daa3ccab1ba3fa3189ee2559ddc185338c626778a08a086d5751f8b6d8e5"},children:et==="saving-draft"?"Saving draft…":"Save draft"})}),e.jsx("p",{className:"text-xs text-muted-foreground w-full",children:"Save draft stores your work without publishing. URL / embed is not required for a draft."})]})]})]})]})}function pa(){return"w-full border border-border px-3 py-2 text-sm bg-background focus:outline-none focus:ring-2 focus:ring-primary"}function gr(t){return t.trim()}function rw(t){var a,r;try{const o=new URL(t);return o.hostname==="youtu.be"?o.pathname.slice(1).split("?")[0]:o.pathname.startsWith("/live/")?((a=o.pathname.split("/live/")[1])==null?void 0:a.split("?")[0])??null:o.pathname.startsWith("/embed/")?((r=o.pathname.split("/embed/")[1])==null?void 0:r.split("?")[0])??null:o.searchParams.get("v")}catch{return null}}function iw(t){const a=t.match(/rumble\.com\/embed\/([vV][A-Za-z0-9]+)/)??t.match(/rumble\.com\/([vV][A-Za-z0-9]+)/);return(a==null?void 0:a[1])??null}const vz=[{value:"youtube",label:"YouTube"},{value:"rumble",label:"Rumble"},{value:"vimeo",label:"Vimeo"},{value:"box",label:"Box"},{value:"other",label:"Other"}];function jz(){const{isAuthenticated:t,isPending:a}=Us(),[r,o]=g.useState(""),[l,d]=g.useState(""),[u,m]=g.useState(""),[p,x]=g.useState(""),[b,y]=g.useState(""),[v,w]=g.useState(""),[C,A]=g.useState(""),[S,z]=g.useState(""),[T,M]=g.useState(""),[P,E]=g.useState("upload"),[U,q]=g.useState(null),[H,J]=g.useState(""),[B,Y]=g.useState(""),[$,D]=g.useState(!1),[W,I]=g.useState(!1),[k,K]=g.useState(""),[L,se]=g.useState(""),[X,le]=g.useState(""),[ge,Se]=g.useState(""),[Me,st]=g.useState(""),[We,Ye]=g.useState(""),[te,me]=g.useState("auto"),[Le,Ie]=g.useState(null),[ve,ze]=g.useState(""),[Ue,ct]=g.useState(""),[Ot,Et]=g.useState(!1),[Zt,as]=g.useState(!1),[Jt,vs]=g.useState(!1),[js,Ws]=g.useState(!1),[Mt,jt]=g.useState("idle"),[ps,Wt]=g.useState(""),[ws,os]=g.useState("");
640if(a)return null;if(!t)return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Add Event – Total Horse Channel"}),e.jsx("meta",{name:"robots",content:"noindex"})]}),e.jsxs("main",{className:"max-w-[680px] mx-auto px-4 py-16 text-center",children:[e.jsx(ys,{size:48,className:"mx-auto mb-4 text-primary"}),e.jsx("h1",{className:"text-2xl font-bold mb-3",children:"Add an Event"}),e.jsx("p",{className:"text-muted-foreground mb-6",children:"You must be logged in to submit an event."}),e.jsx(O,{to:"/login",className:"inline-block bg-primary text-primary-foreground font-semibold px-6 py-3 hover:bg-primary/90 transition-colors",children:"Log in"})]})]});if(Mt==="not-approved")return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Add Event – Total Horse Channel"}),e.jsx("meta",{name:"robots",content:"noindex"})]}),e.jsxs("main",{className:"max-w-[680px] mx-auto px-4 py-16 text-center",children:[e.jsx(so,{size:48,className:"mx-auto mb-4 text-muted-foreground"}),e.jsx("h1",{className:"text-2xl font-bold mb-3",children:"Account not yet approved"}),e.jsx("p",{className:"text-muted-foreground mb-4",children:"Your account needs to be approved before you can submit events."}),e.jsx("a",{href:"mailto:[email protected]",className:"inline-block bg-primary text-primary-foreground font-semibold px-6 py-3 hover:bg-primary/90 transition-colors",children:"Contact us"})]})]});if(Mt==="success")return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Event Submitted – Total Horse Channel"}),e.jsx("meta",{name:"robots",content:"noindex"})]}),e.jsxs("main",{className:"max-w-[680px] mx-auto px-4 py-16 text-center",children:[e.jsx(kn,{size:52,className:"mx-auto mb-4 text-green-600"}),e.jsx("h1",{className:"text-2xl font-bold mb-3",children:"Event published!"}),e.jsxs("p",{className:"text-muted-foreground mb-6",children:["Your event is now live on the ",e.jsx(O,{to:"/events",className:"text-accent hover:underline",children:"Events page"}),"."]}),e.jsxs("div",{className:"flex flex-wrap justify-center gap-3",children:[ws&&e.jsx(O,{to:`/live/${ws}`,className:"bg-primary text-primary-foreground font-semibold px-5 py-2 hover:bg-primary/90 transition-colors",children:"View video page"}),e.jsx(O,{to:"/events",className:"border border-border px-5 py-2 font-semibold hover:bg-muted transition-colors",children:"View Events page"}),e.jsx("button",{onClick:()=>{o(""),d(""),m(""),x(""),y(""),w(""),A(""),z(""),M(""),q(null),J(""),Y(""),E("upload"),I(!1),K(""),se(""),le(""),Se(""),st(""),Ye(""),Ie(null),ze(""),ct(""),me("auto"),as(!1),vs(!1),Ws(!1),jt("idle"),os("")},className:"border border-border px-5 py-2 font-semibold hover:bg-muted transition-colors",children:"Add another event"})]})]})]});async function qt(je){if(je.preventDefault(),Wt(""),!r.trim()){Wt("Title is required."),jt("error");return}if(!l.trim()){Wt("Start date is required."),jt("error");return}if(!p.trim()){Wt("City / venue is required."),jt("error");return}if(W){if(!X.trim()){Wt("Add a video URL or embed for the linked video."),jt("error");return}if(!L){Wt("Please select a video source."),jt("error");return}if(!k){Wt("Please select a video type (Upcoming, Live, Video, or Archive)."),jt("error");return}if(!ge.trim()){Wt("Please select a category for the video."),jt("error");return}if(!Zt||!Jt||!js){Wt("Please check all three confirmation boxes for the linked video."),jt("error");return}}jt("submitting");try{let gt=B.trim()||void 0;if(P==="upload"&&U){D(!0);const ft=new FormData;ft.append("file",U);const Yt=await fetch("/api/member/events/upload-logo",{method:"POST",body:ft,credentials:"include"}),ls=await Yt.json();if(D(!1),!Yt.ok||!ls.url){Wt(ls.error??"Logo upload failed."),jt("error");return}gt=ls.url}let et;if(W){if(te==="auto"&&L==="youtube"){const ft=rw(X.trim());ft&&(et=`https://img.youtube.com/vi/${ft}/hqdefault.jpg`)}else if(te==="auto"&&L==="rumble"){const ft=iw(X.trim());ft&&(et=`https://sp.rmbl.ws/s8/1/${ft}.jpg`)}else if(te==="url")et=Ue.trim()||void 0;else if(te==="upload"&&Le){Et(!0);const ft=new FormData;ft.append("file",Le);
640const Yt=await fetch("/api/live-events/upload-thumbnail",{method:"POST",body:ft,credentials:"include"}),ls=await Yt.json();if(Et(!1),!Yt.ok||!ls.url){Wt(ls.error??"Thumbnail upload failed."),jt("error");return}et=ls.url}}const Xe={title:r,startDate:l,endDate:u,cityVenue:p,country:b,website:v,description:C,note:S,logoUrl:gt,buttonLink:T,createVideo:W,...W?{videoSource:L,videoInput:X,videoType:k,videoThumbnailUrl:et,videoProvidedBy:Me,videoProviderLink:We,videoCountry:b,videoCity:p,videoCategory:ge,isHorseRelated:Zt,hasRights:Jt,isAppropriate:js}:{}},Ae=await fetch("/api/member/submit-event",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(Xe),credentials:"include"}),De=await Ae.json();if(Ae.status===403&&De.notApproved){jt("not-approved");return}if(!Ae.ok){Wt(De.error??"Submission failed. Please try again."),jt("error");return}os(De.videoSlug??""),jt("success")}catch{Wt("Network error. Please try again."),jt("error")}}return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Add Event – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Submit a horse industry event to the Total Horse Channel events calendar."}),e.jsx("link",{rel:"canonical",href:"https://totalhorsechannel.com/add-event"}),e.jsx("meta",{name:"robots",content:"noindex"})]}),e.jsxs("main",{className:"max-w-[760px] mx-auto px-4 py-8",children:[e.jsxs("div",{className:"bg-primary text-primary-foreground px-5 py-4 mb-6 flex items-center gap-3",children:[e.jsx(ys,{size:22}),e.jsx("h1",{className:"text-xl font-bold",children:"Add an Event"})]}),e.jsx("p",{className:"text-muted-foreground mb-6 text-sm leading-relaxed",children:"Submit a horse industry event to the Total Horse Channel events calendar. It will publish immediately. You can also link a video or livestream to the event."}),Mt==="error"&&e.jsxs("div",{className:"flex items-start gap-2 bg-red-50 border border-red-200 text-red-700 px-4 py-3 mb-5 text-sm",children:[e.jsx(Xi,{size:16,className:"mt-0.5 shrink-0"}),e.jsx("span",{children:e.jsx(_,{devId:"4d5dca",guard:{file:"src/pages/add-event.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:1c0238d2a5401216440d3a40ef09cf8a641cbbc703bbdb0cfe4af2625e4564c6"},children:ps})})]}),e.jsxs("form",{onSubmit:qt,noValidate:!0,className:"flex flex-col gap-5",children:[e.jsxs("div",{children:[e.jsxs("label",{htmlFor:"ae-title",className:"block text-sm font-semibold mb-1",children:["Event title ",e.jsx("span",{className:"text-red-500",children:"*"})]}),e.jsx("input",{id:"ae-title",type:"text",required:!0,maxLength:200,value:r,onChange:je=>o(je.target.value),onBlur:je=>o(gr(je.target.value)),placeholder:"e.g. 2026 WDAA World Championship Show",className:pa()})]}),e.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-2 gap-4",children:[e.jsxs("div",{children:[e.jsxs("label",{htmlFor:"ae-start",className:"block text-sm font-semibold mb-1",children:["Start date ",e.jsx("span",{className:"text-red-500",children:"*"})]}),e.jsx("input",{id:"ae-start",type:"date",required:!0,value:l,onChange:je=>d(je.target.value),className:pa()})]}),e.jsxs("div",{children:[e.jsxs("label",{htmlFor:"ae-end",className:"block text-sm font-semibold mb-1",children:["End date ",e.jsx("span",{className:"text-muted-foreground font-normal",children:"(optional)"})]}),e.jsx("input",{id:"ae-end",type:"date",value:u,onChange:je=>m(je.target.value),className:pa()})]})]}),e.jsxs("div",{children:[e.jsxs("label",{htmlFor:"ae-city",className:"block text-sm font-semibold mb-1",children:[e.jsx(ul,{size:13,className:"inline mr-1 text-primary"}),"City / venue ",e.jsx("span",{className:"text-red-500",children:"*"})]}),e.jsx("input",{id:"ae-city",type:"text",required:!0,maxLength:200,value:p,onChange:je=>x(je.target.value),onBlur:je=>x(gr(je.target.value)),placeholder:"e.g. Lazy E Arena, Guthrie, Oklahoma",className:pa()})]}),e.jsxs("div",{children:[e.jsx("label",{htmlFor:"ae-country",className:"block text-sm font-semibold mb-1",children:"Country"}),e.jsx("input",{id:"ae-country",type:"text",maxLength:100,value:b,onChange:je=>y(je.target.value),onBlur:je=>y(gr(je.target.value)),placeholder:"e.g. USA",className:pa()})]}),e.jsxs("div",{children:[e.jsxs("label",{htmlFor:"ae-website",className:"block text-sm font-semibold mb-1",children:["Event website ",e.jsx("span",{className:"text-muted-foreground font-normal",children:"(optional)"})]}),e.jsx("input",{id:"ae-website",type:"url",maxLength:500,value:v,onCh
640ange:je=>w(je.target.value),onBlur:je=>w(gr(je.target.value)),placeholder:"https://eventwebsite.com",className:pa()})]}),e.jsxs("div",{children:[e.jsxs("label",{htmlFor:"ae-description",className:"block text-sm font-semibold mb-1",children:["Description ",e.jsx("span",{className:"text-muted-foreground font-normal",children:"(optional)"})]}),e.jsx("textarea",{id:"ae-description",rows:3,maxLength:1e3,value:C,onChange:je=>A(je.target.value),placeholder:"Brief description of the event…",className:`${pa()} resize-y`})]}),e.jsxs("div",{children:[e.jsxs("label",{htmlFor:"ae-note",className:"block text-sm font-semibold mb-1",children:["Provided by ",e.jsx("span",{className:"text-muted-foreground font-normal",children:"(optional)"})]}),e.jsx("input",{id:"ae-note",type:"text",maxLength:200,value:S,onChange:je=>z(je.target.value),onBlur:je=>z(gr(je.target.value)),placeholder:"e.g. WDAA, RainDancer Video",className:pa()})]}),e.jsxs("div",{children:[e.jsxs("label",{htmlFor:"ae-button-link",className:"block text-sm font-semibold mb-1",children:["Button link ",e.jsx("span",{className:"text-muted-foreground font-normal",children:"(optional)"})]}),e.jsx("input",{id:"ae-button-link",type:"url",maxLength:500,value:T,onChange:je=>M(je.target.value),onBlur:je=>M(gr(je.target.value)),placeholder:"Leave blank — defaults to the linked video page (if any)",className:pa()}),e.jsx("p",{className:"text-xs text-muted-foreground mt-1",children:"If you link a video below, the button will point to that video page automatically. Override here if needed."})]}),e.jsxs("div",{children:[e.jsxs("label",{className:"block text-sm font-semibold mb-0.5",children:["Event logo / image ",e.jsx("span",{className:"text-muted-foreground font-normal",children:"(optional)"})]}),e.jsx("p",{className:"text-xs text-muted-foreground mb-2",children:"Shown on the event card. Upload a file or paste a URL."}),e.jsxs("div",{className:"flex gap-0 mb-3 border border-border rounded overflow-hidden w-fit text-xs font-semibold",children:[e.jsx("button",{type:"button",onClick:()=>E("upload"),className:`px-3 py-1.5 transition-colors ${P==="upload"?"bg-primary text-white":"bg-background hover:bg-muted"}`,children:"Upload image"}),e.jsx("button",{type:"button",onClick:()=>E("url"),className:`px-3 py-1.5 transition-colors ${P==="url"?"bg-primary text-white":"bg-background hover:bg-muted"}`,children:"Paste URL"})]}),P==="upload"&&(H?e.jsxs("div",{className:"relative w-32",children:[e.jsx("img",{src:H,alt:"Logo preview",className:"w-32 h-auto border border-border rounded"}),e.jsx("button",{type:"button",onClick:()=>{q(null),J("")},className:"absolute -top-2 -right-2 bg-white border border-border rounded-full p-0.5 hover:bg-red-50 transition-colors",title:"Remove",children:e.jsx(Vt,{size:12,className:"text-red-600"})})]}):e.jsxs("label",{className:"flex items-center gap-2 cursor-pointer border border-dashed border-border px-4 py-3 rounded hover:bg-muted transition-colors w-fit",children:[e.jsx(ln,{size:15,className:"text-muted-foreground"}),e.jsx("span",{className:"text-sm text-muted-foreground",children:"Choose JPG, PNG, or WebP (max 5 MB)"}),e.jsx("input",{type:"file",accept:"image/jpeg,image/png,image/webp,image/avif",className:"sr-only",onChange:je=>{var et;const gt=(et=je.target.files)==null?void 0:et[0];gt&&(q(gt),J(URL.createObjectURL(gt)))}})]})),P==="url"&&e.jsxs("div",{className:"relative",children:[e.jsx(Lc,{size:14,className:"absolute left-3 top-1/2 -translate-y-1/2 text-muted-foreground pointer-events-none"}),e.jsx("input",{type:"url",maxLength:1e3,value:B,onChange:je=>Y(je.target.value),onBlur:je=>Y(gr(je.target.value)),placeholder:"https://example.com/logo.png",className:`${pa()} pl-8`})]})]}),e.jsxs("div",{className:"border border-border rounded p-4 flex flex-col gap-4",children:[e.jsxs("label",{className:"flex items-start gap-3 cursor-pointer select-none",children:[e.jsx("input",{type:"checkbox",checked:W,onChange:je=>I(je.target.checked),className:"mt-0.5 accent-primary shrink-0"}),e.jsxs("div",{children:[e.jsxs("p",{className:"text-sm font-semibold flex items-center gap-1.5",children:[e.jsx(Vs,{size:14,className:"text-primary"})," Also publish a linked video / live"]}),e.jsx("p",{className:"text-xs text-muted-foreground mt-0.5",children:"Creates a video page on Watch Live Events. The event card button will link to it automatically."})]})]}),W&&e.jsxs("div",{className:"flex flex-col gap-4 pt-1 border-t border-border",children:[e.jsxs("div",{children:[e.jsxs("label",{className:"block text-sm font-semibold mb-2",children:["Type ",e.jsx("span",{className:"text-red-500",children:"*"})]}),e.jsx("div",{className:"flex gap-3 flex-wrap",children:[{value:"upcoming",label:"Upcoming",icon:e.jsx(Ms,{size:14}),desc:"Scheduled future event"},{value:"live",label:"Live",icon:e.jsx(Ft,{size:14}),desc:"Currently streaming"},{value:"video",label:"Video",icon:e.jsx(Yn,{size:14}),desc:"Recorded video"},{value:"archive",label:"Archive",icon:e.jsx(Qi,{size:14}),desc:"Past/ended live"}].map(({value:je,label:gt,icon:et,desc:Xe})=>e.jsxs("label",{className:`flex items-center gap-2 border rounded px-3 py-2.5 cursor-pointer flex-1 min-w-[120px] transition-colors ${k===je?"border-primary bg-primary/5":"border-border hover:bg-muted"}`,children:[e.jsx("input",{type:"radio",name:"ae-video-type",value:je,checked:k===je,onChange:()=>K(je),className:"accent-primary"}),e.jsx("span",{className:k===je?"text-primary":"text-muted-foreground",children:et}),e.jsxs("div",{children:[e.jsx("p",{className:"text-xs font-semibold leading-tight",children:gt}),e.jsx("p",{className:"text-xs text-muted-foreground",children:Xe})]})]},je))})]}),e.jsxs("div",{children:[e.jsxs("label",{className:"block text-sm font-semibold mb-1",children:["Source ",e.jsx("span",{className:"text-red-500",children:"*"})]}),e.jsxs("select",{value:L,onChange:je=>{se(je.target.value),!["youtube","rumble"].includes(je.target.value)&&te==="auto"&&me("upload")},className:pa(),children:[e.jsx("option",{value:"",children:"— Select source —"}),vz.map(je=>e.jsx("option",{value:je.value,children:je.label},je.value))]})]}),e.jsxs("div",{children:[e.jsxs("label",{className:"block text-sm font-semibold mb-1",children:["Video URL or iframe embed ",e.jsx("span",{className:"text-red-500",children:"*"})]}),e.jsx("textarea",{rows:3,value:X,onChange:je=>le(je.target.value),onBlur:je=>le(gr(je.target.value)),placeholder:"Paste the YouTube <iframe> embed or a Rumble/Vimeo/Box URL",className:`${pa()} font-mono resize-y`}),e.jsxs("div",{className:"mt-1.5 flex items-start gap-2 text-xs text-muted-foreground",children:[e.jsx(Xf,{size:13,className:"mt-0.5 shrink-0 text-primary"}),e.jsxs("span",{children:[e.jsx("strong",{children:"YouTube:"})," use Share → Embed to get the ",e.jsx("code",{className:"bg-muted px-1 rounded",children:"<iframe>"})," code."]})]})]}),e.jsxs("div",{children:[e.jsxs("label",{className:"block text-sm font-semibold mb-1",children:["Category ",e.jsx("span",{className:"text-red-500",children:"*"})]}),e.jsxs("select",{value:ge,onChange:je=>Se(je.target.value),className:pa(),children:[e.jsx("option",{value:"",children:"— Select category —"}),Sn.map(je=>e.jsx("optgroup",{label:je.group,children:je.items.map(gt=>e.jsx("option",{value:gt,children:gt},gt))},je.group))]})]}),e.jsxs("div",{children:[e.jsxs("label",{className:"block text-sm font-semibold mb-1",children:["Provided by ",e.jsx("span",{className:"text-muted-foreground font-normal",children:"(optional)"})]}),e.jsx("input",{type:"text",maxLength:200,value:Me,onChange:je=>st(je.target.value),placeholder:"e.g. RainDancer Video",className:pa()})]}),e.jsxs("div",{children:[e.jsxs("label",{className:"block text-sm font-semibold mb-1",children:["Provider link ",e.jsx("span",{className:"text-muted-foreground font-normal",children:"(optional)"})]}),e.jsx("input",{type:"url",maxLength:500,value:We,onChange:je=>Ye(je.target.value),placeholder:"https://provider-website.com",className:pa()})]}),e.jsxs("div",{children:[e.jsx("label",{className:"block text-sm font-semibold mb-0.5",children:"Thumbnail"}),e.jsx("p",{className:"text-xs text-muted-foreground mb-2",children:"Shown on the video card."}),e.jsxs("div",{className:"flex gap-0 mb-3 border border-border rounded overflow-hidden w-fit text-xs font-semibold",children:[(L==="youtube"||L==="rumble")&&e.jsxs("button",{type:"button",onClick:()=>me("auto"),className:`px-3 py-1.5 transition-colors ${te==="auto"?"bg-primary text-white":"bg-background hover:bg-muted"}`,children:["Auto (",L==="youtube"?"YouTube":"Rumble",")"]}),e.jsx("button",{type:"button",onClick:()=>me("upload"),className:`px-3 py-1.5 transition-colors ${te==="upload"?"bg-primary text-white":"bg-background hover:bg-muted"}`,children:"Upload image"}),e.jsx("button",{type:"button",onClick:()=>me("url"),className:`px-3 py-1.5 transition-colors ${te==="url"?"bg-primary text-white":"bg-background hover:bg-muted"}`,children:"Paste URL"})]}),te==="auto"&&L==="youtube"&&e.jsxs("p",{className:"text-xs text-muted-foreground",children:["Pulled from YouTube automatically.",rw(X.trim())?e.jsx("span",{className:"ml-1 text-green-700 font-medium",children:"✓ ID detected."}):e.jsx("span",{className:"ml-1 text-amber-600",children:" Enter the YouTube URL above first."})]}),te==="auto"&&L==="rumble"&&e.jsxs("p",{className:"text-xs text-muted-foreground",children:["Pulled from Rumble automatically.",iw(X.trim())?e.jsx("span",{className:"ml-1 text-green-700 font-medium",children:"✓ ID detected."}):e.jsx("span",{className:"ml-1 text-amber-600",children:" Enter the Rumble URL above first."})]}),te==="upload"&&(ve?e.jsxs("div",{className:"relative w-40",children:[e.jsx("img",{src:ve,alt:"Thumbn
640ail preview",className:"w-40 h-auto border border-border rounded"}),e.jsx("button",{type:"button",onClick:()=>{Ie(null),ze("")},className:"absolute -top-2 -right-2 bg-white border border-border rounded-full p-0.5 hover:bg-red-50 transition-colors",title:"Remove",children:e.jsx(Vt,{size:12,className:"text-red-600"})})]}):e.jsxs("label",{className:"flex items-center gap-2 cursor-pointer border border-dashed border-border px-4 py-3 rounded hover:bg-muted transition-colors w-fit",children:[e.jsx(ln,{size:15,className:"text-muted-foreground"}),e.jsx("span",{className:"text-sm text-muted-foreground",children:"Choose JPG or PNG (max 5 MB)"}),e.jsx("input",{type:"file",accept:"image/jpeg,image/png,image/webp",className:"sr-only",onChange:je=>{var et;const gt=(et=je.target.files)==null?void 0:et[0];gt&&(Ie(gt),ze(URL.createObjectURL(gt)))}})]})),te==="url"&&e.jsxs("div",{className:"relative",children:[e.jsx(Lc,{size:14,className:"absolute left-3 top-1/2 -translate-y-1/2 text-muted-foreground pointer-events-none"}),e.jsx("input",{type:"url",maxLength:1e3,value:Ue,onChange:je=>ct(je.target.value),onBlur:je=>ct(gr(je.target.value)),placeholder:"https://img.youtube.com/vi/VIDEO_ID/hqdefault.jpg",className:`${pa()} pl-8`})]})]}),e.jsxs("div",{className:"border border-border p-4 flex flex-col gap-3",children:[e.jsxs("p",{className:"text-sm font-semibold",children:["Confirm for the linked video: ",e.jsx("span",{className:"text-red-500",children:"*"})]}),e.jsxs("label",{className:"flex items-start gap-3 cursor-pointer select-none",children:[e.jsx("input",{type:"checkbox",checked:Zt,onChange:je=>as(je.target.checked),className:"mt-0.5 accent-primary shrink-0"}),e.jsxs("span",{className:"text-sm",children:["This video is ",e.jsx("strong",{children:"horse-related"})," content."]})]}),e.jsxs("label",{className:"flex items-start gap-3 cursor-pointer select-none",children:[e.jsx("input",{type:"checkbox",checked:Jt,onChange:je=>vs(je.target.checked),className:"mt-0.5 accent-primary shrink-0"}),e.jsxs("span",{className:"text-sm",children:["I have the ",e.jsx("strong",{children:"right to share this embed"}),"."]})]}),e.jsxs("label",{className:"flex items-start gap-3 cursor-pointer select-none",children:[e.jsx("input",{type:"checkbox",checked:js,onChange:je=>Ws(je.target.checked),className:"mt-0.5 accent-primary shrink-0"}),e.jsxs("span",{className:"text-sm",children:["This content is ",e.jsx("strong",{children:"not illegal or adult"})," in nature."]})]})]})]})]}),e.jsxs("div",{className:"pt-2 flex flex-wrap gap-3 items-center",children:[e.jsx("button",{type:"submit",disabled:Mt==="submitting",className:"bg-primary text-primary-foreground font-bold px-8 py-3 hover:bg-primary/90 transition-colors disabled:opacity-60 disabled:cursor-not-allowed",children:e.jsx(_,{devId:"4c9489",guard:{file:"src/pages/add-event.tsx",tagName:"button",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:390703184608a0c29f6014b9525914906022496190b7a79cf243cb765371d419"},children:$||Ot?"Uploading…":Mt==="submitting"?"Publishing…":"Publish Event"})}),e.jsx(O,{to:"/events",className:"border border-border px-5 py-3 font-semibold hover:bg-muted transition-colors text-sm",children:"Cancel"})]})]})]})]})}function wz(){const{user:t,isPending:a}=Us(),[r,o]=g.useState("[email protected]"),[l,d]=g.useState(""),[u,m]=g.useState(!1),[p,x]=g.useState(""),[b,y]=g.useState("");if(a)return null;if(!t||!t.isAdmin)return e.jsx(yi,{to:"/",replace:!0});async function v(w){w.preventDefault(),x(""),y(""),m(!0);try{const C=await fetch("/api/admin/reset-password",{method:"POST",headers:{"Content-Type":"application/json"},credentials:"include",body:JSON.stringify({email:r,newPassword:l})}),A=await C.json();C.ok?x(A.message||"Password reset successfully."):y(A.error||"Failed")}catch{y("Network error.")}finally{m(!1)}}return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Admin: Reset Password – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Admin password reset tool for Total Horse Channel."}),e.jsx("link",{rel:"canonical",href:"https://totalhorsechannel.com/admin/reset-password"}),e.jsx("meta",{name:"robots",content:"noindex"})]}),e.jsx("h1",{className:"sr-only",children:"Admin Reset Password"}),e.jsx("main",{children:e.jsx("div",{className:"max-w-md mx-auto px-4 py-16",children:e.jsxs("div",{className:"border border-border rounded-sm bg-card overflow-hidden",children:[e.jsx("div",{className:"bg-primary px-5 py-3",children:e.jsx("span",{className:"text-primary-foreground font-bold text-sm",children:"Admin — Reset Account Password"})}),e.jsxs("form",{onSubmit:v,className:"px-6 py-6 flex flex-col gap-4",children:[e.jsxs("div",{className:"flex flex-col gap-1",children:[e.jsx("label",{className:"text-xs font-medium text-muted-foreground",htmlFor:"email",children:"Email"}),e.jsx("input",{id:"email",type:"email",value:r,onChange:w=>o(w.target.value),className:"border border-border rounded-sm px-3 py-2 text-sm bg-background focus:outline-none focus:ring-1 focus:ring-primary",required:!0})]}),e.jsxs("div",{className:"flex flex-col gap-1",children:[e.jsx("label",{className:"text-xs font-medium text-muted-foreground",htmlFor:"newpw",children:"New Password"}
640),e.jsx("input",{id:"newpw",type:"text",value:l,onChange:w=>d(w.target.value),className:"border border-border rounded-sm px-3 py-2 text-sm bg-background focus:outline-none focus:ring-1 focus:ring-primary",required:!0,minLength:8})]}),b&&e.jsx("p",{className:"text-sm text-destructive",children:e.jsx(_,{devId:"b7d241",guard:{file:"src/pages/admin-reset-password.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:ca00fccfb408989eddc401062c4d1219a6aceb6b9b55412357f1790862e8f178"},children:b})}),p&&e.jsx("p",{className:"text-sm text-green-600 font-medium",children:e.jsx(_,{devId:"b7d242",guard:{file:"src/pages/admin-reset-password.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:f6a214f7a5fcda0c2cee9660b7fc29f5649e3c68aad48e20e950137c98913a68"},children:p})}),e.jsx("button",{type:"submit",disabled:u,className:"bg-primary text-primary-foreground font-semibold text-sm px-4 py-2 rounded-sm hover:opacity-90 disabled:opacity-60 w-fit",children:e.jsx(_,{devId:"a8d04d",guard:{file:"src/pages/admin-reset-password.tsx",tagName:"button",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:3b1fdb5c440c111b4bae117f0f0efdbb8ba28b7cbee01b5fa2b3964d45be36ee"},children:u?"Resetting…":"Reset Password"})})]})]})})})]})}const Hx="https://totalhorsechannel.com",Sm=`${Hx}/youtube`,Df="https://www.youtube.com/user/Prowinda",Nz={"@context":"https://schema.org","@type":"WebPage","@id":`${Sm}#webpage`,name:"Total Horse Channel on YouTube",url:Sm,isPartOf:{"@id":`${Hx}/#website`},about:{"@id":`${Hx}/#organization`}};function Sz(){return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Total Horse Channel on YouTube"}),e.jsx("meta",{name:"description",content:"Watch lives, replays, and Shorts on the Total Horse Channel YouTube channel. Subscribe for the latest horse industry videos."}),e.jsx("link",{rel:"canonical",href:Sm}),e.jsx("meta",{property:"og:title",content:"Total Horse Channel on YouTube"}),e.jsx("meta",{property:"og:description",content:"Watch lives, replays, and Shorts on our YouTube channel."}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{property:"og:url",content:Sm}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify(Nz)})]}),e.jsxs("main",{children:[e.jsxs("div",{className:"bg-secondary py-8 px-4 text-center",children:[e.jsxs("div",{className:"flex items-center justify-center gap-3 mb-3",children:[e.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 90 63",width:"52",height:"36","aria-hidden":"true",children:[e.jsx("rect",{width:"90",height:"63",rx:"14",fill:"#FF0000"}),e.jsx("polygon",{points:"36,16 36,47 62,31.5",fill:"#fff"})]}),e.jsx("h1",{className:"text-white font-bold",style:{whiteSpace:"pre-line",fontSize:"26px",lineHeight:"1.2"},children:e.jsx(_,{devId:"b897b9",guard:{file:"src/pages/youtube.tsx",tagName:"h1",sourceKind:"content-key",contentKey:"youtube.headline",contentKeyTemplate:null,expressionHash:null},children:Fo.headline})})]}),e.jsx("p",{className:"text-white max-w-xl mx-auto mb-5",style:{whiteSpace:"pre-line",fontSize:"15px",opacity:.88},children:e.jsx(_,{devId:"0bd89c",guard:{file:"src/pages/youtube.tsx",tagName:"p",sourceKind:"content-key",contentKey:"youtube.subtext",contentKeyTemplate:null,expressionHash:null},children:Fo.subtext})}),e.jsxs("a",{href:Df,target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-2 bg-primary text-white font-bold px-6 py-3 rounded-sm hover:opacity-90 transition-opacity",style:{fontSize:"15px",textDecoration:"none"},children:[e.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",width:"18",height:"18",fill:"currentColor","aria-hidden":"true",children:e.jsx("path",{d:"M23.5 6.2a3 3 0 0 0-2.1-2.1C19.5 3.6 12 3.6 12 3.6s-7.5 0-9.4.5A3 3 0 0 0 .5 6.2C0 8.1 0 12 0 12s0 3.9.5 5.8a3 3 0 0 0 2.1 2.1c1.9.5 9.4.5 9.4.5s7.5 0 9.4-.5a3 3 0 0 0 2.1-2.1C24 15.9 24 12 24 12s0-3.9-.5-5.8zM9.6 15.6V8.4l6.3 3.6-6.3 3.6z"})}),Fo.ctaLabel]})]}),e.jsxs("div",{className:"max-w-[1100px] mx-auto px-4 py-8",children:[e.jsxs("div",{className:"flex flex-col sm:flex-row items-start sm:items-center justify-between gap-3 mb-6 pb-5 border-b border-border",children:[e.jsxs("div",{children:[e.jsx("p",{className:"font-bold text-foreground",style:{whiteSpace:"pre-line",fontSize:"17px"},children:e.jsx(_,{devId:"df1dc5",guard:{file:"src/pages/youtube.tsx",tagName:"p",sourceKind:"content-key",contentKey:"youtube.latestVideosHeading",contentKeyTemplate:null,expressionH
640ash:null},children:Fo.latestVideosHeading})}),e.jsx("p",{className:"text-muted-foreground",style:{whiteSpace:"pre-line",fontSize:"13px"},children:e.jsx(_,{devId:"df1dc6",guard:{file:"src/pages/youtube.tsx",tagName:"p",sourceKind:"content-key",contentKey:"youtube.latestVideosSubtext",contentKeyTemplate:null,expressionHash:null},children:Fo.latestVideosSubtext})})]}),e.jsxs("a",{href:Df,target:"_blank",rel:"noopener noreferrer",className:"shrink-0 inline-flex items-center gap-2 border border-border bg-card text-foreground font-semibold px-4 py-2 rounded-sm hover:bg-muted transition-colors",style:{fontSize:"13px",textDecoration:"none"},children:[e.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",width:"15",height:"15",fill:"#FF0000","aria-hidden":"true",children:e.jsx("path",{d:"M23.5 6.2a3 3 0 0 0-2.1-2.1C19.5 3.6 12 3.6 12 3.6s-7.5 0-9.4.5A3 3 0 0 0 .5 6.2C0 8.1 0 12 0 12s0 3.9.5 5.8a3 3 0 0 0 2.1 2.1c1.9.5 9.4.5 9.4.5s7.5 0 9.4-.5a3 3 0 0 0 2.1-2.1C24 15.9 24 12 24 12s0-3.9-.5-5.8zM9.6 15.6V8.4l6.3 3.6-6.3 3.6z"})}),Fo.subscribeLabel]})]}),e.jsxs("div",{className:"flex flex-col items-center justify-center gap-6 border border-border bg-card rounded-sm py-14 px-6 text-center",children:[e.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 90 63",width:"90",height:"63","aria-hidden":"true",children:[e.jsx("rect",{width:"90",height:"63",rx:"14",fill:"#FF0000"}),e.jsx("polygon",{points:"36,16 36,47 62,31.5",fill:"#fff"})]}),e.jsxs("div",{children:[e.jsx("p",{className:"font-bold text-foreground mb-1",style:{fontSize:"20px"},children:"Watch on YouTube"}),e.jsx("p",{className:"text-muted-foreground max-w-md mx-auto",style:{fontSize:"14px"},children:"Live events, replays, how-to guides, and Shorts — all on the Total Horse Channel YouTube page. Click below to browse and subscribe."})]}),e.jsxs("a",{href:Df,target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-2 bg-primary text-white font-bold px-8 py-3 rounded-sm hover:opacity-90 transition-opacity",style:{fontSize:"15px",textDecoration:"none"},children:[e.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",width:"18",height:"18",fill:"currentColor","aria-hidden":"true",children:e.jsx("path",{d:"M23.5 6.2a3 3 0 0 0-2.1-2.1C19.5 3.6 12 3.6 12 3.6s-7.5 0-9.4.5A3 3 0 0 0 .5 6.2C0 8.1 0 12 0 12s0 3.9.5 5.8a3 3 0 0 0 2.1 2.1c1.9.5 9.4.5 9.4.5s7.5 0 9.4-.5a3 3 0 0 0 2.1-2.1C24 15.9 24 12 24 12s0-3.9-.5-5.8zM9.6 15.6V8.4l6.3 3.6-6.3 3.6z"})}),"Open our YouTube channel"]})]})]})]})]})}const zx="https://totalhorsechannel.com",Cm=`${zx}/rumble`,Cz={"@context":"https://schema.org","@type":"WebPage","@id":`${Cm}#webpage`,name:"Total Horse Channel on Rumble",url:Cm,isPartOf:{"@id":`${zx}/#website`},about:{"@id":`${zx}/#organization`}},$2="/airo-assets/images/social/rumble-logo";function ow({width:t,height:a}){return e.jsx("img",{src:$2,alt:"Rumble",width:t,height:a,style:{objectFit:"contain",display:"block"}})}function Of({size:t}){return e.jsx("img",{src:$2,alt:"","aria-hidden":"true",width:t,height:t,style:{objectFit:"contain",display:"block",flexShrink:0}})}function kz(){return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Total Horse Channel on Rumble"}),e.jsx("meta",{name:"description",content:"Watch Total Horse Channel livestreams on Rumble. This is where we stream most often. Subscribe and never miss a live event."}),e.jsx("link",{rel:"canonical",href:Cm}),e.jsx("meta",{property:"og:title",content:"Total Horse Channel on Rumble"}),e.jsx("meta",{property:"og:description",content:"Watch Total Horse Channel livestreams on Rumble. This is where we stream most often."}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{property:"og:url",content:Cm}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify(Cz)})]}),e.jsxs("main",{children:[e.jsxs("div",{className:"bg-secondary py-8 px-4 text-center",children:[e.jsxs("div",{className:"flex items-center justify-center gap-3 mb-3",children:[e.jsx(ow,{width:52,height:36}),e.jsx("h1",{className:"text-white font-bold",style:{whiteSpace:"pre-line",fontSize:"26px",lineHeight:"1.2"},children:e.jsx(_,{devId:"edf7d3",guard:{file:"src/pages/rumble.tsx",tagName:"h1",sourceKind:"content-key",contentKey:"rumble.headline",contentKeyTemplate:null,expressionH
640ash:null},children:tn.headline})})]}),e.jsx("p",{className:"text-white max-w-xl mx-auto mb-5",style:{whiteSpace:"pre-line",fontSize:"15px",opacity:.88},children:e.jsx(_,{devId:"9481f6",guard:{file:"src/pages/rumble.tsx",tagName:"p",sourceKind:"content-key",contentKey:"rumble.subtext",contentKeyTemplate:null,expressionHash:null},children:tn.subtext})}),e.jsxs("a",{href:tn.channelUrl,target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-2 bg-primary text-white font-bold px-6 py-3 rounded-sm hover:opacity-90 transition-opacity",style:{fontSize:"15px",textDecoration:"none"},children:[e.jsx(Of,{size:18}),tn.ctaLabel]})]}),e.jsxs("div",{className:"max-w-[1100px] mx-auto px-4 py-8",children:[e.jsxs("div",{className:"flex flex-col sm:flex-row items-start sm:items-center justify-between gap-3 mb-5 pb-4 border-b border-border",children:[e.jsxs("div",{children:[e.jsx("p",{className:"font-bold text-foreground",style:{whiteSpace:"pre-line",fontSize:"17px"},children:e.jsx(_,{devId:"169e1f",guard:{file:"src/pages/rumble.tsx",tagName:"p",sourceKind:"content-key",contentKey:"rumble.latestStreamsHeading",contentKeyTemplate:null,expressionHash:null},children:tn.latestStreamsHeading})}),e.jsx("p",{className:"text-muted-foreground",style:{whiteSpace:"pre-line",fontSize:"13px"},children:e.jsx(_,{devId:"169e20",guard:{file:"src/pages/rumble.tsx",tagName:"p",sourceKind:"content-key",contentKey:"rumble.latestStreamsSubtext",contentKeyTemplate:null,expressionHash:null},children:tn.latestStreamsSubtext})})]}),e.jsxs("a",{href:tn.channelUrl,target:"_blank",rel:"noopener noreferrer",className:"shrink-0 inline-flex items-center gap-2 border border-border bg-card text-foreground font-semibold px-4 py-2 rounded-sm hover:bg-muted transition-colors",style:{fontSize:"13px",textDecoration:"none"},children:[e.jsx(Of,{size:15}),tn.followLabel]})]}),e.jsxs("div",{className:"flex flex-col items-center justify-center gap-6 border border-border bg-card rounded-sm py-10 px-6 text-center",children:[e.jsx(ow,{width:90,height:63}),e.jsxs("div",{children:[e.jsx("p",{className:"font-bold text-foreground mb-1",style:{whiteSpace:"pre-line",fontSize:"20px"},children:e.jsx(_,{devId:"735360",guard:{file:"src/pages/rumble.tsx",tagName:"p",sourceKind:"content-key",contentKey:"rumble.watchHeading",contentKeyTemplate:null,expressionHash:null},children:tn.watchHeading})}),e.jsx("p",{className:"text-muted-foreground max-w-md mx-auto",style:{whiteSpace:"pre-line",fontSize:"14px"},children:e.jsx(_,{devId:"735361",guard:{file:"src/pages/rumble.tsx",tagName:"p",sourceKind:"content-key",contentKey:"rumble.watchBody",contentKeyTemplate:null,expressionHash:null},children:tn.watchBody})})]}),e.jsxs("a",{href:tn.channelUrl,target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-2 bg-primary text-white font-bold px-8 py-3 rounded-sm hover:opacity-90 transition-opacity",style:{fontSize:"15px",textDecoration:"none"},children:[e.jsx(Of,{size:18}),tn.ctaLabel]})]})]})]})]})}const Rx="https://totalhorsechannel.com",km=`${Rx}/instagram`,Tz={"@context":"https://schema.org","@type":"WebPage","@id":`${km}#webpage`,name:"Total Horse Channel on Instagram",url:km,isPartOf:{"@id":`${Rx}/#website`},about:{"@id":`${Rx}/#organization`}};function Az(){return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Total Horse Channel on Instagram"}),e.jsx("meta",{name:"description",content:"Photos and short video from shows, lives, and the horse community. Follow Total Horse Channel on Instagram."}),e.jsx("link",{rel:"canonical",href:km}),e.jsx("meta",{property:"og:title",content:"Total Horse Channel on Instagram"}),e.jsx("meta",{property:"og:description",content:"Photos and short video from shows, lives, and the horse community."}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{property:"og:url",content:km}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify(Tz)})]}),e.jsxs("main",{children:[e.jsxs("div",{className:"bg-secondary py-8 px-4 text-center",children:[e.jsxs("div",{className:"flex items-center justify-center gap-3 mb-3",children:[e.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 90 63",width:"52",height:"36","aria-hidden":"true",children:[e.jsx("defs",{children:e.jsxs("linearGradient",{id:"ig-grad",x1:"0%",y1:"100%",x2:"100%",y2:"0%",children:[e.jsx("stop",{offset:"0%",stopColor:"#f09433"}),e.jsx("stop",{offset:"25%",stopColor:"#e6683c"}),e.jsx("stop",{offset:"50%",stopColor:"#dc2743"}),e.jsx("stop",{offset:"75%",stopColor:"#cc2366"}),e.jsx("stop",{offset:"100%",stopColor:"#bc1888"})]})}),e.jsx("rect",{width:"90",height:"63",rx:"14",fill:"url(#ig-grad)"}),e.jsx("rect",{x:"27",y:"16",width:"36",height:"31",rx:"8",fill:"none",stroke:"#fff",strokeWidth:"3.5"}
640),e.jsx("circle",{cx:"45",cy:"31.5",r:"8",fill:"none",stroke:"#fff",strokeWidth:"3"}),e.jsx("circle",{cx:"57",cy:"20",r:"2.5",fill:"#fff"})]}),e.jsx("h1",{className:"text-white font-bold",style:{whiteSpace:"pre-line",fontSize:"26px",lineHeight:"1.2"},children:e.jsx(_,{devId:"ef82d2",guard:{file:"src/pages/instagram.tsx",tagName:"h1",sourceKind:"content-key",contentKey:"instagram.headline",contentKeyTemplate:null,expressionHash:null},children:Bo.headline})})]}),e.jsx("p",{className:"text-white max-w-xl mx-auto mb-5",style:{whiteSpace:"pre-line",fontSize:"15px",opacity:.88},children:e.jsx(_,{devId:"15fdd5",guard:{file:"src/pages/instagram.tsx",tagName:"p",sourceKind:"content-key",contentKey:"instagram.subtext",contentKeyTemplate:null,expressionHash:null},children:Bo.subtext})}),e.jsxs("a",{href:Bo.channelUrl,target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-2 bg-primary text-white font-bold px-6 py-3 rounded-sm hover:opacity-90 transition-opacity",style:{fontSize:"15px",textDecoration:"none"},children:[e.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",width:"18",height:"18",fill:"currentColor","aria-hidden":"true",children:e.jsx("path",{d:"M12 2.163c3.204 0 3.584.012 4.85.07 3.252.148 4.771 1.691 4.919 4.919.058 1.265.069 1.645.069 4.849 0 3.205-.012 3.584-.069 4.849-.149 3.225-1.664 4.771-4.919 4.919-1.266.058-1.644.07-4.85.07-3.204 0-3.584-.012-4.849-.07-3.26-.149-4.771-1.699-4.919-4.92-.058-1.265-.07-1.644-.07-4.849 0-3.204.013-3.583.07-4.849.149-3.227 1.664-4.771 4.919-4.919 1.266-.057 1.645-.069 4.849-.069zm0-2.163c-3.259 0-3.667.014-4.947.072-4.358.2-6.78 2.618-6.98 6.98-.059 1.281-.073 1.689-.073 4.948 0 3.259.014 3.668.072 4.948.2 4.358 2.618 6.78 6.98 6.98 1.281.058 1.689.072 4.948.072 3.259 0 3.668-.014 4.948-.072 4.354-.2 6.782-2.618 6.979-6.98.059-1.28.073-1.689.073-4.948 0-3.259-.014-3.667-.072-4.947-.196-4.354-2.617-6.78-6.979-6.98-1.281-.059-1.69-.073-4.949-.073zm0 5.838c-3.403 0-6.162 2.759-6.162 6.162s2.759 6.163 6.162 6.163 6.162-2.759 6.162-6.163c0-3.403-2.759-6.162-6.162-6.162zm0 10.162c-2.209 0-4-1.79-4-4 0-2.209 1.791-4 4-4s4 1.791 4 4c0 2.21-1.791 4-4 4zm6.406-11.845c-.796 0-1.441.645-1.441 1.44s.645 1.44 1.441 1.44c.795 0 1.439-.645 1.439-1.44s-.644-1.44-1.439-1.44z"})}),Bo.ctaLabel]})]}),e.jsx("div",{className:"max-w-[1100px] mx-auto px-4 py-8",children:e.jsxs("div",{className:"flex flex-col items-center justify-center gap-6 border border-border bg-card rounded-sm py-14 px-6 text-center",children:[e.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 90 90",width:"90",height:"90","aria-hidden":"true",children:[e.jsx("defs",{children:e.jsxs("linearGradient",{id:"ig-grad-lg",x1:"0%",y1:"100%",x2:"100%",y2:"0%",children:[e.jsx("stop",{offset:"0%",stopColor:"#f09433"}),e.jsx("stop",{offset:"25%",stopColor:"#e6683c"}),e.jsx("stop",{offset:"50%",stopColor:"#dc2743"}),e.jsx("stop",{offset:"75%",stopColor:"#cc2366"}),e.jsx("stop",{offset:"100%",stopColor:"#bc1888"})]})}),e.jsx("rect",{width:"90",height:"90",rx:"20",fill:"url(#ig-grad-lg)"}),e.jsx("rect",{x:"20",y:"20",width:"50",height:"50",rx:"13",fill:"none",stroke:"#fff",strokeWidth:"4.5"}),e.jsx("circle",{cx:"45",cy:"45",r:"12",fill:"none",stroke:"#fff",strokeWidth:"4"}),e.jsx("circle",{cx:"60",cy:"29",r:"3.5",fill:"#fff"})]}),e.jsxs("div",{children:[e.jsx("p",{className:"font-bold text-foreground mb-1",style:{fontSize:"20px"},children:"Follow us on Instagram"}),e.jsx("p",{className:"text-muted-foreground max-w-md mx-auto",style:{fontSize:"14px"},children:"Behind-the-scenes photos, show highlights, short clips, and updates from the horse community — all on our Instagram page."})]}),e.jsxs("a",{href:Bo.channelUrl,target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-2 bg-primary text-white font-bold px-8 py-3 rounded-sm hover:opacity-90 transition-opacity",style:{fontSize:"15px",textDecoration:"none"},children:[e.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",width:"18",height:"18",fill:"currentColor","aria-hidden":"true",children:e.jsx("path",{d:"M12 2.163c3.204 0 3.584.012 4.85.07 3.252.148 4.771 1.691 4.919 4.919.058 1.265.069 1.645.069 4.849 0 3.205-.012 3.584-.069 4.849-.149 3.225-1.664 4.771-4.919 4.919-1.266.058-1.644.07-4.85.07-3.204 0-3.584-.012-4.849-.07-3.26-.149-4.771-1.699-4.919-4.92-.058-1.265-.07-1.644-.07-4.849 0-3.204.013-3.583.07-4.849.149-3.227 1.664-4.771 4.919-4.919 1.266-.057 1.645-.069 4.849-.069zm0-2.163c-3.259 
6400-3.667.014-4.947.072-4.358.2-6.78 2.618-6.98 6.98-.059 1.281-.073 1.689-.073 4.948 0 3.259.014 3.668.072 4.948.2 4.358 2.618 6.78 6.98 6.98 1.281.058 1.689.072 4.948.072 3.259 0 3.668-.014 4.948-.072 4.354-.2 6.782-2.618 6.979-6.98.059-1.28.073-1.689.073-4.948 0-3.259-.014-3.667-.072-4.947-.196-4.354-2.617-6.78-6.979-6.98-1.281-.059-1.69-.073-4.949-.073zm0 5.838c-3.403 0-6.162 2.759-6.162 6.162s2.759 6.163 6.162 6.163 6.162-2.759 6.162-6.163c0-3.403-2.759-6.162-6.162-6.162zm0 10.162c-2.209 0-4-1.79-4-4 0-2.209 1.791-4 4-4s4 1.791 4 4c0 2.21-1.791 4-4 4zm6.406-11.845c-.796 0-1.441.645-1.441 1.44s.645 1.44 1.441 1.44c.795 0 1.439-.645 1.439-1.44s-.644-1.44-1.439-1.44z"})}),Bo.ctaLabel]})]})})]})]})}const _x="https://totalhorsechannel.com",Tm=`${_x}/community-guidelines`,Ez={"@context":"https://schema.org","@type":"WebPage","@id":`${Tm}#webpage`,name:"Community Guidelines – Total Horse Channel",url:Tm,isPartOf:{"@id":`${_x}/#website`},about:{"@id":`${_x}/#organization`}},Hz=[{id:"respect",heading:"Respect people",body:"No harassment, threats, stalking, hate, or posting someone else's private information."},{id:"horse-content",heading:"Horse content only",body:"Lives and videos you add must be horse-related. We may remove anything that isn't."},{id:"rights",heading:"You must have the right to share it",body:"Only paste links or embeds you own or that the owner made public. Don't use other people's videos, music, or shows without permission."},{id:"no-illegal",heading:"No illegal or adult content",body:"No pornography or sexually explicit material. We will report child sexual exploitation to law enforcement. No animal abuse, drug abuse, or content meant to shock people with death or serious injury."},{id:"no-spam",heading:"No spam",body:"Don't flood comments, follows, or Add Video / Live with junk or ads."},{id:"enforcement",heading:"We can remove content and accounts",body:e.jsxs(e.Fragment,{children:["If you break these rules, we can unpublish a video or close the account. Questions:"," ",e.jsx("a",{href:"mailto:[email protected]",className:"text-primary hover:underline",children:"[email protected]"})]})}];function zz(){return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Community Guidelines – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Total Horse Channel community guidelines. Be respectful, share horse content, and follow the rules that keep our community safe and welcoming."}),e.jsx("link",{rel:"canonical",href:Tm}),e.jsx("meta",{property:"og:title",content:"Community Guidelines – Total Horse Channel"}),e.jsx("meta",{property:"og:description",content:"Total Horse Channel community guidelines. Be respectful, share horse content, and follow the rules that keep our community safe and welcoming."}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{property:"og:url",content:Tm}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify(Ez)})]}),e.jsx("main",{children:e.jsx("div",{className:"max-w-[1280px] mx-auto px-4 py-4",children:e.jsxs("div",{className:"flex flex-col lg:flex-row gap-6",children:[e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("div",{className:"bg-primary px-3 py-2 mb-4",children:e.jsx("h1",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Community Guidelines"})}),e.jsxs("div",{className:"mb-5 border border-border rounded p-5 bg-card",children:[e.jsxs("div",{className:"flex items-start gap-3 mb-3",children:[e.jsx(cg,{size:28,className:"text-primary shrink-0 mt-0.5"}),e.jsx("h2",{className:"font-bold text-foreground leading-snug",style:{fontSize:"22px"},children:"Total Horse Channel Community Guidelines"})]}),e.jsx("p",{className:"text-foreground leading-relaxed",style:{fontSize:"15px"},children:"Total Horse Channel is a horse video community. Be respectful. Follow these rules."})]}),e.jsx("div",{className:"flex flex-col gap-3 mb-6",children:Hz.map((t,a)=>e.jsxs("div",{className:"border border-border rounded bg-card overflow-hidden",children:[e.jsxs("div",{className:"bg-secondary px-4 py-2 flex items-center gap-2",children:[e.jsx("span",{className:"inline-flex items-center justify-center w-5 h-5 rounded-full bg-primary text-white font-bold shrink-0",style:{fontSize:"11px"},children:a+1}),e.jsx("h3",{className:"text-white font-bold text-sm",children:t.heading})]}),e.jsx("div",{className:"px-4 py-3",children:e.jsx("p",{className:"text-foreground leading-relaxed",style:{fontSize:"14px"},children:t.body})})]},t.id))}),e.jsx("div",{className:"bg-muted border border-border rounded p-4 text-center",children:e.jsx("p",{className:"text-muted-foreground text-sm leading-relaxed",children:"These guidelines apply to all content and interactions on Total Horse Channel. We reserve the right to update them at any time."})})]}),e.jsxs("aside",{className:"w-full lg:w-[340px] shrink-0 flex flex-col gap-4",children:[e.jsx(zs,{placement:"sidebar-community-guidelines"}),e.jsx(O,{to:"/watch-live-events",className:"block bg-primary text-white text-center font-bold uppercase py-3 px-4 text-sm tracking-wide hover:bg-primary/90 transition-colors",children:"Watch Live Events"}),e.jsx(O,{to:"/",className:"block bg-secondary text-white text-center font-bold uppercase py-3 px-4 text-sm tracking-wide hover:opacity-90 transition-opacity",children:"← Back to Home"}),e.jsx(O,{to:"/mission",className:"block w-full text-center font-bold uppercase py-2 text-sm bg-gray-200 text-gray-800 hover:bg-gray-300 transition-colors",children:"Our Mission"}),e.jsxs("div",{className:"border border-border p-4 text-center",children:[e.jsx("p",{className:"font-bold text-foreground mb-1",style:{fontSize:"14px"},children:"Advertise With Us"}),e.jsx("p",{className:"text-muted-foreground text-xs mb-3",children:"Reach thousands of horse enthusiasts. Request our media kit today."}),e.jsx(O,{to:"/advertise",className:"inline-block bg-primary text-white text-xs font-bold uppercase px-4 py-2 hover:bg-primary/90 transition-colors",children:"Learn More"})]})]})]})})})]})}const Lx="https://totalhorsechannel.com",Am=`${Lx}/terms-of-service`,Rz={"@context":"https://schema.org","@type":"WebPage","@id":`${Am}#webpage`,name:"Terms of Service – Total Horse Channel",url:Am,isPartOf:{"@id":`${Lx}/#website`},about:{"@id":`${Lx}/#organization`}};function _z(){return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Terms of Service – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Read the Terms of Service for Total Horse Channel. Covers permitted use, content rules, DMCA, accounts, warranty disclaimer, and governing law."}),e.jsx("link",{rel:"canonical",href:Am}),e.jsx("meta",{property:"og:title",content:"Terms of Service – Total Horse Channel"}),e.jsx("meta",{property:"og:description",content:"Read the Terms of Service for Total Horse Channel."}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{property:"og:url",content:Am}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify(Rz)})]}),e.jsx("main",{children:e.jsx("div",{className:"max-w-[1280px] mx-auto px-4 py-4",children:e.jsxs("div",{className:"flex flex-col lg:flex-row gap-6",children:[e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("div",{className:"bg-primary px-3 py-2 mb-4",children:e.jsx("h1",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Terms of Service"})}),e.jsxs("div",{className:"mb-5 border border-border rounded p-5 bg-card",children:[e.jsxs("div",{className:"flex items-start gap-3 mb-3",children:[e.jsx(e2,{size:28,className:"text-primary shrink-0 mt-0.5"}),e.jsxs("div",{children:[e.jsx("h2",{className:"font-bold text-foreground leading-snug",style:{fontSize:"20px"},children:"Total Horse Channel Terms of Service"}),e.jsx("p",{className:"text-muted-foreground text-xs mt-1",children:"Last Updated: August 30, 2026"})]})]}),e.jsxs("p",{className:"text-foreground leading-relaxed",style:{fontSize:"14px"},children:['Total Horse Channel ("THC") offers an online horse video community ("the THC Service") through its website at'," ",e.jsx("a",{href:"https://www.totalhorsechannel.com",className:"text-primary hover:underline",children:"www.totalhorsechannel.com"})," ",'("THC Site"). By using or visiting the THC Site or using the THC Service in any way, you accept these Terms of Service, including the'," ",e.jsx(O,{to:"/community-guidelines",className:"text-primary hover:underline",children:"Community Guidelines"}),", which collectively form a binding agreement between you and THC."]})]}),e.jsx("div",{className:"flex flex-col gap-3 mb-6",children:xA.SECTIONS.map(t=>e.jsxs("div",{className:"border border-border rounded bg-card overflow-hidden",children:[e.jsxs("div",{className:"bg-secondary px-4 py-2 flex items-center gap-2",children:[e.jsx("span",{className:"inline-flex items-center justify-center w-6 h-6 rounded-full bg-primary text-white font-bold shrink-0",style:{whiteSpace:"pre-line",fontSize:"11px"},children:t.num}),e.jsx("h2",{className:"text-white font-bold text-sm",style:{whiteSpace:"pre-line"},children:t.heading})]}),e.jsx("div",{className:"px-4 py-3 flex flex-col gap-3",children:t.subsections.map((a,r)=>
640{const o=a;return e.jsxs("div",{children:[o.label&&e.jsx("span",{className:"font-semibold text-foreground text-sm mr-1",children:o.label}),e.jsx("span",{className:"text-foreground leading-relaxed",style:{fontSize:"13.5px"},children:o.body}),o.list&&e.jsx("ul",{className:"mt-2 ml-4 flex flex-col gap-1 list-disc",children:o.list.map((l,d)=>e.jsx("li",{className:"text-foreground leading-relaxed",style:{fontSize:"13.5px"},children:l},d))})]},r)})})]},t.num))}),e.jsx("div",{className:"bg-muted border border-border rounded p-4 text-center mb-2",children:e.jsxs("p",{className:"text-muted-foreground text-sm leading-relaxed",children:["Questions about these Terms?"," ",e.jsx("a",{href:"mailto:[email protected]",className:"text-primary hover:underline font-medium",children:"[email protected]"})," ","· DMCA: PO Box 773011, Ocala, FL 34477-3011"]})})]}),e.jsxs("aside",{className:"w-full lg:w-[340px] shrink-0 flex flex-col gap-4",children:[e.jsx(zs,{placement:"sidebar-terms"}),e.jsx(O,{to:"/watch-live-events",className:"block bg-primary text-white text-center font-bold uppercase py-3 px-4 text-sm tracking-wide hover:bg-primary/90 transition-colors",children:"Watch Live Events"}),e.jsx(O,{to:"/",className:"block bg-secondary text-white text-center font-bold uppercase py-3 px-4 text-sm tracking-wide hover:opacity-90 transition-opacity",children:"← Back to Home"}),e.jsx(O,{to:"/mission",className:"block w-full text-center font-bold uppercase py-2 text-sm bg-gray-200 text-gray-800 hover:bg-gray-300 transition-colors",children:"Our Mission"}),e.jsxs("div",{className:"border border-border p-4 text-center",children:[e.jsx("p",{className:"font-bold text-foreground mb-1",style:{fontSize:"14px"},children:"Advertise With Us"}),e.jsx("p",{className:"text-muted-foreground text-xs mb-3",children:"Reach thousands of horse enthusiasts. Request our media kit today."}),e.jsx(O,{to:"/advertise",className:"inline-block bg-primary text-white text-xs font-bold uppercase px-4 py-2 hover:bg-primary/90 transition-colors",children:"Learn More"})]})]})]})})})]})}const Dx="https://totalhorsechannel.com",Em=`${Dx}/privacy-policy`,Lz={"@context":"https://schema.org","@type":"WebPage","@id":`${Em}#webpage`,name:"Privacy Policy – Total Horse Channel",url:Em,isPartOf:{"@id":`${Dx}/#website`},about:{"@id":`${Dx}/#organization`}};function Dz(){return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Privacy Policy – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Read the Total Horse Channel Privacy Policy. Covers data collection, cookies, member accounts, content submissions, donations, and your rights."}),e.jsx("link",{rel:"canonical",href:Em}),e.jsx("meta",{property:"og:title",content:"Privacy Policy – Total Horse Channel"}),e.jsx("meta",{property:"og:description",content:"Read the Total Horse Channel Privacy Policy."}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{property:"og:url",content:Em}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify(Lz)})]}),e.jsx("main",{children:e.jsx("div",{className:"max-w-[1280px] mx-auto px-4 py-4",children:e.jsxs("div",{className:"flex flex-col lg:flex-row gap-6",children:[e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("div",{className:"bg-primary px-3 py-2 mb-4",children:e.jsx("h1",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Privacy Policy"})}),e.jsxs("div",{className:"mb-5 border border-border rounded p-5 bg-card",children:[e.jsxs("div",{className:"flex items-start gap-3 mb-3",children:[e.jsx(cg,{size:28,className:"text-primary shrink-0 mt-0.5"}),e.jsxs("div",{children:[e.jsx("h2",{className:"font-bold text-foreground leading-snug",style:{fontSize:"20px"},children:"Total Horse Channel Privacy Policy"}),e.jsx("p",{className:"text-muted-foreground text-xs mt-1",children:"Last Updated: August 30, 2026"})]})]}),e.jsx("p",{className:"text-foreground leading-relaxed",style:{fontSize:"14px"},children:"This policy explains what information Total Horse Channel collects, how it is used, and your choices regarding that information. By using the THC Service you agree to the collection and use of information in accordance with this policy."})]}),e.jsx("div",{className:"flex flex-col gap-3 mb-6",children:fA.SECTIONS.map(t=>e.jsxs("div",{className:"border border-border rounded bg-card overflow-hidden",children:[e.jsxs("div",{className:"bg-secondary px-4 py-2 flex items-center gap-2",children:[e.jsx("span",{className:"inline-flex items-center justify-center w-6 h-6 rounded-full bg-primary text-white font-bold shrink-0",style:{whiteSpace:"pre-line",fontSize:"11px"},children:t.num}),e.jsx("h2",{className:"text-white font-bold text-sm",style:{whiteSpace:"pre-line"},children:t.heading})]}),e.jsx("div",{className:"px-4 py-3 flex flex-col gap-3",children:t.subsections.map((a,r)=>
640{const o=a;return e.jsxs("div",{children:[o.label&&e.jsx("span",{className:"font-semibold text-foreground text-sm mr-1",children:o.label}),e.jsx("span",{className:"text-foreground leading-relaxed",style:{fontSize:"13.5px"},children:o.body}),o.list&&e.jsx("ul",{className:"mt-2 ml-4 flex flex-col gap-1 list-disc",children:o.list.map((l,d)=>e.jsx("li",{className:"text-foreground leading-relaxed",style:{fontSize:"13.5px"},children:l},d))})]},r)})})]},t.num))}),e.jsx("div",{className:"bg-muted border border-border rounded p-4 text-center mb-2",children:e.jsxs("p",{className:"text-muted-foreground text-sm leading-relaxed",children:["Questions about this policy?"," ",e.jsx("a",{href:"mailto:[email protected]",className:"text-primary hover:underline font-medium",children:"[email protected]"})," ","· PO Box 773011, Ocala, FL 34477-3011"]})})]}),e.jsxs("aside",{className:"w-full lg:w-[340px] shrink-0 flex flex-col gap-4",children:[e.jsx(zs,{placement:"sidebar-privacy"}),e.jsx(O,{to:"/watch-live-events",className:"block bg-primary text-white text-center font-bold uppercase py-3 px-4 text-sm tracking-wide hover:bg-primary/90 transition-colors",children:"Watch Live Events"}),e.jsx(O,{to:"/",className:"block bg-secondary text-white text-center font-bold uppercase py-3 px-4 text-sm tracking-wide hover:opacity-90 transition-opacity",children:"← Back to Home"}),e.jsx(O,{to:"/mission",className:"block w-full text-center font-bold uppercase py-2 text-sm bg-gray-200 text-gray-800 hover:bg-gray-300 transition-colors",children:"Our Mission"}),e.jsxs("div",{className:"border border-border p-4 bg-card",children:[e.jsx("p",{className:"font-bold text-foreground mb-3 border-b border-border pb-2",style:{fontSize:"14px"},children:"Legal & Guidelines"}),e.jsxs("div",{className:"flex flex-col gap-2",children:[e.jsx(O,{to:"/terms-of-service",className:"text-accent text-sm hover:underline",children:"→ Terms of Service"}),e.jsx(O,{to:"/community-guidelines",className:"text-accent text-sm hover:underline",children:"→ Community Guidelines"}),e.jsx(O,{to:"/tech-support",className:"text-accent text-sm hover:underline",children:"→ Tech Support"})]})]}),e.jsxs("div",{className:"border border-border p-4 text-center",children:[e.jsx("p",{className:"font-bold text-foreground mb-1",style:{fontSize:"14px"},children:"Advertise With Us"}),e.jsx("p",{className:"text-muted-foreground text-xs mb-3",children:"Reach thousands of horse enthusiasts. Request our media kit today."}),e.jsx(O,{to:"/advertise",className:"inline-block bg-primary text-white text-xs font-bold uppercase px-4 py-2 hover:bg-primary/90 transition-colors",children:"Learn More"})]})]})]})})})]})}const Oz="https://totalhorsechannel.com";function Mz(){const t=`${Oz}/games`,a="Play horse games without leaving Total Horse Channel. Free horse sims, breeding games, and more.";return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Horse Games – Total Horse Channel"}),e.jsx("meta",{name:"description",content:a}),e.jsx("link",{rel:"canonical",href:t}),e.jsx("meta",{property:"og:title",content:"Horse Games – Total Horse Channel"}),e.jsx("meta",{property:"og:description",content:a}),e.jsx("meta",{property:"og:url",content:t}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"})]}),e.jsx("main",{children:e.jsxs("div",{className:"max-w-[1100px] mx-auto px-4 py-6",children:[e.jsxs("div",{className:"bg-primary px-4 py-2.5 mb-5 flex items-center gap-2",children:[e.jsx(Pu,{size:15,className:"text-white shrink-0"}),e.jsx("h1",{className:"text-white font-bold text-sm uppercase tracking-wide",children:"Horse Games"})]}),e.jsx("p",{className:"text-gray-700 text-sm mb-6 leading-relaxed",children:"Play horse games without leaving Total Horse Channel. If a game cannot display here, use the Play button to open it in a new tab."}),e.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-6 mb-8",children:mA.GAMES.map(r=>e.jsxs("div",{className:"border border-gray-200 rounded bg-white overflow-hidden flex flex-col",children:[e.jsxs("div",{className:"bg-primary px-4 py-2.5 flex items-center gap-2",children:[e.jsx(Pu,{size:15,className:"text-white shrink-0"}),e.jsx("span",{className:"text-white font-bold text-sm uppercase tracking-wide",style:{whiteSpace:"pre-line"},children:r.title})]}),e.jsxs("div",{className:"px-5 py-5 flex flex-col gap-4 flex-1",children:[e.jsx("p",{className:"text-gray-700 text-sm leading-relaxed",style:{whiteSpace:"pre-line"},children:r.description}),e.jsxs("div",{className:"flex flex-wrap items-center gap-3 mt-auto",children:[e.jsxs(O,{to:r.href,className:"inline-flex items-center gap-1.5 bg-primary text-white text-sm font-semibold px-5 py-2.5 rounded hover:bg-primary/90 transition-colors",children:[e.jsx(Lt,{size:14}),"Open Game Page"]}),e.jsxs("a",{href:r.playUrl,target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-1.5 border border-primary text-primary text-sm font-semibold px-5 py-2.5 rounded hover:bg-primary hover:text-white transition-colors",children:[e.jsx(dt,{size:13}),"Play in New Tab"]})]})]})]},r.href))}),e.jsxs("div",{className:"border border-gray-200 rounded bg-white px-5 py-4 flex flex-col sm:flex-row items-start sm:items-center gap-3",children:[e.jsx(B0,{size:20,className:"text-primary shrink-0"}),e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("p",{className:"text-sm font-semibold text-gray-800",children:"Horse Puzzles"}),e.jsx("p",{className:"text-xs text-gray-500 mt-0.5",children:"Jigsaw puzzles featuring horses, shows, and equestr
640ian events."})]}),e.jsxs(O,{to:"/puzzles",className:"inline-flex items-center gap-1.5 bg-secondary text-white text-sm font-semibold px-4 py-2 rounded hover:opacity-90 transition-opacity shrink-0",children:[e.jsx(B0,{size:13}),"Play Puzzles"]})]})]})})]})}const Uz="https://totalhorsechannel.com",Pz="https://horseeden.com/",Kz="https://horseeden.com/";function Iz({title:t,embedUrl:a,playUrl:r}){const[o,l]=g.useState(!1),[d,u]=g.useState(!1),m=g.useRef(null),p=g.useRef(null);g.useEffect(()=>(l(!1),u(!1),p.current=setTimeout(()=>{l(y=>y||!d)},5e3),()=>{p.current&&clearTimeout(p.current)}),[a]);function x(){var y;p.current&&clearTimeout(p.current),u(!0);try{const v=(y=m.current)==null?void 0:y.contentDocument;v&&v.body&&v.body.innerHTML.trim()===""&&l(!0)}catch{}}function b(){p.current&&clearTimeout(p.current),l(!0)}return e.jsxs("div",{className:"border border-gray-200 rounded bg-white overflow-hidden",children:[!o&&e.jsx("div",{className:"w-full",style:{height:"600px"},children:e.jsx("iframe",{ref:m,src:a,title:t,width:"100%",height:"100%",style:{border:"none",display:"block"},referrerPolicy:"no-referrer-when-downgrade",onLoad:x,onError:b,sandbox:"allow-scripts allow-same-origin allow-forms allow-popups allow-popups-to-escape-sandbox"})}),o&&e.jsx("div",{className:"px-5 py-6 bg-amber-50 border-b border-amber-200",children:e.jsx("p",{className:"text-sm text-amber-800",children:"This game cannot display inside the page. Use the Play button below to open it in a new tab."})}),e.jsx("div",{className:"px-5 py-4",children:e.jsxs("a",{href:r,target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-2 bg-primary text-white text-sm font-semibold px-6 py-2.5 rounded hover:bg-primary/90 transition-colors",children:[e.jsx(dt,{size:14}),"Play ",t]})})]})}function Bz(){const t=`${Uz}/games/horse-eden`,a="Play Horse Eden — a free eventing horse sim. Breed, train, and show your horses on Total Horse Channel.";return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Horse Eden – Total Horse Channel"}),e.jsx("meta",{name:"description",content:a}),e.jsx("link",{rel:"canonical",href:t}),e.jsx("meta",{property:"og:title",content:"Horse Eden – Total Horse Channel"}),e.jsx("meta",{property:"og:description",content:a}),e.jsx("meta",{property:"og:url",content:t}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"})]}),e.jsx("main",{children:e.jsxs("div",{className:"max-w-[1100px] mx-auto px-4 py-6",children:[e.jsxs("nav",{"aria-label":"Breadcrumb",className:"text-xs text-gray-500 mb-3 flex items-center gap-1",children:[e.jsx(O,{to:"/",className:"hover:text-primary transition-colors",children:"Home"}),e.jsx("span",{children:"/"}),e.jsx(O,{to:"/games",className:"hover:text-primary transition-colors",children:"Games"}),e.jsx("span",{children:"/"}),e.jsx("span",{className:"text-gray-700",children:"Horse Eden"})]}),e.jsxs("div",{className:"bg-primary px-4 py-2.5 mb-4 flex items-center gap-2",children:[e.jsx(Pu,{size:15,className:"text-white shrink-0"}),e.jsx("h1",{className:"text-white font-bold text-sm uppercase tracking-wide",children:"Horse Eden"})]}),e.jsx("p",{className:"text-gray-700 text-sm mb-5 leading-relaxed",children:"Free eventing horse sim. Breed, train, and show your horses. If the game does not load below, use the Play button to open it directly."}),e.jsx(Iz,{title:"Horse Eden",embedUrl:Kz,playUrl:Pz}),e.jsx("div",{className:"mt-5",children:e.jsxs(O,{to:"/games",className:"inline-flex items-center gap-1.5 text-primary text-sm font-medium hover:underline",children:[e.jsx(En,{size:15}),"Back to Games"]})})]})})]})}const $z="https://totalhorsechannel.com",Vz="https://www.horseworldonline.net/",Fz="https://www.horseworldonline.net/";function Wz({title:t,embedUrl:a,playUrl:r}){const[o,l]=g.useState(!1),[d,u]=g.useState(!1),m=g.useRef(null),p=g.useRef(null);g.useEffect(()=>(l(!1),u(!1),p.current=setTimeout(()=>{l(y=>y||!d)},5e3),()=>{p.current&&clearTimeout(p.current)}),[a]);function x(){var y;p.current&&clearTimeout(p.current),u(!0);try{const v=(y=m.current)==null?void 0:y.contentDocument;v&&v.body&&v.body.innerHTML.trim()===""&&l(!0)}catch{}}function b(){p.current&&clearTimeout(p.current),l(!0)}return e.jsxs("div",{className:"border border-gray-200 rounded bg-white overflow-hidden",children:[!
640o&&e.jsx("div",{className:"w-full",style:{height:"600px"},children:e.jsx("iframe",{ref:m,src:a,title:t,width:"100%",height:"100%",style:{border:"none",display:"block"},referrerPolicy:"no-referrer-when-downgrade",onLoad:x,onError:b,sandbox:"allow-scripts allow-same-origin allow-forms allow-popups allow-popups-to-escape-sandbox"})}),o&&e.jsx("div",{className:"px-5 py-6 bg-amber-50 border-b border-amber-200",children:e.jsx("p",{className:"text-sm text-amber-800",children:"This game cannot display inside the page. Use the Play button below to open it in a new tab."})}),e.jsx("div",{className:"px-5 py-4",children:e.jsxs("a",{href:r,target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-2 bg-primary text-white text-sm font-semibold px-6 py-2.5 rounded hover:bg-primary/90 transition-colors",children:[e.jsx(dt,{size:14}),"Play ",t]})})]})}function qz(){const t=`${$z}/games/horse-world-online`,a="Play Horse World Online — a free horse breeding and training game on Total Horse Channel.";return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Horse World Online – Total Horse Channel"}),e.jsx("meta",{name:"description",content:a}),e.jsx("link",{rel:"canonical",href:t}),e.jsx("meta",{property:"og:title",content:"Horse World Online – Total Horse Channel"}),e.jsx("meta",{property:"og:description",content:a}),e.jsx("meta",{property:"og:url",content:t}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"})]}),e.jsx("main",{children:e.jsxs("div",{className:"max-w-[1100px] mx-auto px-4 py-6",children:[e.jsxs("nav",{"aria-label":"Breadcrumb",className:"text-xs text-gray-500 mb-3 flex items-center gap-1",children:[e.jsx(O,{to:"/",className:"hover:text-primary transition-colors",children:"Home"}),e.jsx("span",{children:"/"}),e.jsx(O,{to:"/games",className:"hover:text-primary transition-colors",children:"Games"}),e.jsx("span",{children:"/"}),e.jsx("span",{className:"text-gray-700",children:"Horse World Online"})]}),e.jsxs("div",{className:"bg-primary px-4 py-2.5 mb-4 flex items-center gap-2",children:[e.jsx(Pu,{size:15,className:"text-white shrink-0"}),e.jsx("h1",{className:"text-white font-bold text-sm uppercase tracking-wide",children:"Horse World Online"})]}),e.jsx("p",{className:"text-gray-700 text-sm mb-5 leading-relaxed",children:"Free horse breeding and training game. If the game does not load below, use the Play button to open it directly."}),e.jsx(Wz,{title:"Horse World Online",embedUrl:Fz,playUrl:Vz}),e.jsx("div",{className:"mt-5",children:e.jsxs(O,{to:"/games",className:"inline-flex items-center gap-1.5 text-primary text-sm font-medium hover:underline",children:[e.jsx(En,{size:15}),"Back to Games"]})})]})})]})}const Yz=[{label:"Campolina",href:"/category/campolina"},{label:"Cavalo Crioulo",href:"/category/cavalo-crioulo"},{label:"Campdraft",href:"/category/campdraft"},{label:"Cutting Horse",href:"/category/cutting-horse"},{label:"Eventing",href:"/category/eventing"},{label:"Harness Racing",href:"/category/harness-racing"},{label:"Horse Health",href:"/category/horse-health"},{label:"Horse Music Videos",href:"/category/horse-music-videos"},{label:"Horse Racing",href:"/category/horse-racing"},{label:"Horse Sale",href:"/category/horse-sale"},{label:"How To Videos",href:"/category/how-to-videos"}
640,{label:"Other / General",href:"/category/other-general"},{label:"Podcast",href:"/category/podcast"},{label:"Quarter Horse",href:"/category/quarter-horse"},{label:"Reined Cow Horse",href:"/category/reined-cow-horse"},{label:"Reining",href:"/category/reining"},{label:"Show Jumping",href:"/category/show-jumping"},{label:"Western Dressage",href:"/category/western-dressage"},{label:"Working Equitation",href:"/#working-equitation"}];function Gz(t,a){return An(t,a)}function Ks({category:t,slug:a,heroImage:r,imageCreditUrl:o,imageCreditLabel:l,breedDescription:d,learnMoreUrl:u,contestSlot:m,articles:p}){const[x,b]=g.useState([]);g.useEffect(()=>{fetch(`/api/live-events/by-category?category=${encodeURIComponent(t)}`).then(v=>v.json()).then(v=>b(v.events??[])).catch(()=>{})},[t]);const y=p.length>0||x.length>0;return e.jsx("main",{children:e.jsx("div",{className:"max-w-[1280px] mx-auto px-4 py-4",children:e.jsxs("div",{className:"flex flex-col lg:flex-row gap-6",children:[e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("div",{className:"bg-primary px-3 py-2 mb-4",children:e.jsx("h1",{className:"text-white font-bold uppercase text-sm tracking-wide",children:e.jsx(_,{devId:"7334a5",guard:{file:"src/components/CategoryPage.tsx",tagName:"h1",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:edb2cd3b74c999af70f0b7054990f2072dc6e10a847af6ed05954b8994b730fe"},children:t})})}),r&&e.jsxs("div",{className:"mb-4 w-full",children:[e.jsx("img",{src:r,alt:t,width:860,height:480,className:"w-full h-auto object-contain block",loading:"eager",fetchPriority:"high"}),o&&e.jsxs("p",{className:"text-right text-muted-foreground mt-1",style:{fontSize:"11px"},children:["Photo:"," ",e.jsx("a",{href:o,target:"_blank",rel:"noopener noreferrer",className:"text-accent hover:underline",children:e.jsx(_,{devId:"0bd9ef",guard:{file:"src/components/CategoryPage.tsx",tagName:"a",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:37442c6d034e3dbcac538afb4cf33324bc8f086dda00ca7d04719c72a12e9ba8"},children:l??o})})]})]}),d&&e.jsxs("div",{className:"mb-4 text-sm text-foreground leading-relaxed",children:[e.jsx("p",{children:e.jsx(_,{devId:"184b1e",guard:{file:"src/components/CategoryPage.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:aed0a1f379ddb591095b8114d07f51f2a4d0a412fa2395c3de422c304d318036"},children:d})}),u&&e.jsx("p",{className:"mt-2",children:e.jsxs("a",{href:u,target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-1 text-accent hover:underline font-medium",children:["Learn more about the ",t," breed",e.jsx(dt,{size:13,className:"shrink-0"})]})})]}),m&&e.jsx("div",{className:"mb-5",children:m}),!y&&e.jsx("div",{className:"border border-border bg-card px-6 py-10 text-center mb-5",children:e.jsx("p",{className:"text-muted-foreground",style:{fontSize:"15px"},children:"No videos in this category yet."})}),x.length>0&&e.jsxs("div",{className:"mb-5",children:[e.jsx("div",{className:"bg-secondary px-3 py-2 mb-3",children:e.jsx("p",{className:"text-white font-bold uppercase text-xs tracking-wide",children:"Videos"})}),e.jsx("div",{className:"flex flex-col divide-y divide-border border border-border",children:x.map(v=>e.jsxs(O,{to:`/live/${v.slug}`,className:"flex gap-3 px-4 py-4 bg-card hover:bg-muted transition-colors",children:[v.thumbnailUrl&&e.jsx("div",{className:"shrink-0 w-[120px] h-[80px] overflow-hidden bg-muted",children:e.jsx("img",{src:v.thumbnailUrl,alt:v.title,width:120,height:80,className:"w-full h-full object-cover",loading:"lazy"})}),e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsxs("div",{className:"flex items-center gap-2 mb-1",children:[e.jsx("span",{className:"inline-block bg-secondary text-white text-[10px] font-bold uppercase px-1.5 py-0.5 rounded",children:v.isArchived?"Archive":"Video"}),e.jsx("h2",{className:"font-bold text-accent hover:underline",style:{fontSize:"15px",lineHeight:"21px"},children:v.title})]}),e.jsxs("p",{className:"text-muted-foreground mb-1",style:{fontSize:"12px"},children:[Gz(v.startAt,v.title),v.location?` · ${v.location}`:""]}),v.description&&e.jsx("p",{className:"text-foreground",style:{fontSize:"13px",lineHeight:"19px"},children:v.description}),v.providedBy&&e.jsxs("p",{className:"text-muted-foreground mt-1",style:{fontSize:"12px"},children:["Provided by"," ",v.providerLink?e.jsxs("a",{href:v.providerLink,target:"_blank",rel:"noopener noreferrer",className:"text-accent hover:underline inline-flex items-center gap-0.5",onClick:w=>w.stopPropagation(),children:[v.providedBy," ",e.jsx(dt,{size:10})]}):v.providedBy]})]})]},v.id))})]}),p.length>0&&e.jsx("div",{className:"flex flex-col divide-y divide-border border border-border mb-5",children:p.map(v=>e.jsxs("a",{href:v.href,target:"_blank",rel:"noopener noreferrer",className:"flex gap-3 px-4 py-4 bg-card hover:bg-muted transition-colors",children:[v.thumbnail?e.jsx("div",{className:"shrink-0 w-[120px] h-[80px] overflow-hidden bg-muted",children:e.jsx("img",{src:v.thumbnail,alt:v.title,width:120,height:80,className:"w-full h-full object-cover",loading:"lazy"})}):null,e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("h2",{className:"font-bold text-accent hover:underline mb-1",style:{fontSize:"16px",lineHeight:"22px"},children:v.title}),e.jsx("p",{className:"text-muted-foreground mb-1",style:{fontSize:"13px",lineHeight:"18px"},children:v.date}),e.jsx("p",{className:"text-foreground",style:{fontSize:"14px",lineHeight:"21px"},children:v.excerpt})]})]},v.id))}),e.jsx("div",{className:"mb-4",children:e.jsx(O,{to:"/news",className:"text-accent text-sm hover:underline",children:"← All News & Articles"})})]}),e.jsxs("div",{className:"w-full lg:w-[340px] shrink-0 flex flex-col gap-4",children:[e.jsx(zs,{placement:"sidebar-category"}),e.jsx(O,{to:"/",className:"block w-full text-center text-white font-bold uppercase py-2 text-sm bg-secondary hover:opacity-90 transition-opacity",children:"← Back to Home"}),e.jsx(O,{to:"/watch-live-events",className:"block w-full text-center text-white font-bold uppercase py-3 text-base bg-primary hover:bg-primary/90 transition-colors",children:"WATCH LIVE EVENTS"}),e.jsx(Cr,{placement:"sidebar-category-220"}),e.jsxs("div",{className:"border border-border p-4 bg-card",children:[e.jsx("p",{className:"font-bold text-foreground mb-3 border-b border-border pb-2",style:{fontSize:"14px"},children:"Top Categories"}),e.jsx("div",{className:"flex flex-col gap-2",children:Yz.filter(v=>
640v.label!==t).map(v=>e.jsxs(O,{to:v.href,className:"text-accent text-sm hover:underline",children:["→ ",v.label]},v.href))})]})]})]})})})}const V2=Ps,Zz=V2.articles.filter(t=>(t.category??"")==="Horse Health").map(({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d})=>({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d}));function Jz(){return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Horse Health – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Horse health articles, care tips, and equine wellness resources from Total Horse Channel."}),e.jsx("link",{rel:"canonical",href:"https://totalhorsechannel.com/category/horse-health"})]}),e.jsx("h1",{className:"sr-only",children:"Horse Health"}),e.jsx(Ks,{category:"Horse Health",slug:"horse-health",heroImage:"/airo-assets/images/breeds/arabian",articles:Zz,sidebarBanners:V2.SIDEBAR_BANNERS})]})}const F2=Ps,Xz=F2.articles.filter(t=>(t.category??"")==="How To Videos").map(({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d})=>({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d}));function Qz(){return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"How To Videos – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"How-to horse videos covering training, care, riding techniques, and more from Total Horse Channel."}),e.jsx("link",{rel:"canonical",href:"https://totalhorsechannel.com/category/how-to-videos"})]}),e.jsx("h1",{className:"sr-only",children:"How To Videos"}),e.jsx(Ks,{category:"How To Videos",slug:"how-to-videos",heroImage:"/airo-assets/images/disciplines/trail",articles:Xz,sidebarBanners:F2.SIDEBAR_BANNERS})]})}const W2=Ps,eR=W2.articles.filter(t=>(t.category??"")==="Horse Racing").map(({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d})=>({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d}));function tR(){return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Horse Racing – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Horse racing news, race previews, results, and betting analysis from Total Horse Channel."}),e.jsx("link",{rel:"canonical",href:"https://totalhorsechannel.com/category/horse-racing"})]}),e.jsx("h1",{className:"sr-only",children:"Horse Racing"}),e.jsx(Ks,{category:"Horse Racing",slug:"horse-racing",heroImage:"/airo-assets/images/breeds/thoroughbred",articles:eR,sidebarBanners:W2.SIDEBAR_BANNERS})]})}const q2=Ps,sR=q2.articles.filter(t=>(t.category??"")==="Harness Racing").map(({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d})=>({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d}));function aR(){return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Harness Racing – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Harness racing news, race previews, results, and coverage from Total Horse Channel."}),e.jsx("link",{rel:"canonical",href:"https://totalhorsechannel.com/category/harness-racing"})]}),e.jsx("h1",{className:"sr-only",children:"Harness Racing"}),e.jsx(Ks,{category:"Harness Racing",slug:"harness-racing",heroImage:"/airo-assets/images/disciplines/harness-racing",articles:sR,sidebarBanners:q2.SIDEBAR_BANNERS})]})}const Y2=Ps,nR=Y2.articles.filter(t=>(t.category??"")==="Show Jumping").map(({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d})=>({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d}));function rR(){return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Show Jumping – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Show jumping videos, competition coverage, and news from Total Horse Channel."}),e.jsx("link",{rel:"canonical",href:"https://totalhorsechannel.com/category/show-jumping"})]}),e.jsx("h1",{className:"sr-only",children:"Show Jumping"}),e.jsx(Ks,{category:"Show Jumping",slug:"show-jumping",heroImage:"/airo-assets/images/disciplines/show-jumping",articles:nR,sidebarBanners:Y2.SIDEBAR_BANNERS})]})}const G2=Ps,iR=G2.articles.filter(t=>(t.category??"")==="Quarter Horse").map(({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d})=>({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d}));function oR(){return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Quarter Horse – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Quarter Horse videos, news, and breed 
640information from Total Horse Channel."}),e.jsx("link",{rel:"canonical",href:"https://totalhorsechannel.com/category/quarter-horse"})]}),e.jsx("h1",{className:"sr-only",children:"Quarter Horse"}),e.jsx(Ks,{category:"Quarter Horse",slug:"quarter-horse",heroImage:"/airo-assets/images/breeds/american-quarter-horse",articles:iR,sidebarBanners:G2.SIDEBAR_BANNERS})]})}const Z2=Ps,lR=Z2.articles.filter(t=>(t.category??"")==="Cutting Horse").map(({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d})=>({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d}));function cR(){return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Cutting Horse – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Cutting horse videos, competition coverage, and news from Total Horse Channel."}),e.jsx("link",{rel:"canonical",href:"https://totalhorsechannel.com/category/cutting-horse"})]}),e.jsx("h1",{className:"sr-only",children:"Cutting Horse"}),e.jsx(Ks,{category:"Cutting Horse",slug:"cutting-horse",heroImage:"/airo-assets/images/disciplines/cutting",articles:lR,sidebarBanners:Z2.SIDEBAR_BANNERS})]})}const J2=Ps,dR=J2.articles.filter(t=>(t.category??"")==="Campdraft").map(({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d})=>({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d})),Hm="https://totalhorsechannel.com/category/campdraft",Lu="Campdraft – Total Horse Channel",Du="Campdraft videos, competition coverage, and news from Total Horse Channel. Watch Australian stockhorse and campdraft events.",Ox="https://totalhorsechannel.com/airo-assets/images/logo/horizontal",uR={"@context":"https://schema.org","@type":"CollectionPage","@id":`${Hm}#webpage`,name:Lu,description:Du,url:Hm,image:Ox,isPartOf:{"@id":"https://totalhorsechannel.com/#website"},about:{"@id":"https://totalhorsechannel.com/#organization"}};function mR(){return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:Lu}),e.jsx("meta",{name:"description",content:Du}),e.jsx("link",{rel:"canonical",href:Hm}),e.jsx("meta",{property:"og:title",content:Lu}),e.jsx("meta",{property:"og:description",content:Du}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{property:"og:url",content:Hm}),e.jsx("meta",{property:"og:image",content:Ox}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("meta",{name:"twitter:title",content:Lu}),e.jsx("meta",{name:"twitter:description",content:Du}),e.jsx("meta",{name:"twitter:image",content:Ox}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify(uR).replace(/</g,"\\u003c")})]}),e.jsx("h1",{className:"sr-only",children:"Campdraft"}),e.jsx(Ks,{category:"Campdraft",slug:"campdraft",heroImage:"/airo-assets/images/disciplines/campdraft",articles:dR,sidebarBanners:J2.SIDEBAR_BANNERS})]})}const X2=Ps,hR=X2.articles.filter(t=>(t.category??"")==="Reined Cow Horse").map(({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d})=>({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d}));function pR(){return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Reined Cow Horse – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Reined cow horse videos, competition coverage, and news from Total Horse Channel."}),e.jsx("link",{rel:"canonical",href:"https://totalhorsechannel.com/category/reined-cow-horse"})]}),e.jsx("h1",{className:"sr-only",children:"Reined Cow Horse"}),e.jsx(Ks,{category:"Reined Cow Horse",slug:"reined-cow-horse",heroImage:"/airo-assets/images/disciplines/cutting",articles:hR,sidebarBanners:X2.SIDEBAR_BANNERS})]})}const Q2=Ps,fR=Q2.articles.filter(t=>(t.category??"")==="Eventing").map(({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d})=>({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d}));function xR(){return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Eventing – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Eventing videos, three-day event coverage, and competition news from Total Horse Channel."}),e.jsx("link",{rel:"canonical",href:"https://totalhorsechannel.com/category/eventing"})]}),e.jsx("h1",{className:"sr-only",children:"Eventing"}),e.jsx(Ks,{category:"Eventing",slug:"eventing",heroImage:"/airo-assets/images/disciplines/eventing",articles:fR,sidebarBanners:Q2.SIDEBAR_BANNERS})]})}const eN=Ps,gR=eN.articles.filter(t=>
640(t.category??"")==="Reining").map(({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d})=>({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d}));function bR(){const a=ai.contestBanner.status==="current";return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Reining – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Reining videos, sliding stop competition coverage, and news from Total Horse Channel."}),e.jsx("link",{rel:"canonical",href:"https://totalhorsechannel.com/category/reining"})]}),e.jsx("h1",{className:"sr-only",children:"Reining"}),e.jsx(Ks,{category:"Reining",slug:"reining",heroImage:"/airo-assets/images/disciplines/reining",articles:gR,sidebarBanners:eN.SIDEBAR_BANNERS,contestSlot:e.jsxs("div",{className:`border-2 rounded-sm overflow-hidden ${a?"border-primary":"border-secondary"}`,children:[e.jsxs("div",{className:`px-4 py-2.5 flex items-center gap-3 flex-wrap ${a?"bg-primary":"bg-secondary"}`,children:[e.jsx(Xs,{size:15,className:"text-white shrink-0"}),e.jsx("span",{className:"text-white font-bold text-sm",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"166af4",guard:{file:"src/pages/category/reining.tsx",tagName:"span",sourceKind:"content-key",contentKey:"category_reining.contestBanner.title",contentKeyTemplate:null,expressionHash:null},children:ai.contestBanner.title})}),a?e.jsx("span",{className:"ml-auto text-white text-xs opacity-80 font-semibold",children:"Submissions open now"}):e.jsxs("span",{className:"ml-auto text-white text-xs opacity-80",children:["Opens ",ai.contestBanner.opensLabel]})]}),e.jsxs("div",{className:"bg-card px-4 py-4",children:[e.jsxs("div",{className:"flex flex-wrap gap-x-6 gap-y-1 mb-3 text-xs text-muted-foreground border-b border-border pb-3",children:[e.jsxs("span",{className:a?"text-primary font-semibold":"",children:[e.jsx(Ms,{size:11,className:"inline mr-1 -mt-0.5"}),"Submissions: ",e.jsx("strong",{children:ai.contestBanner.submissionDates})]}),e.jsxs("span",{children:["Voting: ",e.jsx("strong",{children:ai.contestBanner.votingDates})]}),e.jsxs("span",{children:["Prize: ",e.jsx("strong",{children:ai.contestBanner.prize})]})]}),e.jsxs("p",{className:"text-sm text-foreground mb-3",children:["The winning photo becomes the official ",e.jsx("strong",{children:"Reining category image"})," on TotalHorseChannel.com for one year. Winner also receives a ",e.jsx("strong",{children:ai.contestBanner.prize}),"."]}),e.jsx(O,{to:`/contests${ai.contestBanner.contestAnchor}`,className:"inline-flex items-center gap-1.5 bg-primary text-white text-xs font-bold uppercase px-4 py-2 hover:opacity-90 transition-opacity",children:a?"Enter contest →":"View contest details →"})]})]})})]})}const tN=Ps,yR=tN.articles.filter(t=>(t.category??"")==="Western Dressage").map(({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d})=>({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d}));function vR(){const t=vn.contestBanner,a=t.status==="closed",r=t.status==="current";return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Western Dressage – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Western dressage news, competition coverage, training tips, and event videos from Total Horse Channel."}),e.jsx("link",{rel:"canonical",href:"https://totalhorsechannel.com/category/western-dressage"})]}),e.jsx("h1",{className:"sr-only",children:"Western Dressage"}),e.jsx(Ks,{category:"Western Dressage",slug:"western-dressage",heroImage:"/airo-assets/images/disciplines/western-dressage",articles:yR,sidebarBanners:tN.SIDEBAR_BANNERS,contestSlot:e.jsxs("div",{className:"border-2 border-primary rounded-sm overflow-hidden",children:[e.jsxs("div",{className:"bg-primary px-4 py-2.5 flex items-center gap-3 flex-wrap",children:[e.jsx(Xs,{size:15,className:"text-white shrink-0"}),e.jsx("span",{className:"text-white font-bold text-sm",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"fbfb2b",guard:{file:"src/pages/category/western-dressage.tsx",tagName:"span",sourceKind:"content-key",contentKey:"category_western_dressage.contestBanner.title",contentKeyTemplate:null,expressionH
640ash:null},children:vn.contestBanner.title})}),a&&e.jsx("span",{className:"ml-auto text-white text-xs font-semibold opacity-90",children:"Voting Closed"}),r&&e.jsx("span",{className:"ml-auto text-white text-xs opacity-80 font-semibold",children:"Submissions open now"})]}),e.jsx("div",{className:"bg-card px-4 py-4",children:a?e.jsxs(e.Fragment,{children:[e.jsxs("div",{className:"flex items-start gap-3 mb-3",children:[e.jsx(Xs,{size:16,className:"text-primary shrink-0 mt-0.5"}),e.jsxs("div",{children:[e.jsxs("p",{className:"text-sm font-bold text-foreground",children:["Winner: ",e.jsx("span",{className:"text-primary",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"9bc935",guard:{file:"src/pages/category/western-dressage.tsx",tagName:"span",sourceKind:"content-key",contentKey:"category_western_dressage.contestBanner.winner",contentKeyTemplate:null,expressionHash:null},children:vn.contestBanner.winner})})," ","— ",e.jsx("span",{style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"9bc936",guard:{file:"src/pages/category/western-dressage.tsx",tagName:"span",sourceKind:"content-key",contentKey:"category_western_dressage.contestBanner.winnerOwner",contentKeyTemplate:null,expressionHash:null},children:vn.contestBanner.winnerOwner})})]}),e.jsx("p",{className:"text-xs text-muted-foreground mt-0.5",children:"Their photo is now the Western Dressage category icon on TotalHorseChannel.com for one year."}),e.jsxs("p",{className:"text-xs text-muted-foreground mt-0.5",children:["Prize: ",e.jsx("strong",{children:vn.contestBanner.prize})," — we'll email the winner."]}
640),e.jsx("p",{className:"text-xs text-muted-foreground mt-0.5",children:"Thank you to everyone who entered and voted!"})]})]}),e.jsx(O,{to:`/contests${vn.contestBanner.contestAnchor}`,className:"inline-flex items-center gap-1.5 bg-primary text-white text-xs font-bold uppercase px-4 py-2 hover:opacity-90 transition-opacity",children:"View Final Results →"})]}):e.jsxs(e.Fragment,{children:[e.jsxs("div",{className:"flex flex-wrap gap-x-6 gap-y-1 mb-3 text-xs text-muted-foreground border-b border-border pb-3",children:[e.jsxs("span",{className:r?"text-primary font-semibold":"",children:[e.jsx(Ms,{size:11,className:"inline mr-1 -mt-0.5"}),"Submissions: ",e.jsx("strong",{children:vn.contestBanner.submissionDates})]}),e.jsxs("span",{children:["Voting: ",e.jsx("strong",{children:vn.contestBanner.votingDates})]}),e.jsxs("span",{children:["Prize: ",e.jsx("strong",{children:vn.contestBanner.prize})]})]}),e.jsxs("p",{className:"text-sm text-foreground mb-3",children:["The winning photo becomes the official ",e.jsx("strong",{children:"Western Dressage category image"})," on TotalHorseChannel.com for one year. Winner also receives a ",e.jsx("strong",{children:vn.contestBanner.prize}),"."]}),e.jsx(O,{to:`/contests${vn.contestBanner.contestAnchor}`,className:"inline-flex items-center gap-1.5 bg-primary text-white text-xs font-bold uppercase px-4 py-2 hover:opacity-90 transition-opacity",children:r?"Enter contest →":"View contest details →"})]})})]})})]})}const sN=Ps,jR=sN.articles.filter(t=>(t.category??"")==="Campolina").map(({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d})=>({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d}));function wR(){return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Campolina – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Campolina horse breed videos, news, and events on Total Horse Channel."}),e.jsx("link",{rel:"canonical",href:"https://totalhorsechannel.com/category/campolina"})]}),e.jsx("h1",{className:"sr-only",children:"Campolina"}),e.jsx(Ks,{category:"Campolina",slug:"campolina",heroImage:"/airo-assets/images/breeds/campolina",imageCreditUrl:"https://www.pinterest.com/pin/176836722867913116/",imageCreditLabel:"Pinterest",breedDescription:"The Campolina is a Brazilian gaited horse breed developed in the state of Minas Gerais during the late 19th century. Known for its smooth, four-beat marcha gait, gentle temperament, and impressive size, the Campolina is one of Brazil's most beloved native breeds. It is widely used for pleasure riding, trail work, and light farm duties, and is celebrated for its elegance, endurance, and calm disposition.",learnMoreUrl:"https://chevauxdumonde.com/en/horse/campolina",articles:jR,sidebarBanners:sN.SIDEBAR_BANNERS})]})}const aN=Ps,NR=aN.articles.filter(t=>(t.category??"")==="Rocky Mountain Horse").map(({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d})=>({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d}));function SR(){return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Rocky Mountain Horse – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Rocky Mountain Horse breed videos, news, and events on Total Horse Channel."}),e.jsx("link",{rel:"canonical",href:"https://totalhorsechannel.com/category/rocky-mountain-horse"}),e.jsx("meta",{property:"og:title",content:"Rocky Mountain Horse – Total Horse Channel"}),e.jsx("meta",{property:"og:description",content:"Rocky Mountain Horse breed videos, news, and events on Total Horse Channel."}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{property:"og:url",content:"https://totalhorsechannel.com/category/rocky-mountain-horse"}),e.jsx("meta",{property:"og:image",content:"https://totalhorsechannel.com/airo-assets/images/breeds/rocky-mountain-horse"}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("meta",{name:"twitter:title",content:"Rocky Mountain Horse – Total Horse Channel"}),e.jsx("meta",{name:"twitter:description",content:"Rocky Mountain Horse breed videos, news, and events on Total Horse Channel."}),e.jsx("meta",{name:"twitter:image",content:"https://totalhorsechannel.com/airo-assets/images/breeds/rocky-mountain-horse"})]}),e.jsx("h1",{className:"sr-only",children:"Rocky Mountain Horse"}),e.jsx(Ks,{category:"Rocky Mountain Horse",slug:"rocky-mountain-horse",heroImage:"/airo-assets/images/breeds/rocky-mountain-horse",imageCreditUrl:"https://pin.it/3hOYMmFrz",imageCreditLabel:"Pinterest",breedDescription:"The Rocky Mountain Horse is a gaited breed that originated in the Appalachian Mountains of eastern Kentucky. Known for its distinctive chocolate coat with a flaxen mane and tail, the breed is celebrated for its smooth, ambling four-beat gait that makes it exceptionally comfortable to ride over long distances. Rocky Mountain Horses are prized for their gentle, willing temperament, sure-footedness on mountain terrain, and hardiness in cold climates.",learnMoreUrl:"https://www.rmhorse.com",articles:NR,sidebarBanners:aN.SIDEBAR_BANNERS})]})}const nN=Ps,CR=nN.articles.filter(t=>(t.category??"")==="Cavalo Crioulo").map(({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d})=>({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d}));function kR(){return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Cavalo Crioulo – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Cavalo Crioulo breed videos, news, and events on Total Horse Channel."}),e.jsx("link",{rel:"canonical",href:"https://totalhorsechannel.com/category/cavalo-crioulo"})]}),e.jsx("h1",{className:"sr-only",children:"Cavalo Crioulo"}),e.jsx(Ks,{category:"Cavalo Crioulo",slug:"cavalo-crioulo",articles:CR,sidebarBanners:nN.SIDEBAR_BANNERS})]})}const rN=Ps,TR=rN.articles.filter(t=>(t.category??"")==="Horse Sale").map(({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d})=>({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d}));function AR(){return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Horse Sale – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Horse sale videos, listings, and auction coverage on Total Horse Channel."}),e.jsx("link",{rel:"canonical",href:"https://totalhorsechannel.com/category/horse-sale"})]}),e.jsx("h1",{className:"sr-only",children:"Horse Sale"}),e.jsx(Ks,{category:"Horse Sale",slug:"horse-sale",articles:TR,sidebarBanners:rN.SIDEBAR_BANNERS})]})}const iN=Ps,ER=iN.articles.filter(t=>(t.category??"")==="Podcast").map(({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d})=>({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d}));function HR(){return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Podcast – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Equestrian podcasts, interviews, and audio content on Total Horse Channel."}),e.jsx("link",{rel:"canonical",href:"https://totalhorsechannel.com/category/podcast"})]}),e.jsx("h1",{className:"sr-only",children:"Podcast"}),e.jsx(Ks,{category:"Podcast",slug:"podcast",articles:ER,sidebarBanners:iN.SIDEBAR_BANNERS})]})}const oN=Ps,zR=oN.articles.filter(t=>(t.category??"")==="Other / General").map(({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d})=>({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d}));function RR(){return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Other / General – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"General horse industry videos and content that doesn't fit a specific breed or discipline — Total Horse Channel."}),e.jsx("link",{rel:"canonical",href:"https://totalhorsechannel.com/category/other
640-general"})]}),e.jsx("h1",{className:"sr-only",children:"Other / General"}),e.jsx(Ks,{category:"Other / General",slug:"other-general",articles:zR,sidebarBanners:oN.SIDEBAR_BANNERS})]})}const lN=Ps,_R=lN.articles.filter(t=>(t.category??"")==="Miniature Horse").map(({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d})=>({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d}));function LR(){const a=si.contestBanner.status==="current";return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Miniature Horse – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Miniature horse videos, show coverage, and news from Total Horse Channel."}),e.jsx("link",{rel:"canonical",href:"https://totalhorsechannel.com/category/miniature-horse"})]}),e.jsx("h1",{className:"sr-only",children:"Miniature Horse"}),e.jsx(Ks,{category:"Miniature Horse",slug:"miniature-horse",heroImage:"/airo-assets/images/breeds/miniature-horse",articles:_R,sidebarBanners:lN.SIDEBAR_BANNERS,contestSlot:e.jsxs("div",{className:`border-2 rounded-sm overflow-hidden ${a?"border-primary":"border-secondary"}`,children:[e.jsxs("div",{className:`px-4 py-2.5 flex items-center gap-3 flex-wrap ${a?"bg-primary":"bg-secondary"}`,children:[e.jsx(Xs,{size:15,className:"text-white shrink-0"}),e.jsx("span",{className:"text-white font-bold text-sm",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"3a2b64",guard:{file:"src/pages/category/miniature-horse.tsx",tagName:"span",sourceKind:"content-key",contentKey:"category_miniature_horse.contestBanner.title",contentKeyTemplate:null,expressionHash:null},children:si.contestBanner.title})}),a?e.jsx("span",{className:"ml-auto text-white text-xs opacity-80 font-semibold",children:"Submissions open now"}):e.jsxs("span",{className:"ml-auto text-white text-xs opacity-80",children:["Opens ",si.contestBanner.opensLabel]})]}),e.jsxs("div",{className:"bg-card px-4 py-4",children:[e.jsxs("div",{className:"flex flex-wrap gap-x-6 gap-y-1 mb-3 text-xs text-muted-foreground border-b border-border pb-3",children:[e.jsxs("span",{className:a?"text-primary font-semibold":"",children:[e.jsx(Ms,{size:11,className:"inline mr-1 -mt-0.5"}),"Submissions: ",e.jsx("strong",{children:si.contestBanner.submissionDates})]}),e.jsxs("span",{children:["Voting: ",e.jsx("strong",{children:si.contestBanner.votingDates})]}),e.jsxs("span",{children:["Prize: ",e.jsx("strong",{children:si.contestBanner.prize})]})]}),e.jsxs("p",{className:"text-sm text-foreground mb-3",children:["The winning photo becomes the official ",e.jsx("strong",{children:"Miniature Horse category image"})," on TotalHorseChannel.com for one year. Winner also receives a ",e.jsx("strong",{children:si.contestBanner.prize}),"."]}),e.jsx(O,{to:`/contests${si.contestBanner.contestAnchor}`,className:"inline-flex items-center gap-1.5 bg-primary text-white text-xs font-bold uppercase px-4 py-2 hover:opacity-90 transition-opacity",children:a?"Enter contest →":"View contest details →"})]})]})})]})}const cN=Ps,DR=cN.articles.filter(t=>(t.category??"")==="Horse Music Videos").map(({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d})=>({id:t,title:a,excerpt:r,date:o,href:l,thumbnail:d}));function OR(){const a=$i.contestBanner.status==="current";return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Horse Music Videos – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Horse music videos, equestrian creative content, and the Horse Music Video Contest on Total Horse Channel."}),e.jsx("link",{rel:"canonical",href:"https://totalhorsechannel.com/category/horse-music-videos"})]}),e.jsx("h1",{className:"sr-only",children:"Horse Music Videos"}),e.jsx(Ks,{category:"Horse Music Videos",slug:"horse-music-videos",articles:DR,sidebarBanners:cN.SIDEBAR_BANNERS,contestSlot:e.jsxs("div",{className:"border-2 border-primary rounded-sm overflow-hidden",children:[e.jsxs("div",{className:"bg-primary px-4 py-2.5 flex items-center gap-3 flex-wrap",children:[e.jsx(og,{size:15,className:"text-white shrink-0"}),e.jsx("span",{className:"text-white font-bold text-sm",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"0b0aae",guard:{file:"src/pages/category/horse-music-videos.tsx",tagName:"span",sourceKind:"content-key",contentKey:"category_horse_music_videos.contestBanner.title",contentKeyTemplate:null,expressionH
640ash:null},children:$i.contestBanner.title})}),a&&e.jsx("span",{className:"ml-auto text-white text-xs opacity-80 font-semibold",children:"Entries open now"})]}),e.jsxs("div",{className:"bg-card px-4 py-4",children:[e.jsxs("div",{className:"flex flex-wrap gap-x-6 gap-y-1 mb-3 text-xs text-muted-foreground border-b border-border pb-3",children:[e.jsxs("span",{className:"text-primary font-semibold",children:[e.jsx(Ms,{size:11,className:"inline mr-1 -mt-0.5"}),e.jsx("strong",{children:$i.contestBanner.submissionDates})]}),e.jsxs("span",{children:["Voting: ",e.jsx("strong",{children:$i.contestBanner.votingDates})]}),e.jsxs("span",{children:["Prize: ",e.jsx("strong",{children:$i.contestBanner.prize})]})]}),e.jsxs("p",{className:"text-sm text-foreground mb-3",children:["Submit your best horse music video for a chance to win a ",e.jsx("strong",{children:$i.contestBanner.prize}),". Entries accepted via Rumble or YouTube."]}),e.jsx(O,{to:`/contests${$i.contestBanner.contestAnchor}`,className:"inline-flex items-center gap-1.5 bg-primary text-white text-xs font-bold uppercase px-4 py-2 hover:opacity-90 transition-opacity",children:"Enter contest →"})]})]})})]})}const Mx="https://totalhorsechannel.com",zm=`${Mx}/shop/the-horse-capital-tours`,MR={"@context":"https://schema.org","@type":"WebPage","@id":`${zm}#webpage`,name:"The Horse Capital Tours – Total Horse Channel",url:zm,isPartOf:{"@id":`${Mx}/#website`},about:{"@id":`${Mx}/#organization`}};function UR(){return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"The Horse Capital Tours – Total Horse Channel"}),e.jsx("meta",{name:"description",content:ni.metaDescription}),e.jsx("link",{rel:"canonical",href:zm}),e.jsx("meta",{property:"og:title",content:"The Horse Capital Tours – Total Horse Channel"}),e.jsx("meta",{property:"og:description",content:ni.metaDescription}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{property:"og:url",content:zm}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify(MR)})]}),e.jsx("main",{children:e.jsx("div",{className:"max-w-[1280px] mx-auto px-4 py-4",children:e.jsxs("div",{className:"flex flex-col lg:flex-row gap-6",children:[e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("div",{className:"bg-primary px-3 py-2 mb-4",children:e.jsx("h1",{className:"text-white font-bold uppercase text-sm tracking-wide",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"d42d01",guard:{file:"src/pages/shop/the-horse-capital-tours.tsx",tagName:"h1",sourceKind:"content-key",contentKey:"horse_capital_tours.pageTitle",contentKeyTemplate:null,expressionHash:null},children:ni.pageTitle})})}),e.jsxs("div",{className:"mb-5 border border-border rounded p-5 bg-card",children:[e.jsxs("div",{className:"flex items-start gap-4 mb-4",children:[e.jsx("img",{src:"/airo-assets/images/sponsors/horse-capital-tours",alt:"The Horse Capital Tours logo",width:80,height:80,className:"w-20 h-20 object-contain rounded shrink-0 bg-muted p-1",loading:"eager"}),e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("h2",{className:"font-bold text-foreground leading-snug mb-1",style:{whiteSpace:"pre-line",fontSize:"22px"},children:e.jsx(_,{devId:"21c58b",guard:{file:"src/pages/shop/the-horse-capital-tours.tsx",tagName:"h2",sourceKind:"content-key",contentKey:"horse_capital_tours.intro.heading",contentKeyTemplate:null,expressionHash:null},children:ni.intro.heading})}),e.jsxs("div",{className:"flex items-center gap-1 text-muted-foreground text-sm",children:[e.jsx(ul,{size:13}),e.jsx("span",{children:"Ocala, Florida — The Horse Capital of the World"})]})]})]}),e.jsxs("div",{className:"flex flex-col gap-3",children:[e.jsx("p",{className:"text-foreground leading-relaxed",style:{whiteSpace:"pre-line",fontSize:"15px"},children:e.jsx(_,{devId:"082bce",guard:{file:"src/pages/shop/the-horse-capital-tours.tsx",tagName:"p",sourceKind:"content-key",contentKey:"horse_capital_tours.intro.paragraphs[0]",contentKeyTemplate:null,expressionHash:null},children:ni.intro.paragraphs[0]})}),e.jsx("p",{className:"text-foreground leading-relaxed",style:{whiteSpace:"pre-line",fontSize:"15px"},children:e.jsx(_,{devId:"082bcf",guard:{file:"src/pages/shop/the-horse-capital-tours.tsx",tagName:"p",sourceKind:"content-key",contentKey:"horse_capital_tours.intro.paragraphs[1]",contentKeyTemplate:null,expressionH
640ash:null},children:ni.intro.paragraphs[1]})}),e.jsxs("p",{className:"text-foreground leading-relaxed",style:{fontSize:"15px"},children:["To view current tour offerings, availability, and booking information, visit the official"," ",e.jsx("a",{href:"https://thehorsecapitaltours.com",target:"_blank",rel:"noopener noreferrer",className:"text-primary underline hover:opacity-80 transition-opacity",children:"The Horse Capital Tours website"}),". All tour bookings and inquiries are handled directly through"," ",e.jsx("a",{href:"https://thehorsecapitaltours.com",target:"_blank",rel:"noopener noreferrer",className:"text-primary underline hover:opacity-80 transition-opacity",children:"The Horse Capital Tours"}),"."]})]})]}),e.jsxs("div",{className:"mb-5 border border-border rounded overflow-hidden bg-card",children:[e.jsx("div",{className:"bg-secondary px-3 py-2",children:e.jsx("p",{className:"text-white font-bold uppercase text-xs tracking-wide",children:"Featured Video"})}),e.jsx("div",{className:"aspect-video",children:e.jsx("iframe",{src:"https://www.youtube.com/embed/EnHtBYgCrzo?si=U9VtjLmRzKhVeD_-",title:"YouTube video player",frameBorder:"0",allow:"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share",referrerPolicy:"strict-origin-when-cross-origin",allowFullScreen:!0,className:"w-full h-full",loading:"lazy"})})]}),e.jsxs("div",{className:"border border-border rounded p-6 bg-card text-center",children:[e.jsx("p",{className:"text-foreground font-semibold mb-4",style:{fontSize:"16px"},children:"Ready to visit the Horse Capital of the World?"}),e.jsxs("a",{href:ni.bookingButton.href,target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-2 bg-primary text-white font-bold px-8 py-3 rounded hover:bg-primary/90 transition-colors",style:{fontSize:"15px"},children:[ni.bookingButton.label,e.jsx(dt,{size:15})]}),e.jsx("p",{className:"text-muted-foreground text-xs mt-3",children:"Opens thehorsecapitaltours.com — all bookings handled directly through The Horse Capital Tours."})]})]}),e.jsxs("aside",{className:"w-full lg:w-[340px] shrink-0 flex flex-col gap-4",children:[e.jsx(zs,{placement:"sidebar-horse-capital-tours"}),e.jsx(O,{to:"/watch-live-events",className:"block bg-primary text-white text-center font-bold uppercase py-3 px-4 text-sm tracking-wide hover:bg-primary/90 transition-colors",children:"Watch Live Events"}),e.jsx(O,{to:"/",className:"block bg-secondary text-white text-center font-bold uppercase py-3 px-4 text-sm tracking-wide hover:opacity-90 transition-opacity",children:"← Back to Home"}),e.jsx(O,{to:"/mission",className:"block w-full text-center font-bold uppercase py-2 text-sm bg-gray-200 text-gray-800 hover:bg-gray-300 transition-colors",children:"Our Mission"}),e.jsxs("div",{className:"border border-border p-4 text-center",children:[e.jsx("p",{className:"font-bold text-foreground mb-1",style:{fontSize:"14px"},children:"Advertise With Us"}),e.jsx("p",{className:"text-muted-foreground text-xs mb-3",children:"Reach thousands of horse enthusiasts. Request our media kit today."}),e.jsx(O,{to:"/advertise",className:"inline-block bg-primary text-white text-xs font-bold uppercase px-4 py-2 hover:bg-primary/90 transition-colors",children:"Learn More"})]})]})]})})})]})}const Ux="https://totalhorsechannel.com",Rm=`${Ux}/shop/debbie-brooks-equestrian-collection`,PR={"@context":"https://schema.org","@type":"WebPage","@id":`${Rm}#webpage`,name:"Debbie Brooks Equestrian Collection – Total Horse Channel",url:Rm,isPartOf:{"@id":`${Ux}/#website`},about:{"@id":`${Ux}/#organization`}};function KR(){return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Debbie Brooks Equestrian Collection – Total Horse Channel"}),e.jsx("meta",{name:"description",content:Vi.metaDescription}),e.jsx("link",{rel:"canonical",href:Rm}),e.jsx("meta",{property:"og:title",content:"Debbie Brooks Equestrian Collection – Total Horse Channel"}),e.jsx("meta",{property:"og:description",content:Vi.metaDescription}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{property:"og:url",content:Rm}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify(PR)})]}),e.jsx("main",{children:e.jsx("div",{className:"max-w-[1280px] mx-auto px-4 py-4",children:e.jsxs("div",{className:"flex flex-col lg:flex-row gap-6",children:[e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsx("div",{className:"bg-primary px-3 py-2 mb-4",children:e.jsx("h1",{className:"text-white font-bold uppercase text-sm tracking-wide",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"42545c",guard:{file:"src/pages/shop/debbie-brooks-equestrian-collection.tsx",tagName:"h1",sourceKind:"content-key",contentKey:"debbie_brooks.pageTitle",contentKeyTemplate:null,expressionH
640ash:null},children:Vi.pageTitle})})}),e.jsxs("div",{className:"mb-5 border border-border rounded p-5 bg-card",children:[e.jsxs("div",{className:"flex items-start gap-4 mb-4",children:[e.jsx("img",{src:"/airo-assets/images/sponsors/debbie-brooks-ny",alt:"Debbie Brooks Equestrian Collection logo",width:80,height:80,className:"w-20 h-20 object-contain rounded shrink-0 bg-muted p-1",loading:"eager"}),e.jsx("div",{className:"flex-1 min-w-0",children:e.jsx("h2",{className:"font-bold text-foreground leading-snug",style:{whiteSpace:"pre-line",fontSize:"22px"},children:e.jsx(_,{devId:"cacd66",guard:{file:"src/pages/shop/debbie-brooks-equestrian-collection.tsx",tagName:"h2",sourceKind:"content-key",contentKey:"debbie_brooks.intro.heading",contentKeyTemplate:null,expressionHash:null},children:Vi.intro.heading})})})]}),e.jsx("p",{className:"text-foreground leading-relaxed",style:{whiteSpace:"pre-line",fontSize:"15px"},children:e.jsx(_,{devId:"04b774",guard:{file:"src/pages/shop/debbie-brooks-equestrian-collection.tsx",tagName:"p",sourceKind:"content-key",contentKey:"debbie_brooks.intro.paragraph",contentKeyTemplate:null,expressionHash:null},children:Vi.intro.paragraph})})]}),e.jsxs("div",{className:"mb-5 border border-border rounded p-6 bg-card text-center",children:[e.jsxs("span",{className:"inline-flex items-center gap-2 bg-primary/50 text-white font-bold px-8 py-3 rounded cursor-not-allowed select-none",style:{fontSize:"15px"},title:"Shop coming soon",children:[Vi.shopButton.label,e.jsx(dt,{size:15})]}),e.jsx("p",{className:"text-muted-foreground text-xs mt-2",children:"Shop coming soon on this site"})]}),e.jsxs("div",{className:"mb-5 border border-border rounded p-5 bg-card",children:[e.jsx("div",{className:"bg-secondary px-3 py-2 -mx-5 -mt-5 mb-4 rounded-t",children:e.jsx("p",{className:"text-white font-bold uppercase text-xs tracking-wide",children:"Browse by Category"})}),e.jsxs("div",{className:"flex flex-wrap gap-2",children:[Vi.categories.map(t=>e.jsx("span",{className:"inline-flex items-center gap-1 border border-border text-muted-foreground font-semibold px-4 py-2 rounded text-sm cursor-not-allowed select-none",title:"Shop coming soon",children:e.jsx("span",{style:{whiteSpace:"pre-line"},children:t.label})},t.id)),!1]}),e.jsx("p",{className:"text-muted-foreground text-xs mt-3",children:"Shop coming soon on this site"})]}),e.jsx("div",{className:"mb-5",children:e.jsx("img",{src:"/airo-assets/images/header/banner-debbie-brooks",alt:"Debbie Brooks Equestrian Collection",width:728,height:90,className:"w-full h-auto object-contain",loading:"lazy"})})]}),e.jsxs("aside",{className:"w-full lg:w-[340px] shrink-0 flex flex-col gap-4",children:[e.jsx(zs,{placement:"sidebar-debbie-brooks"}),e.jsx(O,{to:"/watch-live-events",className:"block bg-primary text-white text-center font-bold uppercase py-3 px-4 text-sm tracking-wide hover:bg-primary/90 transition-colors",children:"Watch Live Events"}),e.jsx(O,{to:"/",className:"block bg-secondary text-white text-center font-bold uppercase py-3 px-4 text-sm tracking-wide hover:opacity-90 transition-opacity",children:"← Back to Home"}),e.jsx(O,{to:"/mission",className:"block w-full text-center font-bold uppercase py-2 text-sm bg-gray-200 text-gray-800 hover:bg-gray-300 transition-colors",children:"Our Mission"}),e.jsxs("div",{className:"border border-border p-4 text-center",children:[e.jsx("p",{className:"font-bold text-foreground mb-1",style:{fontSize:"14px"},children:"Advertise With Us"}),e.jsx("p",{className:"text-muted-foreground text-xs mb-3",children:"Reach thousands of horse enthusiasts. Request our media kit today."}),e.jsx(O,{to:"/advertise",className:"inline-block bg-primary text-white text-xs font-bold uppercase px-4 py-2 hover:bg-primary/90 transition-colors",children:"Learn More"})]})]})]})})})]})}const lw="https://totalhorsechannel.com";function IR(t,a){const r=d=>{const[u,m,p]=d.split("-");return new Date(Number(u),Number(m)-1,Number(p)).toLocaleDateString("en-US",{month:"short",day:"numeric",year:"numeric"})};if(!a||a===t)return r(t);const[o]=t.split("-"),[l]=(a||"").split("-");return o===l?`${new Date(Number(o),Number(t.split("-")[1])-1,Number(t.split("-")[2])).toLocaleDateString("en-US",{month:"short",day:"numeric"})} – ${r(a)}`:`${r(t)} – ${r(a)}`}function BR({ev:t}){var d,u;const a=t.id==="wdaa-2026-world-show",r=((d=t.linkLabel)==null?void 0:d.trim())||null,o=((u=t.buttonLabel)==null?void 0:u.trim())||"Watch on THC",l=r?!r.startsWith("/"):!1;return e.jsxs("article",{className:`border rounded-sm overflow-hidden flex flex-col ${a?"border-primary":"border-border"}`,children:[a&&e.jsx("div",{className:"bg-primary px-4 py-1.5",children:e.jsx("span",{className:"text-white text-xs font-bold uppercase tracking-wide",children:"Featured Event — Live on Total Horse Channel"})}),e.jsxs("div",{className:"p-4 flex flex-col gap-3 flex-1",children:[e.jsxs("div",{className:"flex items-start gap-3",children:[t.logoUrl&&e.jsx("img",{src:t.logoUrl,alt:`${t.title} logo`,className:"h-12 w-12 object-contain rounded shrink-0 border border-border bg-white p-0.5"}),e.jsx("h2",{className:"text-base font-bold text-foreground leading-snug",children:e.jsx(_,{devId:"2fd0c2",guard:{file:"src/pages/events.tsx",tagName:"h2",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionH
640ash:"sha256:940358fa95ea1497f9b63f15c13b830cddaffcfff65328ed4d4d4e8e024ac21d"},children:t.title})})]}),e.jsxs("div",{className:"flex flex-col gap-1.5 text-sm text-muted-foreground",children:[e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(ys,{size:14,className:"shrink-0 text-primary"}),e.jsx("span",{children:e.jsx(_,{devId:"1c1b8f",guard:{file:"src/pages/events.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:c197eb3604aeb880b1504378b31abc5cf59306f85a854992caf5866f918d7487"},children:IR(t.startDate,t.endDate)})})]}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(ul,{size:14,className:"shrink-0 text-primary"}),e.jsxs("span",{children:[t.cityVenue,t.country&&t.country!=="USA"?`, ${t.country}`:""]})]})]}),t.description&&e.jsx("p",{className:"text-sm text-muted-foreground leading-relaxed",children:e.jsx(_,{devId:"7c5e64",guard:{file:"src/pages/events.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:0c05b9dca04f89439006edc1e0711df5ca4f373c01989c9fae09fe107517898a"},children:t.description})}),t.note&&e.jsxs("p",{className:"text-xs text-muted-foreground",children:[e.jsx("span",{className:"font-semibold text-foreground",children:"Provided by:"})," ",t.note]}),e.jsxs("div",{className:"mt-auto pt-2 flex flex-wrap gap-2 items-center",children:[r&&!l&&e.jsxs(O,{to:r,className:"inline-flex items-center gap-1.5 text-sm font-semibold text-white bg-primary hover:bg-primary/90 px-3 py-1.5 rounded-sm transition-colors",children:[e.jsx("span",{children:e.jsx(_,{devId:"604f1b",guard:{file:"src/pages/events.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:69c427feb1e778c0551495ccc0cd6bda924f1b2ebe86acc69055de7c75e8dbac"},children:o})}),e.jsx(Lt,{size:14})]}),r&&l&&e.jsxs("a",{href:r,target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-1.5 text-sm font-semibold text-white bg-primary hover:bg-primary/90 px-3 py-1.5 rounded-sm transition-colors",children:[e.jsx("span",{children:e.jsx(_,{devId:"2a222e",guard:{file:"src/pages/events.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:69c427feb1e778c0551495ccc0cd6bda924f1b2ebe86acc69055de7c75e8dbac"},children:o})}),e.jsx(dt,{size:13})]}),!r&&e.jsxs("span",{className:"inline-flex items-center gap-1.5 text-xs font-medium text-muted-foreground border border-border px-3 py-1.5 rounded-sm bg-muted/50 cursor-default select-none",children:[e.jsx(Ms,{size:12}),"Link active when the show starts"]}),t.website&&e.jsxs("a",{href:t.website,target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-1.5 text-sm font-semibold text-accent hover:underline",children:[e.jsx(Ku,{size:13}),e.jsx("span",{children:"Official Site"}),e.jsx(dt,{size:12})]})]})]})]})}function $R(){const[t,a]=g.useState({title:"",startDate:"",endDate:"",cityVenue:"",country:"USA",website:"",description:"",contactEmail:"",logoUrl:""}),[r,o]=g.useState(!1),[l,d]=g.useState(!1),[u,m]=g.useState(""),p=g.useRef(null),[x,b]=g.useState(!1),[y,v]=g.useState(null);function w(T,M){a(P=>({...P,[T]:M}))}async function C(T){var E;const M=(E=T.target.files)==null?void 0:E[0];if(!M)return;if(!["image/jpeg","image/png","image/webp"].includes(M.type)){v({kind:"error",text:"Only JPG, PNG, or WebP files are allowed."}),p.current&&(p.current.value="");return}if(M.size>5*1024*1024){v({kind:"error",text:"File must be under 5 MB."}),p.current&&(p.current.value="");return}v(null),b(!0);try{const U=await new Promise((J,B)=>{const Y=new FileReader;Y.onload=()=>J(Y.result),Y.onerror=B,Y.readAsDataURL(M)}),q=await fetch("/api/events/upload-logo",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({dataUrl:U})}),H=await q.json().catch(()=>({}));if(!q.ok){v({kind:"error",text:H.error||"Upload failed."});return}w("logoUrl",H.url??""),v({kind:"ok",text:"Logo uploaded."})}catch{v({kind:"error",text:"Upload failed. Please try again or paste a URL."})}finally{b(!1),p.current&&(p.current.value="")}}async function A(T){if(T.preventDefault(),m(""),!t.title.trim()||!t.startDate||!t.cityVenue.trim()){m("Event name, start date, and city/venue are required.");return}o(!0);try{const M=await fetch("/api/events/submit",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(t)}),P=await M.json();if(!M.ok){m(P.error||"Submission failed.");return}d(!0)}catch{m("Network error. Please try again.")}finally{o(!1)}}if(l)return e.jsxs("div",{className:"border border-border rounded-sm p-6 text-center",children:[e.jsx("div",{className:"text-primary text-4xl mb-3",children:"✓"}),e.jsx("h3",{className:"font-bold text-foreground mb-1",children:"Event submitted!"}),e.jsx("p",{className:"text-sm text-muted-foreground",children:"Thanks — we'll review it and publish it shortly."})]});const S="w-full border border-border rounded-sm px-3 py-2 text-sm bg-background text-foreground focus:outline-none focus:ring-1 focus:ring-primary",z="block text-xs font-semibold text-muted-foreground uppercase tracking-wide mb-1";return e.jsxs("section",{id:"submit",className:"border border-border rounded-sm p-5",children:[e.jsxs("div",{className:"flex items-start gap-2 bg-amber-50 border border-amber-200 rounded-sm px-4 py-3 mb-4 text-sm text-amber-900",children:[e.jsx("span",{className:"shrink-0 mt-0.5",children:"ℹ️"}),e.jsxs("p",{children:[e.jsx("span",{className:"font-semibold",children:"Event listings are a Maiden-tier feature."})," ","During this introductory period you can submit events with an approved account."," ","Maiden will not stay free — price coming soon."," ",e.jsx("a",{href:"/membership",className:"underline font-medium hover:text-amber-700",children:"See membership tiers →"})]})]}),e.jsxs("h2",{className:"text-base font-bold text-foreground mb-4 flex items-center gap-2",children:[e.jsx(fi,{size:16,className:"text-primary"}),"Submit an Event"]}),e.jsxs("form",{onSubmit:A,className:"flex flex-col gap-4",children:[e.jsxs("div",{children:[e.jsx("label",{className:z,children:"Event name *"}),e.jsx("input",{className:S,value:t.title,onChange:T=>w("title",T.target.value),placeholder:"e.g. 2026 WDAA World Championship Show"})]}),e.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-2 gap-4",children:[e.jsxs("div",{children:[e.jsx("label",{className:z,children:"Start date *"}),e.jsx("input",{type:"date",className:S,value:t.startDate,onChange:T=>w("startDate",T.target.value)})]}),e.jsxs("div",{children:[e.jsx("label",{className:z,children:"End date"}
640),e.jsx("input",{type:"date",className:S,value:t.endDate,onChange:T=>w("endDate",T.target.value)})]})]}),e.jsxs("div",{children:[e.jsx("label",{className:z,children:"City / Venue *"}),e.jsx("input",{className:S,value:t.cityVenue,onChange:T=>w("cityVenue",T.target.value),placeholder:"e.g. Guthrie, OK – Lazy E Arena"})]}),e.jsxs("div",{children:[e.jsx("label",{className:z,children:"Country"}),e.jsx("input",{className:S,value:t.country,onChange:T=>w("country",T.target.value),placeholder:"USA"})]}),e.jsxs("div",{children:[e.jsx("label",{className:z,children:"Event website"}),e.jsx("p",{className:"text-xs text-muted-foreground mb-1.5",children:"Official show or track website, if you have one. Video/livestream links are added later by Total Horse Channel."}),e.jsx("input",{className:S,value:t.website,onChange:T=>w("website",T.target.value),placeholder:"https://yourshow.org"})]}),e.jsxs("div",{children:[e.jsx("label",{className:z,children:"Event logo (optional)"}),e.jsx("p",{className:"text-xs text-muted-foreground mb-2",children:"Upload a file or paste a direct image URL."}),e.jsxs("div",{className:"flex items-center gap-3 flex-wrap mb-2",children:[e.jsxs("button",{type:"button",onClick:()=>{var T;v(null),(T=p.current)==null||T.click()},disabled:x,className:"inline-flex items-center gap-1.5 text-xs border border-border rounded-sm px-3 py-1.5 hover:bg-muted transition-colors disabled:opacity-60",children:[e.jsx(ln,{size:13}),x?"Uploading…":"Upload image"]}),e.jsx("input",{ref:p,type:"file",accept:"image/jpeg,image/png,image/webp",className:"hidden",onChange:C}),e.jsx("span",{className:"text-xs text-muted-foreground",children:"JPG, PNG, WebP · max 5 MB"}),y&&e.jsx("span",{className:`text-xs px-2 py-1 rounded border ${y.kind==="ok"?"text-green-700 bg-green-50 border-green-200":"text-red-700 bg-red-50 border-red-200"}`,children:e.jsx(_,{devId:"04ded5",guard:{file:"src/pages/events.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:666872237f3b7c933965bc56ece594a71632e1a86cf028b4e4b657944191874a"},children:y.text})})]}),e.jsxs("div",{className:"flex gap-2 items-center",children:[e.jsx("input",{className:S,value:t.logoUrl,onChange:T=>{w("logoUrl",T.target.value),v(null)},placeholder:"https://yourshow.org/logo.png  or  /airo-assets/…"}),t.logoUrl&&e.jsx("button",{type:"button",onClick:()=>{w("logoUrl",""),v(null)},className:"text-muted-foreground hover:text-destructive shrink-0",title:"Clear",children:e.jsx(Vt,{size:16})})]}),t.logoUrl&&e.jsx("img",{src:t.logoUrl,alt:"logo preview",className:"mt-2 h-10 w-auto max-w-[160px] object-contain rounded border border-border bg-white p-0.5",onError:T=>{T.currentTarget.style.display="none"},onLoad:T=>{T.currentTarget.style.display=""}})]}),e.jsxs("div",{children:[e.jsx("label",{className:z,children:"Short description"}),e.jsx("textarea",{className:`${S} resize-none`,rows:3,value:t.description,onChange:T=>w("description",T.target.value),placeholder:"Brief description of the event…"})]}),e.jsxs("div",{children:[e.jsx("label",{className:z,children:"Your contact email"}),e.jsx("input",{type:"email",className:S,value:t.contactEmail,onChange:T=>w("contactEmail",T.target.value),placeholder:"[email protected]"})]}),u&&e.jsx("p",{className:"text-sm text-destructive",children:e.jsx(_,{devId:"7c3145",guard:{file:"src/pages/events.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:ca00fccfb408989eddc401062c4d1219a6aceb6b9b55412357f1790862e8f178"},children:u})}),e.jsx("button",{type:"submit",disabled:r,className:"self-start bg-primary hover:bg-primary/90 text-white font-bold uppercase text-sm px-5 py-2.5 rounded-sm transition-colors disabled:opacity-60",children:e.jsx(_,{devId:"5531d1",guard:{file:"src/pages/events.tsx",tagName:"button",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:8bbf7d9cb4b4d2daaa81cb7c865de945fdb8709141178e1ea69fb6f6b4311303"},children:r?"Submitting…":"Submit for Review"})}),e.jsx("p",{className:"text-xs text-muted-foreground",children:"Submissions are reviewed before publishing. We'll reach out if we have questions."})]})]})}function VR(){const[t,a]=g.useState([]),[r,o]=g.useState(!0);g.useEffect(()=>{fetch("/api/events").then(u=>u.json()).then(u=>a(Array.isArray(u)?u:[])).catch(()=>a([])).finally(()=>o(!1))},[]);const l="Upcoming Events – Total Horse Channel",d="Horse shows, races, and rodeos — live on Total Horse Channel or listed so fans can find them.";return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:l}),e.jsx("meta",{name:"description",content:d}),e.jsx("link",{rel:"canonical",href:`${lw}/events`}),e.jsx("meta",{property:"og:title",content:l}),e.jsx("meta",{property:"og:description",content:d}),e.jsx("meta",{property:"og:url",content:`${lw}/events`}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"})]}),e.jsx("main",{children:e.jsx("div",{className:"max-w-[1280px] mx-auto px-4 py-6",children:e.jsxs("div",{className:"flex flex-col lg:flex-row gap-6",children:[e.jsxs("div",{className:"flex-1 min-w-0 flex flex-col gap-6",children:[e.jsxs("div",{className:"border-b border-border pb-4",children:[e.jsx("h1",{className:"text-2xl font-bold text-foreground",children:"Upcoming Events"}),e.jsx("p",{className:"text-sm text-muted-foreground mt-1",children:e.jsx(_,{devId:"92d160",guard:{file:"src/pages/events.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionH
640ash:"sha256:c9046f7a37ad0ea7cee73355984fa5428982f8b37c8f7bcec91f7ac71a7cd104"},children:d})})]}),e.jsx("div",{children:e.jsxs("a",{href:"#submit",className:"inline-flex items-center gap-2 bg-primary hover:bg-primary/90 text-white font-bold uppercase text-sm px-4 py-2.5 rounded-sm transition-colors",children:[e.jsx(fi,{size:14}),"Submit an Event"]})}),r?e.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-4",children:[1,2,3].map(u=>e.jsxs("div",{className:"border border-border rounded-sm p-4 animate-pulse",children:[e.jsx("div",{className:"h-4 bg-muted rounded w-3/4 mb-3"}),e.jsx("div",{className:"h-3 bg-muted rounded w-1/2 mb-2"}),e.jsx("div",{className:"h-3 bg-muted rounded w-2/3"})]},u))}):e.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-4",children:t.map(u=>e.jsx(BR,{ev:u},u.id))}),e.jsx($R,{})]}),e.jsxs("div",{className:"w-full lg:w-[300px] shrink-0 flex flex-col gap-4",children:[e.jsx(zs,{placement:"sidebar-events"}),e.jsx(O,{to:"/watch-live-events",className:"block w-full text-center text-white font-bold uppercase py-3 text-base bg-primary hover:bg-primary/90 transition-colors",children:"WATCH LIVE EVENTS"}),e.jsx(Cr,{placement:"sidebar-events-220"})]})]})})})]})}const Px="https://totalhorsechannel.com",cw=`${Px}/videos`,Mf=24,FR=[{label:"All",value:""},{label:"Horse Racing",value:"Horse Racing"},{label:"Harness Racing",value:"Harness Racing"},{label:"Western Dressage",value:"Western Dressage"},{label:"Show Jumping",value:"Show Jumping"},{label:"Reining",value:"Reining"},{label:"Reined Cow Horse",value:"Reined Cow Horse"},{label:"Cutting Horse",value:"Cutting Horse"},{label:"Eventing",value:"Eventing"},{label:"Quarter Horse",value:"Quarter Horse"},{label:"How To Videos",value:"How To Videos"},{label:"Working Equitation",value:"Working Equitation"},{label:"Other / General",value:"Other / General"}];function WR(t,a){if(!a)return!0;const r=a.toLowerCase();return!!(t.title.toLowerCase().includes(r)||t.providedBy&&t.providedBy.toLowerCase().includes(r))}function qR(t,a){if(!a||t.category===a)return!0;if(t.extraCategories)try{const r=JSON.parse(t.extraCategories);if(Array.isArray(r)&&r.includes(a))return!0}catch{}return!1}function dw(t){return t>=1e6?`${(t/1e6).toFixed(1)}M`:t>=1e3?`${(t/1e3).toFixed(1)}K`:String(t)}function YR({ev:t}){const a=An(t.createdAt,t.title)||An(t.startAt,t.title),r=t.isArchived;return e.jsxs(O,{to:`/live/${t.slug}`,className:"flex flex-col border border-border bg-card hover:border-primary transition-colors group",children:[e.jsxs("div",{className:"relative w-full bg-black overflow-hidden",style:{aspectRatio:"16/9"},children:[t.thumbnailUrl?e.jsx("img",{src:t.thumbnailUrl,alt:t.title,width:320,height:180,className:"absolute inset-0 w-full h-full object-cover group-hover:opacity-90 transition-opacity",loading:"lazy"}):e.jsx("div",{className:"absolute inset-0 flex items-center justify-center bg-gray-900",children:e.jsx(Yn,{size:24,className:"text-gray-600"})}),e.jsx("div",{className:"absolute inset-0 flex items-center justify-center opacity-0 group-hover:opacity-100 transition-opacity pointer-events-none",children:e.jsx("div",{className:"w-10 h-10 rounded-full bg-primary/80 flex items-center justify-center",children:e.jsx("svg",{className:"w-4 h-4 text-white ml-0.5",fill:"currentColor",viewBox:"0 0 20 20",children:e.jsx("path",{d:"M6.3 2.841A1.5 1.5 0 004 4.11V15.89a1.5 1.5 0 002.3 1.269l9.344-5.89a1.5 1.5 0 000-2.538L6.3 2.84z"})})})}),e.jsx("div",{className:"absolute top-1.5 left-1.5 bg-secondary text-white text-[10px] font-bold uppercase px-1.5 py-0.5 pointer-events-none",children:r?"Archive":"Video"})]}),e.jsxs("div",{className:"px-2 py-2 flex flex-col gap-1",children:[e.jsx("p",{className:"font-semibold text-foreground leading-snug line-clamp-2",style:{fontSize:"13px"},children:e.jsx(_,{devId:"5e8c43",guard:{file:"src/pages/videos.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:940358fa95ea1497f9b63f15c13b830cddaffcfff65328ed4d4d4e8e024ac21d"},children:t.title})}),e.jsxs("div",{className:"flex items-center gap-1.5 text-muted-foreground",style:{fontSize:"12px"},children:[e.jsx(ys,{size:11}),e.jsx("span",{children:e.jsx(_,{devId:"6dfc19",guard:{file:"src/pages/videos.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionH
640ash:"sha256:0e87632cd46bd4907c516317eb6d81fe0f921a23c7643018f21292894b470681"},children:a})})]}),e.jsxs("div",{className:"flex items-center gap-3 text-muted-foreground",style:{fontSize:"12px"},children:[(t.viewCount??0)>0&&e.jsxs("span",{className:"flex items-center gap-1",children:[e.jsx(xa,{size:11}),dw(t.viewCount??0)]}),(t.likeCount??0)>0&&e.jsxs("span",{className:"flex items-center gap-1",children:[e.jsx(Gn,{size:11}),dw(t.likeCount??0)]}),t.category&&e.jsx("span",{className:"text-muted-foreground truncate",children:e.jsx(_,{devId:"afd0fc",guard:{file:"src/pages/videos.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:f824327c0ee15f1f2565a6163c254a601b38b71919e80d7ad2bb943683b217c6"},children:t.category})})]}),t.providedBy&&e.jsx("p",{className:"text-muted-foreground truncate",style:{fontSize:"11px"},children:e.jsx(_,{devId:"5e8c44",guard:{file:"src/pages/videos.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:5c5176ac949fb29f6bc040b290182c6415ce5fb7f7e110ce44ab61359e19901a"},children:t.providedBy})})]})]})}function GR(){const{allVideos:t,loading:a}=ed(),[r,o]=g.useState(""),[l,d]=g.useState(""),[u,m]=g.useState(0),p=g.useMemo(()=>t.filter(w=>qR(w,r)&&WR(w,l)),[t,r,l]),x=Math.ceil(p.length/Mf),b=p.slice(u*Mf,(u+1)*Mf);function y(w){o(w),m(0)}function v(w){d(w),m(0)}return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Videos – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Browse all horse videos and archived live events on Total Horse Channel — racing, western dressage, show jumping, reining, and more."}),e.jsx("link",{rel:"canonical",href:cw}),e.jsx("meta",{property:"og:title",content:"Videos – Total Horse Channel"}),e.jsx("meta",{property:"og:description",content:"Browse all horse videos and archived live events on Total Horse Channel."}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{property:"og:url",content:cw}),e.jsx("meta",{property:"og:image",content:`${Px}/assets/images/03d4cc3463b5f931df4f08c7c706f416.png`}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("meta",{name:"twitter:title",content:"Videos – Total Horse Channel"}),e.jsx("meta",{name:"twitter:description",content:"Browse all horse videos and archived live events on Total Horse Channel."}),e.jsx("meta",{name:"twitter:image",content:`${Px}/assets/images/03d4cc3463b5f931df4f08c7c706f416.png`})]}),e.jsx("main",{children:e.jsx("div",{className:"max-w-[1280px] mx-auto px-4 py-4",children:e.jsxs("div",{className:"flex flex-col lg:flex-row gap-6",children:[e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsxs("div",{className:"bg-primary px-3 py-2 mb-4 flex items-center justify-between gap-3",children:[e.jsxs("h1",{className:"text-white font-bold uppercase text-sm tracking-wide flex items-center gap-2",children:[e.jsx(Yn,{size:14}),"Videos"]}),e.jsxs("span",{className:"text-white/70 text-xs",children:[p.length," ",p.length===1?"video":"videos"]})]}),e.jsxs("div",{className:"relative mb-3",children:[e.jsx(pi,{size:14,className:"absolute left-3 top-1/2 -translate-y-1/2 text-muted-foreground pointer-events-none"}),e.jsx("input",{type:"text",value:l,onChange:w=>v(w.target.value),placeholder:"Search by title or provider…",className:"w-full border border-border bg-card text-foreground text-sm pl-8 pr-8 py-2 focus:outline-none focus:ring-1 focus:ring-primary placeholder:text-muted-foreground"}),l&&e.jsx("button",{onClick:()=>v(""),"aria-label":"Clear search",className:"absolute right-2.5 top-1/2 -translate-y-1/2 text-muted-foreground hover:text-foreground",children:e.jsx(Vt,{size:14})})]}),e.jsx("div",{className:"flex flex-wrap gap-1.5 mb-4",children:FR.map(w=>e.jsx("button",{onClick:()=>y(w.value),className:`px-3 py-1 text-xs font-semibold border transition-colors ${r===w.value?"bg-primary text-white border-primary":"bg-card text-foreground border-border hover:border-primary hover:text-primary"}`,children:w.label},w.value))}),a&&e.jsx("div",{className:"grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-3 gap-3 mb-4",children:Array.from({length:6}).map((w,C)=>e.jsx("div",{className:"border border-border bg-card animate-pulse",style:{aspectRatio:"16/9"}},C))}),!a&&b.length===0&&e.jsx("div",{className:"border border-border bg-card px-6 py-10 text-center mb-4",children:e.jsx("p",{className:"text-muted-foreground",style:{fontSize:"15px"},children:"No videos in this category yet."})}),!a&&b.length>0&&e.jsx("div",{className:"grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-3 gap-3 mb-4",children:b.map(w=>e.jsx(YR,{ev:w},w.id))}),x>1&&e.jsxs("div",{className:"flex items-center gap-2 text-sm mb-6 flex-wrap",children:[u>0&&e.jsx("button",{onClick:()=>m(u-1),className:"px-3 py-1 border border-border hover:bg-muted transition-colors",children:"← Prev"}),e.jsxs("span",{className:"text-muted-foreground text-xs",children:["Page ",u+1," of ",x]}),u<x-1&&e.jsx("button",{onClick:()=>m(u+1),className:"px-3 py-1 border border-border hover:bg-muted transition-colors",children:"Next →"})]})]}),e.jsxs("div",{className:"w-full lg:w-[350px] shrink-0 flex flex-col gap-4",children:[e.jsx(zs,{placement:"sidebar-videos"}),e.jsx(O,{to:"/watch-live-events",className:"block w-full text-center text-white font-bold uppercase py-3 text-base bg-primary hover:bg-primary/90 transition-colors",children:"WATCH LIVE EVENTS"}),e.jsx(Cr,{placement:"sidebar-videos-220"})]})]})})})]})}const uw={title:"",startDate:"",endDate:"",cityVenue:"",country:"USA",website:"",description:"",note:"",linkLabel:"",buttonLabel:"",logoUrl:"",status:"published",sortOrder:"0",submitterEmail:""},ku={createVideo:!1,videoSource:"",videoInput:"",videoType:"live",videoThumbnailUrl:"",videoPublished:!0},ia="w-full border border-border rounded-sm px-3 py-2 text-sm bg-background text-foreground focus:outline-none focus:ring-1 focus:ring-primary",Js="block text-xs font-semibold text-muted-foreground uppercase tracking-wide mb-1";function Tu(t){const[a,r,o]=t.split("-");return new Date(Number(a),Number(r)-1,Number(o)).toLocaleDateString("en-US",{month:"short",day:"numeric",year:"numeric"})}function ZR(t){return t.startsWith("https://")||t.startsWith("http://")||t.startsWith("/")}function JR({value:t,onChange:a,uploadEndpoint:r="/api/admin/events/upload-logo"}){const o=g.useRef(null),[l,d]=g.useState(!1),[u,m]=g.useState(null);async function p(b){var w;const y=(w=b.target.files)==null?void 0:w[0];if(!y)return;if(!["image/jpeg","image/png","image/webp"].includes(y.type)){m({kind:"error",text:"Only JPG, PNG, or WebP files are allowed."}),o.current&&(o.current.value="");return}if(y.size>5*1024*1024){m({kind:"error",text:"File must be under 5 MB."}),o.current&&(o.current.value="");return}m(null),d(!0);try{const C=await new Promise((z,T)=>{const M=new FileReader;M.onload=()=>z(M.result),M.onerror=T,M.readAsDataURL(y)}),A=await fetch(r,{method:"POST",headers:{"Content-Type":"application/json"},credentials:"include",body:JSON.stringify({dataUrl:C})}),S=await A.json().catch(()=>({}));if(!A.ok){m({kind:"error",text:S.error||"Upload failed."});return}a(S.url??""),m({kind:"ok",text:"Uploaded successfully."})}catch{m({kind:"error",text:"Upload failed. Please try again or paste a URL."})}finally{d(!1),o.current&&(o.current.value="")}}const x=ZR(t);return e.jsxs("div",{className:"flex flex-col gap-2",children:[e.jsxs("div",{className:"flex gap-2 items-center",children:[e.jsx("input",{className:ia,value:t,onChange:b=>{a(b.target.value),m(null)},placeholder:"https://example.com/logo.png  or /airo-assets/…  or upload below"}),t&&e.jsx("button",{type:"button",onClick:()=>{a(""),m(null)},className:"text-muted-foreground hover:text-destructive shrink-0",title:"Clear",children:e.jsx(Vt,{size:16})})]}),e.jsxs("div",{className:"flex items-center gap-3 flex-wrap",children:[e.jsxs("button",{type:"button",onClick:()=>{var b;m(null),(b=o.current)==null||b.click()},disabled:l,className:"inline-flex items-center gap-1.5 text-xs border border-border rounded-sm px-3 py-1.5 hover:bg-muted transition-colors disabled:opacity-60",children:[e.jsx(s2,{size:13}),l?"Uploading…":"Upload image"]}),e.jsx("input",{ref:o,type:"file",accept:"image/jpeg,image/png,image/webp,image/avif",className:"hidden",onChange:p}),e.jsx("span",{className:"text-xs text-muted-foreground",children:"JPG, PNG, WebP · max 5 MB"}),u&&e.jsx("span",{className:`text-xs px-2 py-1 rounded border ${u.kind==="ok"?"text-green-700 bg-green-50 border-green-200":"text-amber-700 bg-amber-50 border-amber-200"}`,children:e.jsx(_,{devId:"78c43e",guard:{file:"src/pages/admin/events.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionH
640ash:"sha256:84eb1b144e061c3c102fb7a5d0930f56aa3a66e51f17d390b40f3489d0325393"},children:u.text})}),x&&e.jsx("img",{src:t,alt:"logo preview",className:"h-8 w-auto max-w-[120px] object-contain rounded border border-border bg-white p-0.5",onError:b=>{b.currentTarget.style.display="none"},onLoad:b=>{b.currentTarget.style.display=""}})]})]})}function XR({form:t,set:a,video:r,setVideo:o,onSave:l,onCancel:d,busy:u,error:m,isEdit:p}){const x=["youtube","rumble","vimeo","box","other"];return e.jsxs("div",{className:"border border-primary/40 rounded-sm p-5 mb-6 bg-card",children:[e.jsx("h2",{className:"font-bold text-foreground mb-4",children:e.jsx(_,{devId:"035030",guard:{file:"src/pages/admin/events.tsx",tagName:"h2",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:ca6a64ead8fb698402c4d0f27fcd2746568bfbeb782f2f9cf458fd298c31e9dd"},children:p?"Edit Event":"Add Event"})}),e.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-2 gap-4",children:[e.jsxs("div",{className:"sm:col-span-2",children:[e.jsx("label",{className:Js,children:"Event name *"}),e.jsx("input",{className:ia,value:t.title,onChange:b=>a("title",b.target.value)})]}),e.jsxs("div",{children:[e.jsx("label",{className:Js,children:"Start date *"}),e.jsx("input",{type:"date",className:ia,value:t.startDate,onChange:b=>a("startDate",b.target.value)})]}),e.jsxs("div",{children:[e.jsx("label",{className:Js,children:"End date"}),e.jsx("input",{type:"date",className:ia,value:t.endDate,onChange:b=>a("endDate",b.target.value)})]}),e.jsxs("div",{children:[e.jsx("label",{className:Js,children:"City / Venue *"}),e.jsx("input",{className:ia,value:t.cityVenue,onChange:b=>a("cityVenue",b.target.value)})]}),e.jsxs("div",{children:[e.jsx("label",{className:Js,children:"Country"}),e.jsx("input",{className:ia,value:t.country,onChange:b=>a("country",b.target.value)})]}),e.jsxs("div",{className:"sm:col-span-2",children:[e.jsx("label",{className:Js,children:"Event website"}),e.jsx("input",{className:ia,value:t.website,onChange:b=>a("website",b.target.value),placeholder:"https://officialshow.org"})]}),e.jsxs("div",{className:"sm:col-span-2",children:[e.jsx("label",{className:Js,children:"Short description"}),e.jsx("textarea",{className:`${ia} resize-none`,rows:2,value:t.description,onChange:b=>a("description",b.target.value)})]}),e.jsxs("div",{children:[e.jsx("label",{className:Js,children:"Provided by (optional)"}),e.jsx("input",{className:ia,value:t.note,onChange:b=>a("note",b.target.value),placeholder:"e.g. RainDancer Video"})]}),e.jsxs("div",{children:[e.jsx("label",{className:Js,children:"Button link (optional)"}),e.jsx("input",{className:ia,value:t.linkLabel,onChange:b=>a("linkLabel",b.target.value),placeholder:"/home/wdaa  or  https://wdaaworldshow.org"}),e.jsx("p",{className:"text-xs text-muted-foreground mt-1",children:'Path starting with / links to a page on this site. Full URL links externally. Leave blank to show a "Link active when the show starts" placeholder.'})]}),e.jsxs("div",{children:[e.jsx("label",{className:Js,children:"Button label (optional)"}),e.jsx("input",{className:ia,value:t.buttonLabel,onChange:b=>a("buttonLabel",b.target.value),placeholder:"Watch on THC"}),e.jsx("p",{className:"text-xs text-muted-foreground mt-1",children:'Defaults to "Watch on THC" when blank. Only shown when a button link is set.'})]}),e.jsxs("div",{className:"sm:col-span-2",children:[e.jsx("label",{className:Js,children:"Event logo (optional)"}),e.jsx(JR,{value:t.logoUrl,onChange:b=>a("logoUrl",b)})]}),e.jsxs("div",{children:[e.jsx("label",{className:Js,children:"Status"}),e.jsxs("select",{className:ia,value:t.status,onChange:b=>a("status",b.target.value),children:[e.jsx("option",{value:"published",children:"Published"}),e.jsx("option",{value:"pending",children:"Pending"}),e.jsx("option",{value:"rejected",children:"Rejected"})]})]}),e.jsxs("div",{children:[e.jsx("label",{className:Js,children:"Sort order (lower = first)"}),e.jsx("input",{type:"number",className:ia,value:t.sortOrder,onChange:b=>a("sortOrder",b.target.value)})]}),t.submitterEmail&&e.jsxs("div",{className:"sm:col-span-2",children:[e.jsx("label",{className:Js,children:"Submitted by"}),e.jsx("input",{className:ia,value:t.submitterEmail,readOnly:!0})]})]}),!p&&e.jsxs("div",{className:"mt-5 border border-border rounded-sm p-4 flex flex-col gap-4",children:[e.jsxs("label",{className:"flex items-start gap-3 cursor-pointer select-none",children:[e.jsx("input",{type:"checkbox",checked:r.createVideo,onChange:b=>o({...r,createVideo:b.target.checked}),className:"mt-0.5 accent-primary shrink-0"}),e.jsxs("div",{children:[e.jsxs("p",{className:"text-sm font-semibold flex items-center gap-1.5",children:[e.jsx(Vs,{size:14,className:"text-primary"}),"Also add a Video / Live now"]}),e.jsx("p",{className:"text-xs text-muted-foreground mt-0.5",children:"Creates a live event page at the same time. The event card button will link to it automatically unless you set a Button link above."})]})]}),r.createVideo&&e.jsxs("div",{className:"flex flex-col gap-4 pt-1 border-t border-border",children:[e.jsxs("div",{children:[e.jsx("label",{className:Js,children:"Type *"}),e.jsxs("div",{className:"flex gap-3",children:[e.jsxs("label",{className:`flex items-center gap-2 border rounded-sm px-3 py-2 cursor-pointer flex-1 transition-colors ${r.videoType==="live"?"border-primary bg-primary/5":"border-border hover:bg-muted"}`,children:[e.jsx("input",{type:"radio",name:"admin-ev-vtype",value:"live",checked:r.videoType==="live",onChange:()=>o({...r,videoType:"live"}),className:"accent-primary"}),e.jsx(Ft,{size:13,className:r.videoType==="live"?"text-primary":"text-muted-foreground"}),e.jsx("span",{className:"text-sm font-semibold",children:"Live"})]}),e.jsxs("label",{className:`flex items-center gap-2 border rounded-sm px-3 py-2 cursor-pointer flex-1 transition-colors ${r.videoType==="video"?"border-primary bg-primary/5":"border-border hover:bg-muted"}`,children:[e.jsx("input",{type:"radio",name:"admin-ev-vtype",value:"video",checked:r.videoType==="video",onChange:()=>o({...r,videoType:"video"}),className:"accent-primary"}),e.jsx(Yn,{size:13,className:r.videoType==="video"?"text-primary":"text-muted-foreground"}),e.jsx("span",{className:"text-sm font-semibold",children:"Video"})]})]})]}),e.jsxs("div",{children:[e.jsx("label",{className:Js,children:"Source *"}
640),e.jsxs("select",{className:ia,value:r.videoSource,onChange:b=>o({...r,videoSource:b.target.value}),children:[e.jsx("option",{value:"",children:"— Select source —"}),x.map(b=>e.jsx("option",{value:b,children:b.charAt(0).toUpperCase()+b.slice(1)},b))]})]}),e.jsxs("div",{children:[e.jsx("label",{className:Js,children:"Video URL or iframe embed *"}),e.jsx("textarea",{rows:3,value:r.videoInput,onChange:b=>o({...r,videoInput:b.target.value}),placeholder:"Paste the YouTube <iframe> embed or a Rumble/Vimeo URL",className:`${ia} font-mono resize-y`})]}),e.jsxs("div",{children:[e.jsx("label",{className:Js,children:"Thumbnail URL (optional)"}),e.jsx("input",{type:"text",className:ia,value:r.videoThumbnailUrl,onChange:b=>o({...r,videoThumbnailUrl:b.target.value}),placeholder:"https://img.youtube.com/vi/VIDEO_ID/hqdefault.jpg"})]}),e.jsxs("label",{className:"flex items-center gap-2 cursor-pointer select-none text-sm",children:[e.jsx("input",{type:"checkbox",checked:r.videoPublished,onChange:b=>o({...r,videoPublished:b.target.checked}),className:"accent-primary"}),"Publish video immediately"]})]})]}),m&&e.jsx("p",{className:"text-sm text-destructive mt-3",children:e.jsx(_,{devId:"d97026",guard:{file:"src/pages/admin/events.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:ca00fccfb408989eddc401062c4d1219a6aceb6b9b55412357f1790862e8f178"},children:m})}),e.jsxs("div",{className:"flex gap-3 mt-4",children:[e.jsx("button",{onClick:l,disabled:u,className:"bg-primary hover:bg-primary/90 text-white font-bold uppercase text-sm px-5 py-2 rounded-sm transition-colors disabled:opacity-60",children:e.jsx(_,{devId:"32b5a8",guard:{file:"src/pages/admin/events.tsx",tagName:"button",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:184a429cb2ee5629ca6099a72a41f7ea6630c57bac36cbc89debe1e54f9e920c"},children:u?"Saving…":"Save"})}),e.jsx("button",{onClick:d,className:"border border-border px-5 py-2 text-sm font-semibold rounded-sm hover:bg-muted transition-colors",children:"Cancel"})]})]})}function QR(){return e.jsx(kr,{pageTitle:"Manage Events",children:e.jsx(e7,{})})}function e7(){const{user:t,isPending:a}=Us(),[r,o]=g.useState([]),[l,d]=g.useState(!0),[u,m]=g.useState(null),[p,x]=g.useState(!1),[b,y]=g.useState({...uw}),[v,w]=g.useState({...ku}),[C,A]=g.useState(!1),[S,z]=g.useState(""),T=(t==null?void 0:t.isAdmin)===!0;async function M(){d(!0);try{const k=await(await fetch("/api/admin/events",{credentials:"include"})).json();o(Array.isArray(k)?k:[])}finally{d(!1)}}g.useEffect(()=>{T&&M()},[T]);function P(){y({...uw}),w({...ku}),m(null),x(!0),z(""),setTimeout(()=>{var I;return(I=document.getElementById("event-form-anchor"))==null?void 0:I.scrollIntoView({behavior:"smooth"})},50)}function E(I){y({title:I.title,startDate:I.startDate,endDate:I.endDate||"",cityVenue:I.cityVenue,country:I.country,website:I.website||"",description:I.description||"",note:I.note||"",linkLabel:I.linkLabel||"",buttonLabel:I.buttonLabel||"",logoUrl:I.logoUrl||"",status:I.status,submitterEmail:I.submitterEmail||"",sortOrder:String(I.sortOrder??0)}),m(I),x(!1),z(""),setTimeout(()=>{var k;return(k=document.getElementById("event-form-anchor"))==null?void 0:k.scrollIntoView({behavior:"smooth"})},50)}function U(I,k){y(K=>({...K,[I]:k}))}async function q(){if(z(""),!b.title.trim()||!b.startDate||!b.cityVenue.trim()){z("Title, start date, and city/venue are required.");return}if(!u&&v.createVideo){if(!v.videoSource){z("Please select a video source.");return}if(!v.videoInput.trim()){z("Video URL or embed code is required.");return}}A(!0);try{const I=u?`/api/admin/events/${u.id}`:"/api/admin/events",k=u?"PUT":"POST",K=u?b:{...b,...v},L=await fetch(I,{method:k,headers:{"Content-Type":"application/json"},credentials:"include",body:JSON.stringify(K)}),se=await L.json();if(!L.ok){z(se.error||"Save failed.");return}x(!1),m(null),w({...ku}),await M()}catch{z("Network error.")}finally{A(!1)}}async function H(I,k){confirm(`Delete "${k}"? This cannot be undone.`)&&(await fetch(`/api/admin/events/${I}`,{method:"DELETE",credentials:"include"}),await M())}async function J(I){await fetch(`/api/admin/events/${I}/approve`,{method:"POST",credentials:"include"}),await M()}async function B(I){const k=I.status==="published"?"pending":"published";await fetch(`/api/admin/events/${I.id}`,{method:"PUT",headers:{"Content-Type":"application/json"},credentials:"include",body:JSON.stringify({...I,status:k,sortOrder:String(I.sortOrder)})}),await M()}async function Y(I,k){const K=k==="up"?I.sortOrder-1:I.sortOrder+1;await fetch(`/api/admin/events/${I.id}`,{method:"PUT",headers:{"Content-Type":"application/json"},credentials:"include",body:JSON.stringify({...I,sortOrder:String(K)})}),await M()}if(a)return null;if(!T)return e.jsx(yi,{to:"/",replace:!0});const $=r.filter(I=>I.status==="pending"),D=r.filter(I=>I.status==="published"),W=p||u!==null;return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Admin – Events | Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Admin panel for managing upcoming horse events on Total Horse Channel."}),e.jsx("link",{rel:"canonical",href:"https://totalhorsechannel.com/admin/events"}),e.jsx("meta",{name:"robots",content:"noindex"})]}),e.jsx("main",{children:e.jsxs("div",{className:"max-w-[1100px] mx-auto px-4 py-8",children:[e.jsxs("div",{className:"flex items-center justify-between mb-6",children:[e.jsx("h1",{className:"text-xl font-bold text-foreground",children:"Manage Events"}),e.jsxs("button",{onClick:P,className:"flex items-center gap-2 bg-primary hover:bg-primary/90 text-white font-bold uppercase text-sm px-4 py-2 rounded-sm transition-colors",children:[e.jsx(Iu,{size:15}),"Add Event"]})]}),e.jsx("div",{id:"event-form-anchor"}),W&&e.jsx(XR,{form:b,set:U,video:v,setVideo:w,onSave:q,onCancel:()=>{x(!1),m(null),w({...ku})},busy:C,error:S,isEdit:u!==null}),l?e.jsx("p",{className:"text-sm text-muted-foreground",children:"Loading…"}):e.jsxs("div",{className:"flex flex-col gap-10",children:[e.jsxs("section",{children:[e.jsxs("div",{className:"flex items-center gap-3 mb-3 border-b border-border pb-2",children:[e.jsx(Ms,{size:16,className:"text-yellow-600"}),e.jsxs("h2",{className:"font-bold text-foreground",children:["Pending Submissions",$.length>0&&e.jsx("span",{className:"ml-2 text-xs font-semibold bg-yellow-100 text-yellow-700 px-2 py-0.5 rounded-full",children:e.jsx(_,{devId:"5a43d9",guard:{file:"src/pages/admin/events.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionH
640ash:"sha256:6cb0eb26debe15c52471c20b363a055dc7dfb6b954c0d024556fbc277c0e9fc1"},children:$.length})})]})]}),$.length===0?e.jsx("p",{className:"text-sm text-muted-foreground",children:"No pending submissions."}):e.jsx("div",{className:"border border-border rounded-sm overflow-hidden",children:e.jsxs("table",{className:"w-full text-sm",children:[e.jsx("thead",{children:e.jsxs("tr",{className:"bg-yellow-50 border-b border-border",children:[e.jsx("th",{className:"text-left px-4 py-2 font-semibold text-muted-foreground",children:"Event"}),e.jsx("th",{className:"text-left px-4 py-2 font-semibold text-muted-foreground hidden md:table-cell",children:"Dates"}),e.jsx("th",{className:"text-left px-4 py-2 font-semibold text-muted-foreground hidden lg:table-cell",children:"Location"}),e.jsx("th",{className:"text-right px-4 py-2 font-semibold text-muted-foreground",children:"Actions"})]})}),e.jsx("tbody",{className:"divide-y divide-border",children:$.map(I=>e.jsxs("tr",{className:"hover:bg-muted/40 transition-colors",children:[e.jsx("td",{className:"px-4 py-3",children:e.jsxs("div",{className:"flex items-center gap-2",children:[I.logoUrl&&e.jsx("img",{src:I.logoUrl,alt:"",className:"h-7 w-7 object-contain rounded shrink-0"}),e.jsxs("div",{children:[e.jsx("div",{className:"font-medium text-foreground leading-snug",children:I.title}),I.submitterEmail&&e.jsxs("div",{className:"text-xs text-muted-foreground",children:["From: ",I.submitterEmail]}),I.website&&e.jsx("a",{href:I.website,target:"_blank",rel:"noopener noreferrer",className:"text-xs text-accent hover:underline",children:I.website})]})]})}),e.jsxs("td",{className:"px-4 py-3 text-muted-foreground hidden md:table-cell whitespace-nowrap",children:[Tu(I.startDate),I.endDate?` – ${Tu(I.endDate)}`:""]}),e.jsx("td",{className:"px-4 py-3 text-muted-foreground hidden lg:table-cell",children:I.cityVenue}),e.jsx("td",{className:"px-4 py-3",children:e.jsxs("div",{className:"flex items-center justify-end gap-2",children:[e.jsxs("button",{onClick:()=>J(I.id),className:"inline-flex items-center gap-1 text-xs font-bold bg-green-600 hover:bg-green-700 text-white px-3 py-1.5 rounded-sm transition-colors",title:"Approve — publish to Upcoming Events",children:[e.jsx(Gn,{size:12}),"Approve"]}),e.jsx("button",{onClick:()=>E(I),className:"text-muted-foreground hover:text-primary transition-colors",title:"Edit",children:e.jsx(Vn,{size:15})}),e.jsx("button",{onClick:()=>H(I.id,I.title),className:"text-muted-foreground hover:text-destructive transition-colors",title:"Delete",children:e.jsx(Tn,{size:15})})]})})]},I.id))})]})})]}),e.jsxs("section",{children:[e.jsxs("div",{className:"flex items-center gap-3 mb-3 border-b border-border pb-2",children:[e.jsx(kn,{size:16,className:"text-green-600"}),e.jsxs("h2",{className:"font-bold text-foreground",children:["Published Events",D.length>0&&e.jsx("span",{className:"ml-2 text-xs font-semibold bg-green-100 text-green-700 px-2 py-0.5 rounded-full",children:e.jsx(_,{devId:"34aa1a",guard:{file:"src/pages/admin/events.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:a13742b8a4a69a64d95ad1d6494247a4fde43c4ffd930c25ce638679c217089e"},children:D.length})})]})]}),D.length===0?e.jsx("p",{className:"text-sm text-muted-foreground",children:"No published events yet."}):e.jsx("div",{className:"border border-border rounded-sm overflow-hidden",children:e.jsxs("table",{className:"w-full text-sm",children:[e.jsx("thead",{children:e.jsxs("tr",{className:"bg-muted border-b border-border",children:[e.jsx("th",{className:"text-left px-4 py-2 font-semibold text-muted-foreground w-10",children:"Order"}),e.jsx("th",{className:"text-left px-4 py-2 font-semibold text-muted-foreground",children:"Event"}),e.jsx("th",{className:"text-left px-4 py-2 font-semibold text-muted-foreground hidden md:table-cell",children:"Dates"}),e.jsx("th",{className:"text-left px-4 py-2 font-semibold text-muted-foreground hidden lg:table-cell",children:"Location"}),e.jsx("th",{className:"text-right px-4 py-2 font-semibold text-muted-foreground",children:"Actions"})]})}),e.jsx("tbody",{className:"divide-y divide-border",children:D.map((I,k)=>e.jsxs("tr",{className:"hover:bg-muted/40 transition-colors",children:[e.jsx("td",{className:"px-4 py-2",children:e.jsxs("div",{className:"flex flex-col gap-0.5",children:[e.jsx("button",{onClick:()=>Y(I,"up"),disabled:k===0,className:"text-muted-foreground hover:text-foreground disabled:opacity-30 transition-colors",children:e.jsx(Zc,{size:14})}),e.jsx("button",{onClick:()=>Y(I,"down"),disabled:k===D.length-1,className:"text-muted-foreground hover:text-foreground disabled:opacity-30 transition-colors",children:e.jsx($n,{size:14})})]})}),e.jsx("td",{className:"px-4 py-3",children:e.jsxs("div",{className:"flex items-center gap-2",children:[I.logoUrl&&e.jsx("img",{src:I.logoUrl,alt:"",className:"h-7 w-7 object-contain rounded shrink-0"}),e.jsxs("div",{children:[e.jsx("div",{className:"font-medium text-foreground leading-snug",children:I.title}),I.submitterEmail&&e.jsxs("div",{className:"text-xs text-muted-foreground",children:["Submitted by: ",I.submitterEmail]})]})]})}),e.jsxs("td",{className:"px-4 py-3 text-muted-foreground hidden md:table-cell whitespace-nowrap",children:[Tu(I.startDate),I.endDate?` – ${Tu(I.endDate)}`:""]}),e.jsx("td",{className:"px-4 py-3 text-muted-foreground hidden lg:table-cell",children:I.cityVenue}),e.jsx("td",{className:"px-4 py-3",children:e.jsxs("div",{className:"flex items-center justify-end gap-2",children:[e.jsx("button",{onClick:()=>B(I),className:"text-xs text-muted-foreground hover:text-yellow-700 border border-border px-2 py-1 rounded-sm hover:bg-yellow-50 transition-colors",title:"Move back to pending",children:"Unpublish"}),e.jsx("button",{onClick:()=>E(I),className:"text-muted-foreground hover:text-primary transition-colors",title:"Edit",children:e.jsx(Vn,{size:15})}),e.jsx("button",{onClick:()=>H(I.id,I.title),className:"text-muted-foreground hover:text-destructive transition-colors",title:"Delete",children:e.jsx(Tn,{size:15})})]})})]},I.id))})]})})]})]})]})})]})}const t7={pending:"bg-yellow-100 text-yellow-800 border-yellow-300",approved:"bg-green-100 text-green-800 border-green-300",rejected:"bg-red-100 text-red-800 border-red-300"};function s7(){return e.jsx(kr,{pageTitle:"Manage Contest",children:e.jsx(a7,{})})}function a7(){const{user:t,isPending:a}=Us(),[r,o]=g.useState([]),[l,d]=g.useState(!0),[u,m]=g.useState(""),[p,x]=g.useState(null),[b,y]=g.useState("all"),v=t==null?void 0:t.isAdmin;g.useEffect(()=>{!a&&v&&fetch("/api/admin/contest").then(S=>S.json()).then(S=>{o(S.submissions??[]),d(!1)}).catch(()=>{m("Failed to load submissions."),d(!1)})},[a,v]);async function w(S,z){x(S);try{if(!(await fetch(`/api/admin/contest/${S}`,{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify({status:z})})).ok)throw new Error;o(M=>M.map(P=>P.id===S?{...P,status:z}:P))}catch{alert("Failed to update status.")}finally{x(null)}}if(a)return null;if(!v)return e.jsxs("main",{className:"max-w-xl mx-auto px-4 py-16 text-center",children:[e.jsx("p",{className:"text-muted-foreground",children:"Admin access required."}),e.jsx(O,{to:"/",className:"text-primary underline mt-4 block",children:"Go home"})]});const C=b==="all"?r:r.filter(S=>S.status===b),A={all:r.length,pending:r.filter(S=>S.status==="pending").length,approved:r.filter(S=>S.status==="approved").length,rejected:r.filter(S=>S.status==="rejected").length};return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Contest Admin – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Admin review panel for the Western Dressage icon photo contest."}),e.jsx("link",{rel:"canonical",href:"https://totalhorsechannel.com/admin/contest"}),e.jsx("meta",{name:"robots",content:"noindex"})]}),e.jsxs("main",{className:"max-w-[1100px] mx-auto px-4 py-8",children:[e.jsxs("div",{className:"flex items-center justify-between mb-6 flex-wrap gap-3",children:[e.jsxs("div",{children:[e.jsx("h1",{className:"text-2xl font-bold text-primary",children:"Western Dressage Icon Contest"}),e.jsx("p",{className:"text-muted-foreground text-sm mt-1",children:"Review and approve photo submissions"})]}),e.jsxs("div",{className:"flex items-center gap-4",children:[e.jsx("a",{href:"/admin/contests",className:"text-sm text-primary underline",children:"All Contests"}),e.jsx("a",{href:"/#admin",className:"text-sm text-primary underline",children:"← Admin home"})]})]}),e.jsx("div",{className:"flex gap-2 mb-6 flex-wrap",children:["all","pending","approved","rejected"].map(S=>e.jsxs("button",{onClick:()=>y(S),className:["px-4 py-1.5 rounded-sm text-sm font-semibold border transition-colors capitalize",b===S?"bg-primary text-white border-primary":"bg-card text-foreground border-border hover:border-primary"].join(" "),children:[S," ",e.jsxs("span",{className:"opacity-70",children:["(",A[S],")"]})]},S))}),l&&e.jsx("p",{className:"text-muted-foreground",children:"Loading…"}),u&&e.jsx("p",{className:"text-destructive",children:e.jsx(_,{devId:"b45334",guard:{file:"src/pages/admin/contest.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionH
640ash:"sha256:ca00fccfb408989eddc401062c4d1219a6aceb6b9b55412357f1790862e8f178"},children:u})}),!l&&C.length===0&&e.jsx("p",{className:"text-muted-foreground text-sm",children:"No submissions in this category."}),e.jsx("div",{className:"grid gap-4 grid-cols-1 sm:grid-cols-2 lg:grid-cols-3",children:C.map(S=>e.jsxs("div",{className:"border border-border rounded-sm overflow-hidden bg-card flex flex-col",children:[e.jsx("div",{className:"aspect-square bg-black overflow-hidden",children:e.jsx("img",{src:S.imageUrl,alt:S.horseName,className:"w-full h-full object-contain",loading:"lazy"})}),e.jsxs("div",{className:"p-3 flex flex-col gap-2 flex-1",children:[e.jsxs("div",{className:"flex items-start justify-between gap-2",children:[e.jsxs("div",{children:[e.jsx("p",{className:"font-semibold text-foreground text-sm",children:S.horseName}),S.ownerRider&&e.jsx("p",{className:"text-xs text-muted-foreground",children:S.ownerRider})]}),e.jsx("span",{className:`shrink-0 text-xs font-semibold px-2 py-0.5 rounded border capitalize ${t7[S.status]}`,children:S.status})]}),e.jsxs("div",{className:"text-xs text-muted-foreground space-y-0.5",children:[e.jsxs("p",{children:["Submitted by: ",e.jsx("span",{className:"text-foreground",children:S.userName??"—"})]}),e.jsx("p",{className:"break-all",children:S.userEmail??""}),e.jsxs("p",{children:["Votes: ",e.jsx("span",{className:"text-foreground font-semibold",children:S.voteCount})]}),e.jsx("p",{children:new Date(S.createdAt).toLocaleDateString("en-US",{month:"short",day:"numeric",year:"numeric",hour:"2-digit",minute:"2-digit"})})]}),e.jsxs("div",{className:"flex gap-2 mt-auto pt-2 flex-wrap",children:[S.status!=="approved"&&e.jsxs("button",{disabled:p===S.id,onClick:()=>w(S.id,"approved"),className:"flex items-center gap-1 px-3 py-1.5 text-xs font-semibold bg-green-600 text-white rounded-sm hover:bg-green-700 disabled:opacity-50 transition-colors",children:[e.jsx(eo,{size:13})," Approve"]}),S.status!=="rejected"&&e.jsxs("button",{disabled:p===S.id,onClick:()=>w(S.id,"rejected"),className:"flex items-center gap-1 px-3 py-1.5 text-xs font-semibold bg-destructive text-white rounded-sm hover:opacity-90 disabled:opacity-50 transition-colors",children:[e.jsx($m,{size:13})," Reject"]}),S.status!=="pending"&&e.jsxs("button",{disabled:p===S.id,onClick:()=>w(S.id,"pending"),className:"flex items-center gap-1 px-3 py-1.5 text-xs font-semibold bg-muted text-muted-foreground rounded-sm hover:bg-border disabled:opacity-50 transition-colors",children:[e.jsx(r2,{size:13})," Reset"]})]})]})]},S.id))})]})]})}const dN=[{key:"all",label:"All Contests"},{key:"western-dressage",label:"Western Dressage Icon",note:"Photo"},{key:"horse-music-video",label:"Horse Music Video",note:"Video"},{key:"reined-cow-horse",label:"Reined Cow Horse",note:"Video"},{key:"miniature-horse",label:"Miniature Horse",note:"Video"},{key:"reining",label:"Reining",note:"Video"}],n7={pending:"bg-yellow-100 text-yellow-800 border-yellow-300",approved:"bg-green-100  text-green-800  border-green-300",rejected:"bg-red-100    text-red-800    border-red-300"};function r7(){return e.jsx(kr,{pageTitle:"Manage Contests",children:e.jsx(i7,{})})}function i7(){const[t,a]=g.useState([]),[r,o]=g.useState(!0),[l,d]=g.useState(""),[u,m]=g.useState(null),[p,x]=g.useState("all"),[b,y]=g.useState("all");g.useEffect(()=>{fetch("/api/admin/contests",{credentials:"include"}).then(S=>S.json()).then(S=>{a(S.entries??[]),o(!1)}).catch(()=>{d("Failed to load entries."),o(!1)})},[]);async function v(S,z){m(S.id);try{if(!(await fetch(`/api/admin/contests/${S.id}`,{method:"PATCH",credentials:"include",headers:{"Content-Type":"application/json"},body:JSON.stringify({status:z,contestType:S.contestType})})).ok)throw new Error;a(M=>M.map(P=>P.id===S.id?{...P,status:z}:P))}catch{alert("Failed to update status.")}finally{m(null)}}const w=t.filter(S=>{const z=p==="all"||S.contestType===p,T=b==="all"||S.status===b;return z&&T});function C(S){return S==="all"?t.length:t.filter(z=>z.contestType===S).length}const A={all:w.length,pending:w.filter(S=>S.status==="pending").length,approved:w.filter(S=>S.status==="approved").length,rejected:w.filter(S=>S.status==="rejected").length};return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Admin – Contests | Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Admin contest entry review panel for Total Horse Channel."}),e.jsx("link",{rel:"canonical",href:"https://totalhorsechannel.com/admin/contests"}),e.jsx("meta",{name:"robots",content:"noindex"})]}),e.jsx("main",{children:e.jsxs("div",{className:"max-w-[1280px] mx-auto px-4 py-4",children:[e.jsxs("div",{className:"bg-primary px-3 py-2 mb-6 flex items-center gap-4 flex-wrap",children:[e.jsx("h1",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Admin – Contests"}),e.jsx("a",{href:"/admin/articles",className:"text-white/70 hover:text-white text-xs transition-colors",children:"Articles"}),e.jsx("a",{href:"/admin/live-events",className:"text-white/70 hover:text-white text-xs transition-colors",children:"Live Events"}),e.jsx("a",{href:"/admin/users",className:"text-white/70 hover:text-white text-xs transition-colors",children:"Users"})]}),e.jsx("div",{className:"flex gap-2 mb-4 flex-wrap",children:dN.map(S=>e.jsxs("button",{onClick:()=>x(S.key),className:["px-3 py-1.5 rounded-sm text-xs font-semibold border transition-colors",p===S.key?"bg-primary text-white border-primary":"bg-card text-foreground border-border hover:border-primary"].join(" "),children:[S.label,S.note&&e.jsxs("span",{className:"ml-1 opacity-60",children:["(",S.note,")"]}),e.jsx("span",{className:"ml-1 opacity-70",children:C(S.key)})]},S.key))}),e.jsx("div",{className:"flex gap-2 mb-6 flex-wrap",children:["all","pending","approved","rejected"].map(S=>e.jsxs("button",{onClick:()=>y(S),className:["px-3 py-1.5 rounded-sm text-xs font-semibold border transition-colors capitalize",b===S?"bg-secondary text-white border-secondary":"bg-card text-foreground border-border hover:border-secondary"].join(" "),children:[S," ",e.jsxs("span",{className:"opacity-70",children:["(",A[S],")"]})]},S))}),r&&e.jsx("p",{className:"text-muted-foreground text-sm",children:"Loading entr
640ies…"}),l&&e.jsx("p",{className:"text-destructive text-sm",children:e.jsx(_,{devId:"32873b",guard:{file:"src/pages/admin/contests.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:ca00fccfb408989eddc401062c4d1219a6aceb6b9b55412357f1790862e8f178"},children:l})}),!r&&w.length===0&&e.jsx("p",{className:"text-muted-foreground text-sm",children:"No entries match this filter."}),e.jsx("div",{className:"grid gap-4 grid-cols-1 sm:grid-cols-2 lg:grid-cols-3 xl:grid-cols-4",children:w.map(S=>e.jsx(o7,{entry:S,busy:u===S.id,onSetStatus:z=>v(S,z)},S.id))})]})})]})}function o7({entry:t,busy:a,onSetStatus:r}){var d;const o=((d=dN.find(u=>u.key===t.contestType))==null?void 0:d.label)??t.contestType,l=new Date(t.createdAt).toLocaleDateString("en-US",{month:"short",day:"numeric",year:"numeric"});return e.jsxs("div",{className:"border border-border rounded-sm overflow-hidden bg-card flex flex-col",children:[e.jsx("div",{className:"bg-black",style:{aspectRatio:"16/9",overflow:"hidden"},children:t.mediaKind==="photo"?e.jsx("img",{src:t.mediaUrl,alt:t.title,className:"w-full h-full object-contain",loading:"lazy"}):e.jsxs("div",{className:"w-full h-full flex flex-col items-center justify-center gap-2 px-3",children:[e.jsx(Vs,{size:28,className:"text-white/40"}),e.jsxs("a",{href:t.mediaUrl,target:"_blank",rel:"noopener noreferrer",className:"text-xs text-primary underline break-all text-center flex items-center gap-1",children:[e.jsx(dt,{size:11}),t.mediaUrl.length>50?t.mediaUrl.slice(0,50)+"…":t.mediaUrl]})]})}),e.jsxs("div",{className:"p-3 flex flex-col gap-2 flex-1",children:[e.jsxs("div",{className:"flex items-center justify-between gap-2 flex-wrap",children:[e.jsxs("span",{className:"text-xs font-semibold text-muted-foreground flex items-center gap-1",children:[t.mediaKind==="photo"?e.jsx(s2,{size:11}):e.jsx(Vs,{size:11}),o]}),e.jsx("span",{className:`shrink-0 text-xs font-semibold px-2 py-0.5 rounded border capitalize ${n7[t.status]}`,children:e.jsx(_,{devId:"269b30",guard:{file:"src/pages/admin/contests.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:015249ba8a63dc5e79da7185c12d4edc1fc13ca753b97598495d6baaf2237533"},children:t.status})})]}),e.jsx("p",{className:"font-semibold text-foreground text-sm leading-snug",children:e.jsx(_,{devId:"48aa99",guard:{file:"src/pages/admin/contests.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:39826505764bdec41759aa2ebe688cd14e946e46d64e68c59eaeee9f5d036a25"},children:t.title})}),t.ownerRider&&e.jsx("p",{className:"text-xs text-muted-foreground -mt-1",children:e.jsx(_,{devId:"48aa9a",guard:{file:"src/pages/admin/contests.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:2df0cae10b9be59128aa4f3e95d9404d2e6d791a06c360c11d026714b852cef1"},children:t.ownerRider})}),e.jsxs("div",{className:"text-xs text-muted-foreground space-y-0.5",children:[e.jsxs("p",{children:["Submitted by:"," ",t.submitterUsername?e.jsx("a",{href:`/u/${t.submitterUsername}`,target:"_blank",rel:"noopener noreferrer",className:"text-primary underline",children:e.jsx(_,{devId:"5a86c0",guard:{file:"src/pages/admin/contests.tsx",tagName:"a",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:c9e43671f12c5414722622328c946922a2cdbb93ff9171cc0170fb67e82e0c04"},children:t.submitterUsername})}):e.jsx("span",{className:"text-foreground",children:"—"})]}),t.submitterEmail&&e.jsx("p",{className:"break-all",children:e.jsx(_,{devId:"051eef",guard:{file:"src/pages/admin/contests.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:55e8f1cc95e74244be08d6d6911eefcee78409f6aa2ea7367bad324685821696"},children:t.submitterEmail})}),e.jsx("p",{children:e.jsx(_,{devId:"051ef0",guard:{file:"src/pages/admin/contests.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:ae932f00ab4e9506f916753605bd77f068194ab4834cb7581cd94762c3cf50ac"},children:l})})]}),e.jsxs("div",{className:"flex gap-2 mt-auto pt-2 flex-wrap",children:[t.status!=="approved"&&e.jsxs("button",{disabled:a,onClick:()=>r("approved"),className:"flex items-center gap-1 px-3 py-1.5 text-xs font-semibold bg-green-600 text-white rounded-sm hover:bg-green-700 disabled:opacity-50 transition-colors",children:[e.jsx(eo,{size:13})," Approve"]}),t.status!=="rejected"&&e.jsxs("button",{disabled:a,onClick:()=>r("rejected"),className:"flex items-center gap-1 px-3 py-1.5 text-xs font-semibold bg-destructive text-white rounded-sm hover:opacity-90 disabled:opacity-50 transition-colors",children:[e.jsx($m,{size:13})," Reject"]}),t.status!=="pending"&&e.jsxs("button",{disabled:a,onClick:()=>r("pending"),className:"flex items-center gap-1 px-3 py-1.5 text-xs font-semibold bg-muted text-muted-foreground rounded-sm hover:bg-border disabled:opacity-50 transition-colors",children:[e.jsx(r2,{size:13})," Reset"]})]})]})]})}const l7={single:"$100 — One article",two_pack:"$175 — Two articles",homepage_6mo:"$300 — Homepage link 6 months",homepage_1yr:"$525 — Homepage link 1 year",social_boost:"$35 — Social boost",existing:"Existing agreement"},c7={pending:"bg-yellow-100 text-yellow-800",published:"bg-green-100 text-green-800",unpublished:"bg-gray-100 text-gray-600"};function mw(t){if(!t)return"—";const a=new Date(t);return isNaN(a.getTime())?"—":a.toLocaleDateString("en-US",{month:"short",day:"numeric",year:"numeric"})}function d7(t){if(!t)return[];try{return JSON.parse(t)}catch{return[]}}function u7(){return e.jsx(kr,{pageTitle:"Manage News",children:e.jsx(m7,{})})}function m7(){const{user:t,isPending:a}=Us(),r=(t==null?void 0:t.isAdmin)===!0,[o,l]=g.useState([]),[d,u]=g.useState(!0),[m,p]=g.useState(null),[x,b]=g.useState("all"),[y,v]=g.useState(null),w=g.useCallback(()=>{u(!0),fetch("/api/admin/news").then(T=>T.json()).then(T=>l(T.articles??[])).catch(()=>{}).finally(()=>u(!1))},[]);if(g.useEffect(()=>{w()},[w]),a)return null;if(!r)return e.jsx(yi,{to:"/",replace:!0});async function C(T,M){v(T);try{await fetch(`/api/admin/news/${T}`,{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify(M)}),w()}finally{v(null)}}
640async function A(T,M){if(confirm(`Delete "${M}"? This cannot be undone.`)){v(T);try{await fetch(`/api/admin/news/${T}`,{method:"DELETE"}),w()}finally{v(null)}}}const S=x==="all"?o:o.filter(T=>T.status===x),z={all:o.length,pending:o.filter(T=>T.status==="pending").length,published:o.filter(T=>T.status==="published").length,unpublished:o.filter(T=>T.status==="unpublished").length};return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Admin — News Articles – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Admin panel for managing news article submissions on Total Horse Channel."}),e.jsx("link",{rel:"canonical",href:"https://totalhorsechannel.com/admin/news"}),e.jsx("meta",{name:"robots",content:"noindex,nofollow"})]}),e.jsx("main",{children:e.jsxs("div",{className:"max-w-[1100px] mx-auto px-4 py-6",children:[e.jsxs("div",{className:"bg-primary px-3 py-2 mb-5 flex items-center justify-between",children:[e.jsx("h1",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Admin — News Articles"}),e.jsx(O,{to:"/news",className:"text-white/80 hover:text-white text-xs",children:"View public page →"})]}),e.jsx("div",{className:"flex gap-1 mb-5 flex-wrap",children:["all","pending","published","unpublished"].map(T=>e.jsxs("button",{onClick:()=>b(T),className:`px-3 py-1.5 text-xs font-semibold uppercase border transition-colors ${x===T?"bg-primary text-white border-primary":"border-border text-muted-foreground hover:bg-muted"}`,children:[T," (",z[T],")"]},T))}),d&&e.jsx("div",{className:"text-sm text-muted-foreground py-6 text-center",children:"Loading…"}),!d&&S.length===0&&e.jsx("div",{className:"text-sm text-muted-foreground py-6 text-center border border-border bg-card",children:"No articles."}),!d&&S.length>0&&e.jsx("div",{className:"flex flex-col gap-3",children:S.map(T=>{const M=m===T.id,P=d7(T.links),E=y===T.id;return e.jsxs("div",{className:"border border-border bg-card",children:[e.jsxs("div",{className:"flex items-start gap-3 px-4 py-3",children:[e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsxs("div",{className:"flex items-center gap-2 flex-wrap mb-1",children:[e.jsx("span",{className:`text-xs font-semibold px-2 py-0.5 rounded ${c7[T.status]}`,children:T.status}),(T.isComp===!0||T.isComp===1)&&e.jsx("span",{className:"text-xs font-semibold px-2 py-0.5 rounded bg-blue-100 text-blue-800",children:"COMP"}),e.jsx("span",{className:"text-xs text-muted-foreground",children:l7[T.package]??T.package})]}),e.jsx("p",{className:"font-bold text-foreground text-sm leading-snug mb-0.5",children:T.title}),e.jsxs("div",{className:"flex items-center gap-3 text-xs text-muted-foreground flex-wrap",children:[e.jsxs("span",{children:[T.authorName," <",T.authorEmail,">"]}),e.jsxs("span",{className:"flex items-center gap-1",children:[e.jsx(ys,{size:10}),mw(T.createdAt)]}),T.publishedAt&&e.jsxs("span",{children:["Published ",mw(T.publishedAt)]})]})]}),e.jsxs("div",{className:"flex items-center gap-1.5 shrink-0 flex-wrap justify-end",children:[e.jsxs("a",{href:`/news/${T.slug}`,target:"_blank",rel:"noopener noreferrer",className:"flex items-center gap-1 text-xs border border-border px-2 py-1 hover:bg-muted transition-colors",title:"Preview",children:[e.jsx(xa,{size:12})," Preview"]}),T.status!=="published"&&e.jsxs("button",{disabled:E,onClick:()=>C(T.id,{status:"published"}),className:"flex items-center gap-1 text-xs bg-green-600 text-white px-2 py-1 hover:bg-green-700 transition-colors disabled:opacity-50",children:[e.jsx(Ea,{size:12})," Publish"]}),T.status==="published"&&e.jsxs("button",{disabled:E,onClick:()=>C(T.id,{status:"unpublished"}),className:"flex items-center gap-1 text-xs bg-gray-500 text-white px-2 py-1 hover:bg-gray-600 transition-colors disabled:opacity-50",children:[e.jsx(Vt,{size:12})," Unpublish"]}),e.jsx("button",{disabled:E,onClick:()=>C(T.id,{isComp:!(T.isComp===!0||T.isComp===1)}),className:`flex items-center gap-1 text-xs px-2 py-1 border transition-colors disabled:opacity-50 ${T.isComp===!0||T.isComp===1?"bg-blue-100 text-blue-800 border-blue-300":"border-border text-muted-foreground hover:bg-muted"}`,title:"Toggle comp / custom rate",children:"Comp"}),e.jsx("button",{disabled:E,onClick:()=>A(T.id,T.title),className:"flex items-center gap-1 text-xs text-destructive border border-destructive/30 px-2 py-1 hover:bg-destructive/10 transition-colors disabled:opacity-50",children:e.jsx(Tn,{size:12})}),e.jsx("button",{onClick:()=>p(M?null:T.id),className:"flex items-center gap-1 text-xs border border-border px-2 py-1 hover:bg-muted transition-colors",children:M?e.jsx(Zc,{size:12}):e.jsx($n,{size:12})})]})]}),M&&e.jsxs("div",{className:"border-t border-border px-4 py-4 bg-muted/30 text-sm flex flex-col gap-3",children:[T.note&&e.jsxs("div",{children:[e.jsx("p",{className:"text-xs font-semibold text-muted-foreground uppercase mb-1",children:"Note from submitter"}),e.jsx("p",{className:"text-foreground",children:T.note})]}),T.imageUrl&&e.jsxs("div",{children:[e.jsx("p",{className:"text-xs font-semibold text-muted-foreground uppercase mb-1",children:"Image"}),e.jsxs("a",{href:T.imageUrl,target:"_blank",rel:"noopener noreferrer",className:"text-accent hover:underline text-xs flex items-center gap-1",children:[e.jsx(dt,{size:11}),T.imageUrl]})]}),T.videoUrl&&e.jsxs("div",{children:[e.jsx("p",{className:"text-xs font-semibold text-muted-foreground uppercase mb-1",children:"Video"}),e.jsx("p",{className:"text-xs text-foreground break-all",children:T.videoUrl})]}),P.length>0&&e.jsxs("div",{children:[e.jsx("p",{className:"text-xs font-semibold text-muted-foreground uppercase mb-1",children:"Do-follow links"}),e.jsx("ul",{className:"flex flex-col gap-1",children:P.map((U,q)=>e.jsxs("li",{className:"flex items-center gap-1.5 text-xs",children:[e.jsx(dt,{size:10,
640className:"shrink-0 text-muted-foreground"}),e.jsx("a",{href:U.url,target:"_blank",rel:"noopener noreferrer",className:"text-accent hover:underline",children:U.label||U.url}),e.jsxs("span",{className:"text-muted-foreground",children:["(",U.url,")"]})]},q))})]}),e.jsxs("div",{children:[e.jsx("p",{className:"text-xs font-semibold text-muted-foreground uppercase mb-1",children:"Article body (preview)"}),e.jsx("p",{className:"text-foreground whitespace-pre-wrap text-xs leading-relaxed max-h-[200px] overflow-y-auto border border-border bg-background p-2",children:T.body})]}),e.jsx("div",{className:"flex gap-2 flex-wrap",children:e.jsxs("a",{href:`/news/${T.slug}`,target:"_blank",rel:"noopener noreferrer",className:"text-xs text-accent hover:underline flex items-center gap-1",children:[e.jsx(dt,{size:11})," Open preview in new tab"]})})]})]},T.id)})})]})})]})}const h7=/\.(jpe?g|png|webp|avif)$/i,p7=/^https?:\/\/.+\.(com|net|org|io|co|uk|au|ca|de|fr|es|it|nl|ru|br|jp|cn|in|mx|ar|cl|pe|co\.uk|com\.au|co\.nz|co\.za)(\/|$)/i;function f7(t){return!t.startsWith("http")||h7.test(t.split("?")[0])?!1:p7.test(t)}function uN({url:t,onUrl:a,label:r="Article image"}){const o=g.useRef(null),[l,d]=g.useState(!1),[u,m]=g.useState(""),p="w-full border border-border bg-background text-foreground px-3 py-2 text-sm focus:outline-none focus:border-primary";async function x(y){if(m(""),!y.type.startsWith("image/")){m("Please select an image file (JPG, PNG, WebP, or AVIF).");return}if(y.size>8*1024*1024){m("Image must be under 8 MB.");return}d(!0);try{const v=new FormData;v.append("file",y);const w=await fetch("/api/news/upload-image",{method:"POST",body:v}),C=await w.json();if(!w.ok){m(C.error??"Upload failed.");return}a(C.url)}catch{m("Upload failed. Please try again.")}finally{d(!1)}}function b(y){if(y&&f7(y)){m("Please enter a direct image URL ending in .jpg, .png, .webp, or .avif — not a webpage link.");return}m(""),a(y)}return e.jsxs("div",{className:"flex flex-col gap-2",children:[e.jsxs("p",{className:"text-sm font-semibold text-foreground",children:[r," ",e.jsx("span",{className:"text-muted-foreground font-normal",children:"(optional)"})]}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsxs("button",{type:"button",disabled:l,onClick:()=>{var y;return(y=o.current)==null?void 0:y.click()},className:"flex items-center gap-1.5 border border-border text-sm px-3 py-2 hover:bg-muted transition-colors disabled:opacity-50 shrink-0",children:[e.jsx(ln,{size:14}),l?"Uploading…":"Upload image"]}),e.jsx("span",{className:"text-xs text-muted-foreground",children:"JPG, PNG, WebP, AVIF · max 8 MB"}),e.jsx("input",{ref:o,type:"file",accept:"image/jpeg,image/png,image/webp,image/avif",className:"hidden",onChange:y=>{var w;const v=(w=y.target.files)==null?void 0:w[0];v&&x(v),y.target.value=""}})]}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx("input",{type:"text",className:p+" flex-1",value:t,onChange:y=>b(y.target.value),placeholder:"Or paste a direct image URL (.jpg / .png / .webp)"}),t&&e.jsx("button",{type:"button",onClick:()=>{a(""),m("")},className:"text-muted-foreground hover:text-primary transition-colors shrink-0",title:"Clear",children:e.jsx(Vt,{size:15})})]}),t&&!u&&e.jsxs("div",{className:"flex items-start gap-3",children:[e.jsx("img",{src:t,alt:"Preview",className:"h-20 w-auto object-cover border border-border"}),e.jsxs("a",{href:t,target:"_blank",rel:"noopener noreferrer",className:"text-xs text-accent hover:underline flex items-center gap-1 mt-1",children:[e.jsx(dt,{size:11})," View full size"]})]}),u&&e.jsx("p",{className:"text-xs text-destructive",children:e.jsx(_,{devId:"48267c",guard:{file:"src/components/ArticleImageUpload.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:60dba8424719825bc387d45fcdbd93a4b1bd1b48ce230a1333ece3ea9a157c07"},children:u})})]})}const x7=g.lazy(()=>Fx(()=>import("./ArticleRichTextEditor-Cfo8kN2k.js"),__vite__mapDeps([0,1,2,3]))),g7={single:"$100 — One article",two_pack:"$175 — Two articles",homepage_6mo:"$300 — Homepage link 6 months",homepage_1yr:"$525 — Homepage link 1 year",social_boost:"$35 — Social boost",existing:"Existing agreement"},b7={draft:"bg-blue-50 text-blue-700 border border-blue-300",pen
640ding:"bg-yellow-100 text-yellow-800 border border-yellow-300",published:"bg-green-100 text-green-800 border border-green-300",unpublished:"bg-gray-100 text-gray-600 border border-gray-300"};function hw(t){if(!t)return"—";const a=new Date(t);return isNaN(a.getTime())?"—":a.toLocaleDateString("en-US",{month:"short",day:"numeric",year:"numeric"})}function Kx(t){if(!t)return[];try{return JSON.parse(t)}catch{return[]}}function y7(t){return t===!0||t===1}function v7({article:t,onSave:a,onCancel:r,saving:o}){const[l,d]=g.useState({title:t.title,body:t.body,imageUrl:t.imageUrl??"",imageCredit:t.imageCredit??"",videoUrl:t.videoUrl??"",note:t.note??"",links:Kx(t.links).length>0?Kx(t.links):[{label:"",url:""}]}),u="w-full border border-border bg-background text-foreground px-2 py-1.5 text-sm focus:outline-none focus:border-primary";function m(){l.links.length<4&&d(b=>({...b,links:[...b.links,{label:"",url:""}]}))}function p(b){d(y=>({...y,links:y.links.filter((v,w)=>w!==b)}))}function x(b,y,v){d(w=>({...w,links:w.links.map((C,A)=>A===b?{...C,[y]:v}:C)}))}return e.jsxs("div",{className:"border-t border-border px-4 py-4 bg-muted/20 flex flex-col gap-4",children:[e.jsx("p",{className:"text-xs font-semibold text-muted-foreground uppercase",children:"Edit article"}),e.jsxs("div",{children:[e.jsx("label",{className:"block text-xs font-semibold text-muted-foreground mb-1",children:"Title"}),e.jsx("input",{className:u,value:l.title,onChange:b=>d(y=>({...y,title:b.target.value}))})]}),e.jsxs("div",{children:[e.jsx("label",{className:"block text-xs font-semibold text-muted-foreground mb-1",children:"Body"}),e.jsx(g.Suspense,{fallback:e.jsx("div",{className:"border border-border bg-muted text-muted-foreground text-sm px-3 py-4 text-center",children:"Loading editor…"}),children:e.jsx(x7,{initialHtml:l.body,onChange:b=>d(y=>({...y,body:b})),minHeight:200})})]}),e.jsxs("div",{className:"flex flex-col gap-2",children:[e.jsx(uN,{url:l.imageUrl,onUrl:b=>d(y=>({...y,imageUrl:b})),label:"Article image"}),e.jsxs("div",{children:[e.jsx("label",{className:"block text-xs font-semibold text-muted-foreground mb-1",children:"Image credit / source link"}),e.jsx("input",{className:u,type:"text",value:l.imageCredit,onChange:b=>d(y=>({...y,imageCredit:b.target.value})),placeholder:"e.g. https://example.com/photo-source or 'Photo: Jane Doe'"})]})]}),e.jsxs("div",{children:[e.jsx("label",{className:"block text-xs font-semibold text-muted-foreground mb-1",children:"Video URL / embed"}),e.jsx("input",{className:u,type:"text",value:l.videoUrl,onChange:b=>d(y=>({...y,videoUrl:b.target.value})),placeholder:"YouTube, Rumble, or iframe…"})]}),e.jsxs("div",{children:[e.jsx("label",{className:"block text-xs font-semibold text-muted-foreground mb-1",children:"Do-follow links (up to 4)"}),e.jsxs("div",{className:"flex flex-col gap-2",children:[l.links.map((b,y)=>e.jsxs("div",{className:"flex gap-2 items-center",children:[e.jsx("input",{className:u+" flex-1",value:b.label,onChange:v=>x(y,"label",v.target.value),placeholder:"Link label"}),e.jsx("input",{className:u+" flex-[2]",type:"text",value:b.url,onChange:v=>x(y,"url",v.target.value),placeholder:"https://…"}),e.jsx("button",{type:"button",onClick:()=>p(y),className:"text-muted-foreground hover:text-primary transition-colors shrink-0",children:e.jsx(Vt,{size:14})})]},y)),l.links.length<4&&e.jsxs("button",{type:"button",onClick:m,className:"flex items-center gap-1 text-xs text-accent hover:underline self-start",children:[e.jsx(sl,{size:12})," Add link"]})]})]}),e.jsxs("div",{children:[e.jsx("label",{className:"block text-xs font-semibold text-muted-foreground mb-1",children:"Internal note"}),e.jsx("input",{className:u,value:l.note,onChange:b=>d(y=>({...y,note:b.target.value})),placeholder:"Internal note…"})]}),e.jsxs("div",{className:"flex gap-2",children:[e.jsxs("button",{disabled:o,onClick:()=>a(l),className:"flex items-center gap-1.5 bg-primary text-white text-xs font-bold px-3 py-1.5 hover:opacity-90 transition-opacity disabled:opacity-50",children:[e.jsx(_C,{size:12})," Save changes"]}),e.jsxs("button",{onClick:r,className:"flex items-center gap-1.5 border border-border text-muted-foreground text-xs px-3 py-1.5 hover:bg-muted transition-colors",children:[e.jsx($m,{size:12})," Cancel"]})]})]})}function j7(){return e.jsx(kr,{pageTitle:"Manage Articles",children:e.jsx(w7,{})})}function w7(){const{user:t,isPending:a}=Us(),r=(t==null?void 0:t.isAdmin)===!0,[o,l]=g.useState([]),[d,u]=g.useState(!0),[m,p]=g.useState("all"),[x,b]=g.useState(null),[y,v]=g.useState(null),[w,C]=g.useState(null),[A,S]=g.useState(""),z=g.useCallback(()=>{u(!0),fetch("/api/admin/news").then(H=>H.json()).then(H=>l(H.articles??[])).catch(()=>S("Failed to load articles.")).finally(()=>u(!1))},[]);if(g.useEffect(()=>{z()},[z]),a)return null;if(!r)return e.jsx(yi,{to:"/",replace:!0});async function T(H,J){C(H);try{const B=await fetch(`/api/admin/news/${H}`,{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify(J)});if(!B.ok){const Y=await B.json();S(Y.error??"Update failed.");return}z()}catch{S("Network error.")}finally{C(null)}}async function M(H,J){const B=J.links.filter(Y=>Y.url.trim());await T(H,{title:J.title.trim(),body:J.body.trim(),imageUrl:J.imageUrl.trim(),imageCredit:J.imageCredit.trim(),videoUrl:J.videoUrl.trim(),note:J.note.trim(),links:B}),v(null)}async function P(H,J){if(confirm(`Delete "${J}"?
641
642This cannot be undone.`)){C(H);try{await fetch(`/api/admin/news/${H}`,{method:"DELETE"}),z()}catch{S("Delete failed.")}finally{C(null)}}}const E={all:o.length,draft:o.filter(H=>H.status==="draft").length,pending:o.filter(H=>H.status==="pending").length,published:o.filter(H=>H.status==="published").length,unpublished:o.filter(H=>H.status==="unpublished").length},U=m==="all"?o:o.filter(H=>H.status===m),q="flex items-center gap-1 text-xs px-2.5 py-1.5 font-semibold transition-colors disabled:opacity-40";return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Admin – Articles | Total Horse Channel"}),e.jsx("meta",{name:"robots",content:"noindex,nofollow"}),e.jsx("meta",{name:"description",content:"Admin — manage news articles."}),e.jsx("link",{rel:"canonical",href:"https://totalhorsechannel.com/admin/articles"})]}),e.jsx("main",{children:e.jsxs("div",{className:"max-w-[1280px] mx-auto px-4 py-4",children:[e.jsxs("div",{className:"bg-primary px-3 py-2 mb-5 flex items-center justify-between gap-3 flex-wrap",children:[e.jsxs("div",{className:"flex items-center gap-4",children:[e.jsx("h1",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Admin – Articles"}),e.jsx("a",{href:"/admin/live-events",className:"text-white/70 hover:text-white text-xs transition-colors",children:"Live Events"}),e.jsx("a",{href:"/admin/users",className:"text-white/70 hover:text-white text-xs transition-colors",children:"Users"}),e.jsx("a",{href:"/admin/contests",className:"text-white/70 hover:text-white text-xs transition-colors",children:"Contests"}),e.jsx("a",{href:"/admin/events",className:"text-white/70 hover:text-white text-xs transition-colors",children:"Events"})]}),e.jsxs("a",{href:"/news/submit",target:"_blank",rel:"noopener noreferrer",className:"flex items-center gap-1.5 bg-white text-primary text-xs font-bold px-3 py-1.5 hover:bg-gray-100 transition-colors",children:[e.jsx(dt,{size:12})," Public submit form"]})]}),A&&e.jsxs("div",{className:"bg-red-50 border border-red-200 text-red-700 text-sm px-4 py-2 mb-4 flex items-center justify-between",children:[e.jsx("span",{children:e.jsx(_,{devId:"697b15",guard:{file:"src/pages/admin/articles.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionH
642ash:"sha256:ca00fccfb408989eddc401062c4d1219a6aceb6b9b55412357f1790862e8f178"},children:A})}),e.jsx("button",{onClick:()=>S(""),className:"text-red-400 hover:text-red-600",children:e.jsx(Vt,{size:14})})]}),e.jsx("div",{className:"flex gap-1 mb-5 flex-wrap",children:["all","draft","pending","published","unpublished"].map(H=>e.jsxs("button",{onClick:()=>p(H),className:`px-3 py-1.5 text-xs font-semibold uppercase border transition-colors ${m===H?"bg-primary text-white border-primary":"border-border text-muted-foreground hover:bg-muted"}`,children:[H," (",E[H],")"]},H))}),d&&e.jsx("div",{className:"text-sm text-muted-foreground py-8 text-center",children:"Loading…"}),!d&&U.length===0&&e.jsxs("div",{className:"text-sm text-muted-foreground py-8 text-center border border-border bg-card",children:["No ",m==="all"?"":m+" ","articles."]}),!d&&U.length>0&&e.jsx("div",{className:"flex flex-col gap-2",children:U.map(H=>{const J=w===H.id,B=x===H.id,Y=y===H.id,$=Kx(H.links),D=y7(H.isComp);return e.jsxs("div",{className:"border border-border bg-card",children:[e.jsxs("div",{className:"flex items-start gap-3 px-4 py-3",children:[e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsxs("div",{className:"flex items-center gap-2 flex-wrap mb-1",children:[e.jsx("span",{className:`text-xs font-semibold px-2 py-0.5 rounded-sm ${b7[H.status]}`,children:H.status}),D&&e.jsx("span",{className:"text-xs font-semibold px-2 py-0.5 rounded-sm bg-blue-100 text-blue-800 border border-blue-300",children:"COMP"}),e.jsx("span",{className:"text-xs text-muted-foreground",children:g7[H.package]??H.package})]}),e.jsx("p",{className:"font-bold text-foreground text-sm leading-snug mb-0.5 truncate",title:H.title,children:H.title}),e.jsxs("div",{className:"flex items-center gap-3 text-xs text-muted-foreground flex-wrap",children:[e.jsx("span",{className:"font-medium",children:H.authorName}),e.jsx("a",{href:`mailto:${H.authorEmail}`,className:"hover:underline text-accent",children:H.authorEmail}),e.jsxs("span",{className:"flex items-center gap-1",children:[e.jsx(ys,{size:10})," Submitted ",hw(H.createdAt)]}),H.publishedAt&&e.jsxs("span",{children:["Published ",hw(H.publishedAt)]})]})]}),e.jsxs("div",{className:"flex items-center gap-1 flex-wrap justify-end shrink-0",children:[e.jsxs("a",{href:`/news/${H.slug}?preview=1`,target:"_blank",rel:"noopener noreferrer",className:`${q} border border-border text-foreground hover:bg-muted`,title:"Preview",children:[e.jsx(xa,{size:12})," Preview"]}),e.jsxs("button",{disabled:J,onClick:()=>{v(Y?null:H.id),b(null)},className:`${q} border ${Y?"border-primary bg-primary/10 text-primary":"border-border text-foreground hover:bg-muted"}`,children:[e.jsx(Vn,{size:12})," Edit"]}),H.status!=="published"&&e.jsxs("button",{disabled:J,onClick:()=>T(H.id,{status:"published"}),className:`${q} bg-green-600 text-white hover:bg-green-700`,children:[e.jsx(Ea,{size:12})," Publish"]}),H.status==="published"&&e.jsxs("button",{disabled:J,onClick:()=>T(H.id,{status:"draft"}),className:`${q} bg-gray-500 text-white hover:bg-gray-600`,children:[e.jsx(Vt,{size:12})," Unpublish"]}),e.jsx("button",{disabled:J,onClick:()=>T(H.id,{isComp:!D}),title:"Toggle comp / custom rate",className:`${q} border ${D?"bg-blue-100 text-blue-800 border-blue-300":"border-border text-muted-foreground hover:bg-muted"}`,children:"Comp"}),e.jsx("button",{disabled:J,onClick:()=>P(H.id,H.title),className:`${q} border border-destructive/40 text-destructive hover:bg-destructive/10`,title:"Delete",children:e.jsx(Tn,{size:12})}),e.jsx("button",{onClick:()=>{b(B?null:H.id),v(null)},className:`${q} border border-border text-muted-foreground hover:bg-muted`,title:"Details",children:B?e.jsx(Zc,{size:12}):e.jsx($n,{size:12})})]})]}),Y&&e.jsx(v7,{article:H,saving:J,onSave:W=>M(H.id,W),onCancel:()=>v(null)}),B&&!Y&&e.jsxs("div",{className:"border-t border-border px-4 py-4 bg-muted/20 flex flex-col gap-3 text-sm",children:[H.note&&e.jsxs("div",{children:[e.jsx("p",{className:"text-xs font-semibold text-muted-foreground uppercase mb-1",children:"Note"}),e.jsx("p",{className:"text-foreground",children:H.note})]}),H.imageUrl&&e.jsxs("div",{children:[e.jsx("p",{className:"text-xs font-semibold text-muted-foreground uppercase mb-1",children:"Image"}),e.jsx("img",{src:H.imageUrl,alt:"",className:"h-24 w-auto object-cover border border-border mb-1"}),H.imageCredit&&e.jsxs("p",{className:"text-xs text-muted-foreground",children:["Credit: ",H.imageCredit]})]}),H.videoUrl&&e.jsxs("div",{children:[e.jsx("p",{className:"text-xs font-semibold text-muted-foreground uppercase mb-1",children:"Video"}),e.jsx("p",{className:"text-xs text-foreground break-all",children:H.videoUrl})]}),$.length>0&&e.jsxs("div",{children:[e.jsxs("p",{className:"text-xs font-semibold text-muted-foreground uppercase mb-1",children:["Do-follow links (",$.length,")"]}),e.jsx("ul",{className:"flex flex-col gap-1",children:$.map((W,I)=>e.jsxs("li",{className:"flex items-center gap-1.5 text-xs",children:[e.jsx(dt,{size:10,
642className:"shrink-0 text-muted-foreground"}),e.jsx("a",{href:W.url,target:"_blank",rel:"noopener noreferrer",className:"text-accent hover:underline",children:W.label||W.url}),W.label&&e.jsxs("span",{className:"text-muted-foreground",children:["(",W.url,")"]})]},I))})]}),e.jsxs("div",{children:[e.jsx("p",{className:"text-xs font-semibold text-muted-foreground uppercase mb-1",children:"Body preview"}),e.jsx("div",{className:"text-xs text-foreground leading-relaxed max-h-[220px] overflow-y-auto border border-border bg-background p-3 prose prose-sm max-w-none",dangerouslySetInnerHTML:{__html:H.body}})]}),e.jsxs("div",{children:[e.jsx("p",{className:"text-xs font-semibold text-muted-foreground uppercase mb-1",children:"Slug"}),e.jsxs("a",{href:`/news/${H.slug}?preview=1`,target:"_blank",rel:"noopener noreferrer",className:"text-accent hover:underline text-xs flex items-center gap-1",children:[e.jsx(dt,{size:11}),"/news/",H.slug]})]})]})]},H.id)})})]})})]})}const Ix="https://totalhorsechannel.com",_m=`${Ix}/contests`,N7={"@context":"https://schema.org","@type":"WebPage","@id":`${_m}#webpage`,name:"Contests – Total Horse Channel",url:_m,isPartOf:{"@id":`${Ix}/#website`},about:{"@id":`${Ix}/#organization`}},Bx=new Date("2026-09-20T04:00:00Z"),S7=new Date("2026-09-26T03:59:59Z");function C7(t){return t<new Date("2026-09-14T04:00:00Z")?"pre":t<Bx?"submissions":t<=S7?"voting":"closed"}function k7(){const[t,a]=g.useState(()=>new Date);g.useEffect(()=>{const d=setInterval(()=>a(new Date),1e3);return()=>clearInterval(d)},[]);const r=C7(t);let o=null;if(r==="submissions"){const d=Bx.getTime()-t.getTime();if(d>0){const u=Math.floor(d/1e3),m=Math.floor(u/86400),p=Math.floor(u%86400/3600),x=Math.floor(u%3600/60),b=u%60;m>0?o=`${m}d ${p}h ${String(x).padStart(2,"0")}m ${String(b).padStart(2,"0")}s`:o=`${p}h ${String(x).padStart(2,"0")}m ${String(b).padStart(2,"0")}s`}}let l=null;if(r==="submissions")try{const d=Intl.DateTimeFormat().resolvedOptions().timeZone;
642d.startsWith("America/New_York")||d.startsWith("America/Detroit")||d.startsWith("America/Indiana")||d.startsWith("America/Kentucky")||(l=Bx.toLocaleString("en-US",{timeZone:d,month:"long",day:"numeric",year:"numeric",hour:"numeric",minute:"2-digit",timeZoneName:"short"}))}catch{}return{phase:r,countdown:o,localDeadline:l}}function T7({phase:t,countdown:a,localDeadline:r,isAuthenticated:o}){const[l,d]=g.useState([]),[u,m]=g.useState(!0),[p,x]=g.useState(""),[b,y]=g.useState(null),[v,w]=g.useState(""),C=g.useRef(null),A=g.useCallback(async()=>{try{const E=[...(await(await fetch("/api/contest/submissions")).json()).submissions??[]].sort((U,q)=>q.voteCount-U.voteCount||U.id.localeCompare(q.id));d(E),m(!1)}catch{x("Failed to load gallery. Please refresh."),m(!1)}},[]);g.useEffect(()=>{A();const M=t==="voting"?15e3:3e4;return C.current=setInterval(A,M),()=>{C.current&&clearInterval(C.current)}},[A,t]);async function S(M){if(!(!o||t!=="voting")){y(M),w("");try{const P=await fetch("/api/contest/vote",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({submissionId:M})}),E=await P.json();if(!P.ok){w(E.error??"Vote failed. Please try again.");return}d(U=>[...U.map(H=>H.id===M?{...H,votedByMe:!0,voteCount:E.voteCount??H.voteCount}:H)].sort((H,J)=>J.voteCount-H.voteCount||H.id.localeCompare(J.id)))}catch{w("Vote failed. Please try again.")}finally{y(null)}}}if(u)return e.jsx("div",{className:"grid gap-4",style:{gridTemplateColumns:"repeat(auto-fill, minmax(200px, 1fr))"},children:[1,2,3,4].map(M=>e.jsxs("div",{className:"border border-border rounded-sm overflow-hidden bg-card animate-pulse",children:[e.jsx("div",{className:"aspect-square bg-muted"}),e.jsxs("div",{className:"p-3 space-y-2",children:[e.jsx("div",{className:"h-3 bg-muted rounded w-3/4"}),e.jsx("div",{className:"h-3 bg-muted rounded w-1/2"})]})]},M))});if(p)return e.jsx("p",{className:"text-destructive text-sm py-4",children:e.jsx(_,{devId:"9d06f8",guard:{file:"src/pages/contests.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:ca00fccfb408989eddc401062c4d1219a6aceb6b9b55412357f1790862e8f178"},children:p})});if(t==="pre")return e.jsxs("div",{className:"border border-dashed border-border rounded-sm px-6 py-10 text-center",children:[e.jsx(Ms,{size:28,className:"text-muted-foreground mx-auto mb-3"}),e.jsx("p",{className:"text-foreground font-semibold text-sm",children:"Entries will appear after submissions open."}),e.jsx("p",{className:"text-muted-foreground text-xs mt-1",children:"Submissions open September 14, 2026."})]});if(l.length===0)return e.jsx("div",{className:"border border-dashed border-border rounded-sm px-6 py-10 text-center",children:e.jsx("p",{className:"text-muted-foreground text-sm",children:e.jsx(_,{devId:"f8ee0c",guard:{file:"src/pages/contests.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:39f587d8eebcb39c7dc2b917794a868ed86273021d2f30da66b857a7031e0d82"},children:t==="submissions"?"No approved photos yet — check back soon.":"No entries to display."})})});const z=t==="voting",T=t==="voting"||t==="closed";return e.jsxs("div",{children:[T&&l.length>0&&e.jsxs("div",{className:"flex items-center gap-2 mb-4 px-1",children:[e.jsx(kC,{size:15,className:"text-primary shrink-0"}),e.jsx("span",{className:"text-xs font-semibold text-muted-foreground uppercase tracking-wide",children:e.jsx(_,{devId:"917002",guard:{file:"src/pages/contests.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:c239fd257d272ecce323c6cb340d1ee7e68e70f17eaa62ac4273013b7803592a"},children:t==="voting"?"Live leaderboard — updates every 15 seconds":"Final results"})}),t==="voting"&&e.jsxs("span",{className:"ml-auto inline-flex items-center gap-1 text-xs text-green-700 font-semibold",children:[e.jsx("span",{className:"inline-block w-1.5 h-1.5 rounded-full bg-green-500 animate-pulse"}),"Live · 1 vote per entry per day"]})]}),t==="submissions"&&e.jsx("div",{className:"bg-muted border border-border rounded-sm px-4 py-3 mb-4 text-sm text-muted-foreground",children:e.jsxs("div",{className:"flex items-start gap-2",children:[e.jsx(Ms,{size:14,className:"shrink-0 text-primary mt-0.5"}),e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsxs("span",{children:["Submissions close and voting opens"," ",e.jsx("strong",{className:"text-foreground",children:"September 20, 2026 at 12:00 AM Eastern"}),"."]}),r&&e.jsxs("span",{className:"block text-xs mt-0.5 text-muted-foreground",children:["That's ",e.jsx("strong",{className:"text-foreground",children:r})," in your local time."]}),a&&e.jsx("span",{className:"block mt-1.5 font-mono font-bold text-primary text-base tracking-tight",children:e.jsx(_,{devId:"10b68d",guard:{file:"src/pages/contests.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionH
642ash:"sha256:3d7e7ef210f4b36194bb54a0c5eed678e00bd52774f1a2abfb5bd9095d4ac05a"},children:a})})]})]})}),v&&e.jsx("p",{className:"text-destructive text-sm mb-3 px-1",children:e.jsx(_,{devId:"f8ee0c",guard:{file:"src/pages/contests.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:63b74c42f96e121b427676cd1110a2060a29cee537b9d7883280ae1dcc36addf"},children:v})}),z&&!o&&e.jsxs("div",{className:"flex items-center gap-3 bg-muted border border-border rounded-sm px-4 py-2.5 mb-4 text-sm",children:[e.jsx(n2,{size:14,className:"shrink-0 text-primary"}),e.jsxs("span",{className:"text-muted-foreground",children:[e.jsx(O,{to:"/login",className:"text-primary font-semibold hover:underline",children:"Log in"})," ","or"," ",e.jsx(O,{to:"/become-member",className:"text-primary font-semibold hover:underline",children:"create an account"})," ","to vote."]})]}),e.jsx("div",{className:"grid gap-4",style:{gridTemplateColumns:"repeat(auto-fill, minmax(200px, 1fr))"},children:l.map((M,P)=>e.jsxs("div",{className:"border border-border rounded-sm overflow-hidden bg-card flex flex-col",children:[T&&e.jsxs("div",{className:["px-2 py-1 text-xs font-bold flex items-center gap-1.5",P===0?"bg-yellow-400 text-yellow-900":P===1?"bg-gray-300 text-gray-700":P===2?"bg-amber-600 text-white":"bg-muted text-muted-foreground"].join(" "),children:[P===0?"🥇":P===1?"🥈":P===2?"🥉":`#${P+1}`,e.jsxs("span",{className:"ml-auto",children:[M.voteCount," ",M.voteCount===1?"vote":"votes"]})]}),e.jsx("div",{className:"bg-black overflow-hidden",style:{aspectRatio:"1/1"},children:e.jsx("img",{src:M.imageUrl,alt:M.horseName,className:"w-full h-full object-contain",loading:"lazy",width:400,height:400})}),e.jsxs("div",{className:"p-3 flex flex-col gap-2 flex-1",children:[e.jsxs("div",{children:[e.jsx("p",{className:"font-semibold text-foreground text-sm leading-tight",children:M.horseName}),M.ownerRider&&e.jsx("p",{className:"text-xs text-muted-foreground mt-0.5 leading-tight",children:M.ownerRider})]}),z&&e.jsxs("button",{onClick:()=>!M.votedByMe&&S(M.id),disabled:!o||b===M.id||M.votedByMe,title:o?M.votedByMe?"You voted today — come back tomorrow to vote again":"Vote for this photo":"Log in to vote",className:["mt-auto flex items-center justify-center gap-1.5 py-2 rounded-sm text-xs font-semibold transition-colors",M.votedByMe?"bg-primary text-white opacity-80 cursor-default":o?"bg-muted text-foreground hover:bg-primary hover:text-white":"bg-muted text-muted-foreground cursor-not-allowed opacity-60"].join(" "),children:[e.jsx(Gn,{size:12}),e.jsx("span",{children:M.voteCount}),M.votedByMe&&e.jsx("span",{className:"text-xs",children:"✓ voted today"})]}),t==="submissions"&&e.jsxs("div",{className:"mt-auto flex items-center gap-1.5 text-xs text-muted-foreground",children:[e.jsx(so,{size:11}),e.jsx("span",{children:"Voting opens Sep 20"})]}),t==="closed"&&e.jsxs("div",{className:"mt-auto flex items-center gap-1.5 text-xs text-muted-foreground font-semibold",children:[e.jsx(Gn,{size:11}),e.jsxs("span",{children:[M.voteCount," ",M.voteCount===1?"vote":"votes"]})]})]})]},M.id))})]})}function A7({onClose:t}){const[a,r]=g.useState(""),[o,l]=g.useState(""),[d,u]=g.useState(""),[m,p]=g.useState(!1),[x,b]=g.useState(null),[y,v]=g.useState(!1);async function w(C){if(C.preventDefault(),b(null),!a.trim()){b("Please enter a title for your video.");return}if(!o.trim()){b("Please enter your Rumble or YouTube URL.");return}p(!0);try{const A=await fetch("/api/contest/music-video-entry",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({title:a.trim(),videoInput:o.trim(),thumbnailUrl:d.trim()||void 0})}),S=await A.json();if(!A.ok){b(S.error??"Submission failed. Please try again."),p(!1);return}v(!0)}catch{b("Network error. Please try again."),p(!1)}}return y?e.jsxs("div",{className:"border border-green-300 bg-green-50 rounded-sm p-5 text-center",children:[e.jsx(eo,{size:32,className:"text-green-600 mx-auto mb-2"}),e.jsx("p",{className:"font-semibold text-green-800 text-sm mb-1",children:"Entry submitted!"}),e.jsx("p",{className:"text-green-700 text-xs mb-3",children:"Your video has been saved to your profile and entered in the Horse Music Video Contest."}),e.jsx("button",{onClick:t,className:"text-xs text-green-700 underline hover:no-underline",children:"Close"})]}):e.jsxs("form",{onSubmit:w,noValidate:!0,className:"border border-border rounded-sm bg-muted/40 p-4 mt
642-3",children:[e.jsxs("div",{className:"flex items-center justify-between mb-3",children:[e.jsx("p",{className:"font-semibold text-foreground text-sm",children:"Submit your entry"}),e.jsx("button",{type:"button",onClick:t,className:"text-muted-foreground hover:text-foreground","aria-label":"Close form",children:e.jsx(Vt,{size:16})})]}),x&&e.jsx("p",{className:"text-xs text-destructive bg-destructive/10 border border-destructive/20 rounded-sm px-3 py-2 mb-3",children:e.jsx(_,{devId:"fa27fd",guard:{file:"src/pages/contests.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:ca00fccfb408989eddc401062c4d1219a6aceb6b9b55412357f1790862e8f178"},children:x})}),e.jsxs("div",{className:"space-y-3",children:[e.jsxs("div",{children:[e.jsxs("label",{htmlFor:"hmv-title",className:"block text-xs font-medium text-foreground mb-1",children:["Video title ",e.jsx("span",{className:"text-destructive",children:"*"})]}),e.jsx("input",{id:"hmv-title",type:"text",value:a,onChange:C=>r(C.target.value),placeholder:"e.g. Riding to the Rhythm",className:"w-full border border-input rounded-sm px-3 py-2 text-sm bg-background text-foreground placeholder:text-muted-foreground focus:outline-none focus:ring-1 focus:ring-ring"})]}),e.jsxs("div",{children:[e.jsxs("label",{htmlFor:"hmv-url",className:"block text-xs font-medium text-foreground mb-1",children:["Rumble or YouTube URL ",e.jsx("span",{className:"text-destructive",children:"*"})]}),e.jsx("input",{id:"hmv-url",type:"url",value:o,onChange:C=>l(C.target.value),placeholder:"https://rumble.com/v… or https://youtu.be/…",className:"w-full border border-input rounded-sm px-3 py-2 text-sm bg-background text-foreground placeholder:text-muted-foreground focus:outline-none focus:ring-1 focus:ring-ring"}),e.jsx("p",{className:"text-xs text-muted-foreground mt-1",children:"Rumble preferred. Must be a video you control."})]}),e.jsxs("div",{children:[e.jsxs("label",{htmlFor:"hmv-thumb",className:"block text-xs font-medium text-foreground mb-1",children:["Thumbnail URL ",e.jsx("span",{className:"text-muted-foreground font-normal",children:"(optional)"})]}),e.jsx("input",{id:"hmv-thumb",type:"url",value:d,onChange:C=>u(C.target.value),placeholder:"https://…",className:"w-full border border-input rounded-sm px-3 py-2 text-sm bg-background text-foreground placeholder:text-muted-foreground focus:outline-none focus:ring-1 focus:ring-ring"})]})]}),e.jsx("p",{className:"text-xs text-muted-foreground mt-3 mb-4 leading-relaxed",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"fa27fe",guard:{file:"src/pages/contests.tsx",tagName:"p",sourceKind:"content-key",contentKey:"contests.hmv.rightsDisclaimer",contentKeyTemplate:null,expressionHash:null},children:$s.hmv.rightsDisclaimer})}),e.jsxs("div",{className:"flex items-center gap-3",children:[e.jsxs("button",{type:"submit",disabled:m,className:"inline-flex items-center gap-2 px-5 py-2.5 rounded-sm font-semibold text-sm bg-primary text-white hover:opacity-90 transition-opacity disabled:opacity-60",children:[e.jsx(fi,{size:13}),m?"Submitting…":"Submit entry"]}),e.jsx("button",{type:"button",onClick:t,className:"text-xs text-muted-foreground hover:text-foreground",children:"Cancel"})]})]})}function E7({isAuthenticated:t,isPending:a}){const r=ga(),[o,l]=g.useState(!1);return e.jsxs("div",{id:"horse-music-video",className:"border border-border rounded-sm overflow-hidden bg-card mb-6",children:[e.jsx("div",{className:"h-1.5 bg-primary"}),e.jsxs("div",{className:"p-5 flex flex-col sm:flex-row gap-5",children:[e.jsx("div",{className:"shrink-0 flex items-start justify-center sm:justify-start",children:e.jsx("div",{className:"w-24 h-24 sm:w-28 sm:h-28 border border-border bg-muted rounded-sm flex items-center justify-center",children:e.jsx(og,{size:44,className:"text-primary"})})}),e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsxs("div",{className:"flex flex-wrap items-start gap-2 mb-2",children:[e.jsx("h2",{className:"text-foreground font-bold text-lg leading-tight",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"f6a114",guard:{file:"src/pages/contests.tsx",tagName:"h2",sourceKind:"content-key",contentKey:"contests.hmv.title",contentKeyTemplate:null,expressionH
642ash:null},children:$s.hmv.title})}),e.jsx("span",{className:"shrink-0 text-xs font-semibold px-2 py-0.5 rounded border bg-green-100 text-green-800 border-green-300",children:"Entries Open"})]}),e.jsx("p",{className:"text-muted-foreground text-sm mb-3 leading-relaxed",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"3cc6f6",guard:{file:"src/pages/contests.tsx",tagName:"p",sourceKind:"content-key",contentKey:"contests.hmv.description",contentKeyTemplate:null,expressionHash:null},children:$s.hmv.description})}),e.jsxs("div",{className:"flex flex-wrap gap-x-5 gap-y-1 mb-4 text-xs text-muted-foreground",children:[e.jsxs("span",{className:"text-primary font-semibold",children:[e.jsx(Ms,{size:11,className:"inline mr-1 -mt-0.5"}),e.jsx("span",{children:"Entries open now through "}),e.jsx("strong",{children:$s.hmv.entryDeadline})]}),e.jsx("span",{style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"92c50e",guard:{file:"src/pages/contests.tsx",tagName:"span",sourceKind:"content-key",contentKey:"contests.hmv.votingNote",contentKeyTemplate:null,expressionHash:null},children:$s.hmv.votingNote})}),e.jsxs("span",{children:[e.jsx("span",{children:"Prize: "}),e.jsx("strong",{children:$s.hmv.prize})]})]}),e.jsxs("div",{className:"mb-4 p-3 bg-muted rounded-sm border border-border text-xs text-muted-foreground space-y-1.5",children:[e.jsx("p",{className:"font-semibold text-foreground text-xs mb-2",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"98658c",guard:{file:"src/pages/contests.tsx",tagName:"p",sourceKind:"content-key",contentKey:"contests.hmv.platformBoxHeading",contentKeyTemplate:null,expressionHash:null},children:$s.hmv.platformBoxHeading})}),e.jsxs("div",{className:"flex flex-wrap gap-x-6 gap-y-1.5",children:[e.jsxs("a",{href:"https://rumble.com/register/TotalHorseChannel/",target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-1.5 text-primary hover:underline font-medium",children:[e.jsx("span",{className:"text-[10px] font-bold uppercase tracking-wide px-1.5 py-0.5 rounded-sm",style:{backgroundColor:"hsl(var(--rumble-brand))",color:"hsl(var(--rumble-brand-foreground))"},children:"Rumble"}),e.jsx("span",{style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"7bcf95",guard:{file:"src/pages/contests.tsx",tagName:"span",sourceKind:"content-key",contentKey:"contests.hmv.rumbleLabel",contentKeyTemplate:null,expressionHash:null},children:$s.hmv.rumbleLabel})})]}),e.jsxs("a",{href:"https://www.youtube.com/",target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-1.5 text-primary hover:underline font-medium",children:[e.jsx("span",{className:"text-[10px] font-bold uppercase tracking-wide bg-red-600 text-white px-1.5 py-0.5 rounded-sm",children:"YouTube"}),e.jsx("span",{style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"bda476",guard:{file:"src/pages/contests.tsx",tagName:"span",sourceKind:"content-key",contentKey:"contests.hmv.youtubeLabel",contentKeyTemplate:null,expressionHash:null},children:$s.hmv.youtubeLabel})})]})]})]}),e.jsxs("div",{className:"flex flex-wrap items-center gap-3",children:[a?null:t?e.jsxs("button",{onClick:()=>l(d=>!d),className:"inline-flex items-center gap-2 px-5 py-2.5 rounded-sm font-semibold text-sm bg-primary text-white hover:opacity-90 transition-opacity",children:[e.jsx(fi,{size:14}),o?"Hide form":"Submit entry"]}):e.jsxs("button",{onClick:()=>r("/login?redirect=/contests"),className:"inline-flex items-center gap-2 px-5 py-2.5 rounded-sm font-semibold text-sm bg-primary text-white hover:opacity-90 transition-opacity",children:[e.jsx(n2,{size:14}),"Register / Log in to enter"]}),e.jsx(O,{to:"/advertise#sponsor-a-contest",className:"text-accent hover:underline text-sm font-medium shrink-0",children:"Sponsor this contest"})]}),o&&t&&e.jsx(A7,{onClose:()=>l(!1)}),e.jsxs("p",{className:"text-xs text-muted-foreground mt-3",children:[e.jsx("span",{children:"Email the link to "}),e.jsx("a",{href:"mailto:[email protected]",className:"text-primary hover:underline",children:"[email protected]"}),e.jsxs("span",{style:{whiteSpace:"pre-line"},children:[" ",e.jsx(_,{devId:"e423fb",guard:{file:"src/pages/contests.tsx",tagName:"span",sourceKind:"content-key",contentKey:"contests.hmv.emailBackup",contentKeyTemplate:null,expressionH
642ash:null},children:$s.hmv.emailBackup})]})]})]})]}),e.jsxs("details",{className:"border-t border-border",children:[e.jsxs("summary",{className:"cursor-pointer px-5 py-3 text-xs font-semibold text-muted-foreground hover:text-foreground flex items-center gap-1.5 select-none list-none",children:[e.jsx(Lt,{size:13,className:"transition-transform [[open]_&]:rotate-90 shrink-0"}),"How to enter & contest rules"]}),e.jsx("ul",{className:"px-5 pb-4 space-y-1.5 text-xs text-muted-foreground list-disc list-inside leading-relaxed",children:$s.hmv.rules.map(d=>e.jsx("li",{style:{whiteSpace:"pre-line"},children:d.text},d.id))})]})]})}function H7({phase:t,countdown:a,localDeadline:r,isAuthenticated:o,isPending:l,mySubmission:d,loadingMine:u}){const p={pre:{label:"Opens September 14",cls:"bg-muted text-muted-foreground border-border"},submissions:{label:"Submissions Open",cls:"bg-green-100 text-green-800 border-green-300"},voting:{label:"Voting Open",cls:"bg-blue-100 text-blue-800 border-blue-300"},closed:{label:"Voting Closed",cls:"bg-muted text-muted-foreground border-border"}}[t];function x(){return l||u?null:t==="pre"?o?e.jsxs("span",{className:"inline-flex items-center gap-2 text-sm font-semibold text-green-700",children:[e.jsx(eo,{size:16})," You're registered — check back September 14"]}):e.jsx(O,{to:"/become-member",className:"inline-block px-5 py-2.5 rounded-sm font-semibold text-sm bg-primary text-white hover:opacity-90 transition-opacity",style:{textDecoration:"none"},children:"Create Account"}):t==="submissions"?o?d?e.jsxs("span",{className:"inline-flex items-center gap-2 text-sm font-semibold text-green-700",children:[e.jsx(eo,{size:16})," Photo submitted — voting opens September 20"]}):e.jsx(O,{to:"/breedsdisciplines#contest",className:"inline-block px-5 py-2.5 rounded-sm font-semibold text-sm bg-primary text-white hover:opacity-90 transition-opacity",style:{textDecoration:"none"},children:"Submit Photo"}):e.jsxs("div",{className:"flex flex-wrap gap-2",children:[e.jsx(O,{to:"/become-member",className:"inline-block px-5 py-2.5 rounded-sm font-semibold text-sm bg-primary text-white hover:opacity-90 transition-opacity",style:{textDecoration:"none"},children:"Create Account"}),e.jsx(O,{to:"/login",className:"inline-block px-5 py-2.5 rounded-sm font-semibold text-sm border-2 border-primary text-primary hover:bg-primary hover:text-white transition-colors",style:{textDecoration:"none"},children:"Log In to Enter"})]}):t==="voting"?e.jsxs("span",{className:"inline-flex items-center gap-2 text-sm font-semibold text-blue-700",children:[e.jsx(Gn,{size:15})," Voting is open — vote below!"]}):e.jsxs("span",{className:"inline-flex items-center gap-2 text-sm font-semibold text-muted-foreground",children:[e.jsx(so,{size:15})," Voting has closed — results below"]})}return e.jsxs("div",{className:"border border-border rounded-sm overflow-hidden bg-card mb-6",children:[e.jsx("div",{className:"h-1.5 bg-primary"}),e.jsxs("div",{className:"p-5 flex flex-col sm:flex-row gap-5",children:[e.jsx("div",{className:"shrink-0",children:e.jsx(O,{to:"/category/western-dressage",style:{textDecoration:"none"},children:e.jsx("div",{className:"w-24 h-24 sm:w-28 sm:h-28 overflow-hidden border border-border bg-black rounded-sm",children:e.jsx("img",{src:"/airo-assets/images/disciplines/western-dressage",alt:"Western Dressage",width:112,height:112,className:"w-full h-full object-cover",loading:"eager"})})})}),e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsxs("div",{className:"flex flex-wrap items-start gap-2 mb-2",children:[e.jsx("h2",{className:"text-foreground font-bold text-lg leading-tight",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"f6a114",guard:{file:"src/pages/contests.tsx",tagName:"h2",sourceKind:"content-key",contentKey:"contests.wdaa.title",contentKeyTemplate:null,expressionHash:null},children:$s.wdaa.title})}),e.jsx("span",{className:`shrink-0 text-xs font-semibold px-2 py-0.5 rounded border ${p.cls}`,children:e.jsx(_,{devId:"50f02c",guard:{file:"src/pages/contests.tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionH
642ash:"sha256:21464ea7044607cfb0f5d86535968c0054f389e079d88d1c8c67af8e187b771b"},children:p.label})})]}),e.jsx("p",{className:"text-muted-foreground text-sm mb-3 leading-relaxed",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"3cc6f6",guard:{file:"src/pages/contests.tsx",tagName:"p",sourceKind:"content-key",contentKey:"contests.wdaa.description",contentKeyTemplate:null,expressionHash:null},children:$s.wdaa.description})}),e.jsxs("div",{className:"flex flex-wrap gap-x-5 gap-y-1 mb-4 text-xs text-muted-foreground",children:[e.jsxs("span",{className:t==="pre"||t==="submissions"?"text-primary font-semibold":"",children:[e.jsx(Ms,{size:11,className:"inline mr-1 -mt-0.5"}),t==="submissions"&&a?e.jsxs("span",{children:["Voting opens in"," ",e.jsx("strong",{className:"font-mono",children:a}),r&&e.jsxs("span",{className:"font-normal text-muted-foreground",children:[" · ",r," your time"]})]}):e.jsxs(e.Fragment,{children:[e.jsx("span",{children:"Submissions: "}),e.jsx("strong",{children:$s.wdaa.submissionDates})]})]}),e.jsxs("span",{className:t==="voting"?"text-primary font-semibold":"",children:[e.jsx("span",{children:"Voting: "}),e.jsx("strong",{children:$s.wdaa.votingDates})]}),e.jsxs("span",{children:[e.jsx("span",{children:"Prize: "}),e.jsx("strong",{children:$s.wdaa.prize})]})]}),e.jsxs("div",{className:"flex flex-wrap items-center gap-3",children:[x(),e.jsxs(O,{to:"/breedsdisciplines#discipline-western-dressage",className:"text-sm text-primary hover:underline",style:{textDecoration:"none"},children:["Learn about Western Dressage ",e.jsx(Lt,{size:13,className:"inline -mt-0.5"})]})]}),e.jsxs("p",{className:"text-xs text-muted-foreground mt-2",children:["Sponsored by ",e.jsx("span",{className:"font-semibold text-foreground",children:"Total Horse Channel"})]})]})]}),e.jsxs("details",{className:"border-t border-border",children:[e.jsxs("summary",{className:"cursor-pointer px-5 py-3 text-xs font-semibold text-muted-foreground hover:text-foreground flex items-center gap-1.5 select-none list-none",children:[e.jsx(Lt,{size:13,className:"transition-transform [[open]_&]:rotate-90 shrink-0"}),"Contest rules"]}),e.jsx("ul",{className:"px-5 pb-4 space-y-1.5 text-xs text-muted-foreground list-disc list-inside leading-relaxed",children:$s.wdaa.rules.map(b=>e.jsx("li",{style:{whiteSpace:"pre-line"},children:b.text},b.id))})]})]})}function z7(){const{isAuthenticated:t,isPending:a}=Us(),{phase:r,countdown:o,localDeadline:l}=k7(),[d,u]=g.useState(null),[m,p]=g.useState(!1);return g.useEffect(()=>{t&&r==="submissions"&&(p(!0),fetch("/api/contest/my-submission").then(x=>x.json()).then(x=>{u(x.submission??null),p(!1)}).catch(()=>p(!1)))},[t,r]),e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Contests – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Enter photo and video contests on Total Horse Channel. Win prizes and have your content featured on TotalHorseChannel.com."}),e.jsx("link",{rel:"canonical",href:_m}),e.jsx("meta",{property:"og:title",content:"Contests – Total Horse Channel"}),e.jsx("meta",{property:"og:description",content:"Enter photo and video contests on Total Horse Channel. Win prizes and have your content featured on TotalHorseChannel.com."}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{property:"og:url",content:_m}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify(N7)})]}),e.jsx("main",{children:e.jsxs("div",{className:"max-w-[1280px] mx-auto px-4 py-8",children:[e.jsxs("div",{className:"flex items-center gap-3 mb-6",children:[e.jsx(Xs,{size:28,className:"text-primary shrink-0"}),e.jsxs("div",{children:[e.jsx("h1",{className:"text-primary font-bold italic text-2xl leading-tight",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"a0bab3",guard:{file:"src/pages/contests.tsx",tagName:"h1",sourceKind:"content-key",contentKey:"contests.pageHeading",contentKeyTemplate:null,expressionHash:null},children:$s.pageHeading})}),e.jsx("p",{className:"text-muted-foreground text-sm",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"62166a",guard:{file:"src/pages/contests.tsx",tagName:"p",sourceKind:"content-key",contentKey:"contests.pageSubheading",contentKeyTemplate:null,expressionH
642ash:null},children:$s.pageSubheading})})]})]}),e.jsxs("section",{className:"mb-10","aria-label":"Current contests",children:[e.jsxs("div",{className:"bg-primary px-4 py-2 mb-4 flex items-center gap-2",children:[e.jsx("span",{className:"inline-block w-2 h-2 rounded-full bg-white animate-pulse"}),e.jsx("h2",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Current Contests"})]}),e.jsxs("div",{id:"reining-icon",className:"border border-border rounded-sm overflow-hidden bg-card mb-6",children:[e.jsx("div",{className:"h-1.5 bg-primary"}),e.jsxs("div",{className:"p-5 flex flex-col sm:flex-row gap-5",children:[e.jsx("div",{className:"shrink-0",children:e.jsx(O,{to:"/category/reining",style:{textDecoration:"none"},children:e.jsx("div",{className:"w-24 h-24 sm:w-28 sm:h-28 overflow-hidden border border-border bg-black rounded-sm",children:e.jsx("img",{src:"/airo-assets/images/disciplines/reining",alt:"Reining",width:112,height:112,className:"w-full h-full object-cover",loading:"eager"})})})}),e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsxs("div",{className:"flex flex-wrap items-start gap-2 mb-2",children:[e.jsx("h2",{className:"text-foreground font-bold text-lg leading-tight",children:"Reining Category Icon Photo Contest"}),e.jsx("span",{className:"shrink-0 text-xs font-semibold px-2 py-0.5 rounded border bg-green-100 text-green-800 border-green-300",children:"Entries Open"})]}),e.jsx("p",{className:"text-muted-foreground text-sm mb-3 leading-relaxed",children:"Total Horse Channel is running this contest during the Low Roller Reining Classic. It is a THC contest, not a Low Roller or association contest. In honor of that week, we are choosing the Reining category image on TotalHorseChannel.com. The winning photo becomes the official Reining category image on TotalHorseChannel.com for one year."}),e.jsxs("div",{className:"flex flex-wrap gap-x-5 gap-y-1 mb-4 text-xs text-muted-foreground",children:[e.jsxs("span",{className:"text-primary font-semibold",children:[e.jsx(Ms,{size:11,className:"inline mr-1 -mt-0.5"}),e.jsx("span",{children:"Submissions: "}),e.jsx("strong",{children:"October 2 – October 10, 2026"})]}),e.jsxs("span",{children:[e.jsx("span",{children:"Voting: "}),e.jsx("strong",{children:"week of October 11"})]}),e.jsxs("span",{children:[e.jsx("span",{children:"Prize: "}),e.jsx("strong",{children:"$150 Visa gift card + category icon for one year"})]})]}),e.jsxs("div",{className:"flex flex-wrap items-center gap-3",children:[!a&&(t?e.jsxs(O,{to:"/breedsdisciplines#contest-reining",className:"inline-flex items-center gap-2 px-5 py-2.5 rounded-sm font-semibold text-sm bg-primary text-white hover:opacity-90 transition-opacity",style:{textDecoration:"none"},children:[e.jsx(fi,{size:14}),"Submit Photo"]}):e.jsxs("div",{className:"flex flex-wrap gap-2",children:[e.jsx(O,{to:"/become-member",className:"inline-block px-5 py-2.5 rounded-sm font-semibold text-sm bg-primary text-white hover:opacity-90 transition-opacity",style:{textDecoration:"none"},children:"Create Account"}),e.jsx(O,{to:"/login",className:"inline-block px-5 py-2.5 rounded-sm font-semibold text-sm border-2 border-primary text-primary hover:bg-primary hover:text-white transition-colors",style:{textDecoration:"none"},children:"Log In to Enter"})]})),e.jsx(O,{to:"/advertise#sponsor-a-contest",className:"text-accent hover:underline text-sm font-medium shrink-0",children:"Sponsor this contest"})]}),e.jsxs("p",{className:"text-xs text-muted-foreground mt-2",children:["Sponsored by ",e.jsx("span",{className:"font-semibold text-foreground",children:"Total Horse Channel"})]})]})]}),e.jsxs("details",{className:"border-t border-border",children:[e.jsxs("summary",{className:"cursor-pointer px-5 py-3 text-xs font-semibold text-muted-foreground hover:text-foreground flex items-center gap-1.5 select-none list-none",children:[e.jsx(Lt,{size:13,className:"transition-transform [[open]_&]:rotate-90 shrink-0"}),"Contest rules"]}),e.jsxs("ul",{className:"px-5 pb-4 space-y-1.5 text-xs text-muted-foreground list-disc list-inside leading-relaxed",children:[e.jsx("li",{children:"Open to all TotalHorseChannel.com members. Free to enter."}),e.jsx("li",{children:"Submissions open October 2 and close October 10, 2026 at 11:59 PM EDT."}),e.jsx("li",{children:"One photo entry per member."}),e.jsx("li",{children:"Photo must feature a Reining horse or run. No AI-generated images."}),e.jsx("li",{children:"Submitter must own the photo and have rights to submit it."}),e.jsx("li",{children:"Photo must be suitable for a category icon: clear subject, good lighting, square or near-square crop preferred."}),e.jsx("li",{children:"Voting opens the week of October 11. One vote per member per day."}),e.jsx("li",{children:"Prize: $150 Visa gift card to the winner. Winning photo becomes the Reining category image on TotalHorseChannel.com for one year."}),e.jsx("li",{children:"Total Horse Channel reserves the right to disqualify entries that do not meet guidelines."})]})]})]}),e.jsx("div",{className:"mt-8",children:e.jsxs("div",{id:"miniature-horse-icon",className:"border border-border rounded-sm overflow-hidden bg-card mb-6",children:[e.jsx("div",{className:"h-1.5 bg-primary"}),e.jsxs("div",{className:"p-5 flex flex-col sm:flex-row gap-5",children:[e.jsx("div",{className:"shrink-0",children:e.jsx(O,{to:"/category/miniature-horse",style:{textDecoration:"none"},children:e.jsx("div",{className:"w-24 h-24 sm:w-28 sm:h-28 overflow-hidden border border-border bg-black rounded-sm",children:e.jsx("img",{src:"/airo-assets/images/breeds/miniature-horse",alt:"Miniature Horse",width:112,height:112,className:"w-full h-full object-cover",loading:"lazy"})})})}),e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsxs("div",{className:"flex flex-wrap items-start gap-2 mb-2",children:[e.jsx("h2",{className:"text-foreground font-bold text-lg leading-tight",children:"Miniature Horse Category Icon Photo Contest"}),e.jsx("span",{className:"shrink-0 text-xs font-semibold px-2 py-0.5 rounded border bg-green-100 text-green-800 border-green-300",children:"Entries Open"})]}),e.jsx("p",{className:"text-muted-foreground text-sm mb-3 leading-relaxed",children:"Total Horse Channel is running this contest during the AMHA World Championship Show. It is a THC contest, not an AMHA or show contest. In honor of that week, we are cho
642osing the Miniature Horse category image on TotalHorseChannel.com. The winning photo becomes the official Miniature Horse category image on TotalHorseChannel.com for one year."}),e.jsxs("div",{className:"flex flex-wrap gap-x-5 gap-y-1 mb-4 text-xs text-muted-foreground",children:[e.jsxs("span",{className:"text-primary font-semibold",children:[e.jsx(Ms,{size:11,className:"inline mr-1 -mt-0.5"}),e.jsx("span",{children:"Submissions: "}),e.jsx("strong",{children:"September 25 – October 3, 2026"})]}),e.jsxs("span",{children:[e.jsx("span",{children:"Voting: "}),e.jsx("strong",{children:"week of October 4"})]}),e.jsxs("span",{children:[e.jsx("span",{children:"Prize: "}),e.jsx("strong",{children:"$150 Visa gift card + category icon for one year"})]})]}),e.jsxs("div",{className:"flex flex-wrap items-center gap-3",children:[!a&&(t?e.jsxs(O,{to:"/breedsdisciplines#contest-miniature-horse",className:"inline-flex items-center gap-2 px-5 py-2.5 rounded-sm font-semibold text-sm bg-primary text-white hover:opacity-90 transition-opacity",style:{textDecoration:"none"},children:[e.jsx(fi,{size:14}),"Submit Photo"]}):e.jsxs("div",{className:"flex flex-wrap gap-2",children:[e.jsx(O,{to:"/become-member",className:"inline-block px-5 py-2.5 rounded-sm font-semibold text-sm bg-primary text-white hover:opacity-90 transition-opacity",style:{textDecoration:"none"},children:"Create Account"}),e.jsx(O,{to:"/login",className:"inline-block px-5 py-2.5 rounded-sm font-semibold text-sm border-2 border-primary text-primary hover:bg-primary hover:text-white transition-colors",style:{textDecoration:"none"},children:"Log In to Enter"})]})),e.jsx(O,{to:"/advertise#sponsor-a-contest",className:"text-accent hover:underline text-sm font-medium shrink-0",children:"Sponsor this contest"})]}),e.jsxs("p",{className:"text-xs text-muted-foreground mt-2",children:["Sponsored by ",e.jsx("span",{className:"font-semibold text-foreground",children:"Total Horse Channel"})]})]})]}),e.jsxs("details",{className:"border-t border-border",children:[e.jsxs("summary",{className:"cursor-pointer px-5 py-3 text-xs font-semibold text-muted-foreground hover:text-foreground flex items-center gap-1.5 select-none list-none",children:[e.jsx(Lt,{size:13,className:"transition-transform [[open]_&]:rotate-90 shrink-0"}),"Contest rules"]}),e.jsxs("ul",{className:"px-5 pb-4 space-y-1.5 text-xs text-muted-foreground list-disc list-inside leading-relaxed",children:[e.jsx("li",{children:"Open to all TotalHorseChannel.com members. Free to enter."}),e.jsx("li",{children:"Submissions open September 25 and close October 3, 2026 at 11:59 PM EDT."}),e.jsx("li",{children:"One photo entry per member."}),e.jsx("li",{children:"Photo must feature a Miniature Horse. No AI-generated images."}),e.jsx("li",{children:"Submitter must own the photo and have rights to submit it."}),e.jsx("li",{children:"Photo must be suitable for a category icon: clear subject, good lighting, square or near-square crop preferred."}),e.jsx("li",{children:"Voting opens the week of October 4. One vote per member per day."}),e.jsx("li",{children:"Prize: $150 Visa gift card to the winner. Winning photo becomes the Miniature Horse category image on TotalHorseChannel.com for one year."}),e.jsx("li",{children:"Total Horse Channel reserves the right to disqualify entries that do not meet guidelines."})]})]})]})}),e.jsx("div",{className:"mt-8",children:e.jsx(E7,{isAuthenticated:t,isPending:a})})]}),e.jsxs("section",{"aria-label":"Past contests",children:[e.jsx("div",{className:"bg-secondary px-4 py-2 mb-4",children:e.jsx("h2",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Past Contests"})}),e.jsx(H7,{phase:r,countdown:o,localDeadline:l,isAuthenticated:t,isPending:a,mySubmission:d,loadingMine:m}),e.jsx(T7,{phase:r,countdown:o,localDeadline:l,isAuthenticated:t})]})]})})]})}const R7=g.lazy(()=>Fx(()=>import("./ArticleRichTextEditor-Cfo8kN2k.js"),__vite__mapDeps([0,1,2,3]))),_7="https://totalhorsechannel.com",pw=`${_7}/news/submit`,L7=[{value:"single",label:"$100 — One article"},{value:"two_pack",label:"$175 — Two articles"},{value:"homepage_6mo",label:"$300 — Homepage link 6 months"},{value:"homepage_1yr",label:"$525 — Homepage link 1 year"},{value:"social_boost",label:"$35 — Social media boost"},{value:"existing",label:"Existing agreement (custom)"}];function D7(){const{user:t,isAuthenticated:a}=Us(),[r,o]=g.useState(""),[l,d]=g.useState(""),[u,m]=g.useState(""),[p,x]=g.useState(""),[b,y]=g.useState(""),[v,w]=g.useState(""),[C,A]=g.useState(""),[S,z]=g.useState([{label:"",url:""}]),[T,M]=g.useState("single"),[P,E]=g.useState(""),[U,q]=g.useState(!1),[H,J]=g.useState(!1),[B,Y]=g.useState(!1),[$,D]=g.useState(""),[W,I]=g.useState(!1),[k,K]=g.useState(!1),[L]=g.useState(()=>Date.now()),[se,X]=g.useState("");g.useEffect(()=>{a&&t&&(t.name&&o(t.name),t.email&&d(t.email))},[a,t]);function le(){S.length<4&&z(me=>[...me,{label:"",url:""}])}function ge(me){z(Le=>Le.filter((Ie,ve)=>ve!==me))}function Se(me,Le,Ie){z(ve=>ve.map((ze,Ue)=>Ue===me?{...ze,[Le]:Ie}:ze))}function Me(me={}){return JSON.stringify({authorName:r,authorEmail:l,title:u,body:p,imageUrl:b,imageCredit:v,videoUrl:C,links:S.filter(Le=>Le.url.trim()),pkg:T,note:P,website2:se,_formLoadedAt:String(L),...me})}async function st(me){me.preventDefault(),D("");const Le=p.replace(/<[^>]+>/g,"").trim();if(!u.trim()){D("Article title is required to save a draft.");return}if(!Le){D("Article body is required to save a draft.");return}const Ie=Me();if(Ie.length>9*1024*1024){D("Your article is too large (over 9 MB). Please reduce the amount of embedded images and try again.");return}Y(!0);try{const ve=await fetch("/api/news/draft",{method:"POST",headers:{"Content-Type":"application/json"},body:Ie});
642if(ve.status===413){D("Your article is too large. Please reduce the amount of embedded images and try again.");return}const ze=await ve.json();if(!ve.ok){D(ze.error??"Could not save draft.");return}K(!0),setTimeout(()=>K(!1),4e3)}catch{D("Network error. Please try again.")}finally{Y(!1)}}async function We(me){if(me.preventDefault(),D(""),!U){D("You must check the agreement checkbox.");return}if(!p.replace(/<[^>]+>/g,"").trim()){D("Article body is required.");return}const Ie=Me({agreedToTerms:U});if(Ie.length>9*1024*1024){D("Your article is too large to submit (over 9 MB). Please reduce the amount of embedded images in the body and try again.");return}J(!0);try{const ve=new AbortController,ze=setTimeout(()=>ve.abort(),6e4),Ue=await fetch("/api/news",{method:"POST",headers:{"Content-Type":"application/json"},body:Ie,signal:ve.signal});if(clearTimeout(ze),Ue.status===413){D("Your article is too large to submit. Please reduce the amount of embedded images in the body and try again.");return}const ct=await Ue.json();if(!Ue.ok){D(ct.error??"Submission failed.");return}I(!0)}catch(ve){ve instanceof Error&&ve.name==="AbortError"?D("The submission timed out. Your article may be too large — try shortening the body text and resubmitting."):D("Network error. Please try again.")}finally{J(!1)}}const Ye="w-full border border-border bg-background text-foreground px-3 py-2 text-sm focus:outline-none focus:border-primary",te="block text-sm font-semibold text-foreground mb-1";return W?e.jsxs(e.Fragment,{children:[e.jsx(we,{children:e.jsx("title",{children:"Article Submitted – Total Horse Channel"})}),e.jsx("main",{children:e.jsx("div",{className:"max-w-[700px] mx-auto px-4 py-12 text-center",children:e.jsxs("div",{className:"bg-card border border-border p-8",children:[e.jsx("h1",{className:"text-2xl font-bold text-foreground mb-3",children:"Article received!"}),e.jsx("p",{className:"text-muted-foreground mb-6",children:"We received your article. Check your email for rates and next steps. We will review it and send a preview link plus a PayPal invoice when it is ready to publish."}),e.jsx(O,{to:"/news",className:"inline-block bg-primary text-white font-bold px-6 py-2 hover:opacity-90 transition-opacity",children:"Back to News"})]})})})]}):e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Submit an Article – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Submit a horse-industry article to Total Horse Channel. Do-follow links, permanent placement, and homepage link options available."}),e.jsx("link",{rel:"canonical",href:pw}),e.jsx("meta",{property:"og:title",content:"Submit an Article – Total Horse Channel"}),e.jsx("meta",{property:"og:description",content:"Submit a horse-industry article to Total Horse Channel."}),e.jsx("meta",{property:"og:url",content:pw}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{name:"twitter:card",content:"summary"})]}),e.jsx("main",{children:e.jsxs("div",{className:"max-w-[760px] mx-auto px-4 py-6",children:[e.jsx("div",{className:"bg-primary px-3 py-2 mb-5",children:e.jsx("h1",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Submit an Article"})}),e.jsxs("div",{className:"bg-muted border border-border px-4 py-4 mb-6 text-sm text-foreground leading-relaxed",children:[e.jsx("p",{className:"font-semibold mb-2",children:"Article post rates:"}),e.jsxs("ul",{className:"list-disc list-inside space-y-1 text-muted-foreground",children:[e.jsxs("li",{children:[e.jsx("strong",{children:"$100"})," — one article with do-follow links (permanent)"]}),e.jsxs("li",{children:[e.jsx("strong",{children:"$175"})," — two articles"]}),e.jsxs("li",{children:[e.jsx("strong",{children:"$300"})," — homepage link for 6 months"]}),e.jsxs("li",{children:[e.jsx("strong",{children:"$525"})," — homepage link for 1 year"]}),e.jsxs("li",{children:[e.jsx("strong",{children:"$35"})," — social media boost (Facebook, X, Instagram)"]}),e.jsx("li",{children:"Existing agreement — select below and note your deal"})]}),e.jsx("p",{className:"mt-2 text-muted-foreground",children:"Articles must be horse-industry related. We will email a preview link and PayPal invoice when ready to publish."})]}),e.jsxs("form",{onSubmit:We,className:"flex flex-col gap-5",children:[e.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-2 gap-4",children:[e.jsxs("div",{children:[e.jsxs("label",{className:te,children:["Name ",e.jsx("span",{className:"text-primary",children:"*"})]}),e.jsx("input",{className:Ye,value:r,onChange:me=>o(me.target.value),required:!0,placeholder:"Your name"})]}),e.jsxs("div",{children:[e.jsxs("label",{className:te,children:["Email ",e.jsx("span",{className:"text-primary",children:"*"})]}
642),e.jsx("input",{className:Ye,type:"email",value:l,onChange:me=>d(me.target.value),required:!0,placeholder:"[email protected]"})]})]}),e.jsxs("div",{children:[e.jsxs("label",{className:te,children:["Article title ",e.jsx("span",{className:"text-primary",children:"*"})]}),e.jsx("input",{className:Ye,value:u,onChange:me=>m(me.target.value),required:!0,placeholder:"Article headline"})]}),e.jsxs("div",{children:[e.jsxs("label",{className:te,children:["Article body ",e.jsx("span",{className:"text-primary",children:"*"})]}),e.jsx("p",{className:"text-xs text-muted-foreground mb-1.5",children:"Paste text, links, and images directly. Use the toolbar to insert images from your computer or paste a screenshot."}),e.jsx(g.Suspense,{fallback:e.jsx("div",{className:"border border-border bg-muted text-muted-foreground text-sm px-3 py-4 text-center",children:"Loading editor…"}),children:e.jsx(R7,{onChange:x,minHeight:260})})]}),e.jsxs("div",{className:"flex flex-col gap-3",children:[e.jsx(uN,{url:b,onUrl:y,label:"Thumbnail image (optional — separate from body images)"}),e.jsxs("div",{children:[e.jsxs("label",{className:te,children:["Image credit / source link ",e.jsx("span",{className:"text-muted-foreground font-normal",children:"(optional)"})]}),e.jsx("input",{className:Ye,type:"text",value:v,onChange:me=>w(me.target.value),placeholder:"e.g. https://example.com/photo-source or 'Photo: Jane Doe'"})]})]}),e.jsxs("div",{children:[e.jsxs("label",{className:te,children:["Video URL / embed ",e.jsx("span",{className:"text-muted-foreground font-normal",children:"(optional)"})]}),e.jsx("input",{className:Ye,type:"text",value:C,onChange:me=>A(me.target.value),placeholder:"YouTube, Rumble, or iframe…"})]}),e.jsxs("div",{children:[e.jsxs("label",{className:te,children:["Do-follow links ",e.jsx("span",{className:"text-muted-foreground font-normal",children:"(up to 4, optional)"})]}),e.jsxs("div",{className:"flex flex-col gap-2",children:[S.map((me,Le)=>e.jsxs("div",{className:"flex gap-2 items-center",children:[e.jsx("input",{className:Ye+" flex-1",value:me.label,onChange:Ie=>Se(Le,"label",Ie.target.value),placeholder:"Link label"}),e.jsx("input",{className:Ye+" flex-[2]",type:"text",value:me.url,onChange:Ie=>Se(Le,"url",Ie.target.value),placeholder:"https://…"}),S.length>1&&e.jsx("button",{type:"button",onClick:()=>ge(Le),className:"text-muted-foreground hover:text-primary transition-colors shrink-0",children:e.jsx(Vt,{size:16})})]},Le)),S.length<4&&e.jsxs("button",{type:"button",onClick:le,className:"flex items-center gap-1 text-sm text-accent hover:underline self-start mt-1",children:[e.jsx(sl,{size:14})," Add another link"]})]})]}),e.jsxs("div",{children:[e.jsxs("label",{className:te,children:["Package ",e.jsx("span",{className:"text-primary",children:"*"})]}),e.jsx("select",{className:Ye,value:T,onChange:me=>M(me.target.value),required:!0,children:L7.map(me=>e.jsx("option",{value:me.value,children:me.label},me.value))})]}),e.jsxs("div",{children:[e.jsxs("label",{className:te,children:["Note ",e.jsx("span",{className:"text-muted-foreground font-normal",children:"(optional — existing deal, deadline, etc.)"})]}),e.jsx("textarea",{className:Ye+" min-h-[80px] resize-y",value:P,onChange:me=>E(me.target.value),placeholder:"Any notes for us…"})]}),e.jsxs("label",{className:"flex items-start gap-3 cursor-pointer",children:[e.jsx("input",{type:"checkbox",checked:U,onChange:me=>q(me.target.checked),className:"mt-0.5 shrink-0 accent-primary w-4 h-4"}),e.jsxs("span",{className:"text-sm text-foreground",children:["This article is horse-industry related. I have the right to publish this content and the links. ",e.jsx("span",{className:"text-primary",children:"*"})]})]}),$&&e.jsx("p",{className:"text-sm text-destructive",children:e.jsx(_,{devId:"9d8874",guard:{file:"src/pages/news/submit.tsx",tagName:"p",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:ca00fccfb408989eddc401062c4d1219a6aceb6b9b55412357f1790862e8f178"},children:$})}),k&&e.jsx("p",{className:"text-sm text-green-700 font-semibold",children:"Draft saved. You can continue editing and submit when ready."}),e.jsxs("div",{className:"flex flex-wrap items-center gap-3",children:[e.jsx("button",{type:"submit",disabled:H||B,className:"bg-primary text-white font-bold uppercase px-6 py-3 hover:opacity-90 transition-opacity disabled:opacity-50",children:e.jsx(_,{devId:"9da7fc",guard:{file:"src/pages/news/submit.tsx",tagName:"button",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionH
642ash:"sha256:798d877a76e4c2cf1181591df265aaa5821b1423af9b860a28a37d27f9b17f0b"},children:H?"Submitting…":"Submit Article"})}),e.jsx("button",{type:"button",disabled:H||B,onClick:st,className:"border border-border text-foreground font-semibold px-5 py-3 hover:bg-muted transition-colors disabled:opacity-50 text-sm",children:e.jsx(_,{devId:"9da7fd",guard:{file:"src/pages/news/submit.tsx",tagName:"button",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:d98899fff81784052d8bdba8f73378d9b4eb8876fc1d40d04d81a943fae37889"},children:B?"Saving…":"Save draft"})}),e.jsx("span",{className:"text-xs text-muted-foreground",children:"Save draft keeps your work without sending any emails."})]}),e.jsx("div",{style:{display:"none"},"aria-hidden":"true",children:e.jsx("input",{type:"text",name:"website2",value:se,onChange:me=>X(me.target.value),tabIndex:-1,autoComplete:"off"})})]})]})})]})}const fw="https://totalhorsechannel.com";function O7(t){if(!t)return"";const a=new Date(t);return isNaN(a.getTime())?"":a.toLocaleDateString("en-US",{year:"numeric",month:"long",day:"numeric"})}function M7(t){if(!t)return[];try{return JSON.parse(t)}catch{return[]}}function U7(t){if(!t)return null;if(t.trim().startsWith("<iframe"))return t;const a=t.match(/(?:youtube\.com\/(?:watch\?v=|embed\/|live\/)|youtu\.be\/)([A-Za-z0-9_-]{11})/);if(a)return`<iframe width="100%" height="100%" src="https://www.youtube.com/embed/${a[1]}" frameborder="0" allowfullscreen></iframe>`;const r=t.match(/rumble\.com\/embed\/([^/?]+)/);return r?`<iframe width="100%" height="100%" src="https://rumble.com/embed/${r[1]}/" frameborder="0" allowfullscreen></iframe>`:null}function P7(t){return t.replace(/<[^>]+>/g," ").replace(/\s+/g," ").trim()}function K7(){const t=sg(),[a,r]=g.useState(t);g.useEffect(()=>{!(t!=null&&t.clientFetch)||!t.slug||fetch(`/api/news/${t.slug}?preview=1`).then(b=>b.ok?b.json():Promise.reject(b.status)).then(b=>r(b)).catch(()=>r({article:null,notFound:!0}))},[t==null?void 0:t.clientFetch,t==null?void 0:t.slug]);const o=(a==null?void 0:a.article)??null,l=(a==null?void 0:a.notFound)??(!o&&!(t!=null&&t.clientFetch));if(t!=null&&t.clientFetch&&!(a!=null&&a.article)&&!(a!=null&&a.notFound))return e.jsx("main",{children:e.jsx("div",{className:"max-w-[760px] mx-auto px-4 py-12 text-center",children:e.jsx("p",{className:"text-muted-foreground",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"937e0e",guard:{file:"src/pages/news/[slug].tsx",tagName:"p",sourceKind:"content-key",contentKey:"news_article.loadingText",contentKeyTemplate:null,expressionHash:null},children:xr.loadingText})})})});if(l||!o)return e.jsxs(e.Fragment,{children:[e.jsx(we,{children:e.jsx("title",{children:xr.notFoundTitle})}),e.jsx("main",{children:e.jsxs("div",{className:"max-w-[760px] mx-auto px-4 py-12 text-center",children:[e.jsx("p",{className:"text-muted-foreground mb-4",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"937e0e",guard:{file:"src/pages/news/[slug].tsx",tagName:"p",sourceKind:"content-key",contentKey:"news_article.notFoundBody",contentKeyTemplate:null,expressionHash:null},children:xr.notFoundBody})}),e.jsx(O,{to:"/news",className:"text-accent hover:underline text-sm",children:xr.backToNews})]})})]});const d=`${fw}/news/${o.slug}`,u=O7(o.publishedAt??o.createdAt),m=M7(o.links),p=o.videoUrl?U7(o.videoUrl):null,x=P7(o.body).slice(0,160);return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsxs("title",{children:[o.title," – Total Horse Channel"]}),e.jsx("meta",{name:"description",content:x}),e.jsx("link",{rel:"canonical",href:d}),e.jsx("meta",{property:"og:title",content:o.title}),e.jsx("meta",{property:"og:description",content:x}),e.jsx("meta",{property:"og:url",content:d}),e.jsx("meta",{property:"og:type",content:"article"}),o.imageUrl&&e.jsx("meta",{property:"og:image",content:o.imageUrl}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify({"@context":"https://schema.org","@type":"NewsArticle",headline:o.title,url:d,datePublished:o.publishedAt??o.createdAt,author:{"@type":"Person",name:o.authorName},publisher:{"@type":"Organization",name:"Total Horse Channel",url:fw},...o.imageUrl?{image:o.imageUrl}:{}})})]}),e.jsx("main",{children:e.jsxs("div",{className:"max-w-[760px] mx-auto px-4 py-6",children:[e.jsxs("div",{className:"text-xs text-muted-foreground mb-4",children:[e.jsx(O,{to:"/",className:"hover:underline",children:xr.breadcrumbHome})," › ",e.jsx(O,{to:"/news",className:"hover:underline",children:xr.breadcrumbNews})," › ",e.jsx("span",{className:"text-foreground",children:e.jsx(_,{devId:"232244",guard:{file:"src/pages/news/[slug].tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionH
642ash:"sha256:21ab1d82bd227a9070bfca00dccc31c0659242fce380b787c6f405d05ffef639"},children:o.title})})]}),e.jsx("h1",{className:"text-2xl font-bold text-foreground leading-snug mb-2",children:e.jsx(_,{devId:"ff16d7",guard:{file:"src/pages/news/[slug].tsx",tagName:"h1",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:21ab1d82bd227a9070bfca00dccc31c0659242fce380b787c6f405d05ffef639"},children:o.title})}),e.jsxs("div",{className:"flex items-center gap-2 text-muted-foreground text-xs mb-5",children:[e.jsx(ys,{size:12}),e.jsx("span",{children:e.jsx(_,{devId:"64f725",guard:{file:"src/pages/news/[slug].tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:ae932f00ab4e9506f916753605bd77f068194ab4834cb7581cd94762c3cf50ac"},children:u})}),o.authorName&&e.jsxs(e.Fragment,{children:[e.jsx("span",{children:"·"}),e.jsx("span",{children:e.jsx(_,{devId:"64f727",guard:{file:"src/pages/news/[slug].tsx",tagName:"span",sourceKind:"bound-expression",contentKey:null,contentKeyTemplate:null,expressionHash:"sha256:c1af82e242820f9237a98ec6be79dacc414e82edc0cf3bb58a768e12a76782c2"},children:o.authorName})})]})]}),o.imageUrl&&e.jsxs("figure",{className:"mb-5",children:[e.jsx("img",{src:o.imageUrl,alt:o.title,className:"w-full object-cover max-h-[420px]",loading:"eager",fetchPriority:"high"}),o.imageCredit&&e.jsx("figcaption",{className:"text-xs text-muted-foreground mt-1",children:o.imageCredit.startsWith("http")?e.jsx("a",{href:o.imageCredit,target:"_blank",rel:"noopener noreferrer",className:"hover:underline text-accent",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"f810a7",guard:{file:"src/pages/news/[slug].tsx",tagName:"a",sourceKind:"content-key",contentKey:"news_article.imageCreditLabel",contentKeyTemplate:null,expressionHash:null},children:xr.imageCreditLabel})}):o.imageCredit})]}),e.jsx("style",{children:`
643            .article-body h2 { font-size: 1.3rem; font-weight: 700; margin: 1.4em 0 0.5em; }
644            .article-body h3 { font-size: 1.1rem; font-weight: 700; margin: 1.2em 0 0.4em; }
645            .article-body p  { margin: 0 0 1em; line-height: 1.75; }
646            .article-body p:first-child { margin-top: 0; }
647            .article-body ul { list-style: disc; padding-left: 1.5em; margin: 0 0 1em; }
648            .article-body ol { list-style: decimal; padding-left: 1.5em; margin: 0 0 1em; }
649            .article-body li { margin: 0.3em 0; line-height: 1.7; }
650            .article-body a  { color: hsl(var(--accent)); text-decoration: underline; }
651            .article-body img { max-width: 100%; height: auto; display: block; margin: 1em 0; }
652            .article-body iframe { max-width: 100%; }
653            .article-body div[style*="padding-bottom: 56.25%"] { margin: 1em 0; }
654          `}),e.jsx("div",{className:"article-body text-sm text-foreground leading-relaxed mb-6",dangerouslySetInnerHTML:{__html:o.body}}),p&&e.jsx("div",{className:"mb-6",children:e.jsx("div",{className:"relative w-full bg-black",style:{aspectRatio:"16/9"},children:e.jsx("div",{className:"absolute inset-0",dangerouslySetInnerHTML:{__html:p}})})}),m.length>0&&e.jsxs("div",{className:"border border-border bg-muted px-4 py-4 mb-6",children:[e.jsx("p",{className:"text-xs font-semibold uppercase text-muted-foreground mb-2",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"763fa6",guard:{file:"src/pages/news/[slug].tsx",tagName:"p",sourceKind:"content-key",contentKey:"news_article.relatedLinksHeading",contentKeyTemplate:null,expressionHash:null},children:xr.relatedLinksHeading})}),e.jsx("ul",{className:"flex flex-col gap-1.5",children:m.map((b,y)=>e.jsx("li",{children:e.jsxs("a",{href:b.url,target:"_blank",rel:"noopener noreferrer",className:"flex items-center gap-1.5 text-accent hover:underline text-sm",children:[e.jsx(dt,{size:12,className:"shrink-0"}),b.label||b.url]})},y))})]}),e.jsx(O,{to:"/news",className:"text-sm text-accent hover:underline",children:xr.backToNews})]})})]})}const $x="https://totalhorsechannel.com",Lm=`${$x}/mission`,I7={"@context":"https://schema.org","@type":"AboutPage","@id":`${Lm}#webpage`,name:"Our Mission – Total Horse Channel",url:Lm,isPartOf:{"@id":`${$x}/#website`},about:{"@id":`${$x}/#organization`}};function B7(){return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:"Our Mission – Total Horse Channel"}),e.jsx("meta",{name:"description",content:"Total Horse Channel exists so the horse industry isn't scattered across a hundred sites. One platform for fans. Fair promotion for every barn, breed, and broadcast."}),e.jsx("link",{rel:"canonical",href:Lm}),e.jsx("meta",{property:"og:title",content:"Our Mission – Total Horse Channel"}),e.jsx("meta",{property:"og:description",content:"Total Horse Channel exists so the horse industry isn't scattered across a hundred sites. One platform for fans. Fair promotion for every barn, breed, and broadcast."}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{property:"og:url",content:Lm}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("script",{type:"application/ld+json",children:JSON.stringify(I7)})]}),e.jsx("main",{children:e.jsxs("div",{className:"max-w-[860px] mx-auto px-4 py-6",children:[e.jsx("div",{className:"bg-primary px-3 py-2 mb-6",children:e.jsx("h1",{className:"text-white font-bold uppercase text-sm tracking-wide",children:"Our Mission"})}),e.jsxs("div",{className:"bg-card border border-border px-6 py-8",children:[e.jsx("p",{className:"text-foreground mb-5",style:{fontSize:"16px",lineHeight:"27px"},children:"Total Horse Channel exists so the horse industry isn't scattered across a hundred sites."}),e.jsx("p",{className:"text-foreground mb-5",style:{fontSize:"16px",lineHeight:"27px"},children:"We stream and embed lives and videos from tracks, shows, associations, and video companies — including partners who keep content on their own sites. We don't replace RFD-TV, ClipMyHorse, or a show's homepage. We point people there, and we give those same organizations a profile, a place to post, and a way for fans to follow them."}),e.jsx("p",{className:"text-foreground font-semibold",style:{fontSize:"16px",lineHeight:"27px"},children:"One platform for fans. Fair promotion for every barn, breed, and broadcast that wants to be found."})]}),e.jsxs("div",{className:"flex flex-wrap items-center gap-4 mt-6 text-sm",children:[e.jsx(O,{to:"/",className:"text-accent hover:underline",children:"← Back to Home"}),e.jsx(O,{to:"/sponsors-partners",className:"text-accent hover:underline",children:"Partners"}),e.jsx(O,{to:"/advertise",className:"text-accent hover:underline",children:"Advertise"})]})]})})]})}function $7(){const t=`${Zs.title} | Total Horse Channel`,a="Watch the 2026 Low Roller Reining Classic live from Ford Idaho Horse Park, Nampa, Idaho. Livestreams provided by RainDancer Video on Total Horse Channel.",r="https://totalhorsechannel.com/home/low-roller/";return e.jsxs(e.Fragment,{children:[e.jsxs(we,{children:[e.jsx("title",{children:t}),e.jsx("meta",{name:"description",content:a}),e.jsx("link",{rel:"canonical",href:r}),e.jsx("meta",{property:"og:title",content:t}),e.jsx("meta",{property:"og:description",content:a}),e.jsx("meta",{property:"og:url",content:r}),e.jsx("meta",{property:"og:type",content:"website"}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("meta",{name:"twitter:title",content:t}),e.jsx("meta",{name:"twitter:description",content:a})]}),e.jsxs("main",{className:"bg-background text-foreground",children:[e.jsx("section",{className:"bg-primary text-primary-foreground py-8 px-4",children:e.jsxs("div",{className:"max-w-5xl mx-auto text-center",children:[e.jsx("h1",{className:"text-3xl md:text-4xl font-bold mb-2",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"69b085",guard:{file:"src/pages/home/low-roller.tsx",tagName:"h1",sourceKind:"content-key",contentKey:"low_roller.title",contentKeyTemplate:null,expressionH
654ash:null},children:Zs.title})}),e.jsx("p",{className:"text-lg md:text-xl font-semibold opacity-90",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"1a99fc",guard:{file:"src/pages/home/low-roller.tsx",tagName:"p",sourceKind:"content-key",contentKey:"low_roller.dates",contentKeyTemplate:null,expressionHash:null},children:Zs.dates})}),e.jsx("p",{className:"text-base md:text-lg opacity-85 mt-1",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"1a99fd",guard:{file:"src/pages/home/low-roller.tsx",tagName:"p",sourceKind:"content-key",contentKey:"low_roller.venue",contentKeyTemplate:null,expressionHash:null},children:Zs.venue})}),e.jsx("p",{className:"text-sm opacity-80 mt-2",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"1a99fe",guard:{file:"src/pages/home/low-roller.tsx",tagName:"p",sourceKind:"content-key",contentKey:"low_roller.credit",contentKeyTemplate:null,expressionHash:null},children:Zs.credit})})]})}),e.jsxs("section",{className:"max-w-5xl mx-auto px-4 py-8",children:[e.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-8",children:[e.jsxs("div",{className:"flex flex-col",children:[e.jsx("h2",{className:"text-xl font-bold mb-1 text-foreground",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"4a337b",guard:{file:"src/pages/home/low-roller.tsx",tagName:"h2",sourceKind:"content-key",contentKey:"low_roller.arena1.name",contentKeyTemplate:null,expressionHash:null},children:Zs.arena1.name})}),e.jsx("p",{className:"text-sm text-muted-foreground mb-3",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"db9611",guard:{file:"src/pages/home/low-roller.tsx",tagName:"p",sourceKind:"content-key",contentKey:"low_roller.arena1.startTime",contentKeyTemplate:null,expressionHash:null},children:Zs.arena1.startTime})}),e.jsx("div",{className:"relative w-full",style:{paddingBottom:"56.25%"},children:e.jsx("iframe",{className:"absolute inset-0 w-full h-full rounded",src:Zs.arena1.embedSrc,title:Zs.arena1.embedTitle,frameBorder:"0",allowFullScreen:!0,allow:"autoplay; fullscreen"})}),e.jsx(O,{to:"/live/2026-low-roller-reining-classic-main-arena-october-3rd",className:"mt-3 inline-block bg-primary text-primary-foreground font-semibold px-5 py-2 rounded hover:opacity-90 transition-opacity text-sm text-center",children:"Watch Arena 1"})]}),e.jsxs("div",{className:"flex flex-col",children:[e.jsx("h2",{className:"text-xl font-bold mb-1 text-foreground",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"9f5c1c",guard:{file:"src/pages/home/low-roller.tsx",tagName:"h2",sourceKind:"content-key",contentKey:"low_roller.arena2.name",contentKeyTemplate:null,expressionHash:null},children:Zs.arena2.name})}),e.jsx("p",{className:"text-sm text-muted-foreground mb-3",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"edae92",guard:{file:"src/pages/home/low-roller.tsx",tagName:"p",sourceKind:"content-key",contentKey:"low_roller.arena2.startTime",contentKeyTemplate:null,expressionHash:null},children:Zs.arena2.startTime})}),e.jsx("div",{className:"relative w-full",style:{paddingBottom:"56.25%"},children:e.jsx("iframe",{className:"absolute inset-0 w-full h-full rounded",src:Zs.arena2.embedSrc,title:Zs.arena2.embedTitle,frameBorder:"0",allowFullScreen:!0,allow:"autoplay; fullscreen"})}),e.jsx(O,{to:"/live/2026-low-roller-reining-classic-covered-arena-october-3rd",className:"mt-3 inline-block bg-primary text-primary-foreground font-semibold px-5 py-2 rounded hover:opacity-90 transition-opacity text-sm text-center",children:"Watch Arena 2"})]})]}),e.jsxs("div",{className:"mt-8 flex flex-wrap gap-3 justify-center",children:[e.jsx("a",{href:"https://www.lowrollerreining.com/",target:"_blank",rel:"noopener noreferrer",className:"inline-block bg-primary text-primary-foreground font-semibold px-5 py-2 rounded hover:opacity-90 transition-opacity text-sm",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"8927ef",guard:{file:"src/pages/home/low-roller.tsx",tagName:"a",sourceKind:"content-key",contentKey:"low_roller.buttons.officialSite",contentKeyTemplate:null,expressionHash:null},children:Zs.buttons.officialSite})}),e.jsx("a",{href:"https://www.lowrollerreining.com/live/Arena1.html",target:"_blank",rel:"noopener noreferrer",className:"inline-block bg-secondary text-secondary-foreground font-semibold px-5 py-2 rounded hover:opacity-90 transition-opacity text-sm",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"8927f0",guard:{file:"src/pages/home/low-roller.tsx",tagName:"a",sourceKind:"content-key",contentKey:"low_roller.buttons.arena1Scores",contentKeyTemplate:null,expressionH
654ash:null},children:Zs.buttons.arena1Scores})}),e.jsx("a",{href:"https://www.lowrollerreining.com/live/Arena2.html",target:"_blank",rel:"noopener noreferrer",className:"inline-block bg-secondary text-secondary-foreground font-semibold px-5 py-2 rounded hover:opacity-90 transition-opacity text-sm",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"8927f1",guard:{file:"src/pages/home/low-roller.tsx",tagName:"a",sourceKind:"content-key",contentKey:"low_roller.buttons.arena2Scores",contentKeyTemplate:null,expressionHash:null},children:Zs.buttons.arena2Scores})}),e.jsx("a",{href:"https://www.lowrollerreining.com/files/2026-LRRC/2026-LRRC-Class-List-and-Schedule.pdf",target:"_blank",rel:"noopener noreferrer",className:"inline-block bg-secondary text-secondary-foreground font-semibold px-5 py-2 rounded hover:opacity-90 transition-opacity text-sm",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"8927f2",guard:{file:"src/pages/home/low-roller.tsx",tagName:"a",sourceKind:"content-key",contentKey:"low_roller.buttons.schedule",contentKeyTemplate:null,expressionHash:null},children:Zs.buttons.schedule})})]}),e.jsx("p",{className:"text-center text-sm text-muted-foreground mt-4",style:{whiteSpace:"pre-line"},children:e.jsx(_,{devId:"ba9769",guard:{file:"src/pages/home/low-roller.tsx",tagName:"p",sourceKind:"content-key",contentKey:"low_roller.scoresDisclaimer",contentKeyTemplate:null,expressionHash:null},children:Zs.scoresDisclaimer})}),e.jsxs("div",{className:"mt-8 border border-border bg-card flex flex-col sm:flex-row items-stretch gap-0 overflow-hidden rounded",children:[e.jsx("div",{className:"sm:w-1.5 w-full h-1.5 sm:h-auto bg-primary shrink-0"}),e.jsxs("div",{className:"flex-1 px-4 py-4 flex flex-col gap-1.5",children:[e.jsxs("div",{className:"flex items-center gap-2 flex-wrap",children:[e.jsx(Xs,{size:14,className:"text-primary shrink-0"}),e.jsx("span",{className:"font-bold text-foreground text-sm uppercase tracking-wide leading-tight",children:"Reining Category Icon Photo Contest"}),e.jsx("span",{className:"text-xs font-semibold px-1.5 py-0.5 rounded border bg-green-100 text-green-800 border-green-300",children:"Entries Open"})]}),e.jsx("p",{className:"text-muted-foreground text-sm leading-relaxed",children:"Total Horse Channel is running this contest during the Low Roller Reining Classic. It is a THC contest, not a Low Roller or association contest. Submit your best reining photo — the winner becomes the official Reining category image on TotalHorseChannel.com for one year."}),e.jsxs("p",{className:"text-muted-foreground text-xs",children:[e.jsx("span",{className:"font-semibold text-foreground",children:"Submissions:"})," October 2–10, 2026  · ",e.jsx("span",{className:"font-semibold text-foreground",children:"Voting:"})," week of October 11  · ",e.jsx("span",{className:"font-semibold text-foreground",children:"Prize:"})," $150 Visa gift card + category icon for one year"]}),e.jsxs("div",{className:"flex items-center gap-3 flex-wrap mt-1",children:[e.jsx(O,{to:"/contests#reining-icon",className:"bg-primary text-white text-xs font-bold uppercase px-3 py-1.5 rounded hover:opacity-90 transition-opacity shrink-0",children:"Enter Contest"}),e.jsx(O,{to:"/contests#reining-icon",className:"text-accent hover:underline text-xs shrink-0",children:"Contest Rules & Details"})]}),e.jsxs("p",{className:"text-xs text-muted-foreground mt-1",children:["Sponsored by ",e.jsx("span",{className:"font-semibold text-foreground",children:"Total Horse Channel"})]})]})]})]})]})]})}const V7=O;function F7(){return e.jsx("div",{className:"min-h-screen flex items-center justify-center",style:{background:"linear-gradient(to bottom right, hsl(var(--primary)), hsl(var(--secondary)))"},children:e.jsx("div",{className:"container mx-auto px-4 max-w-2xl text-center",children:e.jsxs("div",{className:"space-y-8",children:[e.jsxs("div",{className:"space-y-4",children:[e.jsx("h1",{className:"text-6xl font-bold text-white/90",children:"404"}),e.jsx("h2",{className:"text-2xl font-semibold text-white/90",children:"Page Not Found"}),e.jsx("p",{className:"text-white/90",children:"Sorry, the page you're looking for doesn't exist or has been moved."})]}),e.jsxs("div",{className:"flex justify-center gap-4",children:[e.jsx(V7,{to:"/",children:e.jsx("button",{className:"px-8 py-3 bg-white font-semibold rounded-lg shadow-lg hover:shadow-xl transition-all hover:scale-105",style:{color:"hsl(var(--primary))"},children:"🏠 Go Home"})}),e.jsx("button",{className:"px-8 py-3 bg-white font-semibold rounded-lg shadow-lg hover:shadow-xl transition-all hover:scale-105",style:{color:"hsl(var(--primary))"},onClick:()=>window.history.back(),children:"← Go Back"})]})]})})})}const W7=F7,q7=[{path:"/home/low-roller",element:e.jsx($7,{})},{path:"/",element:e.jsx(y8,{})},{path:"/search",element:e.jsx(k8,{})},{path:"/watch-live-events",element:e.jsx(R8,{})},{path:"/videos",element:e.jsx(GR,{})},{path:"/news",element:e.jsx(P8,{}),loader:async({request:t})=>{const a=new URL(t.url),r=Number(a.searchParams.get("offset")??"0");try{const o=await fetch(`/api/news?limit=16&offset=${r}`,{headers:{Accept:"application/json"}});return o.ok?o.json():{articles:[],isAdmin:!1}}catch{return{articles:[],isAdmin:!1}}}},{path:"/wdaa-video-orders",element:e.jsx(D8,{})},{path:"/home/wdaa",element:e.jsx(I8,{})},{path:"/video/wdaa-world-championship-show-live",element:e.jsx(W8,{})},{path:"/video/wdaa-world-championship-show-live-ring-2",element:e.jsx(Z8,{})},{path:"/video/wdaa-world-championship-show-live-ring-3",element:e.jsx(e9,{})},{path:"/video/wdaa-world-championship-show-live-ring-4",element:e.jsx(n9,{})},{path:"/wdaa-replays",element:e.jsx(i9,{})},{path:"/wdaa-sponsorships",element:e.jsx(l9,{})},{path:"/wdaa-hub",loader:()=>Response.redirect("/home/wdaa",301),element:null},{path:"/admin/wdaa-orders",element:e.jsx(d9,{})},{path:"/admin/live-events",element:e.jsx(R9,{})},{path:"/admin/users",element:e.jsx(M9,{})},{path:"/live-helper",element:e.jsx(B9,{})},{path:"/live/upcoming",element:e.jsx(cH,{})},{path:"/live/archives",element:e.jsx(pH,{})},{path:"/live/:slug",element:e.jsx(nH,{})},{path:"/sponsors-partners",element:e.jsx(xH,{})},{path:"/mission",element:e.jsx(B7,{})},{path:"/help",element:e.jsx(bH,{})},{path:"/donations",element:e.jsx(SH,{})},{path:"/tech-support",element:e.jsx(TH,{})},{path:"/advertise",element:e.jsx(EH,{})},{path:"/breedsdisciplines",element:e.jsx(OH,{})},{path:"/puzzles",element:e.jsx(UH,{})},{path:"/become-member",element:e.jsx(BH,{})},{path:"/membership",element:e.jsx(FH,{})},{path:"/login",element:e.jsx(qH,{})},{path:"/signup",element:e.jsx(YH,{})},{path:"/forgot-password",element:e.jsx(GH,{})},{path:"/reset-password",element:e.jsx(ZH,{})},{path:"/u/:username",element:e.jsx(uz,{})},{path:"/link-to-totalhorsechannel-com",element:e.jsx(fz,{})},{path:"/link-to",loader:()=>Response.redirect("/link-to-totalhorsechannel-com",301),element:null},{path:"/aha-media-partner",element:e.jsx(gz,{})},{path:"/add-video-live",element:e.jsx(yz,{})},{path:"/add-event",element:e.jsx(jz,{})},{path:"/admin/reset-password",element:e.jsx(wz,{})},{path:"/youtube",element:e.jsx(Sz,{})},{path:"/rumble",element:e.jsx(kz,{})},{path:"/instagram",element:e.jsx(Az,{})},{path:"/community-guidelines",element:e.jsx(zz,{})},{path:"/terms-of-service",element:e.jsx(_z,{})},{path:"/privacy-policy",element:e.jsx(Dz,{})},{path:"/games",element:e.jsx(Mz,{})},{path:"/games/horse-eden",element:e.jsx(Bz,{})},{path:"/games/horse-world-online",element:e.jsx(qz,{})},{path:"/category/horse-health",element:e.jsx(Jz,{})},{path:"/category/how-to-videos",element:e.jsx(Qz,{})},{path:"/category/horse-racing",element:e.jsx(tR,{})},{path:"/category/harness-racing",element:e.jsx(aR,{})},{path:"/category/show-jumping",element:e.jsx(rR,{})},{path:"/category/quarter-horse",element:e.jsx(oR,{})}
654,{path:"/category/cutting-horse",element:e.jsx(cR,{})},{path:"/category/campdraft",element:e.jsx(mR,{})},{path:"/category/reined-cow-horse",element:e.jsx(pR,{})},{path:"/category/eventing",element:e.jsx(xR,{})},{path:"/category/reining",element:e.jsx(bR,{})},{path:"/category/western-dressage",element:e.jsx(vR,{})},{path:"/category/campolina",element:e.jsx(wR,{})},{path:"/category/rocky-mountain-horse",element:e.jsx(SR,{})},{path:"/category/cavalo-crioulo",element:e.jsx(kR,{})},{path:"/category/horse-sale",element:e.jsx(AR,{})},{path:"/category/podcast",element:e.jsx(HR,{})},{path:"/category/other-general",element:e.jsx(RR,{})},{path:"/category/miniature-horse",element:e.jsx(LR,{})},{path:"/category/horse-music-videos",element:e.jsx(OR,{})},{path:"/shop/the-horse-capital-tours",element:e.jsx(UR,{})},{path:"/shop/debbie-brooks-equestrian-collection",element:e.jsx(KR,{})},{path:"/events",element:e.jsx(VR,{})},{path:"/admin/events",element:e.jsx(QR,{})},{path:"/admin/contest",element:e.jsx(s7,{})},{path:"/admin/contests",element:e.jsx(r7,{})},{path:"/admin/news",element:e.jsx(u7,{})},{path:"/admin/articles",element:e.jsx(j7,{})},{path:"/contests",element:e.jsx(z7,{})},{path:"/community",element:e.jsx(v8,{})},{path:"/community/p/:postId",element:e.jsx(w8,{}),loader:async({params:t})=>{const a=t.postId;if(!a)return{post:null};try{const r=await fetch(`/api/community/posts/${a}`);return r.ok?{post:(await r.json()).post??null}:{post:null}}catch{return{post:null}}}},{path:"/news/submit",element:e.jsx(D7,{})},{path:"/news/:slug",element:e.jsx(K7,{}),loader:async({params:t,request:a})=>{const l=new URL(a.url).searchParams.get("preview")==="1"?"?preview=1":"";try{const d=await fetch(`/api/news/${t.slug}${l}`,{headers:{Accept:"application/json"}});return d.status===404?{article:null,notFound:!0}:d.ok?d.json():{article:null,notFound:!1}}catch(d){return console.error(`[client /news/:slug loader] fetch error for slug: ${t.slug}`,d),{article:null,notFound:!1}}}},{path:"*",element:e.jsx(W7,{})}],Y7=g.lazy(()=>Fx(()=>import("./CookieBanner-ChUegC1S.js"),__vite__mapDeps([4,1,3,2])).catch(t=>(console.warn("Failed to load CookieBanner:",t),{default:()=>null}))),G7=()=>e.jsx("div",{className:"flex justify-center py-8 h-screen items-center",children:e.jsx(_6,{})}),Z7=e.jsx(g.Suspense,{fallback:e.jsx(G7,{}),children:e.jsx(R6,{children:e.jsx(A3,{})})}),J7=[{element:Z7,children:q7}],X7=aC(J7);function Q7(){return e.jsxs(e.Fragment,{children:[e.jsx(gC,{router:X7}),e.jsx(bC,{children:e.jsx(g.Suspense,{fallback:null,children:e.jsx(Y7,{})})})]})}const e_=new g4({defaultOptions:{queries:{staleTime:1e3*60*5,gcTime:1e3*60*10,retry:1,refetchOnWindowFocus:!1},mutations:{retry:0}}}),Ou=document.getElementById("app");if(!Ou)throw new Error("Root element not found");const t_=e.jsx(I4,{children:e.jsx(b4,{client:e_,children:e.jsx(Q7,{})})}),xw=e.jsx(g.StrictMode,{children:t_});Ou.firstElementChild?i0.hydrateRoot(Ou,xw):i0.createRoot(Ou).render(xw);export{Qc as B,Jf as I,Vs as V,Te as c};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.