<?php

$pinned_post = get_latest_sticky_post_by_category(740);


if ($pinned_post) :
?>

    <a href="<?php echo get_permalink($pinned_post->ID); ?>" class="hero-banner">
        <div class="hero-banner__bg">
            <?= show_post_image($pinned_post->ID); ?>
        </div>
        <!--<p class="hero-banner__main">Главное</p>-->
        <div class="hero-banner__content">
            <p class="hero-banner__title subtitle-16">
                <?php echo get_the_title($pinned_post->ID); ?>
            </p>
            <p class="hero-banner__text text-13">
                <?php echo get_the_excerpt($pinned_post->ID); ?>
            </p>
        </div>
        <div class="tag hero-banner__tag"><?php echo esc_html( get_priority_category_en($pinned_post) ); ?></div>
    </a>

<?php endif; ?>