@o2vend/theme-cli 1.0.37 → 1.0.38

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (89) hide show
  1. package/lib/lib/dev-server.js +309 -40
  2. package/lib/lib/liquid-engine.js +3 -1
  3. package/lib/lib/mock-data.js +36 -124
  4. package/lib/lib/widget-service.js +12 -4
  5. package/package.json +1 -1
  6. package/test-theme/assets/async-sections.js +32 -24
  7. package/test-theme/assets/cart-drawer.js +20 -22
  8. package/test-theme/assets/cart-manager.js +1 -15
  9. package/test-theme/assets/checkout-price-handler.js +12 -11
  10. package/test-theme/assets/checkout.css +1415 -0
  11. package/test-theme/assets/checkout.js +3174 -0
  12. package/test-theme/assets/components.css +178 -29
  13. package/test-theme/assets/delivery-zone.js +1 -1
  14. package/test-theme/assets/product-detail.css +1050 -0
  15. package/test-theme/assets/product-detail.js +2940 -0
  16. package/test-theme/assets/theme.css +95 -120
  17. package/test-theme/assets/theme.js +781 -186
  18. package/test-theme/layout/theme.liquid +91 -17
  19. package/test-theme/sections/content.liquid +64 -57
  20. package/test-theme/sections/footer-fallback.liquid +57 -7
  21. package/test-theme/sections/footer.liquid +63 -12
  22. package/test-theme/sections/header-fallback.liquid +41 -41
  23. package/test-theme/sections/header.liquid +41 -51
  24. package/test-theme/sections/hero-fallback.liquid +1 -1
  25. package/test-theme/sections/hero.liquid +159 -136
  26. package/test-theme/snippets/account-sidebar.liquid +121 -29
  27. package/test-theme/snippets/add-to-cart-modal.liquid +258 -206
  28. package/test-theme/snippets/breadcrumbs.liquid +98 -11
  29. package/test-theme/snippets/cart-drawer.liquid +93 -0
  30. package/test-theme/snippets/delivery-zone-city-selector.liquid +101 -15
  31. package/test-theme/snippets/delivery-zone-modal.liquid +529 -84
  32. package/test-theme/snippets/delivery-zone-search.liquid +104 -18
  33. package/test-theme/snippets/login-modal.liquid +269 -82
  34. package/test-theme/snippets/mega-menu.liquid +130 -43
  35. package/test-theme/snippets/news-thumbnail.liquid +120 -28
  36. package/test-theme/snippets/pagination.liquid +1 -1
  37. package/test-theme/snippets/price.liquid +100 -9
  38. package/test-theme/snippets/product-card-related.liquid +22 -4
  39. package/test-theme/snippets/product-card-simple.liquid +521 -25
  40. package/test-theme/snippets/product-card.liquid +145 -232
  41. package/test-theme/snippets/rating.liquid +100 -9
  42. package/test-theme/snippets/skeleton-collection-grid.liquid +94 -8
  43. package/test-theme/snippets/skeleton-product-card.liquid +102 -16
  44. package/test-theme/snippets/skeleton-product-grid.liquid +87 -1
  45. package/test-theme/snippets/social-sharing.liquid +133 -32
  46. package/test-theme/templates/account/dashboard.liquid +30 -0
  47. package/test-theme/templates/account/loyalty-redemption.liquid +29 -28
  48. package/test-theme/templates/account/loyalty.liquid +45 -43
  49. package/test-theme/templates/account/order-detail.liquid +15 -8
  50. package/test-theme/templates/account/orders.liquid +189 -35
  51. package/test-theme/templates/account/profile.liquid +509 -114
  52. package/test-theme/templates/account/register.liquid +18 -8
  53. package/test-theme/templates/account/return-orders.liquid +31 -30
  54. package/test-theme/templates/account/store-credit.liquid +27 -26
  55. package/test-theme/templates/account/subscriptions.liquid +22 -5
  56. package/test-theme/templates/account/wishlist.liquid +88 -19
  57. package/test-theme/templates/address-book.liquid +166 -69
  58. package/test-theme/templates/categories.liquid +90 -30
  59. package/test-theme/templates/checkout.liquid +137 -3834
  60. package/test-theme/templates/error.liquid +23 -21
  61. package/test-theme/templates/index.liquid +29 -0
  62. package/test-theme/templates/login.liquid +33 -6
  63. package/test-theme/templates/order-confirmation.liquid +67 -9
  64. package/test-theme/templates/page.liquid +418 -206
  65. package/test-theme/templates/product-detail.liquid +124 -3878
  66. package/test-theme/templates/products.liquid +155 -30
  67. package/test-theme/templates/search.liquid +739 -225
  68. package/test-theme/widgets/brand-carousel.liquid +102 -82
  69. package/test-theme/widgets/brand.liquid +78 -50
  70. package/test-theme/widgets/carousel.liquid +253 -121
  71. package/test-theme/widgets/category-list-carousel.liquid +32 -8
  72. package/test-theme/widgets/category-list.liquid +21 -6
  73. package/test-theme/widgets/category.liquid +104 -37
  74. package/test-theme/widgets/discount-time.liquid +326 -119
  75. package/test-theme/widgets/footer-menu.liquid +115 -23
  76. package/test-theme/widgets/footer.liquid +118 -5
  77. package/test-theme/widgets/gallery.liquid +29 -5
  78. package/test-theme/widgets/header-menu.liquid +25 -13
  79. package/test-theme/widgets/header.liquid +64 -26
  80. package/test-theme/widgets/html.liquid +29 -6
  81. package/test-theme/widgets/news.liquid +6 -0
  82. package/test-theme/widgets/product-canvas.liquid +20 -12
  83. package/test-theme/widgets/product-carousel.liquid +118 -56
  84. package/test-theme/widgets/shared/product-grid.liquid +12 -0
  85. package/test-theme/widgets/single-product.liquid +688 -250
  86. package/test-theme/widgets/spacebar-carousel.liquid +39 -10
  87. package/test-theme/widgets/spacebar.liquid +77 -6
  88. package/test-theme/widgets/splash.liquid +40 -30
  89. package/test-theme/widgets/testimonial-carousel.liquid +111 -67
