<!DOCTYPE html>
<html lang="pt-br">
	<head>
		<meta charset="utf-8">
		<meta http-equiv="X-UA-Compatible" content="IE=edge">
		<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">

		<link href="<?php show_file_link(PROJECT_ICON); ?>" rel="icon">
		<title><?php show_title("Erro 500"); ?></title>
		
		<link href="<?php show_file_link("/assets/vendor/bootstrap/css/bootstrap.min.css"); ?>" rel="stylesheet">
		<link href="<?php show_file_link("/assets/vendor/fontawesome/releases/v6.1.1/css/all.css"); ?>" rel="stylesheet" type="text/css">
		<link href="<?php show_file_link("/assets/fonts/rubik/font.css"); ?>" rel="stylesheet">
		<style>
			body{
				font-family: "Rubik" !important;
			}
		</style>
	</head>
	<body>
		<div class="container">
			<div class="row justify-content-center my-3">
				<div class="col-md-12 text-center">
					<span class="display-1 d-block">500</span>
					<div class="mb-4 lead">Erro interno no sistema!</div>
					
					<?php if (DEBUG == true): ?>
						<div class="card card-body mb-4 lead bg-light text-start" style="font-size: 18px;">
							<p class="mb-0"><?php echo "<strong>Mensagem:</strong> {$e->getMessage()}"; ?></p>
							<p class="mb-0"><?php echo "<strong>Código:</strong> {$e->getCode()}"; ?></p>
							<p class="mb-0"><?php echo "<strong>Arquivo:</strong> {$e->getFile()}"; ?></p>
							<p class="mb-0"><?php echo "<strong>Linha:</strong> {$e->getLine()}"; ?></p>
							<br>
							<div style="background: #fff; border-radius: 0.25rem; padding: 0.5rem; border: 1px solid rgba(0, 0, 0, 0.125);">
								<p><strong>Detalhamento:</strong></p>
								<?php show($e->getTrace()); ?>
							</div>
						</div>
					<?php endif; ?>
				</div>
			</div>
		</div>
	</body>
</html>