@extends('layouts.app') @section('title', 'Mon profil') @section('content') @php $pct = (int) ($completion['percent'] ?? 0); $missing = array_slice($completion['missing'] ?? [], 0, 3); $isPremium = $user->isPremium(); $initials = \Illuminate\Support\Str::of($user->name)->explode(' ')->filter()->take(2)->map(fn ($w) => mb_strtoupper(mb_substr($w, 0, 1)))->implode(''); $typeWord = $user->account_type === 'client' ? 'Recruteur' : 'Candidat'; @endphp
{{-- ===== Identité ===== --}}
@if ($profile->photo_path) Ma photo @else @endif

{{ $user->name }}

{{ $typeWord }}@if ($profile->city) · {{ $profile->city }}@endif

{{ $isPremium ? 'Premium' : 'Compte simple' }}
Modifier mes informations
{{-- ===== Complétion (candidats) ===== --}} @if ($isWorker)

Mon profil est complet à {{ $pct }} %

@if (count($missing) === 0)

Votre profil est complet.

@endif
@if (count($missing))

Que faire maintenant ?

    @foreach ($missing as $item)
  1. {{ $item['label'] }}
  2. @endforeach
@endif
@endif {{-- ===== Abonnement ===== --}}

Abonnement

@if ($isPremium)

Premium actif

Valable jusqu'au {{ $user->premium_until->locale('fr')->translatedFormat('d F Y') }}.

Prolonger mon abonnement → @else

Compte simple

Passez en Premium pour voir le détail des missions et répondre aux clients.

Découvrir Premium @endif @if ($payments->isNotEmpty()) @php $last = $payments->first(); @endphp

Dernier paiement : {{ $last->amountLabel() }}, {{ $last->created_at->format('d/m/Y') }} · {{ ['pending' => 'En attente', 'paid' => 'Payé', 'failed' => 'Non réussi', 'cancelled' => 'Annulé', 'refunded' => 'Remboursé'][$last->status] ?? $last->status }}

@endif
{{-- ===== Accès rapides ===== --}}

Accès rapides

{{-- ===== Inviter ===== --}}
@include('partials.install-card')
@include('partials.push-toggle')

Inviter mes amis

{{ $referral['validated'] }} ami{{ $referral['validated'] > 1 ? 's' : '' }} inscrit{{ $referral['validated'] > 1 ? 's' : '' }} grâce à vous.

{{-- ===== Actions de compte ===== --}}
@endsection