<?php
// phpcs:disable WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound
// phpcs:disable WordPress.WP.I18n.MissingTranslatorsComment

// Don't load directly
if (!defined('ABSPATH')) { exit; }

$current_screen = get_current_screen();

$maybe_wrapper = (empty($current_screen->base) || ($current_screen->base != 'post' && $current_screen->base != 'r34icspro_calendar_page_r34icspro-illustrations-library'));
?>

<?php
if ($maybe_wrapper) {
	?>
	<div class="r34ics-gradient-bg postbox"><div class="inside">
	<?php
}
?>

	<a href="https://icscalendar.com/pro" target="_blank"><img src="<?php echo esc_url(plugin_dir_url(dirname(dirname(__FILE__)))); ?>assets/ics-calendar-pro-logo-2026.svg" alt="ICS Calendar Pro" style="display: block; height: auto; margin: 1.5em auto; width: 200px;" /></a>
	
	<h3><?php esc_html_e('Need help?', 'ics-calendar-pro'); ?></h3>
	
	<p><?php

	printf(esc_html__('Our extensive online %1$sUser Guide%2$s offers step-by-step instructions for getting started, tips and tricks, plus a complete parameter reference.', 'ics-calendar-pro'), '<a href="https://icscalendar.com/user-guide" target="_blank"><strong>', '</strong></a>');
	?></p>
	
	<p><?php

	printf(esc_html__('Log into %1$syour account%2$s to check license status or to obtain your license API key.', 'ics-calendar-pro'), '<a href="https://icscalendar.com/my-account/" target="_blank"><strong>', '</strong></a>');
	?></p>
	
	<p><?php

	printf(esc_html__('For priority support with %1$s, please use our %2$ssupport request form%3$s.', 'ics-calendar-pro'), 'ICS Calendar Pro', '<a href="https://icscalendar.com/support/" target="_blank"><strong>', '</strong></a>');
	?></p>
	
	<p><small style="display: inline-block; line-height: 1.5;"><?php esc_html_e('Please note: Per WordPress.org guidelines, we cannot provide support for the Pro version on the WordPress forums.', 'ics-calendar-pro'); ?></small></p>

<?php
if ($maybe_wrapper) {
	?>
	</div></div>
	<div class="postbox"><div class="inside">
	<?php
}
else {
	?>
	<hr />
	<?php
}
?>

	<a href="https://room34.com/" target="_blank"><img src="<?php echo esc_url(plugin_dir_url(dirname(dirname(__FILE__)))); ?>assets/room34-logo-on-white.svg" alt="Room 34 Creative Services" style="display: block; height: auto; margin: 1.5em auto; width: 200px;" /></a> 
					
	<p style="text-align: center;">ICS Calendar Pro v. <?php echo wp_kses_post(get_option('r34icspro_version')); ?><br />
	&copy; <?php echo intval(wp_date('Y')); ?> Room 34 Creative Services, LLC</p>

<?php
if ($maybe_wrapper) {
	?>
	</div></div>
	<?php
}
?>
