{% extends "base.html" %}
{% block title %}Link Account — ComplyForm Dashboard{% endblock %}
{% block content %}
<div class="max-w-md mx-auto mt-16 p-6 rounded-lg"
     style="background: var(--bg-surface); border: 1px solid var(--border-default);">
  <h1 class="text-xl font-semibold mb-4" style="color: var(--text-primary);">Link Your Account</h1>
  <p class="text-sm mb-6" style="color: var(--text-secondary);">
    Enter your ComplyForm license key to link this account to your dashboard.
  </p>
  {% if error %}
  <div class="mb-4 p-3 rounded text-sm" style="background: #fef2f2; color: #dc2626; border: 1px solid #fecaca;">
    {{ error }}
  </div>
  {% endif %}
  <form method="POST" action="/dashboard/link-account">
    <input type="hidden" name="_csrf" value="{{ csrf_token }}">
    <label for="license_key" class="block text-sm font-medium mb-2" style="color: var(--text-primary);">License Key</label>
    <input type="text" id="license_key" name="license_key"
           placeholder="cf_live_..."
           class="w-full px-3 py-2 rounded text-sm"
           style="background: var(--bg-primary); border: 1px solid var(--border-default); color: var(--text-primary);"
           required>
    <button type="submit"
            class="mt-4 w-full px-4 py-2 rounded text-sm font-medium"
            style="background: var(--accent); color: #ffffff;">
      Link Account
    </button>
  </form>
</div>
{% endblock %}
