<?php get_header(); ?>
<div class="mainArea">
  <div class="main_inner">
    <p class="main_txt">Printing Pros, <br>Trust & Quality<br>at Taihei Print.<span>信頼と品質にこだわる印刷のプロフェッショナル。<br>大平特殊印刷所がお客様のニーズを叶えます。</span></p>
  </div>
	<div class="scrolldown1"><span>SCROLL</span></div>
</div>
<div class="transparent_bg">
  <div class="newsArea">
    <div class="inner">
      <div class="left">
        <div class="h2Area">
          <h2>新着情報</h2>
          </div>
        </div>
      <div class="right">
        <ul>
<?php
$args = [
	"posts_per_page" => 3,
	'paged' => get_query_var('paged') ? get_query_var('paged') : 1,
	"post_type" => "post",
	"orderby " => "date",
	"post_status" => "publish",
	"category_name" => "news"
];
	$the_query = new WP_Query($args);
	if ($the_query->have_posts()) {
	while ($the_query->have_posts()) {
		$the_query->the_post();
		$cat = get_the_category();
		$cat = $cat[0];
?>
          <li>
            <div class="n_left">
              <time class="date"><?php the_time("Y-m-d"); ?></time>
              </div>
            <div class="n_right">
              <div class="ttl"><a href="<?php the_permalink(); ?>"><?php echo mb_strimwidth(get_the_title(), 0, 250, "..."); ?></a></div>
              </div>
            </li>
<?php	}
} else { ?>
			<p class="nopost">現在、投稿情報はございません。</p>
<?php }
?>
          </ul>
        <div class="btn"><a href="<?php echo home_url('topics/'); ?>" class="btnarrow btn01">お知らせ一覧</a></div>
        </div>
      </div>
    </div>
  <div class="aboutArea">
    <div class="inner fadeUpTrigger">
      <div class="left">
        <div class="h2Area">
          <h2>大平特殊印刷について</h2>
        </div>
		  <div class="img"><img src="<?php echo get_theme_file_uri('/img/top/about_logo.svg'); ?>" alt="有限会社 大平特殊印刷所"></div>
        <p>弊社は常にお客様の目線に立って<br>一つ一つ丁寧なものづくりを心がけています。<br>培った経験とノウハウであらゆる角度からお客様のニーズにお応えいたします。</p>
        </div>
		<div class="right">
			<div class="img"></div>
			<div class="btn"><a href="<?php echo home_url('service/'); ?>" class="btnarrow btn01">事業内容</a></div>
		</div>
	  </div>
  </div>
  <div class="contentArea">
    <ul class="fadeUpTrigger">
      <li>
        <div class="h2Area">
          <h2>製作事績</h2>
          </div>
        <div class="btn"><a href="<?php echo home_url('works/'); ?>" class="btnarrow btn01">実績のご紹介</a></div>
        </li>
      <li>
        <div class="h2Area">
          <h2>会社概要</h2>
          </div>
        <div class="btn"><a href="<?php echo home_url('company/'); ?>" class="btnarrow btn01">会社情報の紹介</a></div>
        </li>
      <li>
        <div class="h2Area">
          <h2>お問い合わせ</h2>
          </div>
        <div class="btn"><a href="<?php echo home_url('contact/'); ?>" class="btnarrow btn01">問い合わせフォーム</a></div>
        </li>
      </ul>
    </div>
</div>
<?php get_footer(); ?>
