<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>{{ $notice->title }} - {{ $global_settings['college_name'] ?? 'College Name' }}</title>
    @php
        $favicon = $global_settings['site_favicon'] ?? 'frontend/assets/img/favicon.png';
        if (preg_match('/^(http|data:)/', $favicon)) {
            $favUrl = $favicon;
        } elseif (file_exists(public_path('storage/' . $favicon))) {
            $favUrl = asset('storage/' . $favicon);
        } else {
            $favUrl = asset($favicon);
        }
    @endphp
    <!-- Favicon -->
    <link rel="shortcut icon" href="{{ $favUrl }}" type="image/x-icon">
    <link rel="icon" href="{{ $favUrl }}" type="image/x-icon">
    <style>
        body, html {
            margin: 0;
            padding: 0;
            height: 100%;
            overflow: hidden;
            background: #525659; /* Default PDF viewer bg color */
        }
        iframe {
            width: 100%;
            height: 100%;
            border: none;
        }
    </style>
</head>
<body>
    <iframe src="{{ route('notice.stream', $notice->id) }}" type="application/pdf"></iframe>
</body>
</html>
