@php
    $owner  = $this->document->owner;
    $claim  = $owner instanceof \App\Models\Claim\Claim
                ? $owner
                : ($owner && method_exists($owner, 'claim') ? $owner->claim : null);
    $client = $claim?->client?->fullName ?? $claim?->client?->display_name ?? null;
    $context = $client ?: 'Document evidence';
@endphp
<div class="flex-grow-1 d-flex flex-column" style="min-height:0;">
    <livewire:dsar.evidence-viewer
        :document="$this->document"
        :back-url="url()->previous()"
        :file-name="$this->document->display_name"
        :context-label="$context"
        :key="'viewer-doc-' . $this->document->id"
    />
</div>
