<?php
$source = "C:\\Users\\ASUS\\.gemini\\antigravity\\brain\\69907928-efa2-41bd-997d-edfadc3e88d6\\uploaded_image_1766890026822.jpg";
$dest = __DIR__ . "/profile-hero.jpg";

echo "Attempting to copy from $source to $dest\n";

if (file_exists($source)) {
    echo "Source exists!\n";
    $content = file_get_contents($source);
    if ($content !== false) {
        echo "Successfully read source content (" . strlen($content) . " bytes)\n";
        if (file_put_contents($dest, $content)) {
            echo "SUCCESS: File written via file_put_contents\n";
        } else {
            echo "ERROR: Failed to write to $dest\n";
        }
    } else {
        echo "ERROR: Failed to read from $source\n";
    }
} else {
    echo "ERROR: Source file does not exist.\n";
}
?>
