{{-- 试卷图片组件(仅OCR场景) --}}
<div class="card bg-base-100 shadow-lg border">
    <div class="card-body">
        <h3 class="card-title text-lg mb-4">
            <svg class="w-5 h-5" fill="none" stroke="currentColor" viewBox="0 0 24 24">
                <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M4 16l4.586-4.586a2 2 0 012.828 0L16 16m-2-2l1.586-1.586a2 2 0 012.828 0L20 14m-6-6h.01M6 20h12a2 2 0 002-2V6a2 2 0 00-2-2H6a2 2 0 00-2 2v12a2 2 0 002 2z"></path>
            </svg>
            试卷图片
        </h3>
        <div class="relative">
            <img
                src="{{ asset($recordData['image_path']) }}"
                alt="试卷图片"
                class="w-full rounded-lg border shadow-sm"
                onerror="this.src='data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNDAwIiBoZWlnaHQ9IjMwMCIgdmlld0JveD0iMCAwIDQwMCAzMDAiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CjxyZWN0IHdpZHRoPSI0MDAiIGhlaWdodD0iMzAwIiBmaWxsPSIjRjNGNEY2Ii8+Cjx0ZXh0IHg9IjIwMCIgeT0iMTUwIiB0ZXh0LWFuY2hvcj0ibWlkZGxlIiBmaWxsPSIjNjc3NDg4IiBmb250LXNpemU9IjE0Ij7lm77niYfliqDovb3lpLHotKU8L3RleHQ+Cjwvc3ZnPg=='"
            >
            @if($recordData['status'] === 'processing')
                <div class="absolute inset-0 bg-black bg-opacity-50 rounded-lg flex items-center justify-center">
                    <div class="text-center text-white">
                        <div class="loading loading-spinner loading-lg"></div>
                        <p class="mt-2">识别处理中...</p>
                    </div>
                </div>
            @endif
        </div>
        <div class="mt-4 text-sm text-gray-600">
            <p>文件名: {{ $recordData['image_filename'] ?? '' }}</p>
            @if(isset($recordData['image_width']) && isset($recordData['image_height']) && $recordData['image_width'] && $recordData['image_height'])
                <p>尺寸: {{ $recordData['image_width'] }} × {{ $recordData['image_height'] }} px</p>
            @endif
            @if(isset($recordData['image_size']) && $recordData['image_size'])
                <p>大小: {{ number_format($recordData['image_size'] / 1024, 1) }} KB</p>
            @endif
        </div>
    </div>
</div>
