<?php

// Exit if accessed directly.
if ( ! defined( 'ABSPATH' ) ) {
    exit;
}

$wp_customize->add_section( 'graylc_background_section', array(
        'title' => 'Background Section',
        'panel' => 'glc-panels',
) );

$wp_customize->add_setting('graylc_bg_image', array(
    'default'    => '',
    'capability' => 'edit_theme_options',
    'type'       => 'option', // or use 'theme_mod' if preferred
));

$wp_customize->add_control(new WP_Customize_Image_Control(
    $wp_customize,
    'graylc_bg_control',
    array(
        'label'    => __('Background Image', 'gray-login-customizer'),
        'section'  => 'graylc_background_section',
        'settings' => 'graylc_bg_image',
    )
));