<div class="item">
 <div class="name">
 <?php echo \htmlentities($title??'', ENT_QUOTES, 'UTF-8', false); ?>

 </div>

 <?php $__currentLoopData = $values; $this->addLoop($__currentLoopData);$this->getFirstLoop();
 foreach($__currentLoopData as $itemKey => $item): $loop = $this->incrementLoopIndices();  ?>
 <?php if(isset($item['parentKey'])): ?>
 <?php ($additional[] = $item); ?>
 <?php else: ?>
 <?php ($main[] = $item); ?>
 <?php endif; ?>
 <?php endforeach; $this->popLoop(); $loop = $this->getFirstLoop(); ?>

 <div class="content">
 <?php if(isset($main)): ?>
 <div class="subtitle">
 <?php echo \htmlentities(__('site.main_colors')??'', ENT_QUOTES, 'UTF-8', false); ?>

 </div>

 <div class="inner colors">
 <?php $__currentLoopData = $main; $this->addLoop($__currentLoopData);$this->getFirstLoop();
 foreach($__currentLoopData as $item): $loop = $this->incrementLoopIndices();  ?>
 <?php echo $this->runChild('filters.colorItem', ['key' => $key, 'item' => $item]); ?>    
 <?php endforeach; $this->popLoop(); $loop = $this->getFirstLoop(); ?>
 </div>    
 <?php endif; ?>
 
 <?php if(isset($additional)): ?>
 <div class="subtitle">
 <?php echo \htmlentities(__('site.additional_colors')??'', ENT_QUOTES, 'UTF-8', false); ?>

 </div>

 <div class="inner colors">
 <?php $__currentLoopData = $additional; $this->addLoop($__currentLoopData);$this->getFirstLoop();
 foreach($__currentLoopData as $item): $loop = $this->incrementLoopIndices();  ?>
 <?php echo $this->runChild('filters.colorItem', ['key' => $key, 'item' => $item]); ?>
 <?php endforeach; $this->popLoop(); $loop = $this->getFirstLoop(); ?>
 </div>
 <?php endif; ?>
 </div>
</div>