@@ -134,139 +134,534 @@
134
134
  </div>
135
135
  </section>
136
136
 
137
+ <!-- Account Deletion Reason Modal -->
138
+ <div class="deletion-modal-overlay" id="deletion-modal" style="display: none;">
139
+ <div class="deletion-modal">
140
+ <div class="deletion-modal-header">
141
+ <h3 class="deletion-modal-title">Delete Account</h3>
142
+ <button type="button" class="deletion-modal-close" id="deletion-modal-close" aria-label="Close">
143
+ <svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
144
+ <line x1="18" y1="6" x2="6" y2="18"></line>
145
+ <line x1="6" y1="6" x2="18" y2="18"></line>
146
+ </svg>
147
+ </button>
148
+ </div>
149
+ <div class="deletion-modal-body">
150
+ <p class="deletion-modal-warning">
151
+ <svg class="deletion-modal-warning-icon" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
152
+ <path d="M10.29 3.86L1.82 18a2 2 0 0 0 1.71 3h16.94a2 2 0 0 0 1.71-3L13.71 3.86a2 2 0 0 0-3.42 0z"></path>
153
+ <line x1="12" y1="9" x2="12" y2="13"></line>
154
+ <line x1="12" y1="17" x2="12.01" y2="17"></line>
155
+ </svg>
156
+ This action is permanent and cannot be undone. All your data will be deleted.
157
+ </p>
158
+ <label class="deletion-modal-label" for="deletion-reason">
159
+ Please tell us why you want to delete your account <span class="required">*</span>
160
+ </label>
161
+ <textarea
162
+ id="deletion-reason"
163
+ class="deletion-modal-textarea"
164
+ placeholder="Enter your reason for account deletion..."
165
+ rows="4"
166
+ required
167
+ ></textarea>
168
+ <p class="deletion-modal-error" id="deletion-reason-error" style="display: none;">
169
+ Please provide a reason for account deletion.
170
+ </p>
171
+ </div>
172
+ <div class="deletion-modal-footer">
173
+ <button type="button" class="btn btn-secondary" id="deletion-modal-cancel">Cancel</button>
174
+ <button type="button" class="btn btn-danger" id="deletion-modal-confirm">
175
+ <span class="btn-text">Delete My Account</span>
176
+ <span class="btn-loading" style="display: none;">
177
+ <svg class="spinner" viewBox="0 0 24 24">
178
+ <circle cx="12" cy="12" r="10" stroke="currentColor" stroke-width="3" fill="none" stroke-dasharray="32" stroke-linecap="round"></circle>
179
+ </svg>
180
+ Deleting...
181
+ </span>
182
+ </button>
183
+ </div>
184
+ </div>
185
+ </div>
186
+
137
187
  <script>
