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

?>

<section class="section supply-chain-management-process <?php echo $class; ?>">
    <div class="container">
        <div class="text-cont text-center">
            <?php if(get_field('supply_chain_process_mgmt_section_title')):?>
            <h2 class="section-title"><?php echo get_field('supply_chain_process_mgmt_section_title')?></h2>
            <?php endif;?>
            <?php if(get_field('supply_chain_process_mgmt_section_text')):?>
            <p class="section-content pt-0 mt-0"><?php echo get_field('supply_chain_process_mgmt_section_text') ?></p>
            <?php endif;?>

        </div>
        <?php if( have_rows('supply_chain_process_mgmt_steps') ): ;
            $i = 1;
            
            ?>
        <ul>
        <?php while( have_rows('supply_chain_process_mgmt_steps') ): the_row();
        ?>
            <li>
                <span><?php echo $i < 10 ? '0'.$i : $i?></span>
               <p><?php echo get_sub_field('supply_chain_process_mgmt_step_heading');?></p>
            </li>
            <?php
            $i++;
         endwhile; ?>
        </ul>
        <?php endif; ?>
    </div>
</section>