-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathinvite_view.php
More file actions
575 lines (528 loc) · 31.3 KB
/
invite_view.php
File metadata and controls
575 lines (528 loc) · 31.3 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
<?php
// invite_view.php - Public Invite View (Read-Only)
// No authentication required - uses token validation
require_once 'config.php';
require_once 'auth_check.php';
$error_message = '';
$invite = null;
$diamonds = [];
// Get token from URL
$token = isset($_GET['token']) ? trim($_GET['token']) : '';
if (empty($token) || !is_valid_token($token)) {
$error_message = "Invalid invite link.";
} else {
// Fetch invite details
$stmt = $conn->prepare("SELECT id, client_id, token, customer_name, diamonds_shared, expires_at, used, access_count
FROM invites
WHERE token = ?");
if ($stmt) {
$stmt->bind_param("s", $token);
$stmt->execute();
$result = $stmt->get_result();
if ($result && $result->num_rows > 0) {
$invite = $result->fetch_assoc();
// Check if expired
if (strtotime($invite['expires_at']) < time()) {
$error_message = "This invite link has expired.";
$invite = null;
}
// Check if revoked
elseif ($invite['used'] == 1) {
$error_message = "This invite link has been revoked.";
$invite = null;
}
// Valid invite
else {
// Log access
$invite_id = $invite['id'];
$ip_address = $_SERVER['REMOTE_ADDR'] ?? null;
$user_agent = $_SERVER['HTTP_USER_AGENT'] ?? null;
// Update access count and last accessed time
$update_stmt = $conn->prepare("UPDATE invites SET access_count = access_count + 1, last_accessed_at = NOW() WHERE id = ?");
if ($update_stmt) {
$update_stmt->bind_param("i", $invite_id);
$update_stmt->execute();
$update_stmt->close();
}
// Log to access log (if table exists)
$log_stmt = $conn->prepare("INSERT INTO invite_access_log (invite_id, ip_address, user_agent) VALUES (?, ?, ?)");
if ($log_stmt) {
$log_stmt->bind_param("iss", $invite_id, $ip_address, $user_agent);
$log_stmt->execute();
$log_stmt->close();
}
// Fetch shared diamonds (including image_url and certificate_url)
$diamond_ids = json_decode($invite['diamonds_shared'], true);
if (is_array($diamond_ids) && !empty($diamond_ids)) {
$placeholders = implode(',', array_fill(0, count($diamond_ids), '?'));
$diamond_stmt = $conn->prepare("SELECT id, stock_no, shape, size, color, clarity, cut, polish, symmetry, diamond_type, image_url, certificate_url, status
FROM diamonds
WHERE id IN ($placeholders)");
if ($diamond_stmt) {
$types = str_repeat('i', count($diamond_ids));
$diamond_stmt->bind_param($types, ...$diamond_ids);
$diamond_stmt->execute();
$diamond_result = $diamond_stmt->get_result();
if ($diamond_result) {
while ($row = $diamond_result->fetch_assoc()) {
$diamonds[] = $row;
}
}
$diamond_stmt->close();
}
}
}
} else {
$error_message = "Invite not found.";
}
$stmt->close();
}
}
?>
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title><?php echo $invite ? 'Diamond Collection' : 'Invite Error'; ?> - DS Diamonds</title>
<script src="https://cdn.tailwindcss.com"></script>
<link
href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=Playfair+Display:wght@600;700&display=swap"
rel="stylesheet">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css" />
<script src="https://cdn.jsdelivr.net/npm/alpinejs@3.x.x/dist/cdn.min.js" defer></script>
<style>
body {
font-family: 'Inter', sans-serif;
}
.heading-font {
font-family: 'Playfair Display', serif;
}
.gradient-bg {
background: linear-gradient(135deg, #7b2ff7, #f83077);
}
.diamond-card {
transition: all 0.3s ease;
}
.diamond-card:hover {
transform: translateY(-5px);
box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}
</style>
</head>
<body class="bg-gray-50" x-data="{
showModal: false,
selectedDiamond: null,
openModal(diamond) {
this.selectedDiamond = diamond;
this.showModal = true;
document.body.style.overflow = 'hidden';
},
closeModal() {
this.showModal = false;
document.body.style.overflow = 'auto';
}
}">
<!-- Header -->
<nav class="bg-white border-b border-gray-200">
<div class="max-w-7xl mx-auto px-4 sm:px-6 lg:px-8">
<div class="flex justify-between items-center h-16">
<div class="flex items-center">
<i class="far fa-gem text-3xl text-purple-600 mr-2"></i>
<span class="text-2xl font-bold heading-font">DS<span class="text-pink-600">Diamonds</span></span>
</div>
<div class="text-sm text-gray-600">
<i class="fas fa-lock mr-1"></i>Secure View-Only Access
</div>
</div>
</div>
</nav>
<!-- Main Content -->
<main class="max-w-7xl mx-auto px-4 sm:px-6 lg:px-8 py-12">
<?php if ($error_message): ?>
<!-- Error State -->
<div class="max-w-md mx-auto text-center">
<div class="bg-red-50 border border-red-200 rounded-xl p-8 mb-6">
<i class="fas fa-exclamation-triangle text-5xl text-red-500 mb-4"></i>
<h2 class="text-2xl font-bold text-gray-800 mb-2">Access Denied</h2>
<p class="text-gray-600"><?php echo h($error_message); ?></p>
</div>
<p class="text-sm text-gray-500">
If you believe this is an error, please contact your reseller for a new invite link.
</p>
</div>
<?php else: ?>
<!-- Success: Show Diamonds -->
<div class="mb-8">
<div class="text-center mb-6">
<?php if ($invite['customer_name']): ?>
<h1 class="text-3xl md:text-4xl font-bold heading-font text-gray-800 mb-2">
Welcome, <?php echo h($invite['customer_name']); ?>
</h1>
<?php else: ?>
<h1 class="text-3xl md:text-4xl font-bold heading-font text-gray-800 mb-2">
Exclusive Diamond Collection
</h1>
<?php endif; ?>
<p class="text-gray-600">Your reseller has shared these premium diamonds with you.</p>
</div>
<!-- Info Banner -->
<div class="bg-gradient-to-r from-purple-50 to-pink-50 border border-purple-200 rounded-xl p-6 mb-8">
<div class="flex items-start">
<i class="fas fa-info-circle text-purple-600 text-xl mt-1 mr-4"></i>
<div class="flex-1">
<h3 class="font-semibold text-gray-800 mb-2">Important Information</h3>
<ul class="text-sm text-gray-700 space-y-1">
<li><i class="fas fa-check text-green-600 mr-2"></i>All diamonds are certified and verified
</li>
<li><i class="fas fa-check text-green-600 mr-2"></i>This is a read-only preview for your
convenience</li>
<li><i class="fas fa-check text-green-600 mr-2"></i>All transactions are conducted in person
</li>
<li><i class="fas fa-check text-green-600 mr-2"></i>Contact your reseller to purchase or
request more details</li>
<li><i class="fas fa-clock text-orange-600 mr-2"></i>This link expires on
<?php echo format_date($invite['expires_at'], 'M d, Y'); ?></li>
</ul>
</div>
</div>
</div>
</div>
<?php if (empty($diamonds)): ?>
<div class="text-center py-12">
<i class="far fa-gem text-6xl text-gray-300 mb-4"></i>
<p class="text-xl text-gray-500">No diamonds available in this collection.</p>
</div>
<?php else: ?>
<!-- Diamond Count -->
<div class="mb-6">
<p class="text-gray-600">
<i class="fas fa-gem mr-2"></i>
<strong><?php echo count($diamonds); ?></strong>
<?php echo count($diamonds) == 1 ? 'diamond' : 'diamonds'; ?> shared with you
</p>
</div>
<!-- Diamond Grid -->
<div class="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-6">
<?php foreach ($diamonds as $diamond):
$diamond_id = $diamond['id'];
// Check if diamond has custom image, otherwise use default images
if (!empty($diamond['image_url']) && file_exists($diamond['image_url'])) {
$diamond_image = $diamond['image_url'];
} else {
// Use rotating default images (1-5)
$image_num = (($diamond_id - 1) % 5) + 1;
$diamond_image = "assets/images/diamonds/diamond-{$image_num}.jpg";
}
?>
<div class="diamond-card bg-white rounded-xl shadow-md overflow-hidden">
<!-- Diamond Visual -->
<div
class="bg-gradient-to-br from-purple-100 to-pink-100 h-56 flex items-center justify-center relative overflow-hidden">
<?php if (file_exists($diamond_image)): ?>
<img src="<?php echo $diamond_image; ?>" alt="Diamond <?php echo h($diamond['stock_no']); ?>"
class="w-full h-full object-cover">
<?php else: ?>
<i class="fas fa-gem text-8xl text-purple-300"></i>
<?php endif; ?>
<div
class="absolute top-3 right-3 bg-white/90 px-3 py-1 rounded-full text-xs font-semibold text-gray-700">
Certified
</div>
</div>
<!-- Diamond Info -->
<div class="p-6">
<div class="flex justify-between items-start mb-3">
<div>
<div class="text-xs text-gray-500 uppercase mb-1">
<?php echo h($diamond['shape'] ?? 'N/A'); ?>
</div>
<div class="text-3xl font-bold text-gray-800">
<?php echo h($diamond['size']); ?> ct
</div>
</div>
<div class="text-right">
<div class="text-xs text-gray-500 mb-1">Stock</div>
<div class="text-sm font-semibold text-gray-700">
<?php echo h($diamond['stock_no']); ?>
</div>
</div>
</div>
<div class="grid grid-cols-2 gap-3 mb-4">
<div class="bg-gray-50 p-3 rounded-lg">
<div class="text-xs text-gray-500 mb-1">Color</div>
<div class="font-semibold text-gray-800"><?php echo h($diamond['color']); ?></div>
</div>
<div class="bg-gray-50 p-3 rounded-lg">
<div class="text-xs text-gray-500 mb-1">Clarity</div>
<div class="font-semibold text-gray-800"><?php echo h($diamond['clarity']); ?></div>
</div>
<div class="bg-gray-50 p-3 rounded-lg">
<div class="text-xs text-gray-500 mb-1">Cut</div>
<div class="font-semibold text-gray-800"><?php echo h($diamond['cut']); ?></div>
</div>
<div class="bg-gray-50 p-3 rounded-lg">
<div class="text-xs text-gray-500 mb-1">Polish</div>
<div class="font-semibold text-gray-800"><?php echo h($diamond['polish']); ?></div>
</div>
</div>
<button @click="openModal({
id: '<?php echo $diamond_id; ?>',
stock_no: '<?php echo addslashes(h($diamond['stock_no'])); ?>',
shape: '<?php echo addslashes(h($diamond['shape'] ?? 'N/A')); ?>',
size: '<?php echo addslashes(h($diamond['size'])); ?>',
color: '<?php echo addslashes(h($diamond['color'])); ?>',
clarity: '<?php echo addslashes(h($diamond['clarity'])); ?>',
cut: '<?php echo addslashes(h($diamond['cut'])); ?>',
polish: '<?php echo addslashes(h($diamond['polish'])); ?>',
symmetry: '<?php echo addslashes(h($diamond['symmetry'])); ?>',
diamond_type: '<?php echo addslashes(h($diamond['diamond_type'] ?? '')); ?>',
status: '<?php echo addslashes(h($diamond['status'] ?? 'Available')); ?>',
image: '<?php echo addslashes($diamond_image); ?>',
certificate: '<?php echo !empty($diamond['certificate_url']) ? addslashes($diamond['certificate_url']) : ''; ?>',
certificate_ext: '<?php echo !empty($diamond['certificate_url']) ? strtolower(pathinfo($diamond['certificate_url'], PATHINFO_EXTENSION)) : ''; ?>'
})"
class="w-full gradient-bg text-white px-4 py-3 rounded-lg font-semibold hover:opacity-90 transition">
<i class="fas fa-eye mr-2"></i>View Full Details
</button>
</div>
</div>
<?php endforeach; ?>
</div>
<?php endif; ?>
<?php endif; ?>
</main>
<!-- Global Diamond Details Modal -->
<div x-show="showModal" @click.self="closeModal()" x-cloak
class="fixed inset-0 bg-black bg-opacity-70 backdrop-blur-sm flex items-center justify-center z-50 p-4"
style="display: none;">
<div class="bg-white rounded-3xl max-w-5xl w-full max-h-[90vh] overflow-hidden shadow-2xl" @click.stop>
<!-- Header with gradient background -->
<div class="gradient-bg text-white p-6 md:p-8 relative overflow-hidden">
<div class="absolute top-0 right-0 opacity-10">
<i class="fas fa-gem text-9xl"></i>
</div>
<div class="relative z-10 flex justify-between items-start">
<div>
<div class="text-xs md:text-sm opacity-90 mb-2">DIAMOND DETAILS</div>
<h3 class="text-2xl md:text-4xl font-bold heading-font mb-2"
x-text="'Stock #' + (selectedDiamond?.stock_no || '')"></h3>
<div class="flex flex-wrap items-center gap-2 md:gap-3">
<span
class="px-3 py-1 bg-white/20 backdrop-blur-sm rounded-full text-xs md:text-sm font-semibold"
x-text="selectedDiamond?.shape || ''"></span>
<span
class="px-3 py-1 bg-white/20 backdrop-blur-sm rounded-full text-xs md:text-sm font-semibold"
x-text="(selectedDiamond?.size || '') + ' Carat'"></span>
<span
class="px-3 py-1 bg-white/90 text-purple-600 rounded-full text-xs md:text-sm font-semibold">
<i class="fas fa-certificate mr-1"></i>Certified
</span>
</div>
</div>
<button @click="closeModal()"
class="w-10 h-10 bg-white/20 backdrop-blur-sm rounded-full hover:bg-white/30 transition flex items-center justify-center flex-shrink-0">
<i class="fas fa-times text-xl"></i>
</button>
</div>
</div>
<!-- Scrollable Content -->
<div class="overflow-y-auto max-h-[calc(90vh-200px)] p-4 md:p-8">
<!-- Two Column Layout -->
<div class="grid lg:grid-cols-2 gap-6 md:gap-8">
<!-- Left: Diamond Image & Certificate -->
<div class="space-y-4">
<!-- Diamond Image -->
<div
class="bg-gradient-to-br from-purple-50 via-pink-50 to-purple-50 rounded-2xl p-6 md:p-8 h-64 md:h-80 flex items-center justify-center overflow-hidden shadow-lg border border-purple-100">
<template x-if="selectedDiamond?.image">
<img :src="selectedDiamond.image" alt="Diamond"
class="max-w-full max-h-full object-contain">
</template>
<template x-if="!selectedDiamond?.image">
<i class="fas fa-gem text-7xl md:text-9xl text-purple-200"></i>
</template>
</div>
<!-- Certificate Section -->
<template x-if="selectedDiamond?.certificate">
<div
class="bg-gradient-to-br from-blue-50 to-indigo-50 rounded-2xl p-4 md:p-6 border border-blue-100">
<div class="flex items-center mb-4">
<div
class="w-10 h-10 md:w-12 md:h-12 bg-gradient-to-br from-blue-500 to-indigo-600 rounded-xl flex items-center justify-center mr-3 md:mr-4 flex-shrink-0">
<i class="fas fa-certificate text-white text-lg md:text-xl"></i>
</div>
<div>
<h4 class="font-bold text-gray-800 text-base md:text-lg">Certificate Available
</h4>
<p class="text-xs md:text-sm text-gray-600">Verified & Authenticated</p>
</div>
</div>
<!-- Certificate Preview -->
<template
x-if="selectedDiamond?.certificate_ext && ['jpg', 'jpeg', 'png'].includes(selectedDiamond.certificate_ext)">
<div class="bg-white rounded-lg p-2 mb-4 border border-blue-200">
<img :src="selectedDiamond.certificate" alt="Certificate"
class="w-full rounded">
</div>
</template>
<template x-if="selectedDiamond?.certificate_ext === 'pdf'">
<div
class="bg-white rounded-lg p-4 mb-4 border border-blue-200 flex items-center justify-center">
<i class="fas fa-file-pdf text-5xl md:text-6xl text-red-500"></i>
</div>
</template>
<a :href="selectedDiamond?.certificate" target="_blank"
class="w-full bg-gradient-to-r from-blue-600 to-indigo-600 text-white px-4 py-3 rounded-lg font-semibold hover:from-blue-700 hover:to-indigo-700 transition flex items-center justify-center text-sm md:text-base">
<i class="fas fa-download mr-2"></i>Download Certificate
</a>
</div>
</template>
</div>
<!-- Right: Specifications -->
<div>
<h4
class="text-xl md:text-2xl font-bold heading-font text-gray-800 mb-4 md:mb-6 flex items-center">
<i class="fas fa-list-ul text-purple-600 mr-2 md:mr-3"></i>
Complete Specifications
</h4>
<div class="space-y-4">
<!-- The 4 Cs -->
<div
class="bg-gradient-to-br from-purple-50 to-pink-50 rounded-xl p-4 md:p-6 border border-purple-100">
<div class="text-xs uppercase text-purple-600 font-bold mb-3 md:mb-4 tracking-wider">The
Four C's</div>
<div class="grid grid-cols-2 gap-3 md:gap-4">
<div>
<div class="text-xs text-gray-500 mb-1">CARAT WEIGHT</div>
<div class="text-2xl md:text-3xl font-bold text-gray-800"
x-text="selectedDiamond?.size || ''"></div>
<div class="text-xs text-gray-500">carats</div>
</div>
<div>
<div class="text-xs text-gray-500 mb-1">COLOR GRADE</div>
<div class="text-2xl md:text-3xl font-bold text-gray-800"
x-text="selectedDiamond?.color || ''"></div>
<div class="text-xs text-gray-500">grade</div>
</div>
<div>
<div class="text-xs text-gray-500 mb-1">CLARITY</div>
<div class="text-2xl md:text-3xl font-bold text-gray-800"
x-text="selectedDiamond?.clarity || ''"></div>
<div class="text-xs text-gray-500">grade</div>
</div>
<div>
<div class="text-xs text-gray-500 mb-1">CUT QUALITY</div>
<div class="text-2xl md:text-3xl font-bold text-gray-800"
x-text="selectedDiamond?.cut || ''"></div>
<div class="text-xs text-gray-500">grade</div>
</div>
</div>
</div>
<!-- Additional Details -->
<div class="grid grid-cols-2 gap-3">
<div
class="bg-white border border-gray-200 rounded-xl p-3 md:p-4 hover:shadow-md transition">
<div class="flex items-center mb-2">
<i class="fas fa-shapes text-purple-600 mr-2 text-sm"></i>
<div class="text-xs text-gray-500 uppercase">Shape</div>
</div>
<div class="text-base md:text-lg font-bold text-gray-800"
x-text="selectedDiamond?.shape || ''"></div>
</div>
<div
class="bg-white border border-gray-200 rounded-xl p-3 md:p-4 hover:shadow-md transition">
<div class="flex items-center mb-2">
<i class="fas fa-gem text-purple-600 mr-2 text-sm"></i>
<div class="text-xs text-gray-500 uppercase">Polish</div>
</div>
<div class="text-base md:text-lg font-bold text-gray-800"
x-text="selectedDiamond?.polish || ''"></div>
</div>
<div
class="bg-white border border-gray-200 rounded-xl p-3 md:p-4 hover:shadow-md transition">
<div class="flex items-center mb-2">
<i class="fas fa-balance-scale text-purple-600 mr-2 text-sm"></i>
<div class="text-xs text-gray-500 uppercase">Symmetry</div>
</div>
<div class="text-base md:text-lg font-bold text-gray-800"
x-text="selectedDiamond?.symmetry || ''"></div>
</div>
<template x-if="selectedDiamond?.diamond_type">
<div
class="bg-white border border-gray-200 rounded-xl p-3 md:p-4 hover:shadow-md transition">
<div class="flex items-center mb-2">
<i class="fas fa-tag text-purple-600 mr-2 text-sm"></i>
<div class="text-xs text-gray-500 uppercase">Type</div>
</div>
<div class="text-base md:text-lg font-bold text-gray-800"
x-text="selectedDiamond?.diamond_type || ''"></div>
</div>
</template>
</div>
<!-- Quality Indicators -->
<div
class="bg-gradient-to-r from-green-50 to-emerald-50 rounded-xl p-4 border border-green-200">
<div class="flex items-center justify-between mb-2">
<span class="text-xs md:text-sm font-semibold text-gray-700">Quality
Indicators</span>
<i class="fas fa-check-circle text-green-600"></i>
</div>
<div class="grid grid-cols-3 gap-2 text-center">
<div>
<div class="text-xl md:text-2xl font-bold text-green-600"
x-text="selectedDiamond?.cut || ''"></div>
<div class="text-xs text-gray-600">Cut</div>
</div>
<div>
<div class="text-xl md:text-2xl font-bold text-green-600"
x-text="selectedDiamond?.polish || ''"></div>
<div class="text-xs text-gray-600">Polish</div>
</div>
<div>
<div class="text-xl md:text-2xl font-bold text-green-600"
x-text="selectedDiamond?.symmetry || ''"></div>
<div class="text-xs text-gray-600">Symmetry</div>
</div>
</div>
</div>
<!-- Contact Reseller Notice -->
<div class="bg-blue-50 border border-blue-200 rounded-xl p-4">
<p class="text-xs md:text-sm text-blue-800">
<i class="fas fa-info-circle mr-2"></i>
<strong>To purchase or request more information,</strong> please contact your
reseller directly. All transactions are conducted in person for your security and
confidence.
</p>
</div>
</div>
</div>
</div>
</div>
<!-- Footer Actions -->
<div class="border-t border-gray-200 p-4 md:p-6 bg-gray-50">
<button @click="closeModal()"
class="w-full px-6 py-3 md:py-4 bg-gray-200 text-gray-700 rounded-xl font-semibold hover:bg-gray-300 transition text-sm md:text-base">
Close
</button>
</div>
</div>
</div>
<!-- Footer -->
<footer class="bg-white border-t border-gray-200 mt-20 py-8">
<div class="max-w-7xl mx-auto px-4 sm:px-6 lg:px-8 text-center">
<p class="text-gray-600 mb-2">
<i class="far fa-gem text-purple-600 mr-1"></i>
<strong>DS Diamonds</strong> - Premium Diamond Collection
</p>
<p class="text-sm text-gray-500">
All transactions conducted in person. This is a secure, read-only preview.
</p>
<p class="text-xs text-gray-400 mt-4">
© 2025 DS Diamonds. All rights reserved.
</p>
</div>
</footer>
</body>
</html>
<?php $conn->close(); ?>