138
- document.addEventListener('DOMContentLoaded', function() {
139
- // Initialize intl-tel-input for profile phone
140
- const profilePhoneInput = document.getElementById('profile-phone');
141
- let profilePhoneIti = null;
142
-
143
- if (profilePhoneInput && typeof intlTelInput !== 'undefined') {
144
- const existingPhone = profilePhoneInput.value || '';
145
-
146
- profilePhoneIti = intlTelInput(profilePhoneInput, {
147
- utilsScript: 'https://cdn.jsdelivr.net/npm/intl-tel-input@23.0.0/build/js/utils.js',
148
- initialCountry: 'auto',
149
- geoIpLookup: function(callback) {
150
- fetch('https://ipapi.co/json/')
151
- .then(res => res.json())
152
- .then(data => callback(data.country_code ? data.country_code.toLowerCase() : 'us'))
153
- .catch(() => callback('us'));
154
- },
155
- preferredCountries: ['us', 'gb', 'ca', 'au', 'in'],
156
- separateDialCode: true,
157
- nationalMode: false
158
- });
159
-
160
- // Store instance for form submission
161
- window.profilePhoneIti = profilePhoneIti;
162
-
163
- // Set existing phone number if available (after a small delay to ensure utils are loaded)
164
- if (existingPhone) {
165
- setTimeout(function() {
166
- profilePhoneIti.setNumber(existingPhone);
167
- }, 100);
188
+ document.addEventListener('DOMContentLoaded', () => {
189
+
190
+ /* ===============================
191
+ Button Loading Utility
192
+ =============================== */
193
+ function setButtonLoading(button, loading) {
194
+ if (!button) return;
195
+
196
+ const btnText = button.querySelector('.btn-text');
197
+ const btnLoading = button.querySelector('.btn-loading');
198
+
199
+ button.disabled = loading;
200
+
201
+ if (btnText) btnText.style.display = loading ? 'none' : 'inline';
202
+ if (btnLoading) btnLoading.style.display = loading ? 'inline-flex' : 'none';
203
+ }
204
+
205
+ /* ===============================
206
+ Phone Input Initialization
207
+ =============================== */
208
+ let iti = null;
209
+ const phoneInput = document.getElementById('profile-phone');
210
+
211
+ if (phoneInput && typeof intlTelInput !== 'undefined') {
212
+ iti = intlTelInput(phoneInput, {
213
+ utilsScript: 'https://cdn.jsdelivr.net/npm/intl-tel-input@23.0.0/build/js/utils.js',
214
+ initialCountry: 'auto',
215
+ geoIpLookup: (callback) => {
216
+ fetch('https://ipapi.co/json/')
217
+ .then(res => res.json())
218
+ .then(data => callback(data.country_code ? data.country_code.toLowerCase() : 'us'))
219
+ .catch(() => callback('us'));
220
+ },
221
+ separateDialCode: true,
222
+ nationalMode: false,
223
+ dropdownContainer: document.body
224
+ });
225
+ }
226
+
227
+ /* ===============================
228
+ Profile Form Submission
229
+ =============================== */
230
+ const profileForm = document.getElementById('profile-form');
231
+
232
+ if (profileForm) {
233
+ profileForm.addEventListener('submit', async (e) => {
234
+ e.preventDefault();
235
+
236
+ const submitBtn = document.getElementById('save-profile-btn');
237
+ setButtonLoading(submitBtn, true);
238
+
239
+ const formData = new FormData(profileForm);
240
+
241
+ let phoneNumber = formData.get('phone');
242
+ if (iti) {
243
+ const fullPhone = iti.getNumber();
244
+ if (fullPhone) {
245
+ phoneNumber = fullPhone.replace(/^\+/, '');
246
+ }
168
247
  }
169
- }
170
-
171
- // Button loading utility function
172
- function setButtonLoading(button, loading, loadingText = null) {
173
- if (!button) return;
174
-
175
- const btnText = button.querySelector('.btn-text');
176
- const btnLoading = button.querySelector('.btn-loading');
177
-
178
- if (loading) {
179
- button.disabled = true;
180
- button.classList.add('loading');
181
- if (btnText) btnText.style.display = 'none';
182
- if (btnLoading) {
183
- btnLoading.style.display = 'flex';
184
- if (loadingText && btnLoading.querySelector('span:last-child')) {
185
- btnLoading.querySelector('span:last-child').textContent = loadingText;
186
- }
187
- } else if (loadingText) {
188
- button.textContent = loadingText;
248
+
249
+ const data = {
250
+ fullName: formData.get('firstName'),
251
+ email: formData.get('email'),
252
+ phoneNumber: phoneNumber
253
+ };
254
+
255
+ try {
256
+ const response = await fetch('/webstoreapi/customer/profile', {
257
+ method: 'PUT',
258
+ headers: {
259
+ 'Content-Type': 'application/json',
260
+ 'X-Requested-With': 'XMLHttpRequest'
261
+ },
262
+ body: JSON.stringify(data)
263
+ });
264
+
265
+ if (response.ok) {
266
+ window.location.reload();
267
+ } else {
268
+ const error = await response.json();
269
+ alert(error.message || 'Error updating profile');
270
+ setButtonLoading(submitBtn, false);
189
271
  }
190
- } else {
191
- button.disabled = false;
192
- button.classList.remove('loading');
193
- if (btnText) btnText.style.display = 'inline';
194
- if (btnLoading) btnLoading.style.display = 'none';
272
+ } catch (error) {
273
+ console.error('Profile update error:', error);
274
+ alert('Error updating profile. Please try again.');
275
+ setButtonLoading(submitBtn, false);
195
276
  }
277
+ });
278
+ }
279
+
280
+ /* ===============================
281
+ Account Deletion Request
282
+ =============================== */
283
+ const deleteBtn = document.getElementById('request-account-deletion-btn');
284
+ const deletionModal = document.getElementById('deletion-modal');
285
+ const deletionModalClose = document.getElementById('deletion-modal-close');
286
+ const deletionModalCancel = document.getElementById('deletion-modal-cancel');
287
+ const deletionModalConfirm = document.getElementById('deletion-modal-confirm');
288
+ const deletionReasonTextarea = document.getElementById('deletion-reason');
289
+ const deletionReasonErrEl = document.getElementById('deletion-reason-error');
290
+
291
+ // Show modal
292
+ function showDeletionModal() {
293
+ if (deletionModal) {
294
+ deletionModal.style.display = 'flex';
295
+ deletionReasonTextarea.value = '';
296
+ deletionReasonErrEl.style.display = 'none';
297
+ deletionReasonTextarea.focus();
298
+ document.body.style.overflow = 'hidden';
196
299
  }
300
+ }
197
301
 
198
- // Handle form submission
199
- const profileForm = document.getElementById('profile-form');
200
- if (profileForm) {
201
- profileForm.addEventListener('submit', async function(e) {
202
- e.preventDefault();
203
-
204
- const submitBtn = document.getElementById('save-profile-btn');
205
- setButtonLoading(submitBtn, true, 'Saving...');
206
-
207
- const formData = new FormData(this);
208
-
209
- // Get phone number from intl-tel-input if available
210
- let phoneNumber = formData.get('phone');
211
- if (window.profilePhoneIti) {
212
- const fullPhoneNumber = window.profilePhoneIti.getNumber();
213
- if (fullPhoneNumber) {
214
- // Remove leading + sign
215
- phoneNumber = fullPhoneNumber.replace(/^\+/, '');
216
- }
217
- }
218
-
219
- const data = {
220
- fullName: formData.get('firstName'),
221
- phone: phoneNumber
222
- };
223
-
302
+ // Hide modal
303
+ function hideDeletionModal() {
304
+ if (deletionModal) {
305
+ deletionModal.style.display = 'none';
306
+ document.body.style.overflow = '';
307
+ }
308
+ }
309
+
310
+ // Set confirm button loading state
311
+ function setConfirmButtonLoading(loading) {
312
+ if (!deletionModalConfirm) return;
313
+ const btnText = deletionModalConfirm.querySelector('.btn-text');
314
+ const btnLoading = deletionModalConfirm.querySelector('.btn-loading');
315
+
316
+ if (loading) {
317
+ deletionModalConfirm.disabled = true;
318
+ if (btnText) btnText.style.display = 'none';
319
+ if (btnLoading) btnLoading.style.display = 'inline-flex';
320
+ } else {
321
+ deletionModalConfirm.disabled = false;
322
+ if (btnText) btnText.style.display = '';
323
+ if (btnLoading) btnLoading.style.display = 'none';
324
+ }
325
+ }
326
+
327
+ // Submit deletion request
328
+ async function submitDeletionRequest() {
329
+ const reason = deletionReasonTextarea.value.trim();
330
+
331
+ // Validate reason is provided
332
+ if (!reason) {
333
+ deletionReasonErrEl.style.display = 'block';
334
+ deletionReasonTextarea.focus();
335
+ return;
336
+ }
337
+
338
+ deletionReasonErrEl.style.display = 'none';
339
+ setConfirmButtonLoading(true);
340
+
341
+ try {
342
+ const response = await fetch('/webstoreapi/customer/account/delete-request', {
343
+ method: 'POST',
344
+ credentials: 'same-origin',
345
+ headers: {
346
+ 'Content-Type': 'application/json',
347
+ 'X-Requested-With': 'XMLHttpRequest'
348
+ },
349
+ body: JSON.stringify({ reason: reason })
350
+ });
351
+
352
+ const responseData = await response.json();
353
+
354
+ if (response.ok) {
355
+ // Show success message from the API
356
+ const successMessage = responseData.data?.message || responseData.message || 'Account deletion request submitted successfully.';
357
+ alert(successMessage);
358
+
359
+ // Logout via API and then redirect to home as logged-out user.
224
360
  try {
225
- const response = await fetch('/webstoreapi/customer/profile', {
226
- method: 'PUT',
361
+ await fetch('/webstoreapi/customer/logout', {
362
+ method: 'POST',
363
+ credentials: 'same-origin',
227
364
  headers: {
228
- 'Content-Type': 'application/json',
365
+ 'Accept': 'application/json',
229
366
  'X-Requested-With': 'XMLHttpRequest'
230
- },
231
- body: JSON.stringify(data)
367
+ }
232
368
  });
233
-
234
- if (response.ok) {
235
- window.location.reload();
236
- } else {
237
- const error = await response.json();
238
- setButtonLoading(submitBtn, false);
239
- alert('Error updating profile: ' + (error.error || error.message || 'Unknown error'));
240
- }
241
- } catch (error) {
242
- console.error('Error updating profile:', error);
243
- setButtonLoading(submitBtn, false);
244
- alert('Error updating profile. Please try again.');
369
+ } catch (logoutError) {
370
+ console.warn('Logout after deletion failed, redirecting to home anyway:', logoutError);
245
371
  }
246
- });
372
+
373
+ window.location.replace('/');
374
+ } else {
375
+ alert(responseData.error || responseData.message || 'Error requesting account deletion');
376
+ setConfirmButtonLoading(false);
377
+ }
378
+ } catch (error) {
379
+ console.error('Account deletion error:', error);
380
+ alert('Error requesting account deletion. Please try again.');
381
+ setConfirmButtonLoading(false);
382
+ }
383
+ }
384
+
385
+ // Event listeners
386
+ if (deleteBtn) {
387
+ deleteBtn.addEventListener('click', showDeletionModal);
388
+ }
389
+
390
+ if (deletionModalClose) {
391
+ deletionModalClose.addEventListener('click', hideDeletionModal);
392
+ }
393
+
394
+ if (deletionModalCancel) {
395
+ deletionModalCancel.addEventListener('click', hideDeletionModal);
396
+ }
397
+
398
+ if (deletionModalConfirm) {
399
+ deletionModalConfirm.addEventListener('click', submitDeletionRequest);
400
+ }
401
+
402
+ // Close modal on overlay click
403
+ if (deletionModal) {
404
+ deletionModal.addEventListener('click', (e) => {
405
+ if (e.target === deletionModal) {
406
+ hideDeletionModal();
407
+ }
408
+ });
409
+ }
410
+
411
+ // Close modal on Escape key
412
+ document.addEventListener('keydown', (e) => {
413
+ if (e.key === 'Escape' && deletionModal && deletionModal.style.display === 'flex') {
414
+ hideDeletionModal();
247
415
  }
248
416
  });
417
+
418
+ // Hide error when user starts typing
419
+ if (deletionReasonTextarea) {
420
+ deletionReasonTextarea.addEventListener('input', () => {
421
+ if (deletionReasonTextarea.value.trim()) {
422
+ deletionReasonErrEl.style.display = 'none';
423
+ }
424
+ });
425
+ }
426
+
427
+ });
249
428
  </script>
250
429
 
430
+
251
431
  <style>
252
- /* Account profile page uses theme.css variables - no local :root needed */
253
- --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
254
- --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
255
- --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
256
- --radius-sm: 0.375rem;
257
- --radius-md: 0.5rem;
258
- --radius-lg: 0.75rem;
259
- --radius-xl: 1rem;
432
+ :root {
433
+ --shadow-md: var(--shadow-md);
434
+ --shadow-lg: var(--shadow-lg);
435
+ --shadow-xl: var(--shadow-xl);
436
+ --radius-sm: var(--radius-md);
437
+ --radius-md: var(--radius-lg);
438
+ --radius-lg: var(--radius-xl);
439
+ --radius-xl: var(--radius-2xl);
260
440
  --transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
441
+ --color-white: #ffffff;
261
442
  }
262
443
 
263
444
  * {
264
445
  box-sizing: border-box;
265
446
  }
266
447
 
448
+ /* ===============================
449
+ Account Deletion Modal Styles
450
+ =============================== */
451
+ .deletion-modal-overlay {
452
+ position: fixed;
453
+ inset: 0;
454
+ background: rgba(0, 0, 0, 0.6);
455
+ backdrop-filter: blur(4px);
456
+ z-index: 9999;
457
+ display: flex;
458
+ align-items: center;
459
+ justify-content: center;
460
+ padding: 1rem;
461
+ }
462
+
463
+ .deletion-modal {
464
+ background: var(--color-white, #fff);
465
+ border-radius: var(--radius-lg, 12px);
466
+ box-shadow: var(--shadow-xl, 0 25px 50px -12px rgba(0, 0, 0, 0.25));
467
+ width: 100%;
468
+ max-width: 480px;
469
+ max-height: 90vh;
470
+ overflow: hidden;
471
+ animation: modalSlideIn 0.2s ease-out;
472
+ }
473
+
474
+ @keyframes modalSlideIn {
475
+ from {
476
+ opacity: 0;
477
+ transform: scale(0.95) translateY(-10px);
478
+ }
479
+ to {
480
+ opacity: 1;
481
+ transform: scale(1) translateY(0);
482
+ }
483
+ }
484
+
485
+ .deletion-modal-header {
486
+ display: flex;
487
+ align-items: center;
488
+ justify-content: space-between;
489
+ padding: 1.25rem 1.5rem;
490
+ border-bottom: 1px solid var(--color-border, #e5e7eb);
491
+ background: linear-gradient(to right, #fef2f2, #fff);
492
+ }
493
+
494
+ .deletion-modal-title {
495
+ margin: 0;
496
+ font-size: 1.25rem;
497
+ font-weight: 600;
498
+ color: #dc2626;
499
+ }
500
+
501
+ .deletion-modal-close {
502
+ background: transparent;
503
+ border: none;
504
+ cursor: pointer;
505
+ padding: 0.5rem;
506
+ color: var(--color-text-muted, #6b7280);
507
+ border-radius: 0.375rem;
508
+ transition: background 0.2s, color 0.2s;
509
+ }
510
+
511
+ .deletion-modal-close:hover {
512
+ background: var(--color-surface-hover, #f3f4f6);
513
+ color: var(--color-text, #111827);
514
+ }
515
+
516
+ .deletion-modal-close svg {
517
+ width: 20px;
518
+ height: 20px;
519
+ }
520
+
521
+ .deletion-modal-body {
522
+ padding: 1.5rem;
523
+ }
524
+
525
+ .deletion-modal-warning {
526
+ display: flex;
527
+ align-items: flex-start;
528
+ gap: 0.75rem;
529
+ padding: 1rem;
530
+ background: #fef2f2;
531
+ border: 1px solid #fecaca;
532
+ border-radius: var(--radius-md, 8px);
533
+ color: #991b1b;
534
+ font-size: 0.875rem;
535
+ line-height: 1.5;
536
+ margin: 0 0 1.25rem 0;
537
+ }
538
+
539
+ .deletion-modal-warning-icon {
540
+ width: 20px;
541
+ height: 20px;
542
+ flex-shrink: 0;
543
+ stroke: #dc2626;
544
+ }
545
+
546
+ .deletion-modal-label {
547
+ display: block;
548
+ font-size: 0.875rem;
549
+ font-weight: 500;
550
+ color: var(--color-text, #374151);
551
+ margin-bottom: 0.5rem;
552
+ }
553
+
554
+ .deletion-modal-label .required {
555
+ color: #dc2626;
556
+ }
557
+
558
+ .deletion-modal-textarea {
559
+ width: 100%;
560
+ padding: 0.75rem 1rem;
561
+ border: 1px solid var(--color-border, #d1d5db);
562
+ border-radius: var(--radius-md, 8px);
563
+ font-size: 0.9375rem;
564
+ font-family: inherit;
565
+ resize: vertical;
566
+ min-height: 100px;
567
+ transition: border-color 0.2s, box-shadow 0.2s;
568
+ }
569
+
570
+ .deletion-modal-textarea:focus {
571
+ outline: none;
572
+ border-color: #dc2626;
573
+ box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.1);
574
+ }
575
+
576
+ .deletion-modal-textarea::placeholder {
577
+ color: var(--color-text-muted, #9ca3af);
578
+ }
579
+
580
+ .deletion-modal-error {
581
+ margin: 0.5rem 0 0 0;
582
+ font-size: 0.8125rem;
583
+ color: #dc2626;
584
+ }
585
+
586
+ .deletion-modal-footer {
587
+ display: flex;
588
+ gap: 0.75rem;
589
+ justify-content: flex-end;
590
+ padding: 1rem 1.5rem;
591
+ border-top: 1px solid var(--color-border, #e5e7eb);
592
+ background: var(--color-surface, #f9fafb);
593
+ }
594
+
595
+ .deletion-modal-footer .btn {
596
+ padding: 0.625rem 1.25rem;
597
+ font-size: 0.875rem;
598
+ font-weight: 500;
599
+ border-radius: var(--radius-md, 8px);
600
+ cursor: pointer;
601
+ transition: all 0.2s;
602
+ }
603
+
604
+ .deletion-modal-footer .btn-secondary {
605
+ background: var(--color-white, #fff);
606
+ border: 1px solid var(--color-border, #d1d5db);
607
+ color: var(--color-text, #374151);
608
+ }
609
+
610
+ .deletion-modal-footer .btn-secondary:hover {
611
+ background: var(--color-surface-hover, #f3f4f6);
612
+ }
613
+
614
+ .deletion-modal-footer .btn-danger {
615
+ background: #dc2626;
616
+ border: 1px solid #dc2626;
617
+ color: #fff;
618
+ display: inline-flex;
619
+ align-items: center;
620
+ justify-content: center;
621
+ gap: 0.5rem;
622
+ }
623
+
624
+ .deletion-modal-footer .btn-danger:hover:not(:disabled) {
625
+ background: #b91c1c;
626
+ border-color: #b91c1c;
627
+ }
628
+
629
+ .deletion-modal-footer .btn-danger:disabled {
630
+ opacity: 0.7;
631
+ cursor: not-allowed;
632
+ }
633
+
634
+ .deletion-modal-footer .btn-loading {
635
+ display: inline-flex;
636
+ align-items: center;
637
+ gap: 0.5rem;
638
+ }
639
+
640
+ .deletion-modal-footer .spinner {
641
+ width: 16px;
642
+ height: 16px;
643
+ animation: spin 1s linear infinite;
644
+ }
645
+
646
+ @keyframes spin {
647
+ from { transform: rotate(0deg); }
648
+ to { transform: rotate(360deg); }
649
+ }
650
+
651
+ @media (max-width: 480px) {
652
+ .deletion-modal-footer {
653
+ flex-direction: column-reverse;
654
+ }
655
+
656
+ .deletion-modal-footer .btn {
657
+ width: 100%;
658
+ justify-content: center;
659
+ }
660
+ }
661
+
267
662
  .account-page {
268
663
  padding: 2rem 1rem;
269
- background: linear-gradient(to bottom, var(--color-background) 0%, #ffffff 100%);
664
+ background: linear-gradient(to bottom, var(--color-background) 0%, var(--color-surface) 100%);
270
665
  min-height: 100vh;
271
666
  }
272
667
 
@@ -335,7 +730,7 @@
335
730
  align-items: center;
336
731
  gap: 1.5rem;
337
732
  padding: 2rem;
338
- background: linear-gradient(135deg, var(--color-primary-light) 0%, #ffffff 100%);
733
+ background: linear-gradient(135deg, var(--color-primary-light) 0%, var(--color-surface) 100%);
339
734
  border-bottom: 1px solid var(--color-border);
340
735
  }
341
736
 
@@ -354,7 +749,7 @@
354
749
  .avatar-icon {
355
750
  width: 45px;
356
751
  height: 45px;
357
- color: white;
752
+ color: var(--color-white);
358
753
  }
359
754
 
360
755
  .profile-header-text {
@@ -473,7 +868,7 @@
473
868
 
474
869
  .iti__country-list {
475
870
  z-index: 1000;
476
- box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
871
+ box-shadow: 0 4px 12px rgba(0, 0, 0, calc(var(--shadow-opacity, 0.1) * 1.5));
477
872
  border: 1.5px solid var(--color-border);
478
873
  border-radius: var(--radius-md);
479
874
  max-height: 200px;
@@ -567,7 +962,7 @@
567
962
 
568
963
  .btn-primary {
569
964
  background: var(--color-primary);
570
- color: white;
965
+ color: var(--color-white);
571
966
  border-color: var(--color-primary);
572
967
  }
573
968
 
@@ -595,7 +990,7 @@
595
990
 
596
991
  .btn-danger {
597
992
  background: var(--color-danger);
598
- color: white;
993
+ color: var(--color-white);
599
994
  border-color: var(--color-danger);
600
995
  }
601
996
 
@@ -755,4 +1150,4 @@
755
1150
  margin: 1rem;
756
1151
  }
757
1152
  }
758
- </style>
1153
+ </style>