<?php
/**
 * Product Categories Widget
 * Displays product categories for single product pages with links to category archive pages
 */

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

require_once __DIR__ . '/widget-product-categories/elementor-render.php';

class GGM_Commerce_Widget_Product_Categories extends \GGM_Commerce_Base_Widget {

    public function get_name() {
        return 'ggmc-product-categories';
    }

    public function get_title() {
        return 'Product Categories';
    }

    public function get_icon() {
        return 'eicon-folder';
    }

    public function get_keywords() {
        return ['product', 'categories', 'category', 'taxonomy', 'ggm-commerce'];
    }

    protected function register_controls() {
        require __DIR__ . '/widget-product-categories/elementor-controls.php';
        require __DIR__ . '/widget-product-categories/elementor-controls-style.php';
    }

    protected function render() {
        ggmc_product_categories_render( $this );
    }

    /**
     * Get default styles for this widget
     * Uses centralized configuration from default-widget-styles.php
     */
    public static function get_static_default_styles() {
        return self::get_defaults_from_config();
    }
}
