@extends('layouts.app') @section('content')

Your Shopping Bag

@if(session('success'))
{{ session('success') }}
@endif @if(count($cart) > 0) @php $total = 0; @endphp @foreach($cart as $key => $item) @php $total += (float)str_replace(',', '', $item['price']) * $item['quantity']; @endphp @endforeach
Item Details Price Action
@php $images = []; if (!empty($item['image'])) { $decoded = json_decode($item['image'], true); if (is_array($decoded)) { $images = $decoded; } else { $images = [$item['image']]; } } $firstImg = $images[0] ?? 'default-placeholder.png'; $imgSrc = str_starts_with($firstImg, 'http') ? $firstImg : asset('assets/images/product/' . trim($firstImg)); @endphp {{ $item['name'] }}

{{ $item['name'] }}

Metal: {{ $item['metal'] }} Quality: {{ $item['quality'] }} Size: {{ $item['ring_size'] }} @if(!empty($item['carat'])) Carat: {{ $item['carat'] }} CT @endif
$ {{ $item['price'] }} USD
@csrf

Subtotal: $ {{ number_format($total, 2) }} USD

Shipping & taxes calculated at checkout

Continue Shopping CHECKOUT
@else

Your bag is currently empty.

Shop Engagement Rings
@endif
@endsection