<div class="row">
    <div class="col order-2 order-md-1">

        <!-- Description -->
        <div class="card mb-4">
            <div class="card-body">

                {!! Form::open(['url' => route('user_shop_store'), 'class' => 'form-horizontal', 'id'=>'']) !!}
                <div class="form-group">
                    <label class="custom-control custom-checkbox float-right">
                        {!! Form::checkbox('active', 1, $user->shop->active, ['class'=>'custom-control-input']) !!}
                        <span class="custom-control-label">{{__('aktiv')}}</span>
                    </label>
                    <label class="form-label" for="title">{{ __('shop_title') }}</label>
                    {{ Form::text('title',  $user->shop->title,  array('placeholder'=>__('shop_title'), 'class'=>'form-control', 'id'=>'title')) }}
                    <small class="form-text text-muted">{{ __('shop_title_help') }}</small>
                </div>

                <div class="form-group">
                    <label class="form-label" for="contact">{{ __('shop_contact') }}</label>
                    {{ Form::textarea('contact', $user->shop->contact ,  array('placeholder'=>__('shop_contact'), 'class'=>'form-control', 'id'=>'contact', 'rows'=>4)) }}
                    <small class="form-text text-muted">{{ __('shop_contact_help') }}</small>
                </div>

                <div class="form-group">
                    <label class="form-label" for="accessibility">{{ __('shop_accessibility') }}</label>
                    {{ Form::textarea('accessibility', $user->shop->accessibility ,  array('placeholder'=>__('shop_accessibility'), 'class'=>'form-control', 'id'=>'accessibility', 'rows'=>2)) }}
                    <small class="form-text text-muted">{{ __('shop_accessibility_help') }}</small>
                </div>

                <div class="form-group">
                    <label class="form-label" for="about">{{ __('shop_about') }}</label>
                    {{ Form::textarea('about', $user->shop->about ,  array('placeholder'=>'', 'class'=>'form-control', 'id'=>'about', 'rows'=>2)) }}
                    <small class="form-text text-muted">{{ __('shop_about_help') }}</small>
                </div>

                <div class="text-left mt-0 mb-2">
                    <button type="submit" class="btn btn-secondary">{{ __('save') }}</button>&nbsp;
                </div>
                {!! Form::close() !!}

            </div>
        </div>
        <!-- / Description -->
    </div>
    <div class="col-md-5 col-xl-4 order-1 order-md-2">

        <!-- Project details -->
        <div class="card mb-4">
            <h6 class="card-header">{{ __('Shop details') }}</h6>
            <ul class="list-group list-group-flush">
                <li class="list-group-item d-flex justify-content-between align-items-center">
                    <div class="text-muted">{{ __('name') }}</div>
                    <div>
                        {{ $user->shop->name }}
                    </div>
                </li>
                <li class="list-group-item d-flex justify-content-between align-items-center">
                    <div class="text-muted">{{ __('Domain') }}</div>
                    <div>
                        <a href="{{ $user->shop->getSubdomain(false) }}" target="_blank">{{ $user->shop->getSubdomain(false) }}
                        </a>
                    </div>
                </li>
                <li class="list-group-item d-flex justify-content-between align-items-center">
                    <div class="text-muted">{{ __('Status') }}</div>
                    <div class="text-right">
                        @if($user->shop->getSubdomainStatus())
                            <span class="badge badge-pill badge-success"><i class="fa fa-check"> {{ __('available') }} </i> DNS</span><br>
                        @else
                            <span class="badge badge-pill badge-danger"><i class="fa fa-times"> {{ __('not available') }} </i> DNS</span>
                        @endif

                        @if($user->shop->getSubdomainAvailable())
                            <span class="badge badge-pill badge-success"><i class="fa fa-check"> {{ __('available') }} </i>
                            @if($user->shop->getSubdomainSslSin()) HTTPS @else HTTP @endif
                            </span>
                        @else
                            <span class="badge badge-pill badge-danger"><i class="fa fa-times"> {{ __('not available') }} </i> HTTP </span>
                        @endif

                            @if($user->shop->getSubdomainSslSinActive())
                                <span class="badge badge-pill badge-success"><i class="fa fa-check"> {{ __('available') }} </i> SSL
                            </span>
                            @else
                                <span class="badge badge-pill badge-danger"><i class="fa fa-times"> {{ __('not available') }} </i> SSL </span>
                            @endif

                    </div>
                </li>
                @if(!$user->shop->getSubdomainStatus() || !$user->shop->getSubdomainAvailable() || !$user->shop->getSubdomainSslSinActive())
                    <li class="list-group-item d-flex justify-content-between align-items-center">
                        <p class="text-danger">{{ __('not available copy') }}
                            <a href="" class="btn icon-btn btn-xs btn-outline-primary">
                                <span class="lnr lnr-redo"></span>
                            </a>
                        </p>

                    </li>
                @endif
                <li class="list-group-item d-flex justify-content-between align-items-center">
                    <div class="text-muted">{{ __('active since') }}</div>
                    <div>
                        <strong>{{ $user->shop->getActiveDateFormat() }}</strong>
                    </div>
                </li>

            </ul>
        </div>
        <!-- / Project details -->
    </div>
</div>

<div class="row">
    <div class="col-md-4">
        <div class="card mb-4">
            @include('user.components.user_shop_image')
        </div>
    </div>
    <div class="col-md-8">
        <div class="card mb-4">
            @include('user.components.user_shop_on_site')
        </div>
    </div>
</div>

<!-- / image files -->



