<?php
if ( ! defined( 'ABSPATH' ) ) {
	exit; // Exit if accessed directly.
}
?>
<div class="post-category-list style-1 post-trans">	
	<?php
	$categories = get_the_category( get_the_ID() );
	$i          = 0;
	foreach ( $categories as $category ) {
		if ( $i == 0 ) {
			echo '<span><a href="' . esc_url( get_category_link( $category->cat_ID ) ) . '">' . esc_html( $category->name ) . '</a></span>';
		}
		++$i;
	}
	?>
</div>

