<?php if (!defined('DASHBOARD_ROOT')) { http_response_code(403); exit; } ?> <div class="ov-panel"> <div class="ov-panel-hdr"> <span class="ov-panel-title"><svg width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.8"><path d="M12 22s8-4 8-10V5l-8-3-8 3v7c0 6 8 10 8 10z"/></svg> Security Pulse</span> <a href="?view=security" class="ov-panel-link">Details &rarr;</a> </div> <div class="ov-sec-stats"> <div class="ov-sec-stat"><span style="color:#e74c3c"><?= $secToday ?></span><em>Events Today</em></div> <div class="ov-sec-stat"><span style="color:#f39c12"><?= $blockedToday ?></span><em>Blocked IPs</em></div> <div class="ov-sec-stat"><span style="color:#9b59b6"><?= $hpToday ?></span><em>Honeypot Hits</em></div> </div> <div class="ov-sec-feed"><?php foreach ($recentEvents as $ev): $t = $ev['created_at'] ? date('H:i', strtotime($ev['created_at'])) : '&#x2014;'; ?> <div class="ov-sec-row"> <span class="ov-sec-dot"></span> <span class="ov-sec-action"><?= htmlspecialchars($ev['action'] ?? 'event') ?></span> <span class="ov-sec-ip"><?= htmlspecialchars($ev['ip_address'] ?? '') ?></span> <span class="ov-sec-time"><?= $t ?></span> </div><?php endforeach; ?> <?php if (empty($recentEvents)): ?> <div class="ov-panel-empty">No recent events &#x2014; all clear</div><?php endif; ?> </div> <div class="ov-engine-status"> <span class="ov-engine-lbl">Engine</span> <span class="ov-engine-dot <?= $engineStatus === 'running' ? 'on' : 'off' ?>"></span> <span class="ov-engine-val"><?= htmlspecialchars($engineStatus) ?></span> </div> </div>