{if isset($RSThemes['pages'][$templatefile]) && file_exists($RSThemes['pages'][$templatefile]['fullPath'])}
    {include file=$RSThemes['pages'][$templatefile]['fullPath']}
{else}
    {include file="orderforms/$carttpl/common.tpl"}
    <div class="main-grid{if $mainGrid} {$mainGrid}{/if}">
        {if $RSThemes['pages'][$templatefile]['config']['hideSidebar'] != '1'}
        <div class="main-sidebar hidden-sm hidden-md{if $sidebarOnRight || $RSThemes['layouts']['name'] == 'left-nav-wide'} main-sidebar-right {/if}">
            {if $RSThemes['addonSettings']['sticky_sidebars'] == "true"}<div class="sidebar-sticky" {if $RSThemes.addonSettings.show_affixed_navigation == 'enabled'}data-sidebar-sticky{/if}>{/if}
                {include file="orderforms/$carttpl/sidebar-categories.tpl"}
            {if $RSThemes['addonSettings']['sticky_sidebars'] == "true"}</div>{/if}
        </div>
        {/if}
        <div class="main-content {if $mainContentClasses}{$mainContentClasses}{/if}">
            {include file="orderforms/$carttpl/sidebar-categories-collapsed.tpl"}
            <div class="search-box search-box-{$searchBoxStyle}">
                <form method="post" action="{$WEB_ROOT}/cart.php" id="frmDomainChecker" {if isset($RSThemes['addonSettings']['tld_cycle_switcher']) && $RSThemes['addonSettings']['tld_cycle_switcher'] == 'true'}data-show-tld-cycle-switcher {if isset($smarty.get.period)}data-period="{$smarty.get.period|escape}"{/if}{/if} {if $showAdvancedSearchOptions} data-ai-search-enabled{/if}>
                    <input type="hidden" name="a" value="checkDomain">
                    {if $showAdvancedSearchOptions}
                        {include file="orderforms/$carttpl/includes/domain/ai-domain-tab.tpl"}
                        {include file="orderforms/$carttpl/includes/domain/ai-domain-search.tpl"}
                    {/if}
                    <div class="domain-search-input search-group search-group-lg {if ($showAdvancedSearchOptions && $RSThemes.addonSettings.domain_search_default_classic  != 'enabled' && !$smarty.get.query) || isset($smarty.get.message)}hidden{/if}" domain-search-standard>
                        <div class="search-field d-flex flex-nowrap">
                            {if ($RSThemes['pages'][$templatefile]['config']['SearchPrefix'] || $RSThemes['pages'][$templatefile]['config']['SearchPrefix'] == "1")}
                                <div class="inline-form-prefix">
                                    <span>{$LANG.orderForm.www}</span>
                                </div>
                            {/if}
                            <input class="form-control"  type="text" name="domain" placeholder="{$LANG.findyourdomain}" value="{$lookupTerm}" id="inputDomain" data-domain-search-input data-toggle="tooltip" data-delay="100" data-placement="top" data-trigger="manual" title="{lang key='orderForm.domainOrKeyword'}" />
                            <div class="search-field-icon"><i class="lm lm-search" aria-hidden="true"></i></div>
                        </div>
                        <div class="search-group-btn">
                            <button tabindex="0" class="btn btn-primary{if $searchBoxStyle == 'primary'}-faded{/if} domain-check-availability {if $captcha}{$captcha->getButtonClass($captchaForm)}{/if}" type="submit" id="btnCheckAvailability">
                                <span>{$LANG.search}</span>
                                <div class="loader loader-button">
                                    {include file="$template/includes/common/loader.tpl" classes="spinner-sm spinner-light"}  
                                </div>
                            </button>
                        </div>
                    </div>
                    {include file="orderforms/$carttpl/includes/domain/captcha.tpl"}
                </form>
            </div>
            <div id="DomainSearchResults" class="hidden" data-scroll-to-results="true">
                {* <div id="primaryLookupSearching" class="domain-lookup-loader message message-lg message-no-data {if (!$lookupTerm || $captchaError || $invalid)}hidden{/if}">
                    <div class="loader">
                        {include file="$template/includes/common/loader.tpl"}  
                    </div>
                </div> *}
                <div id="primarySuggestionHeading" class="primary-domain-header"><i class="fa-regular fa-sparkles"></i> {$LANG.domainSearch.topSuggestion}</div>
                <div class="domain-checker-result-headline" id="searchDomainInfo">
                    <div id="primaryLookupResult" class="hidden">
                        {include file="orderforms/$carttpl/includes/domain/search-result.tpl"} 
                    </div>
                </div>
                <div class="section domain-lookup-message domain-lookup-suggestions-message">
                    <div class="section-header">
                        <h2 class="section-title">{lang key='orderForm.suggestedDomains'}</h2>        
                        <p class="section-desc">{lang key='domainssuggestionswarnings'}</p>
                    </div>
                    <div class="section-body">
                        <div class="panel panel-default">
                            <div class="panel-body">
                                {include file="$template/assets/img/aisearch-icon.svg"}
                                <div class="d-flex flex-column">
                                    <h6 class="mb-2 text-center">{$rslang->trans('domains.ai_search.no_data_title')}</h6>
                                    <p class="mb-0 text-center">{$rslang->trans('domains.ai_search.no_data_description')}</p>
                                </div>
                                <button class="btn btn-sm btn-default" type="button" data-reset-domain-search-button>{$rslang->trans('domains.ai_search.reset_search')}</button>
                            </div>
                        </div>
                    </div>
                </div>
                {if $spotlightTlds}
                    {include file="orderforms/$carttpl/includes/domain/spotlight.tpl"}
                {/if}
                {include file="orderforms/$carttpl/includes/domain/suggested.tpl"}
            </div>
            {if $RSThemes['pages'][$templatefile]['config']['showFeaturedTLD'] == '1'}
                {include file="orderforms/$carttpl/includes/domain/featured-tlds.tpl"}
            {/if}
            {include file="orderforms/$carttpl/includes/domain/tld-pricing.tpl"}
            <div class="section">
                <div class="section-body">
                    <div class="row row-eq-height row-eq-height-sm">
                        {if $RSThemes['pages'][$templatefile]['config']['disableHostingReminder'] != '1'}
                            <div class="col-md-{if $domainTransferEnabled}6{else}12{/if}">
                                <div class="domain-promo-box">
                                    <div class="promo-box-body">
                                        <div class="promo-box-content">
                                            <div class="promo-box-icon">
                                                {include file="$template/includes/common/svg-icon.tpl" icon="web-hosting"}
                                            </div>
                                            <div class="promo-box-header">
                                                <h3 class="h5">{lang key='orderForm.addHosting'}</h3>
                                                <p class="description">{lang key='orderForm.chooseFromRange'}</p>
                                            </div>
                                        </div>
                                        <div class="promo-box-content promo-box-content-between">
                                            <p class="promo-description">{lang key='orderForm.packagesForBudget'}</p>
                                            <a tabindex="0" href="{$WEB_ROOT}/cart.php" class="btn btn-primary">
                                                {lang key='orderForm.exploreNow'}
                                            </a>
                                        </div>
                                    </div>
                                </div>
                            </div>
                        {/if}
                        {if $domainTransferEnabled}
                            <div class="col-md-6">
                                <div class="domain-promo-box">
                                    <div class="promo-box-body">
                                        <div class="promo-box-content">
                                            <div class="promo-box-icon">
                                                {include file="$template/includes/common/svg-icon.tpl" icon="transfer-domain"}
                                            </div>
                                            <div class="promo-box-header">
                                                <h3 class="h5">{lang key='orderForm.transferToUs'}</h3>
                                                <p class="description text-primary">{lang key='orderForm.transferExtend'}*</p>
                                            </div>
                                        </div>
                                        <div class="promo-box-content promo-box-content-between">
                                            <p class="promo-description">* {lang key='orderForm.extendExclusions'}</p>
                                            <a tabindex="0" href="{$WEB_ROOT}/cart.php?a=add&domain=transfer" class="btn btn-primary">{lang key='orderForm.transferDomain'}</a>
                                        </div>
                                    </div>
                                </div>
                            </div>
                        {/if}
                    </div>
                </div>
            </div>
            <div id="bottom-action-anchor" class="bottom-action-anchor"></div>
            <div class="bottom-action-sticky hidden" data-fixed-actions href="#bottom-action-anchor">
                <div class="container">
                    <div class="sticky-content">
                        <div class="badge badge-circle-lg" id="cartItemCount">0</div>
                        <span class="m-l-1x">{$rslang->trans('domains.domains_selected')}</span>
                    </div>
                    <div class="sticky-actions">
                        <a tabindex="0" class="btn btn-lg btn-primary" href="cart.php?a=confdomains" id="btnDomainContinue"  data-btn-loader>
                            <span>
                                <i class="ls ls-share"></i>
                                <span class="btn-text">{$LANG.continue}</span>
                            </span>
                            <div class="loader loader-button hidden" >
                                {include file="$template/includes/common/loader.tpl" classes="spinner-sm spinner-light"}  
                            </div>
                        </a>
                    </div>
                </div>
            </div>
        </div>
        <script>
            jQuery(document).ready(function() {
                {if (($lookupTerm || $message) && !$captchaError && !$invalid) || (!$captcha->isEnabled() && ($lookupTerm || $message) && !$invalid)}
                    {literal}
                        setTimeout(function(){
                            jQuery('#btnCheckAvailability').trigger('click');
                        }, 500);
                    {/literal}  
                {/if}
                {if $invalid}
                    jQuery('#primaryLookupSearching').toggle();
                    jQuery('#primaryLookupResult').children().toggle();
                    jQuery('#primaryLookupResult').toggle();
                    jQuery('#DomainSearchResults').toggle();
                    jQuery('.domain-invalid').toggle();
                {/if}
            });
        </script>
    </div>
{/if} 