<div class="offcanvas offcanvas-end pb-sm-2 px-sm-2" id="deliveryOptions" tabindex="-1"
    aria-labelledby="deliveryOptionsLabel" style="width: 500px">

    <!-- Header with nav tabs -->
    <div class="offcanvas-header flex-column align-items-start py-3 pt-lg-4">
        <div class="d-flex align-items-center justify-content-between w-100 pb-xl-1 mb-4">
            <h4 class="offcanvas-title" id="deliveryOptionsLabel">{{ __('grocery.delivery_options_title') }}</h4>
            <button type="button" class="btn-close" data-bs-dismiss="offcanvas" aria-label="Close"></button>
        </div>
        <ul class="nav nav-pills nav-justified w-100" role="tablist">
            <li class="nav-item" role="presentation">
                <button type="button" class="nav-link active" id="delivery-tab" data-bs-toggle="tab"
                    data-bs-target="#delivery-tab-pane" role="tab" aria-controls="delivery-tab-pane"
                    aria-selected="true">
                    <i class="ci-shopping-bag fs-base ms-n1 me-2"></i>
                    {{ __('grocery.delivery_tab') }}
                </button>
            </li>
            <li class="nav-item" role="presentation">
                <button type="button" class="nav-link" id="pickup-tab" data-bs-toggle="tab"
                    data-bs-target="#pickup-tab-pane" role="tab" aria-controls="pickup-tab-pane"
                    aria-selected="false">
                    <i class="ci-box fs-base ms-n1 me-2"></i>
                    {{ __('grocery.pickup_tab') }}
                </button>
            </li>
        </ul>
    </div>

    <div class="offcanvas-body tab-content py-2 py-sm-3">

        <!-- Delivery tab -->
        <div class="tab-pane fade show active" id="delivery-tab-pane" role="tabpanel" aria-labelledby="delivery-tab">

            <!-- Address options collapse -->
            <div class="collapse delivery-address show" id="deliveryAddressOptions">
                <div class="mt-n3">
                    <div class="form-check border-bottom py-4 m-0">
                        <input type="radio" class="form-check-input" id="address-1" name="delivery-address" checked>
                        <label for="address-1" class="form-check-label text-dark-emphasis fw-semibold">{{ __('grocery.address_1') }}</label>
                    </div>
                    <div class="form-check border-bottom py-4 m-0">
                        <input type="radio" class="form-check-input" id="address-2" name="delivery-address">
                        <div class="d-flex w-100">
                            <label for="address-2" class="form-check-label text-dark-emphasis me-3">{{ __('grocery.address_2') }}</label>
                            <button type="button" class="btn-close fs-sm ms-auto" data-bs-toggle="tooltip"
                                data-bs-custom-class="tooltip-sm" data-bs-title="{{ __('grocery.remove') }}" aria-label="{{ __('grocery.remove') }}"></button>
                        </div>
                    </div>
                    <div class="form-check border-bottom py-4 m-0">
                        <input type="radio" class="form-check-input" id="address-3" name="delivery-address">
                        <div class="d-flex w-100">
                            <label for="address-3" class="form-check-label text-dark-emphasis me-3">{{ __('grocery.address_3') }}</label>
                            <button type="button" class="btn-close fs-sm ms-auto" data-bs-toggle="tooltip"
                                data-bs-custom-class="tooltip-sm" data-bs-title="{{ __('grocery.remove') }}" aria-label="{{ __('grocery.remove') }}"></button>
                        </div>
                    </div>
                </div>
            </div>

            <!-- Add new address collapse -->
            <div class="collapse delivery-address" id="deliveryAddressAdd">
                <div class="nav mb-4">
                    <a class="nav-link animate-underline p-0" href=".delivery-address" data-bs-toggle="collapse"
                        aria-expanded="true" aria-controls="deliveryAddressOptions deliveryAddressAdd">
                        <i class="ci-chevron-left fs-lg ms-n1 me-1"></i>
                        <span class="animate-target">{{ __('grocery.back_to_addresses') }}</span>
                    </a>
                </div>
                <div class="d-flex align-items-center justify-content-between mb-3 mb-lg-4">
                    <h5 class="h6 mb-0 me-3">{{ __('grocery.add_address_title') }}</h5>
                    <a class="btn btn-sm btn-outline-primary rounded-pill" href="#!">
                        <i class="ci-map-pin fs-base ms-n1 me-1"></i>
                        {{ __('grocery.find_on_map') }}
                    </a>
                </div>
                <div class="mb-3 mb-lg-4">
                    <label class="form-label">{{ __('grocery.state_label') }} *</label>
                    <select class="form-select form-select-lg rounded-pill"
                        data-select='{
            "classNames": {
              "containerInner": ["form-select", "form-select-lg", "rounded-pill"]
            }
          }'
                        aria-label="Large pill select">
                        <option value="">{{ __('grocery.select_state') }}</option>
                        <option value="Arizona">Arizona</option>
                        <option value="California">California</option>
                        <option value="Montana">Montana</option>
                        <option value="Nevada">Nevada</option>
                        <option value="New Mexico">New Mexico</option>
                        <option value="Texas">Texas</option>
                    </select>
                </div>
                <div class="mb-3 mb-lg-4">
                    <label for="my-postcode" class="form-label">{{ __('grocery.postcode_label') }} *</label>
                    <input type="text" class="form-control form-control-lg rounded-pill" id="my-postcode">
                </div>
                <div class="mb-3 mb-lg-4">
                    <label class="form-label">{{ __('grocery.city_label') }} *</label>
                    <select class="form-select form-select-lg rounded-pill"
                        data-select='{
            "classNames": {
              "containerInner": ["form-select", "form-select-lg", "rounded-pill"]
            }
          }'
                        aria-label="Large pill select">
                        <option value="">{{ __('grocery.select_city') }}</option>
                        <option value="Austin">Austin</option>
                        <option value="Helena">Helena</option>
                        <option value="Sacramento">Sacramento</option>
                        <option value="Santa Fe">Santa Fe</option>
                        <option value="Las Vegas">Las Vegas</option>
                        <option value="Phoenix">Phoenix</option>
                    </select>
                </div>
                <label for="my-address" class="form-label">{{ __('grocery.street_address_label') }} *</label>
                <input type="text" class="form-control form-control-lg rounded-pill" id="my-address">
            </div>

            <!-- Add address collapse toggle -->
            <div class="nav">
                <a class="nav-link hiding-collapse-toggle animate-underline collapsed px-0 mt-4"
                    href=".delivery-address" data-bs-toggle="collapse" aria-expanded="false"
                    aria-controls="deliveryAddressOptions deliveryAddressAdd">
                    <span class="animate-target">{{ __('grocery.add_delivery_address') }}</span>
                    <i class="ci-plus fs-base ms-1"></i>
                </a>
            </div>
        </div>

        <!-- Pickup tab -->
        <div class="tab-pane fade" id="pickup-tab-pane" role="tabpanel" aria-labelledby="pickup-tab">
            <div class="collapse delivery-address show" id="pickupAddressOptions">
                <div class="mt-n3">
                    <div class="form-check border-bottom py-4 m-0">
                        <input type="radio" class="form-check-input" id="pickup-1" name="pickup-address" checked>
                        <label for="pickup-1" class="form-check-label text-dark-emphasis fw-semibold">{{ __('grocery.pickup_address_1') }}</label>
                    </div>
                    <div class="form-check border-bottom py-4 m-0">
                        <input type="radio" class="form-check-input" id="pickup-2" name="pickup-address">
                        <div class="d-flex w-100">
                            <label for="pickup-2" class="form-check-label text-dark-emphasis me-3">{{ __('grocery.pickup_address_2') }}</label>
                            <button type="button" class="btn-close fs-sm ms-auto" data-bs-toggle="tooltip"
                                data-bs-custom-class="tooltip-sm" data-bs-title="{{ __('grocery.remove') }}" aria-label="{{ __('grocery.remove') }}"></button>
                        </div>
                    </div>
                </div>
            </div>

            <!-- Add new pickup address collapse -->
            <div class="collapse delivery-address" id="pickupAddressAdd">
                <div class="nav mb-4">
                    <a class="nav-link animate-underline p-0" href=".delivery-address" data-bs-toggle="collapse"
                        aria-expanded="true" aria-controls="pickupAddressOptions pickupAddressAdd">
                        <i class="ci-chevron-left fs-lg ms-n1 me-1"></i>
                        <span class="animate-target">{{ __('grocery.back_to_addresses') }}</span>
                    </a>
                </div>
                <div class="d-flex align-items-center justify-content-between mb-3 mb-lg-4">
                    <h5 class="h6 mb-0 me-3">{{ __('grocery.add_pickup_address_title') }}</h5>
                    <a class="btn btn-sm btn-outline-primary rounded-pill" href="#!">
                        <i class="ci-map-pin fs-base ms-n1 me-1"></i>
                        {{ __('grocery.find_on_map') }}
                    </a>
                </div>
                <div class="mb-3 mb-lg-4">
                    <label class="form-label">{{ __('grocery.state_label') }} *</label>
                    <select class="form-select form-select-lg rounded-pill"
                        data-select='{
            "classNames": {
              "containerInner": ["form-select", "form-select-lg", "rounded-pill"]
            }
          }'
                        aria-label="Large pill select">
                        <option value="">{{ __('grocery.select_state') }}</option>
                        <option value="Arizona">Arizona</option>
                        <option value="California">California</option>
                        <option value="Montana">Montana</option>
                        <option value="Nevada">Nevada</option>
                        <option value="New Mexico">New Mexico</option>
                        <option value="Texas">Texas</option>
                    </select>
                </div>
                <div class="mb-3 mb-lg-4">
                    <label for="pickup-postcode" class="form-label">{{ __('grocery.postcode_label') }} *</label>
                    <input type="text" class="form-control form-control-lg rounded-pill" id="pickup-postcode">
                </div>
                <div class="mb-3 mb-lg-4">
                    <label class="form-label">{{ __('grocery.city_label') }} *</label>
                    <select class="form-select form-select-lg rounded-pill"
                        data-select='{
            "classNames": {
              "containerInner": ["form-select", "form-select-lg", "rounded-pill"]
            }
          }'
                        aria-label="Large pill select">
                        <option value="">{{ __('grocery.select_city') }}</option>
                        <option value="Austin">Austin</option>
                        <option value="Helena">Helena</option>
                        <option value="Sacramento">Sacramento</option>
                        <option value="Santa Fe">Santa Fe</option>
                        <option value="Las Vegas">Las Vegas</option>
                        <option value="Phoenix">Phoenix</option>
                    </select>
                </div>
                <label for="pickup-address" class="form-label">{{ __('grocery.street_address_label') }} *</label>
                <input type="text" class="form-control form-control-lg rounded-pill" id="pickup-address">
            </div>

            <!-- Add pickup address collapse toggle -->
            <div class="nav">
                <a class="nav-link hiding-collapse-toggle animate-underline collapsed px-0 mt-4"
                    href=".delivery-address" data-bs-toggle="collapse" aria-expanded="false"
                    aria-controls="pickupAddressOptions pickupAddressAdd">
                    <span class="animate-target">{{ __('grocery.add_pickup_address') }}</span>
                    <i class="ci-plus fs-base ms-1"></i>
                </a>
            </div>
        </div>
    </div>
</div>
