@extends('admin.layouts.app')

@section('title', __('dashboard.security_details'))

@section('content')
<x-admin.page-header title="{{ __('dashboard.security_details') }}" :breadcrumbs="[__('dashboard.securities') => route('admin.securities.index'), __('dashboard.details') => '']" />

<div class="row justify-content-center">
    <div class="col-xl-12">
        <!-- Header Card -->
        <div class="card bg-primary bg-gradient mb-4">
            <div class="card-body">
                <div class="d-flex align-items-center">
                    <div class="avatar-lg bg-white bg-opacity-25 rounded d-flex align-items-center justify-content-center me-4" style="width: 80px; height: 80px;">
                        <i class="ri-shield-user-line text-white fs-1"></i>
                    </div>
                    <div>
                        <h3 class="mb-1 text-white">{{ $security->name }}</h3>
                        <p class="text-white-50 mb-0"><i class="ri-mail-line me-1"></i> {{ $security->email }}</p>
                    </div>

                    <div class="ms-auto text-end">
                        @if($security->is_active)
                            <span class="badge bg-success">{{ __('dashboard.active') }}</span>
                        @else
                            <span class="badge bg-danger">{{ __('dashboard.inactive') }}</span>
                        @endif
                    </div>
                </div>
            </div>
        </div>

        <!-- Info Card -->
        <div class="card mb-4">
            <div class="card-header">
                <h5 class="card-title mb-0">{{ __('dashboard.general_info') }}</h5>
            </div>
            <div class="card-body">
                <div class="row">
                    <x-view-col label="{{ __('dashboard.id') }}" :value="$security->id"/>
                    <x-view-col label="{{ __('dashboard.name') }}" :value="$security->name"/>
                    <x-view-col label="{{ __('dashboard.email') }}" :value="$security->email"/>
                    <x-view-col label="{{ __('dashboard.phone') }}" :value="$security->phone ?? '-'"/>
                    <x-view-col label="{{ __('dashboard.scanned_qr_codes') }}" :value="$security->scanned_qr_codes_count"/>
                    <x-view-col label="{{ __('dashboard.created_at') }}" :value="$security->created_at"/>
                    <x-view-col label="{{ __('dashboard.updated_at') }}" :value="$security->updated_at"/>
                </div>
            </div>
        </div>
    </div>
</div>
@endsection
