-- Free-tier buff activations: 3 per rolling 24h window (spec daily task "Use 3 Buffs").
-- Subscribers ignore quota (subscription_active).

ALTER TABLE heroes
	ADD COLUMN IF NOT EXISTS buff_free_charges_remaining INT NOT NULL DEFAULT 3,
	ADD COLUMN IF NOT EXISTS buff_quota_period_end TIMESTAMPTZ NULL;

COMMENT ON COLUMN heroes.buff_free_charges_remaining IS 'Free buff activations left in current window (non-subscribers; resets when period rolls).';
COMMENT ON COLUMN heroes.buff_quota_period_end IS 'End of current 24h buff quota window; NULL until first activation in a session.';
