<?php
/**
 * Target Solutions Module
 */
$tsUrl = getSetting('target_solutions_url', 'https://app.targetsolutions.com');
?>

<div class="page-header">
    <h1>Target Solutions</h1>
</div>

<!-- Hero Card -->
<div class="card" style="text-align:center; padding:48px 32px;">
    <div style="margin-bottom:20px;">
        <svg width="64" height="64" viewBox="0 0 24 24" fill="none" stroke="var(--cfd-red)" stroke-width="1.5" style="margin-bottom:12px;">
            <circle cx="12" cy="12" r="10"/>
            <circle cx="12" cy="12" r="6"/>
            <circle cx="12" cy="12" r="2"/>
        </svg>
    </div>
    <h2 style="font-size:24px; font-weight:800; margin-bottom:8px;">Target Solutions</h2>
    <p style="color:var(--ios-secondary); font-size:15px; max-width:500px; margin:0 auto 24px;">
        Access training assignments, compliance tracking, and certification management through Target Solutions.
    </p>
    <a href="<?= htmlspecialchars($tsUrl) ?>" target="_blank" class="btn btn-primary btn-lg">
        Open Target Solutions
        <svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><path d="M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6"/><polyline points="15 3 21 3 21 9"/><line x1="10" y1="14" x2="21" y2="3"/></svg>
    </a>
</div>

<!-- API Integration Notice -->
<div class="card" style="margin-top:20px;">
    <div class="card-header">
        <h2 class="card-title">API Integration</h2>
        <span class="badge badge-orange">Coming Soon</span>
    </div>
    <p style="color:var(--ios-secondary); font-size:14px;">
        When the Target Solutions API key is available, this module will display training assignments,
        completion status, and certification tracking directly within the portal.
    </p>
    <p style="color:var(--ios-secondary); font-size:14px; margin-top:8px;">
        Contact an administrator to connect your Target Solutions account.
    </p>
</div>
