{{-- DE/EN language switch (R16). Plain links → full reload so the whole UI re-renders
     in the chosen language; persists per-user + session via the locale route. --}}
@php $current = app()->getLocale(); @endphp
<div class="inline-flex shrink-0 items-center rounded-md border border-line bg-inset p-0.5 font-mono text-[10px] uppercase tracking-wider"
     role="group" aria-label="Sprache / Language">
    @foreach (['de' => 'DE', 'en' => 'EN'] as $code => $abbr)
        <a href="{{ route('locale.set', $code) }}"
           @class([
               'rounded px-2 py-1 transition-colors',
               'bg-accent/15 text-accent-text' => $current === $code,
               'text-ink-4 hover:text-ink-2' => $current !== $code,
           ])
           aria-current="{{ $current === $code ? 'true' : 'false' }}"
           title="{{ $code === 'de' ? 'Deutsch' : 'English' }}">{{ $abbr }}</a>
    @endforeach
</div>
