<?php
    $style = isset($args['style']) ? $args['style'] : '';
?>

<section class="section <?php echo $style; ?>">
    <div class="container">
        <div class="text-cont slide-down">
            <h2 class="section-title"><?php echo get_field('master_data_management_heading'); ?></h2>
			<p class="section-content white-text mt-3 mb-0">
                <?php echo get_field('master_data_management_description'); ?>
			</p>
        </div>
        <?php $master_data_management_cards = get_field('master_data_management_cards'); ?>
        <?php if ( is_array($master_data_management_cards) && count($master_data_management_cards) ) : ?>
            <div class="row justify-content-center">
                <?php foreach ($master_data_management_cards as $card) : ?>
                    <div class="col-lg-3 col-md-6">
                        <div class="card slide-down">
                            <div class="img-content">
                                <img src="<?php echo $card['icon']; ?>" alt="<?php echo $card['heading']; ?>" class="img-fluid" loading="lazy">
                            </div>
                            <div class="text-content">
                                <h3><?php echo $card['heading']; ?></h3>
                                <p><?php echo $card['description']; ?></p>
                            </div>
                        </div>
                    </div>
                <?php endforeach; ?>
            </div>
        <?php endif; ?>
    </div>
</section>