UPDATE `aircraft_profiles`
SET
    `profile_data` = JSON_SET(
        COALESCE(`profile_data`, JSON_OBJECT()),
        '$.renderer', 'gltf-a320-v1',
        '$.model_url', 'https://cdn.jsdelivr.net/gh/amvlab/aircraft-models@main/models/A320_nologo.glb',
        '$.texture_size', 2048,
        '$.direct_3d_paint', true,
        '$.paint_engine', 'mesh-uv-raycast-v1',
        '$.model_license.name', 'Creative Commons Attribution 4.0 International',
        '$.model_license.spdx', 'CC-BY-4.0',
        '$.model_license.source', 'https://github.com/amvlab/aircraft-models',
        '$.model_license.author', 'amvlab'
    ),
    `is_active` = 1,
    `supports_3d_paint` = 1,
    `updated_at` = NOW()
WHERE `slug` = 'fbw-a32nx';

SELECT `id`, `slug`, `name`, `supports_3d_paint`, `profile_data`
FROM `aircraft_profiles`
WHERE `slug` = 'fbw-a32nx';
