-- AlterTable: Convert videoStyle from enum to text (data-safe)
-- Step 1: Alter columns to TEXT, casting existing enum values to strings
ALTER TABLE "Project" ALTER COLUMN "videoStyle" DROP DEFAULT;
ALTER TABLE "Project" ALTER COLUMN "videoStyle" TYPE TEXT USING "videoStyle"::TEXT;
ALTER TABLE "Project" ALTER COLUMN "videoStyle" SET DEFAULT 'CINEMATIC';

ALTER TABLE "UserPreference" ALTER COLUMN "defaultVideoStyle" DROP DEFAULT;
ALTER TABLE "UserPreference" ALTER COLUMN "defaultVideoStyle" TYPE TEXT USING "defaultVideoStyle"::TEXT;
ALTER TABLE "UserPreference" ALTER COLUMN "defaultVideoStyle" SET DEFAULT 'CINEMATIC';

-- Step 2: Drop the enum type (no longer needed)
DROP TYPE IF EXISTS "VideoStyle";
