<?php

/**
 * Theme setup and configuration
 *
 * @package Sophia
 * @since 1.0.0
 */

// Prevent direct access
if (!defined('ABSPATH')) {
    exit;
}

if (!function_exists('sophia_theme_setup')) :
    /**
     * Theme setup and support.
     *
     * @since 1.0
     * @return void
     */
    function sophia_theme_setup()
    {
        // Make theme available for translation
        load_theme_textdomain('sophia-lite', get_template_directory() . '/languages');
        
        // Add theme support for custom logo
        add_theme_support('custom-logo');

        // Remove core block patterns
        remove_theme_support('core-block-patterns');

        // Add support for block styles
        add_theme_support('wp-block-styles');

        // Enqueue editor styles
        add_editor_style('style.css');
		
		// WooCommerce support (for status detection & compatibility)
        add_theme_support( 'woocommerce' );
    }
endif;

add_action('after_setup_theme', 'sophia_theme_setup');


