Posts from a category on homepage with category archieves page default css

    $args = array(
        'posts_per_page' => 5,
        'cat' => 77 // 77 - id category
    );

    $query = new WP_Query( $args );

    // loop
    if ( $query->have_posts() ) {
        while ( $query->have_posts() ) {
            $query->the_post();
echo '<li>';
the_post_thumbnail();
            echo '<a href="'.get_permalink().'">' . get_the_title() . '</a></li>';
        }
    } else {
        // posts not fount
    echo 'posts not fount';
    }
    wp_reset_postdata();

Replace the category id (77) with the id of the category you need. You need to add this code to the template. In the place where you want to display the records (for example: index.php).

tech