fix: update ECG feature indexing and heart rate tracking
- Convert P-wave index tracking to per-lead storage
- Update R-peak tracking for two-peak heart rate calculation
- Use per-lead sample counters for global index alignment
- Update QRS and P-wave index types to size_t
- Add extraction and validation debug logging
- Adjust low heart rate QRS detection threshold
- Update affected ECG extraction tests