<div style="line-height:16px; font-size:12px;">
<table cellspacing="0" cellpadding="0" border="0">
    <tr>
        <th width="65%"><?= $GLOBALS['TL_LANG']['MSC']['iso_order_description'] ?></th>
        <th width="<?= $this->total_tax_ids > 1 ? 8 : 9 ?>%" style="text-align:right"><?= $GLOBALS['TL_LANG']['MSC']['iso_order_quantity'] ?></th>
        <th width="<?= $this->total_tax_ids > 1 ? 11 : 13 ?>%" style="text-align:right"><?= $GLOBALS['TL_LANG']['MSC']['iso_order_price'] ?></th>
        <th width="<?= $this->total_tax_ids > 1 ? 11 : 13 ?>%" style="text-align:right"><?= $GLOBALS['TL_LANG']['MSC']['iso_order_total'] ?></th><?php if($this->total_tax_ids > 1): ?>
        <th width="3%">&nbsp;</th><?php endif; ?>
    </tr>
    <tr><td colspan="4" style="font-size:5px;line-height:5px; border-bottom: 2px solid #898989">&nbsp;</td></tr>
    <?php foreach($this->items as $item):; ?>
        <tr><td colspan="4" style="font-size:5px;line-height:5px<?php if($i!=0): ?>; border-top: 1px solid #c4c4c4<?php endif; ?>">&nbsp;</td></tr>
        <tr>
            <td><?= $item['name'] ?>
                <?php if(!empty($item['attributes'])): ?>
                        <?php foreach($item['attributes'] as $name => $value): ?>
                            <br><strong><?= $this->attributeLabel($name) ?>:</strong> <?= $this->attributeValue($name, $value, ['html'=>true, 'item'=>$item['item']]) ?>
                        <?php endforeach; ?>
                <?php endif; ?>
            </td>
            <td style="text-align:center"><?= $item['quantity'] ?></td>
            <td style="text-align:right"><?= $item['price'] ?></td>
            <td style="text-align:right"><?= $item['total'] ?></td><?php if($this->total_tax_ids > 1): ?>
            <td style="text-align:right"><?= $item['tax_id'] ?></td><?php endif; ?>
        </tr>
        <tr><td colspan="4" style="font-size:5px;line-height:5px">&nbsp;</td></tr>
        <?php $i++; endforeach; ?>
    <tr><td colspan="4">&nbsp;</td></tr>
    <tr><td colspan="2" style="font-size:5px"></td><td colspan="2" style="font-size:5px;line-height:5px; border-top: 2px solid #898989">&nbsp;</td></tr>
    <tr>
        <td colspan="2" style="font-weight:bold"><?= $GLOBALS['TL_LANG']['MSC']['subTotalLabel'] ?></td>
        <td colspan="2" style="text-align:right; font-weight:bold"><?= $this->subtotal ?></td><?php if($this->total_tax_ids > 1): ?>
        <td style="text-align:right">&nbsp;</td><?php endif; ?>
    </tr>
    <?php foreach ($this->surcharges as $surcharge): $i=0; ?>
        <tr><td colspan="4" style="font-size:5px;line-height:5px">&nbsp;</td></tr>
        <tr class="<?= $surcharge['rowClass'] ?>">
            <td colspan="2"><?= $surcharge['label'] ?></td>
            <td style="text-align:right"><?= $surcharge['price'] ?></td>
            <td style="text-align:right"><?= $surcharge['total_price'] ?></td><?php if($this->total_tax_ids > 1): ?>
            <td style="text-align:right"><?= $surcharge['tax_id'] ?></td><?php endif; ?>
        </tr>
    <?php endforeach; ?>
    <tr><td colspan="4" style="font-size:5px;line-height:5px">&nbsp;</td></tr>
    <tr>
        <td colspan="2" style="font-size:14px; font-weight: bold"><?= $GLOBALS['TL_LANG']['MSC']['grandTotalLabel'] ?></td>
        <td colspan="2" style="text-align:right; font-size:14px; font-weight: bold"><?= $this->total ?></td><?php if($this->total_tax_ids > 1): ?>
        <td style="text-align:right">&nbsp;</td><?php endif; ?>
    </tr>
</table>
</div>
