import React, { useState, useEffect, useRef } from 'react'; import { BarChart, Bar, XAxis, YAxis, Tooltip, ResponsiveContainer } from 'recharts'; import { initLocalEngine, routeInference } from '../utils/inferenceRouter'; import HCaptcha from '@hcaptcha/react-hcaptcha'; import { supabase, useAuth, GATEWAY_URL, LEMON_CHECKOUT_URL } from '../context'; export default function QuickStatsBar({ usage }) { const daysUntilReset = () => { const now = new Date(); const end = new Date(now.getFullYear(), now.getMonth() + 1, 0); return Math.max(0, end.getDate() - now.getDate()); }; return (