<div class="signatures">
  <div class="sig-block">
    <p class="sig-title">For the Service Provider</p>
    <p><strong>{{provider.name}}</strong></p>
    {{#if hasStaffSignature}}
    {{#each signatures}}
    {{#if (eq role "STAFF")}}
    <div class="sig-image-box">
      {{#if signatureImageUrl}}<img src="{{signatureImageUrl}}" alt="Staff signature" />{{/if}}
    </div>
    <p class="sig-line"><strong>Name:</strong> {{signerDisplayName}}</p>
    <p class="sig-meta"><strong>Role:</strong> Authorized EDR representative</p>
    <p class="sig-meta"><strong>Date:</strong> {{signedAt}}</p>
    {{/if}}
    {{/each}}
    {{else}}
    <div class="sig-image-box"><span class="sig-placeholder">Signature pending</span></div>
    <p class="sig-line"><strong>Name:</strong> Authorized representative</p>
    <p class="sig-meta"><strong>Role:</strong> EDR representative</p>
    <p class="sig-meta"><strong>Date:</strong></p>
    {{/if}}
  </div>
  <div class="sig-block">
    <p class="sig-title">For the Client</p>
    <p><strong>{{client.companyName}}</strong></p>
    {{#if hasCustomerSignature}}
    {{#each signatures}}
    {{#if (eq role "CUSTOMER")}}
    <div class="sig-image-box">
      {{#if signatureImageUrl}}<img src="{{signatureImageUrl}}" alt="Customer signature" />{{/if}}
    </div>
    <p class="sig-line"><strong>Name:</strong> {{signerDisplayName}}</p>
    <p class="sig-meta"><strong>Role:</strong> Authorized client representative</p>
    <p class="sig-meta"><strong>Date:</strong> {{signedAt}}</p>
    {{/if}}
    {{/each}}
    {{else}}
    <div class="sig-image-box"><span class="sig-placeholder">Signature pending</span></div>
    <p class="sig-line"><strong>Name:</strong> Client representative</p>
    <p class="sig-meta"><strong>Role:</strong> Authorized client representative</p>
    <p class="sig-meta"><strong>Date:</strong></p>
    {{/if}}
  </div>
</div>
