<div class="mx-auto max-w-5xl px-4 pb-12 pt-6 sm:px-6 sm:pb-16 sm:pt-8" wire:poll.45s>
    <div class="flex flex-col gap-4 border-b border-border/50 pb-8 sm:flex-row sm:items-end sm:justify-between">
        <div>
            <p class="text-xs font-semibold uppercase tracking-wide text-muted-foreground">{{ __('Partnerships') }}</p>
            <h1 class="mt-1 text-2xl font-bold tracking-tight text-foreground sm:text-3xl">{{ __('Board') }}</h1>
            <p class="mt-1.5 text-sm text-muted-foreground">{{ __(':count active partnerships', ['count' => $activePartnershipCount]) }}</p>
        </div>
        <div class="flex flex-col gap-2 sm:flex-row sm:items-center">
            @if($canManage)
                <button
                    type="button"
                    wire:click="openCreate"
                    class="inline-flex min-h-11 items-center justify-center gap-2 rounded-xl bg-foreground px-5 py-2.5 text-sm font-semibold text-primary-foreground shadow-sm transition-opacity hover:opacity-90 w-full sm:w-auto"
                >
                    <svg class="h-4 w-4 shrink-0" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M5 12h14"/><path d="M12 5v14"/></svg>
                    {{ __('Add collab') }}
                </button>
            @endif
            <a
                href="{{ route('collabs.settings') }}"
                wire:navigate
                class="inline-flex min-h-11 items-center justify-center gap-2 rounded-xl border border-border/80 bg-card px-4 py-2.5 text-sm font-medium text-foreground shadow-sm transition-colors hover:bg-secondary/60 w-full sm:w-auto"
            >
                <svg class="h-4 w-4 shrink-0 text-muted-foreground" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M12.22 2h-.44a2 2 0 0 0-2 2v.18a2 2 0 0 1-1 1.73l-.43.25a2 2 0 0 1-2 0l-.15-.08a2 2 0 0 0-2.73.73l-.22.38a2 2 0 0 0 .73 2.73l.15.1a2 2 0 0 1 1 1.72v.51a2 2 0 0 1-1 1.74l-.15.09a2 2 0 0 0-.73 2.73l.22.38a2 2 0 0 0 2.73.73l.15-.08a2 2 0 0 1 2 0l.43.25a2 2 0 0 1 1 1.73V20a2 2 0 0 0 2 2h.44a2 2 0 0 0 2-2v-.18a2 2 0 0 1 1-1.73l.43-.25a2 2 0 0 1 2 0l.15.08a2 2 0 0 0 2.73-.73l.22-.39a2 2 0 0 0-.73-2.73l-.15-.08a2 2 0 0 1-1-1.74v-.5a2 2 0 0 1 1-1.74l.15-.09a2 2 0 0 0 .73-2.73l-.22-.38a2 2 0 0 0-2.73-.73l-.15.08a2 2 0 0 1-2 0l-.43-.25a2 2 0 0 1-1-1.73V4a2 2 0 0 0-2-2z"/><circle cx="12" cy="12" r="3"/></svg>
                {{ __('Workspace settings') }}
            </a>
        </div>
    </div>

    <div class="mb-8 mt-2 rounded-2xl border border-border/60 bg-card/80 p-4 shadow-sm ring-1 ring-black/[0.04] backdrop-blur-sm dark:bg-card/90 dark:ring-white/[0.06] sm:p-5">
        <div class="flex flex-col gap-3 sm:flex-row sm:items-center">
            <div class="relative min-w-0 flex-1">
                <svg class="pointer-events-none absolute left-3 top-1/2 h-4 w-4 -translate-y-1/2 text-muted-foreground" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><circle cx="11" cy="11" r="8"/><path d="m21 21-4.3-4.3"/></svg>
                <input
                    type="search"
                    wire:model.live.debounce.300ms="search"
                    placeholder="{{ __('Search name, @handle, location, notes…') }}"
                    class="min-h-11 w-full rounded-xl border-0 bg-secondary/40 py-2.5 pl-10 pr-3 text-sm text-foreground placeholder:text-muted-foreground shadow-sm ring-1 ring-inset ring-border/50 transition-shadow focus:ring-2 focus:ring-ring"
                    autocomplete="off"
                />
            </div>
            <div class="flex shrink-0 rounded-xl bg-secondary/50 p-0.5 ring-1 ring-inset ring-border/40" role="tablist" aria-label="{{ __('Board view') }}">
                <button
                    type="button"
                    role="tab"
                    wire:click="$set('tab', 'pipeline')"
                    aria-selected="{{ $tab === 'pipeline' ? 'true' : 'false' }}"
                    class="min-h-10 flex-1 rounded-[0.625rem] px-4 py-2 text-sm font-semibold transition-all duration-200 sm:flex-none sm:min-w-[7.5rem] {{ $tab === 'pipeline' ? 'bg-card text-foreground shadow-sm ring-1 ring-border/50' : 'text-muted-foreground hover:bg-secondary/80 hover:text-foreground' }}"
                >
                    {{ __('Pipeline') }}
                </button>
                <button
                    type="button"
                    role="tab"
                    wire:click="$set('tab', 'history')"
                    aria-selected="{{ $tab === 'history' ? 'true' : 'false' }}"
                    class="min-h-10 flex-1 rounded-[0.625rem] px-4 py-2 text-sm font-semibold transition-all duration-200 sm:flex-none sm:min-w-[7.5rem] {{ $tab === 'history' ? 'bg-card text-foreground shadow-sm ring-1 ring-border/50' : 'text-muted-foreground hover:bg-secondary/80 hover:text-foreground' }}"
                >
                    {{ __('History') }}
                </button>
            </div>
        </div>
    </div>

    @if($tab === 'pipeline')
        @include('livewire.partials.partnership-reminders', ['reminderPartnerships' => $reminderPartnerships])
        <div class="grid grid-cols-1 gap-5 md:grid-cols-3 md:gap-6">
            @include('livewire.partials.partnership-column', ['title' => __('Upcoming'), 'dotClass' => 'bg-accent', 'items' => $upcoming, 'columnStatus' => 'upcoming'])
            @include('livewire.partials.partnership-column', ['title' => __('Confirmed'), 'dotClass' => 'bg-success', 'items' => $confirmed, 'columnStatus' => 'confirmed'])
            @include('livewire.partials.partnership-column', ['title' => __('Contacted'), 'dotClass' => 'bg-warning', 'items' => $contacted, 'columnStatus' => 'contacted'])
        </div>
    @else
        <div class="grid grid-cols-1 gap-5 md:grid-cols-2 md:gap-6">
            @include('livewire.partials.partnership-column', ['title' => __('Completed & posted'), 'dotClass' => 'bg-muted-foreground', 'items' => $completed, 'columnStatus' => 'completed'])
            @include('livewire.partials.partnership-column', ['title' => __('Archived'), 'dotClass' => 'bg-muted-foreground/50', 'items' => $archived, 'columnStatus' => 'archived'])
        </div>
    @endif

    @if($showModal)
        @php
            $nStatus = count($statusOptions);
            $statusIdx = 0;
            foreach ($statusOptions as $i => $st) {
                if ($st->value === $formStatus) {
                    $statusIdx = $i;
                    break;
                }
            }
            $fieldIn = 'mt-1.5 block w-full min-h-11 rounded-xl border-0 bg-secondary/40 py-2.5 px-3 text-base sm:text-sm text-foreground shadow-sm ring-1 ring-inset ring-border focus:ring-2 focus:ring-ring';
            $fieldTa = 'mt-1.5 block w-full min-h-[108px] rounded-xl border-0 bg-secondary/40 py-3 px-3 text-base sm:text-sm leading-relaxed text-foreground shadow-sm ring-1 ring-inset ring-border focus:ring-2 focus:ring-ring';
            $showPostUrl = $formStatus === 'completed' || $formStatus === 'archived';
        @endphp
        <div
            class="fixed inset-0 z-[60] grid place-items-center bg-black/45 backdrop-blur-sm p-3 pb-[max(0.75rem,env(safe-area-inset-bottom))] pt-[max(0.75rem,env(safe-area-inset-top))] sm:p-4 sm:pb-4 sm:pt-4 overflow-y-auto overscroll-y-contain"
            wire:click.self="closeModal"
        >
            <div
                role="dialog"
                aria-modal="true"
                aria-labelledby="collab-modal-title"
                class="collab-modal-panel relative my-auto flex w-full max-w-xl min-h-0 flex-col overflow-hidden rounded-2xl border border-border/60 bg-card shadow-2xl ring-1 ring-black/[0.04] animate-scale-in dark:ring-white/[0.06]"
                wire:click.stop
                wire:key="collab-modal"
            >
                <button
                    type="button"
                    wire:click="closeModal"
                    class="absolute right-3 top-3 z-20 rounded-xl p-2 text-muted-foreground hover:bg-secondary/90 hover:text-foreground transition-colors focus:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-card"
                    aria-label="Close"
                >
                    <svg class="h-5 w-5" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M18 6 6 18"/><path d="m6 6 12 12"/></svg>
                </button>

                <header class="shrink-0 border-b border-border/60 bg-card px-5 pt-6 pb-4 pr-14 sm:px-7 sm:pt-7 sm:pb-5 sm:pr-16">
                    <h2 id="collab-modal-title" class="text-xl font-semibold tracking-tight text-foreground text-left">{{ $editingId ? 'Edit partnership' : 'Add partnership' }}</h2>
                    <p class="text-left text-sm text-muted-foreground mt-1.5 leading-relaxed">
                        @if($editingId)
                            {{ __('Update details and save.') }}
                        @else
                            {{ __('Add the restaurant, then save. Drag the card on the board to change status.') }}
                        @endif
                    </p>
                </header>

                <form wire:submit="savePartnership" class="flex min-h-0 flex-1 flex-col">
                    <div class="dialog-body-scroll min-h-0 flex-1 overflow-y-auto overflow-x-hidden px-5 py-4 sm:px-7 sm:py-5 scroll-smooth">
                    <div class="space-y-6 pb-1">
                        <section class="space-y-4" aria-labelledby="pd-section-restaurant">
                            <h3 id="pd-section-restaurant" class="text-xs font-semibold uppercase tracking-wide text-muted-foreground">Restaurant</h3>
                            <div>
                                <label for="pd-restaurant-name" class="block text-sm font-medium text-foreground">Restaurant name *</label>
                                <input id="pd-restaurant-name" type="text" wire:model="restaurant_name" autocomplete="organization" placeholder="e.g. Grand Café Lisboa" class="{{ $fieldIn }}" />
                                @error('restaurant_name') <p class="text-sm text-destructive mt-1">{{ $message }}</p> @enderror
                            </div>
                            <div>
                                <label for="pd-ig-handle" class="block text-sm font-medium text-foreground">Instagram handle</label>
                                <input id="pd-ig-handle" type="text" wire:model="instagram_handle" placeholder="@yourhandle or restaurant handle" autocomplete="off" autocapitalize="none" spellcheck="false" class="{{ $fieldIn }}" />
                            </div>
                            <div>
                                <p id="pd-status-label" class="block text-sm font-medium text-foreground">Status</p>
                                <div class="mt-1.5 w-full overflow-x-auto overscroll-x-contain pb-0.5 [-webkit-overflow-scrolling:touch]" role="radiogroup" aria-labelledby="pd-status-label">
                                    <div class="relative flex w-full min-w-[20rem] rounded-2xl bg-muted/90 p-1 shadow-inner sm:min-w-0">
                                        <div
                                            aria-hidden="true"
                                            class="pointer-events-none absolute top-1 bottom-1 rounded-xl bg-background shadow-sm ring-1 ring-border/60 transition-[left,width] duration-200 ease-out motion-reduce:transition-none"
                                            style="width: calc((100% - 0.5rem) / {{ $nStatus }}); left: calc(0.25rem + ((100% - 0.5rem) / {{ $nStatus }}) * {{ $statusIdx }});"
                                        ></div>
                                        @foreach($statusOptions as $st)
                                            @php $sel = $formStatus === $st->value; @endphp
                                            <button
                                                type="button"
                                                role="radio"
                                                aria-checked="{{ $sel ? 'true' : 'false' }}"
                                                wire:click="$set('formStatus', '{{ $st->value }}')"
                                                class="relative z-10 flex min-h-11 min-w-0 flex-1 flex-col items-center justify-center gap-0.5 rounded-xl px-0.5 py-1.5 sm:min-h-[3.25rem] sm:py-2 touch-manipulation outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background {{ $sel ? 'text-foreground' : 'text-muted-foreground hover:text-foreground/90' }}"
                                            >
                                                @if($st->value === 'upcoming')
                                                    <svg class="h-4 w-4 shrink-0 sm:h-[1.125rem] sm:w-[1.125rem]" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="{{ $sel ? '2.25' : '2' }}" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M8 2v4"/><path d="M16 2v4"/><rect width="18" height="18" x="3" y="4" rx="2"/><path d="M3 10h18"/></svg>
                                                @elseif($st->value === 'confirmed')
                                                    <svg class="h-4 w-4 shrink-0 sm:h-[1.125rem] sm:w-[1.125rem]" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="{{ $sel ? '2.25' : '2' }}" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><circle cx="12" cy="12" r="10"/><path d="m9 12 2 2 4-4"/></svg>
                                                @elseif($st->value === 'contacted')
                                                    <svg class="h-4 w-4 shrink-0 sm:h-[1.125rem] sm:w-[1.125rem]" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="{{ $sel ? '2.25' : '2' }}" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M7.9 20A9 9 0 1 0 4 16.1L2 22Z"/></svg>
                                                @elseif($st->value === 'completed')
                                                    <svg class="h-4 w-4 shrink-0 sm:h-[1.125rem] sm:w-[1.125rem]" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="{{ $sel ? '2.25' : '2' }}" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="m12 3-1.912 5.813a2 2 0 0 1-1.275 1.275L3 12l5.813 1.912a2 2 0 0 1 1.275 1.275L12 21l1.912-5.813a2 2 0 0 1 1.275-1.275L21 12l-5.813-1.912a2 2 0 0 1-1.275-1.275L12 3Z"/></svg>
                                                @else
                                                    <svg class="h-4 w-4 shrink-0 sm:h-[1.125rem] sm:w-[1.125rem]" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="{{ $sel ? '2.25' : '2' }}" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><rect width="20" height="5" x="2" y="3" rx="1"/><path d="M4 8v11a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8"/><path d="M10 12h4"/></svg>
                                                @endif
                                                <span class="max-w-full truncate px-0.5 text-center text-[10px] font-semibold leading-tight sm:text-[11px]">{{ ucfirst($st->value) }}</span>
                                            </button>
                                        @endforeach
                                    </div>
                                </div>
                                @error('formStatus') <p class="text-sm text-destructive mt-1">{{ $message }}</p> @enderror
                            </div>
                            <div>
                                <label for="pd-ig-url" class="block text-sm font-medium text-foreground">Instagram profile or post link</label>
                                <input id="pd-ig-url" type="url" wire:model="instagram_url" placeholder="https://instagram.com/…" inputmode="url" autocomplete="off" autocapitalize="none" spellcheck="false" class="{{ $fieldIn }}" />
                            </div>
                            @if($canManage)
                                <div>
                                    <span class="block text-sm font-medium text-foreground">Restaurant contact (sees this collab)</span>
                                    @if($restaurantMembers->isNotEmpty())
                                        <select wire:model="managed_by_restaurant" class="{{ $fieldIn }}">
                                            <option value="">Not assigned</option>
                                            @foreach($restaurantMembers as $rm)
                                                <option value="{{ $rm->user_id }}">{{ $rm->user->name }} ({{ $rm->user->email }})</option>
                                            @endforeach
                                        </select>
                                    @else
                                        <input type="text" wire:model="managed_by_restaurant_manual" placeholder="Restaurant user ID (if not in list)" class="{{ $fieldIn }}" inputmode="numeric" />
                                    @endif
                                    <p class="text-xs text-muted-foreground mt-2 leading-relaxed">Restaurant accounts only see collabs assigned here. Invite them in Settings, then choose them from the list.</p>
                                    @error('managed_by_restaurant') <p class="text-sm text-destructive mt-1">{{ $message }}</p> @enderror
                                    @error('managed_by_restaurant_manual') <p class="text-sm text-destructive mt-1">{{ $message }}</p> @enderror
                                </div>
                            @endif
                        </section>

                        <div class="border-t border-border/70" role="presentation"></div>

                        <section class="space-y-4" aria-labelledby="pd-section-visit">
                            <h3 id="pd-section-visit" class="text-xs font-semibold uppercase tracking-wide text-muted-foreground">Visit</h3>
                            <div class="grid grid-cols-1 sm:grid-cols-3 gap-4">
                                <div>
                                    <label for="pd-date" class="block text-sm font-medium text-foreground">Date</label>
                                    <input id="pd-date" type="date" wire:model="scheduled_date" class="{{ $fieldIn }}" />
                                </div>
                                <div>
                                    <label for="pd-time" class="block text-sm font-medium text-foreground">Time</label>
                                    <input id="pd-time" type="time" wire:model="scheduled_time" class="{{ $fieldIn }}" />
                                </div>
                                <div>
                                    <label for="pd-guests" class="block text-sm font-medium text-foreground">Guests</label>
                                    <input id="pd-guests" type="number" min="1" inputmode="numeric" wire:model="guests" placeholder="—" class="{{ $fieldIn }}" />
                                </div>
                            </div>
                            @error('guests') <p class="text-sm text-destructive -mt-2">{{ $message }}</p> @enderror
                            <div>
                                <label for="pd-location" class="block text-sm font-medium text-foreground">City / area</label>
                                <input id="pd-location" type="text" wire:model="location" placeholder="e.g. Lisboa, Chiado" class="{{ $fieldIn }}" />
                            </div>
                        </section>

                        <div class="border-t border-border/70" role="presentation"></div>

                        <section class="space-y-4" aria-labelledby="pd-section-deal">
                            <h3 id="pd-section-deal" class="text-xs font-semibold uppercase tracking-wide text-muted-foreground">What's included</h3>
                            <div class="grid grid-cols-2 sm:grid-cols-4 gap-3 sm:gap-4">
                                <div>
                                    <label for="pd-inc-starters" class="block text-xs text-muted-foreground">Starters</label>
                                    <input id="pd-inc-starters" type="number" min="0" inputmode="numeric" wire:model="inclusion_starters" class="{{ $fieldIn }}" />
                                </div>
                                <div>
                                    <label for="pd-inc-mains" class="block text-xs text-muted-foreground">Mains</label>
                                    <input id="pd-inc-mains" type="number" min="0" inputmode="numeric" wire:model="inclusion_mains" class="{{ $fieldIn }}" />
                                </div>
                                <div>
                                    <label for="pd-inc-desserts" class="block text-xs text-muted-foreground">Desserts</label>
                                    <input id="pd-inc-desserts" type="number" min="0" inputmode="numeric" wire:model="inclusion_desserts" class="{{ $fieldIn }}" />
                                </div>
                                <div>
                                    <label for="pd-inc-drinks" class="block text-xs text-muted-foreground">Drinks</label>
                                    <input id="pd-inc-drinks" type="number" min="0" inputmode="numeric" wire:model="inclusion_drinks" class="{{ $fieldIn }}" />
                                </div>
                            </div>
                            @error('inclusion_starters') <p class="text-sm text-destructive">{{ $message }}</p> @enderror
                            @error('inclusion_mains') <p class="text-sm text-destructive">{{ $message }}</p> @enderror
                            @error('inclusion_desserts') <p class="text-sm text-destructive">{{ $message }}</p> @enderror
                            @error('inclusion_drinks') <p class="text-sm text-destructive">{{ $message }}</p> @enderror
                            <div>
                                <label for="pd-inclusions-desc" class="block text-xs text-muted-foreground">Or describe the deal</label>
                                <input id="pd-inclusions-desc" type="text" wire:model="inclusion_description" placeholder="e.g. Tasting menu for 2, drinks included…" class="{{ $fieldIn }}" />
                            </div>
                            @error('inclusion_description') <p class="text-sm text-destructive mt-1">{{ $message }}</p> @enderror
                        </section>

                        <div class="border-t border-border/70" role="presentation"></div>

                        <section class="space-y-4" aria-labelledby="pd-section-notes">
                            <h3 id="pd-section-notes" class="text-xs font-semibold uppercase tracking-wide text-muted-foreground">Notes</h3>
                            <div>
                                <label for="pd-notes" class="block text-sm font-medium text-foreground">Private notes</label>
                                <textarea id="pd-notes" wire:model="notes" placeholder="Contact name, DM thread, what you agreed on, follow-ups…" class="{{ $fieldTa }}"></textarea>
                            </div>
                            @if($showPostUrl)
                                <div>
                                    <label for="pd-post-url" class="block text-sm font-medium text-foreground">Post URL</label>
                                    <input id="pd-post-url" type="url" wire:model="post_url" placeholder="Link to your reel, story highlight, or TikTok…" inputmode="url" autocomplete="off" autocapitalize="none" spellcheck="false" class="{{ $fieldIn }}" />
                                </div>
                            @endif
                        </section>
                    </div>
                    </div>

                    <footer class="shrink-0 border-t border-border/70 bg-card/95 px-5 py-3 pb-[max(0.75rem,env(safe-area-inset-bottom))] shadow-[0_-12px_32px_-16px_rgba(0,0,0,0.08)] backdrop-blur-sm sm:px-7 dark:shadow-[0_-12px_32px_-16px_rgba(0,0,0,0.35)]">
                        <div class="flex flex-col-reverse gap-3 sm:flex-row sm:flex-wrap sm:items-center sm:justify-between sm:gap-x-4 sm:gap-y-2">
                            <div class="flex flex-wrap items-center gap-2">
                                @if($showQuickAlreadyWent)
                                    <button type="button" wire:click="quickAlreadyWent" class="inline-flex items-center gap-1.5 rounded-lg border border-transparent bg-secondary px-3 py-2 text-xs font-semibold text-secondary-foreground hover:bg-secondary/80 min-h-9 disabled:opacity-50" @disabled(trim($restaurant_name) === '')>
                                        <svg class="h-3.5 w-3.5 shrink-0 opacity-90" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><circle cx="12" cy="12" r="10"/><path d="m9 12 2 2 4-4"/></svg>
                                        {{ __('Already went') }}
                                    </button>
                                @endif
                                @if($showQuickArchive)
                                    <button type="button" wire:click="quickArchive" class="inline-flex items-center gap-1.5 rounded-lg border border-border bg-card px-3 py-2 text-xs font-semibold text-foreground hover:bg-secondary/50 min-h-9 disabled:opacity-50" @disabled(trim($restaurant_name) === '')>
                                        <svg class="h-3.5 w-3.5 shrink-0 opacity-90" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><rect width="20" height="5" x="2" y="3" rx="1"/><path d="M4 8v11a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8"/><path d="M10 12h4"/></svg>
                                        {{ __('Archive') }}
                                    </button>
                                @endif
                                @if($modalCanDelete)
                                    <button type="button" wire:click="deleteModalPartnership" wire:confirm="{{ __('Delete this partnership?') }}" class="rounded-lg px-3 py-2 text-xs font-semibold text-destructive hover:bg-destructive/10 min-h-9">
                                        {{ __('Delete') }}
                                    </button>
                                @endif
                            </div>
                            <div class="flex w-full flex-col gap-2 sm:w-auto sm:flex-row sm:justify-end">
                                <button type="button" wire:click="closeModal" class="w-full rounded-xl border border-border bg-card px-4 py-2.5 text-sm font-medium text-foreground hover:bg-secondary/50 min-h-11 sm:w-auto sm:min-w-[5.5rem]">Cancel</button>
                                <button type="submit" class="w-full rounded-xl bg-foreground px-4 py-2.5 text-sm font-semibold text-primary-foreground shadow-sm hover:opacity-90 min-h-11 sm:w-auto sm:min-w-[5.5rem] disabled:opacity-50" @disabled(trim($restaurant_name) === '')>{{ $editingId ? 'Save' : 'Add' }}</button>
                            </div>
                        </div>
                    </footer>
                </form>
            </div>
        </div>
    @endif
</div>
