<?php

$categories = get_categories();
if (is_array($categories) && count($categories) > 1) {
  echo '<div id="page-menu" class="page-menu light py-4 lg:py-5" >';
  echo '<div class="wrapper">';

  foreach ($categories as $category) {
    $current = is_category($category->term_id) ? 'active' : '';
    echo '<a href="' .  get_category_link($category->term_id) . '" class="pagemenu-item text-[9px] md:text-[10px] mx-10 heading-text uppercase -mt-1 md:mt-0 ' . $current . '" >' . $category->name . '</a>';
  }


  echo '</div>';
  echo '</div>';
}
