- apply_margin_cap: position scales DOWN as drawdown increases.
At 0% DD → 100% position, at 12.5% DD → 50%, at 20% DD → 20%.
Prevents multi-bar cascading losses that pushed max_dd to 38-51%.
- Add trading_days_per_year to DQNHyperparameters (default 252).
Configurable for crypto (365) or different markets.
- Fix trailing stop comment: value IS prev_equity (not approximation).
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>