<div class="mb-3">
    <label for="{{ $for ?? $name }}" class="form-label text-bold">
        {{ __($label) }}:
        {!! ($required ?? false) ? '<span class="span-admin-create">*</span>' : '' !!}
    </label>

    <select 
        class="form-control @error($name) is-invalid @enderror"
        name="{{ $name }}"
        id="{{ $id ?? $name }}"
        {{ ($required ?? false) ? 'required' : '' }}
        {{ ($readonly ?? false) ? 'disabled' : '' }}
        onchange="{{ $onchange ?? '' }}"
    >
        @if(!empty($placeholder))
            <option value="">{{ __($placeholder) }}</option>
        @endif

        @foreach($options as $key => $value)
            <option 
                value="{{ $key }}" 
                {{ old($name, $selected ?? '') == $key ? 'selected' : '' }}
            >
                {{ __($value) }}
            </option>
        @endforeach
    </select>

    @if(isset($small) && $small)
        <small class="text-secondary text-bold">{!! __($small) !!}</small>
    @endif

    @error($name)
        <small class="text-danger text-bold">{{ __($message) }}</small>
    @enderror
</div>
