<?php get_header();

$title = get_theme_mod( 'aurora_lite_404_page_title', __( 'This is a dead end', 'aurora-lite' ) );
$text  = get_theme_mod( 'aurora_lite_404_page_text', __( 'Sorry, the page you are looking for does not exist or the link is incorrect.', 'aurora-lite' ) );

$bg_image = get_theme_mod( 'aurora_lite_404_bg_image' );
if ( empty( $bg_image ) ) {
    $image_name = get_theme_mod( 'aurora_lite_404_page_layout', 'Default' );
    $bg_image = get_template_directory_uri() . '/assets/images/' . sanitize_file_name( $image_name ) . '.jpg';
}

aurora_lite_template_loader('template-parts/404', [
        'title'    => $title,
        'text'     => $text,
        'bg_image' => $bg_image,
    ]
);

get_footer();