window.renderTerminalVariation = function (mount) { const { useEffect, useState } = React; const { ApplyModal, FAQ } = window.ApexUI; const { HumansVsMachinesHero } = window.ApexHeroMachines; const D = window.ApexData; function useResponsive() { const [w, setW] = useState(typeof window !== "undefined" ? window.innerWidth : 1280); useEffect(() => { const onResize = () => setW(window.innerWidth); window.addEventListener("resize", onResize); return () => window.removeEventListener("resize", onResize); }, []); return { w, isMobile: w < 768, isTablet: w >= 768 && w < 1024 }; } const theme = { bg: "#0A0B0D", surface: "#0F1114", surfaceAlt: "#12151A", border: "rgba(255,255,255,0.07)", borderStrong: "rgba(255,255,255,0.14)", fg: "#E7E9EC", dim: "rgba(231,233,236,0.55)", dimmer: "rgba(231,233,236,0.35)", accent: "#00D4C8", green: "#00C389", red: "#E5484D", mono: '"JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace', sans: '"Inter Tight", "Inter", system-ui, -apple-system, sans-serif', }; function fmtPct(value, digits = 1) { if (value === null || value === undefined || Number.isNaN(Number(value))) return "—"; return `${Number(value).toFixed(digits)}%`; } function fmtNumber(value, digits = 1) { if (value === null || value === undefined || Number.isNaN(Number(value))) return "—"; return Number(value).toFixed(digits); } function fetchFeatured() { return fetch("/api/v1/public/main-page") .then((response) => { if (!response.ok) throw new Error(`HTTP ${response.status}`); return response.json(); }); } function Nav({ onApply, r }) { return (
Apex Algo
{r.isMobile ? "Members" : "Members area"}
); } function SectionHead({ eyebrow, title, sub, r }) { return (
{eyebrow}
{title}
{sub &&
{sub}
}
); } function MetricCard({ label, value, tone = "fg", note }) { return (
{label}
{value}
{note ?
{note}
: null}
); } function RiskTabs({ riskProfiles, activeRiskId, onChange, r }) { return (
{riskProfiles.map((risk) => { const active = risk.id === activeRiskId; return ( ); })}
); } function Hero({ featured, activeRisk, activeRiskId, onRiskChange, onApply, r, loading, error }) { const annualReturn = fmtPct(activeRisk?.annualized_return_pct); const maxDrawdown = fmtPct(activeRisk?.max_drawdown_pct); const strategyCount = featured?.strategy_count || 10; const tradeStats = featured?.trade_stats || {}; const avgTradesPerMonth = fmtNumber(tradeStats.average_trades_per_month, 1); const avgHoldTime = tradeStats.average_hold_time || "—"; return (
Featured models

{featured?.label || "BTC Algo 0001"}

{[ { k: "Asset", v: (featured?.asset || "BTC").toUpperCase() }, { k: "Strategies", v: String(strategyCount) }, { k: "Avg trades / month", v: avgTradesPerMonth }, { k: "Avg hold time", v: avgHoldTime }, ].map((item) => (
{item.k}
{item.v}
))}
APX://main/featured ● backtested window
APPROVED RISK PROFILES
{error ? "Public performance data is temporarily unavailable." : featured?.disclaimer || "Based on the prior 3-year backtest window. Past performance does not guarantee future results."}
{!error && featured?.live_calibration_note ? (
{featured.live_calibration_note}
) : null}
); } function Process({ r }) { const steps = [ { n: "01", k: "We research and validate", d: "Strategies are developed through our proprietary research process, then promoted only after they pass live validation." }, { n: "02", k: "You connect your exchange", d: "Link a supported exchange or broker account." }, { n: "03", k: "You choose the approved risk profile", d: "Select the approved risk profile that fits you, then launch the model on your own account." }, { n: "04", k: "The software trades for you", d: "The software runs on your broker or exchange. We license the system; we do not handle your money." }, ]; const cols = r.isMobile ? 1 : (r.isTablet ? 2 : 4); return (
{steps.map((step, index) => (
{step.n} / 04
{step.k}
{step.d}
))}
); } function Pricing({ onApply, r }) { const plans = [ { name: "Access License", price: "$4,999", suffix: "upfront", note: "$499/mo · up to $100k allocated capital", }, { name: "Lifetime License", price: "$20,000", suffix: "one-time", note: "No monthly dues · up to $250k allocated capital", }, { name: "Lifetime License Unlimited", price: "$20,000", suffix: "+ $999/mo", note: "No allocated-capital limit", }, ]; return (
{plans.map((plan) => (
{plan.name}
{plan.price}USD
{plan.suffix}
{plan.note}
))}
No performance fee. Client funds remain with their broker or exchange.
); } function FAQSection({ r }) { return (
); } function FinalCTA({ onApply, r }) { return (
APPLICATIONS OPEN

If the numbers earn your attention, apply.

We review applications personally. Reach us at access@theapexalgo.com.

); } function Footer({ r }) { return ( ); } function App() { const [modal, setModal] = useState(false); const [featured, setFeatured] = useState(null); const [loading, setLoading] = useState(true); const [error, setError] = useState(""); const [activeRiskId, setActiveRiskId] = useState("moderate"); const r = useResponsive(); useEffect(() => { let cancelled = false; setLoading(true); fetchFeatured() .then((payload) => { if (cancelled) return; setFeatured(payload); const available = Array.isArray(payload?.risk_profiles) ? payload.risk_profiles : []; const defaultRisk = payload?.default_risk_profile_id || available[0]?.id || "moderate"; setActiveRiskId(defaultRisk); setError(""); }) .catch(() => { if (cancelled) return; setError("Failed to load public model data."); }) .finally(() => { if (!cancelled) setLoading(false); }); return () => { cancelled = true; }; }, []); const riskProfiles = Array.isArray(featured?.risk_profiles) ? featured.risk_profiles : []; const activeRisk = riskProfiles.find((risk) => risk.id === activeRiskId) || riskProfiles[0] || null; return (
); } ReactDOM.createRoot(mount).render(); }; function btnPrimary(t, extra = {}) { return { background: t.accent, color: "#0A0B0D", border: "none", padding: "9px 16px", fontSize: 13, fontWeight: 500, cursor: "pointer", borderRadius: 2, fontFamily: t.sans, letterSpacing: "-0.005em", ...extra, }; } function btnSecondary(t, extra = {}) { return { background: "transparent", color: t.fg, border: `1px solid ${t.border}`, padding: "9px 16px", fontSize: 13, cursor: "pointer", borderRadius: 2, fontFamily: t.sans, ...extra, }; }