@props(['variant' => 'button']) {{-- button (breeze) | alert | pill --}}

@php
  $base = 'font-semibold';
  $variants = [
    // Keep Breeze behavior unchanged for profile deletion modal.
    'button' => 'inline-flex items-center px-4 py-2 bg-red-600 border border-transparent rounded-md font-semibold text-xs text-white uppercase tracking-widest hover:bg-red-500 active:bg-red-700 focus:outline-none focus:ring-2 focus:ring-red-500 focus:ring-offset-2 transition ease-in-out duration-150',

    // Weshare tokenized variants
    'alert' => 'rounded-xl text-[14px] px-4 py-3 bg-destructive/10 text-destructive',
    'pill' => 'h-12 w-full rounded-full text-[16px] bg-destructive text-destructive-foreground hover:opacity-95',
  ];
  $classes = trim($base.' '.($variants[$variant] ?? $variants['button']));
@endphp

@if ($variant === 'alert')
  <div {{ $attributes->merge(['class' => $classes]) }}>
    {{ $slot }}
  </div>
@else
  <button {{ $attributes->merge(['type' => 'submit', 'class' => $classes]) }}>
    {{ $slot }}
  </button>
@endif
