    <div class="modal fade" id="bvInfoModal" role="dialog" aria-hidden="true" tabindex="-1">
        <div class="modal-dialog" role="document">
            <div class="modal-content">
                <div class="modal-header">
                    <h5 class="modal-title m-0"><?php echo app('translator')->get('Business Volume (BV) info'); ?></h5>
                    <button class="close" data-bs-dismiss="modal" type="button" aria-label="Close">
                        <i class="las la-times"></i>
                    </button>
                </div>
                <div class="modal-body">
                    <span class="text--danger"><?php echo app('translator')->get('When someone from your below tree subscribe this plan, You will get this Business Volume  which will be used for matching bonus'); ?>.</span>
                </div>
                <div class="modal-footer">
                    <button class="btn btn-dark w-100" data-bs-dismiss="modal" type="button"><?php echo app('translator')->get('Close'); ?></button>
                </div>
            </div>
        </div>
    </div>

    <div class="modal fade" id="refComInfoModal" role="dialog" aria-hidden="true" tabindex="-1">
        <div class="modal-dialog" role="document">
            <div class="modal-content">
                <div class="modal-header">
                    <h5 class="modal-title m-0"><?php echo app('translator')->get('Referral Commission info'); ?></h5>
                    <button class="close" data-bs-dismiss="modal" type="button" aria-label="Close">
                        <i class="las la-times"></i>
                    </button>
                </div>
                <div class="modal-body">
                    <span class="text--danger"><?php echo app('translator')->get('When Your Direct-Referred/Sponsored  User Subscribe in'); ?> <b> <?php echo app('translator')->get('ANY PLAN'); ?> </b>,
                        <?php echo app('translator')->get('You will get this amount'); ?>.</span>
                    <br>
                    <br>
                    <span class="text--success"> <?php echo app('translator')->get('This is the reason You should Choose a Plan With Bigger Referral Commission'); ?>.</span>

                </div>
                <div class="modal-footer">
                    <button class="btn btn-dark w-100" data-bs-dismiss="modal" type="button"><?php echo app('translator')->get('Close'); ?></button>
                </div>
            </div>
        </div>
    </div>

    <div class="modal fade" id="treeComInfoModal" role="dialog" aria-hidden="true" tabindex="-1">
        <div class="modal-dialog" role="document">
            <div class="modal-content">
                <div class="modal-header">
                    <h5 class="modal-title m-0"><?php echo app('translator')->get('Commission to tree info'); ?></h5>
                    <button class="close" data-bs-dismiss="modal" type="button" aria-label="Close">
                        <i class="las la-times"></i>
                    </button>
                </div>
                <div class="modal-body">
                    <span class="text--danger"><?php echo app('translator')->get('When someone from your below tree subscribe this plan, You will get this amount as Tree Commission'); ?>. </span>

                </div>
                <div class="modal-footer">
                    <button class="btn btn-dark w-100" data-bs-dismiss="modal" type="button"><?php echo app('translator')->get('Close'); ?></button>
                </div>
            </div>
        </div>
    </div>
    <?php if(auth()->guard()->check()): ?>
        <div class="modal fade" id="purchaseModal">
            <div class="modal-dialog" role="dialog">
                <div class="modal-content">
                    <div class="modal-header">
                        <h5 class="modal-title m-0"><?php echo app('translator')->get('Subscribe to the plan'); ?></h5>
                        <button class="close" data-bs-dismiss="modal" type="button" aria-label="Close">
                            <i class="las la-times"></i>
                        </button>
                    </div>
                    <form action="<?php echo e(route('user.plan.purchase')); ?>" method="post">
                        <?php echo csrf_field(); ?>
                      <!--  <input name="amount" type="hidden" value="0"> -->
                        <input name="id" type="hidden">
                        <div class="modal-body">
                            <div class="form-group">
                                <label><?php echo app('translator')->get('Select Method'); ?></label>
                                <select class="form-control form--control form-select" name="payment_method" required>
                                    <option value=""><?php echo app('translator')->get('Select One'); ?></option>
                                    <?php if(auth()->user()->balance > 0): ?>
                                        <option value="balance"><?php echo app('translator')->get('Balance - ' . $general->cur_sym . showAmount(auth()->user()->balance)); ?></option>
                                    <?php endif; ?>
                                  <!--  <?php $__currentLoopData = $gatewayCurrency; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $data): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                        <option data-gateway="<?php echo e($data); ?>" value="<?php echo e($data->id); ?>" <?php if(old('payment_method') == $data->method_code): echo 'selected'; endif; ?>><?php echo e($data->name); ?></option>
                                    <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?> -->
                                </select>
                                 <label class="form-label"><?php echo app('translator')->get('Amount'); ?></label>
                                <div class="input-group">
                                    <input class="form-control form--control" name="amount" type="number" value="<?php echo e(old('amount')); ?>" step="any" autocomplete="off" required>
                                    <span class="input-group-text"><?php echo e($general->cur_text); ?></span>
                                </div>
                                <code class="gateway-info d-none"><span class="rate-info"><?php echo app('translator')->get('Rate'); ?>: 1
                                        <?php echo e(__($general->cur_text)); ?> = <span class="gateway-rate"></span> <span
                                            class="method_currency"></span>.</span> <?php echo app('translator')->get('Charge'); ?>: <span
                                        class="charge"></span> <?php echo e(__($general->cur_text)); ?>. <?php echo app('translator')->get('Total amount'); ?>: <span
                                        class="total"></span> <?php echo e(__($general->cur_text)); ?>. </code>
                                <code class="gateway-limit"></code>
                            </div>
                        </div>
                        <div class="modal-footer">
                            <button class="btn btn--base w-100" type="submit"><?php echo app('translator')->get('Submit'); ?></button>
                        </div>
                    </form>
                </div>
            </div>
        </div>
    <?php else: ?>
        <div class="modal fade" id="loginModal" role="dialog" aria-hidden="true" tabindex="-1">
            <div class="modal-dialog" role="document">
                <div class="modal-content">
                    <div class="modal-header">
                        <h5 class="modal-title m-0"><?php echo app('translator')->get('Confirmation Alert!'); ?></h5>
                        <button class="close" data-bs-dismiss="modal" type="button" aria-label="Close">
                            <i class="las la-times"></i>
                        </button>
                    </div>
                    <div class="modal-body">
                        <span class="text-center"><?php echo app('translator')->get('Please login to subscribe plans.'); ?></span>
                    </div>
                    <div class="modal-footer">
                        <button class="btn btn-dark h-auto w-auto" data-bs-dismiss="modal" type="button"><?php echo app('translator')->get('Close'); ?></button>
                        <a class="btn btn--base w-auto" href="<?php echo e(route('user.login')); ?>"><?php echo app('translator')->get('Login'); ?></a>
                    </div>
                </div>
            </div>
        </div>

    <?php endif; ?>
    <?php $__env->startPush('script'); ?>
        <script>
            (function($) {
                "use strict";
                $('.subscribeBtn').click(function() {
                    var modal = $('#purchaseModal');
                    var price = $(this).data('amount');
                    var id = $(this).data('id');
                    modal.find('[name=amount]').val(price);
                    modal.find('[name=id]').val(id);
                    modal.modal('show');
                    $('[name=payment_method]').trigger('change');
                });

                $(document).on('change', '[name=payment_method]', function() {
                    var amount = $('[name=amount]').val();
                    if ($(this).val() != 'balance' && amount) {
                        var resource = $('select[name=payment_method] option:selected').data('gateway');
                        var max_amount = parseFloat(resource.max_amount);
                        var min_amount = parseFloat(resource.min_amount);
                        var fixed_charge = parseFloat(resource.fixed_charge);
                        var percent_charge = parseFloat(resource.percent_charge);
                        var charge = parseFloat(fixed_charge + (amount * percent_charge / 100)).toFixed(2);
                        $('.charge').text(charge);
                        $('.gateway-rate').text(parseFloat(resource.rate));
                        $('.gateway-info').removeClass('d-none');
                        $('.gateway-limit').addClass('d-none');
                        $('.rate-info').removeClass('d-none');
                        if (resource.currency == '<?php echo e(__($general->cur_text)); ?>') {
                            $('.rate-info').addClass('d-none');
                        }
                        if (amount < min_amount || amount > max_amount) {
                            $('.gateway-limit').text(`${resource.name} cannot process ${amount} <?php echo e($general->cur_text); ?> due to transaction limit. Gateway limit: ${min_amount} <?php echo e($general->cur_text); ?> - ${max_amount} <?php echo e($general->cur_text); ?>`);
                            $('.gateway-info').addClass('d-none');
                            $('.gateway-limit').removeClass('d-none');
                        }
                        $('.method_currency').text(resource.currency);
                        $('.total').text(parseFloat(charge) + parseFloat(amount));
                    } else {
                        $('.gateway-info').addClass('d-none');
                        $('.gateway-limit').addClass('d-none');
                    }
                });
            })(jQuery)
        </script>
    <?php $__env->stopPush(); ?>
<?php /**PATH /home/mez5ba60cfao/public_html/Files/core/resources/views/templates/basic/partials/plan_modals.blade.php ENDPATH**/ ?>