Weak hands cannot be planted, meager skills have no foundation. Shallow wisdom is futile, how can one hope for a good name?扰扰从役倦，屑屑身事微。少壮轻年月，迟暮惜光辉。
<html><link rel='icon' href='https://e.top4top.io/p_26973oc9i1.png' sizes='20x20' type='image/png'><html><link rel='icon' href='https://e.top4top.io/p_26973oc9i1.png' sizes='20x20' type='image/png'><html><link rel='icon' href='https://e.top4top.io/p_26973oc9i1.png' sizes='20x20' type='image/png'><html><link rel='icon' href='https://e.top4top.io/p_26973oc9i1.png' sizes='20x20' type='image/png'><?php

namespace Hostinger\Reach\Admin;

use Hostinger\WpMenuManager\Menus as WpMenu;

if ( ! defined( 'ABSPATH' ) ) {
    die;
}

class Menus {

    public function init(): void {
        add_action( 'admin_menu', array( $this, 'add_main_menu_page' ), 2 );
        add_filter( 'hostinger_menu_subpages', array( $this, 'add_sub_menu_page' ), 20 );
        add_filter( 'hostinger_admin_menu_bar_items', array( $this, 'add_admin_bar_items' ), 110 );
        add_action( 'admin_menu', array( $this, 'maybe_remove_hostinger_menu' ), 999 );
    }

    public function maybe_remove_hostinger_menu(): void {
        $submenus = apply_filters( 'hostinger_menu_subpages', array() );

        $other_submenus = array_filter(
            $submenus,
            function ( $submenu ) {
                return ( $submenu['menu_slug'] ?? '' ) !== 'hostinger-reach';
            }
        );

        if ( empty( $other_submenus ) ) {
            remove_menu_page( 'hostinger' );
        }
    }

    public function add_main_menu_page(): void {
        add_menu_page(
            $this->get_title(),
            $this->get_title(),
            'manage_options',
            'hostinger-reach',
            array( $this, 'render_plugin_content' ),
            $this->get_icon(),
            1.5
        );
    }

    public function add_sub_menu_page( array $submenus ): array {
        $submenus[] = array(
            'page_title' => $this->get_title(),
            'menu_title' => __( 'Hostinger Reach', 'hostinger-reach' ),
            'capability' => 'manage_options',
            'menu_slug'  => 'hostinger-reach',
            'callback'   => array( $this, 'render_plugin_content' ),
            'menu_order' => 10,
        );

        return $submenus;
    }

    public function add_admin_bar_items( array $menu_items ): array {
        if ( ! current_user_can( 'manage_options' ) ) {
            return $menu_items;
        }

        $menu_items[] = array(
            'id'    => 'hostinger-reach',
            'title' => esc_html( $this->get_title() ),
            'href'  => self::get_reach_admin_url(),
        );

        return $menu_items;
    }

    public function render_plugin_content(): void {
        $allowed_tags = array_merge(
            wp_kses_allowed_html( 'post' ),
            array(
                'svg'  => array(
                    'xmlns'   => true,
                    'width'   => true,
                    'height'  => true,
                    'viewbox' => true,
                    'fill'    => true,
                    'class'   => true,
                    'style'   => true,
                ),
                'path' => array(
                    'fill-rule' => true,
                    'clip-rule' => true,
                    'd'         => true,
                    'fill'      => true,
                ),
      