<?php
if ( ! get_theme_mod( 'luca_portfolio_enable_custom_html_section', false ) ) {
    return;
}

$section_content = array();
$section_content['section_contact_background'] = get_theme_mod( 'luca_portfolio_content_section_background_grey', '--bg-section' );

$section_content = apply_filters( 'luca_portfolio_content_section_content', $section_content );
luca_portfolio_render_content_section( $section_content );

/**
 * Render Contact Section
 */
function luca_portfolio_render_content_section($section_content) {
    $bg = $section_content['section_contact_background'] ? '--bg-grey':'--bg-section';
?>
<section id="content" class="py-5" style="background-color: var(<?php echo esc_attr($bg) ?>)">
    <?php
    if ( is_customize_preview() ) :
        luca_portfolio_section_link( 'luca_portfolio_content_section' );
    endif;
    ?>
    <div class="container-xl">
        <div class="row">
            <div class="col-12">
                <?php the_content(); ?>
            </div>
        </div>
    </div>
</section>
<?php
}
?>
