@php($settings = $settings ?? [])
<div class="modal fade" id="integration-modal-pushover" tabindex="-1" aria-hidden="true"
     data-integration-modal data-integration-id="pushover">
    <div class="modal-dialog modal-dialog-centered">
        <div class="modal-content">
            <div class="modal-header">
                <h5 class="modal-title"><i class="fas fa-bell me-2"></i>Pushover</h5>
                <button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
            </div>
            <div class="modal-body">
                <p class="text-muted small">
                    Register a Pushover app at <a href="https://pushover.net/apps/build" target="_blank" rel="noopener">pushover.net/apps/build</a>
                    for an App Token. Each admin supplies their own User Key.
                </p>
                <div class="row g-3">
                    <div class="col-md-6">
                        <label class="form-label">{{ __('admin/settings.integrations_pushover_app_token') }}</label>
                        <input type="password" class="form-control" name="pushover_app_token" form="settingsForm"
                               value="{{ $settings['pushover_app_token'] ?? '' }}" placeholder="azGDORePK8gMaC0QOYAMyEEuzJnyUi">
                    </div>
                    <div class="col-md-6">
                        <label class="form-label">{{ __('admin/settings.integrations_pushover_admin_user_key') }}</label>
                        <input type="text" class="form-control" name="pushover_admin_user_key" form="settingsForm"
                               value="{{ $settings['pushover_admin_user_key'] ?? '' }}" placeholder="uQiRzpo4DXghDmr9QzzfQu27cmVRsG">
                    </div>
                </div>
            </div>
            <div class="modal-footer">
                <div class="border-top pt-3 mt-1 w-100">
                    <div class="d-flex justify-content-between align-items-start gap-3">
                        <div class="flex-shrink-0">
                            <button type="button" class="btn btn-sm btn-outline-primary" data-integration-test="pushover">
                                <i class="fas fa-plug me-1"></i> {{ __('admin/settings.test_connection') }}
                            </button>
                        </div>
                        <div class="integration-test-result small text-end"></div>
                    </div>
                </div>
                <button type="button" class="btn btn-secondary" data-bs-dismiss="modal">
                    {{ __('admin/settings.integrations_modal_close') }}
                </button>
            </div>
        </div>
    </div>
</div>
