-- Add brand_color column to church_config table
ALTER TABLE church_config 
ADD COLUMN brand_color VARCHAR(7) DEFAULT '#fb8b23';

-- Update existing record with the current brand color
UPDATE church_config 
SET brand_color = '#fb8b23' 
WHERE brand_color IS NULL;

-- Make the column NOT NULL after setting default values
ALTER TABLE church_config 
ALTER COLUMN brand_color SET NOT NULL;