export type AnalyticsPayload = Record<string, unknown>

/**
 * Lightweight analytics stub. In production this should forward to a real
 * provider (PostHog, Plausible, etc.). For now we just log for visibility and
 * keep a typed API so that calls compile even when the real service is absent.
 */
export function track(event: string, payload: AnalyticsPayload = {}) {
    if (import.meta.env.MODE === 'production') {
        // TODO: connect real analytics provider
    } else {
        // eslint-disable-next-line no-console
        console.debug(`[analytics] ${event}`, payload)
    }
} 