interface Props { active: boolean; progress: number; // 0 → 1 onCancel?: () => void; } export function CalibrationOverlay({ active, progress, onCancel }: Props) { if (!active) return null; const pct = Math.round(progress * 100); const secondsLeft = Math.max(0, Math.ceil(5 - progress * 5)); return (

Calibrating sensing

Look at the camera with a relaxed, neutral expression.
We're learning your baseline so detection works on your face.

{secondsLeft > 0 ? `${secondsLeft}s remaining` : "Finishing…"}

{onCancel && ( )}
); }