{if file_exists("templates/orderforms/$carttpl/overwrites/ordersummary-checkout.tpl")}
    {include file="templates/orderforms/$carttpl/overwrites/ordersummary-checkout.tpl"}
{else}
    <div class="panel-body">
        <div class="summary-content content">
            <ul class="summary-list summary-list-subtotal">
                <li class="list-item faded" data-subtotal>
                    <span class="item-name">{$LANG.ordersubtotal}</span>
                    <span class="item-value">{$subtotal}</span>
                </li>
                <li class="list-item list-item-promo" {if !$promotioncode}style="display:none"{/if} data-summary-promocode>
                    <span class="item-name">{include file="$template/assets/img/promocode-label-icon.svg"} <div data-summary-promocode-description>{$promotiondescription}</div></span>
                    <span class="item-value" id="discount" data-summary-promocode-discount>&ndash; {$discount}</span>
                </li>
            </ul>
            <ul class="summary-list" id="recurring">
                <li class="list-item faded">{$LANG.orderForm.totals}</li>
                <li class="list-item" id="recurringMonthly" {if !$totalrecurringmonthly}style="display:none;"{/if}>
                    <span class="item-name">{$LANG.orderpaymenttermmonthly}</span>
                    <span class="item-value">{$totalrecurringmonthly}</span>
                </li>                
                <li class="list-item" id="recurringQuarterly" {if !$totalrecurringquarterly}style="display:none;"{/if}>
                    <span class="item-name">{$LANG.orderpaymenttermquarterly}</span>
                    <span class="item-value">{$totalrecurringquarterly}</span>
                </li>
                <li class="list-item" id="recurringSemiAnnually" {if !$totalrecurringsemiannually}style="display:none;"{/if}>
                    <span class="item-name">{$LANG.orderpaymenttermsemiannually}</span>
                    <span class="item-value">{$totalrecurringsemiannually}</span>
                </li>
                <li class="list-item" id="recurringAnnually" {if !$totalrecurringannually}style="display:none;"{/if}>
                    <span class="item-name">{$LANG.orderpaymenttermannually}</span>
                    <span class="item-value">{$totalrecurringannually}</span>
                </li>
                <li class="list-item" id="recurringBiennially" {if !$totalrecurringbiennially}style="display:none;"{/if}>
                    <span class="item-name">{$LANG.orderpaymenttermbiennially}</span>
                    <span class="item-value">{$totalrecurringbiennially}</span>
                </li>
                <li class="list-item" id="recurringTriennially" {if !$totalrecurringtriennially}style="display:none;"{/if}>
                    <span class="item-name">{$LANG.orderpaymenttermtriennially}</span>
                    <span class="item-value">{$totalrecurringtriennially}</span>
                </li>
            </ul>
            {if $RSThemes['pages'][$templatefile]['config']['displayVatBasedOnSelectedCountry'] != "0"}
                <ul class="summary-list faded {if ((!$taxrate && !$taxrate2) || ($taxtotal|strstr:"0.00" || $taxtotal|strstr:"0,00") && ($taxtotal2|strstr:"0.00" || $taxtotal2|strstr:"0,00"))}hidden{/if}" data-summary-tax-container data-ajax-url="{$WEB_ROOT}/templates/{$template}/core/api/getTaxRate.php">
                    <li class="list-item {if !$taxrate}hidden{/if}" data-summary-tax>
                        <span class="item-name">{$taxname} @ {$taxrate}%</span>
                        <span class="item-value" id="taxTotal1">{$taxtotal}</span>
                    </li>
                    <li class="list-item {if !$taxrate2}hidden{/if}" data-summary-tax2>
                        <span class="item-name">{$taxname2} @ {$taxrate2}%</span>
                        <span class="item-value" id="taxTotal2">{$taxtotal2}</span>
                    </li>
                </ul>
            {else}        
                {if $taxrate || $taxrate2}
                    <ul class="summary-list faded">
                        {if $taxrate}
                            <li class="list-item">
                                <span class="item-name">{$taxname} @ {$taxrate}%</span>
                                <span class="item-value" id="taxTotal1">{$taxtotal}</span>
                            </li>
                        {/if}
                        {if $taxrate2}
                            <li class="list-item">
                                <span class="item-name">{$taxname2} @ {$taxrate2}%</span>
                                <span class="item-value" id="taxTotal2">{$taxtotal2}</span>
                            </li>
                        {/if}
                    </ul>
                {/if}
            {/if}    
        </div>
    </div>
    <div class="panel-footer">                        
        <div class="price price-left-h " data-total>
        <span class="price-total">{$LANG.ordertotalduetoday} {if ($taxrate && !($taxtotal|strstr:"0.00" || $taxtotal|strstr:"0,00")) || ($taxrate2 && !($taxtotal2|strstr:"0.00" || $taxtotal2|strstr:"0,00"))}{$rslang->trans('order.include_vat')}{/if}</span> 
            <div class="price-amount price-amount-promo" {if !$promotioncode}style="display: none;"{/if} data-promo-subtotal="{formatCurrency(0)}">{formatCurrency($total->toNumeric() + $discount->toNumeric())}</div>
            <div class="price-amount price-amount-total amt" id="totalDueToday">{$total}</div>
        </div>    
        <div class="summary-actions">
        {if $RSThemes['pages'][$templatefile] && $RSThemes['pages'][$templatefile]['config']['tosLocation'] === "Above CTA button" }
            {if $accepttos}
                <div class="order-checkbox" data-form-input="#accepttos">
                    <div class="checkbox m-t-0 m-b-1x" id="tos-checkbox">
                        <label>
                            <input class="icheck-control" type="checkbox" data-tos-checkbox />
                            <span>{$LANG.ordertosagreement} <a tabindex="0" href="{$tosurl}" target="_blank">{$LANG.ordertos}</a></span>
                        </label>
                    </div>
                    <div class="alert alert-lagom alert-xs alert-danger m-b-2x hidden">
                        <div class="alert-body">
                            {$LANG.ordererroraccepttos}
                        </div>
                    </div> 
                </div>
                {if file_exists("templates/orderforms/$carttpl/includes/viewcart/custom-tos.tpl")}
                    {include file="templates/orderforms/$carttpl/includes/viewcart/custom-tos.tpl"}
                {/if}
            {/if}
        {/if}
            <button tabindex="0" type="button" class="btn btn-lg btn-primary{if $summaryStyle == "primary"}-faded{/if} btn-checkout{if $cartitems == 0} disabled{/if}" {if $cartitems == 0} disabled{/if} data-btn-loader id="checkout">
                <span>{$rslang->trans('order.place_order')}<i class="ls ls-share m-r-0" aria-hidden="true"></i></span>
                <div class="loader loader-button hidden">
                    {include file="$template/includes/common/loader.tpl" classes="spinner-sm"}  
                </div>
            </button>
        </div>
    </div>
{/if}    