<?php
if ( ! defined( 'ABSPATH' ) ) {
	exit; // Exit if accessed directly
}

/**
 * ============================================
 * FILE: templates/emails/employee/event-reminder.php
 * Employee Event Reminder Email Template
 * ============================================
 */
?>
<?php
do_action( 'rtrb_get_email_header', $email, $booking );
do_action( 'rtrb_email_before_content', $email, $booking );
do_action( 'rtrb_email_content_start', $email, $booking );
?>

<!-- Email Content Text -->
<table width="100%" border="0" cellspacing="0" cellpadding="0">
	<tr>
		<td class="main-content">
			<?php if ( ! empty( $settings['additional_content'] ) ) : ?>
				<?php echo wp_kses_post( wpautop( wptexturize( $settings['additional_content'] ) ) ); ?>
			<?php else : ?>
				<p style="margin: 0;"><?php esc_html_e( 'This is a reminder about an upcoming event on your schedule. Please review the details below and prepare accordingly.', 'radius-booking' ); ?></p>
			<?php endif; ?>
		</td>
	</tr>
</table>

<!-- Recent Registration Info Box -->
<table width="100%" border="0" cellspacing="0" cellpadding="0" style="background-color: #f9fafb; border: 1px solid #e5e7eb; border-radius: 6px; margin: 16px 0;">
	<tr>
		<td style="padding: 16px;">
			<p style="margin: 0 0 8px 0; font-weight: 600; color: #111827;">
				<?php esc_html_e( 'Attendee Information:', 'radius-booking' ); ?>
			</p>
			<p style="margin: 0 0 4px 0; font-size: 14px; color: #374151;">
				<strong><?php esc_html_e( 'Name:', 'radius-booking' ); ?></strong> <?php echo esc_html( $booking['customer']->customer_info['name'] ?? '' ); ?>
			</p>
			<p style="margin: 0 0 4px 0; font-size: 14px; color: #374151;">
				<strong><?php esc_html_e( 'Email:', 'radius-booking' ); ?></strong> <?php echo esc_html( $booking['customer']->customer_info['email'] ?? '' ); ?>
			</p>
			<?php if ( isset( $booking['customer']->customer_info['phone'] ) ) : ?>
				<p style="margin: 0; font-size: 14px; color: #374151;">
					<strong><?php esc_html_e( 'Phone:', 'radius-booking' ); ?></strong> <?php echo esc_html( $booking['customer']->customer_info['phone'] ); ?>
				</p>
			<?php endif; ?>
		</td>
	</tr>
</table>

<?php do_action( 'rtrb_email_before_booking_details', $email, $booking ); ?>

<?php require __DIR__ . '/../partials/event-details-block.php'; ?>

<?php do_action( 'rtrb_email_after_booking_details', $email, $booking ); ?>

<?php if ( ! empty( $settings['footer_text'] ) ) : ?>
	<table width="100%" border="0" cellspacing="0" cellpadding="0">
		<tr>
			<td class="footer-text">
				<?php echo wp_kses_post( wpautop( wptexturize( $settings['footer_text'] ) ) ); ?>
			</td>
		</tr>
	</table>
<?php endif; ?>

<?php do_action( 'rtrb_email_before_button', $email, $booking ); ?>

<?php if ( ! empty( $settings['button_text'] ) ) : ?>
	<?php do_action( 'rtrb_email_button', $email, $booking, $settings ); ?>
<?php endif; ?>

<?php
do_action( 'rtrb_email_content_end', $email, $booking );
do_action( 'rtrb_email_after_content', $email, $booking );
do_action( 'rtrb_get_email_footer', $email, $booking );
?>
