CBV01 commited on
Commit
1d80adf
·
1 Parent(s): 3ab7243

feat: standardize modals to dark grey palette, add telegram simulator scroll, and add admin coupon editing

Browse files
backend/main.py CHANGED
@@ -3856,6 +3856,28 @@ async def create_coupon_admin(req: CouponCreateRequest, admin_id: str = Depends(
3856
  finally:
3857
  if hasattr(conn, "close"): conn.close()
3858
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3859
  @app.post("/api/admin/monetization/coupons/{code}/toggle")
3860
  async def toggle_coupon_admin(code: str, admin_id: str = Depends(get_current_admin)):
3861
  conn = get_db_connection()
 
3856
  finally:
3857
  if hasattr(conn, "close"): conn.close()
3858
 
3859
+ @app.put("/api/admin/monetization/coupons/{code}")
3860
+ async def update_coupon_admin(code: str, req: CouponCreateRequest, admin_id: str = Depends(get_current_admin)):
3861
+ conn = get_db_connection()
3862
+ try:
3863
+ old_code = code.strip().upper()
3864
+ new_code = req.code.strip().upper() if req.code else old_code
3865
+ target_plan = (req.target_plan or "premium").strip().lower()
3866
+ conn.execute(
3867
+ """UPDATE coupons SET
3868
+ code = ?, price = ?, target_plan = ?, duration_hours = ?,
3869
+ max_accounts = ?, max_templates = ?, max_daily_campaigns = ?,
3870
+ max_daily_keywords = ?, scrape_limit = ?
3871
+ WHERE UPPER(code) = ?""",
3872
+ (new_code, req.price, target_plan, req.duration_hours or 0, req.max_accounts, req.max_templates, req.max_daily_campaigns, req.max_daily_keywords, req.scrape_limit, old_code)
3873
+ )
3874
+ if hasattr(conn, "commit"): conn.commit()
3875
+ return {"status": "success", "code": new_code}
3876
+ except Exception as e:
3877
+ raise HTTPException(status_code=400, detail=str(e))
3878
+ finally:
3879
+ if hasattr(conn, "close"): conn.close()
3880
+
3881
  @app.post("/api/admin/monetization/coupons/{code}/toggle")
3882
  async def toggle_coupon_admin(code: str, admin_id: str = Depends(get_current_admin)):
3883
  conn = get_db_connection()
frontend/src/app/admin/page.tsx CHANGED
@@ -11,6 +11,7 @@ import {
11
  Pause,
12
  Play,
13
  Trash2,
 
14
  Database,
15
  Search,
16
  X,
@@ -86,6 +87,7 @@ export default function AdminDashboard() {
86
  max_daily_keywords: '',
87
  scrape_limit: ''
88
  });
 
89
  const [dbHealth, setDbHealth] = useState<any>(null);
90
  const [dbOptimizing, setDbOptimizing] = useState(false);
91
  const [editingPlan, setEditingPlan] = useState<any>(null);
@@ -2123,8 +2125,21 @@ export default function AdminDashboard() {
2123
  <Ticket size={18} />
2124
  </div>
2125
  <div>
2126
- <h3 className="font-bold text-base text-foreground">Create Coupon & Access Vouchers</h3>
2127
- <p className="text-[11px] text-foreground/45 mt-0.5">Generate customized promotional or automatic plan activation codes</p>
 
 
 
 
 
 
 
 
 
 
 
 
 
2128
  </div>
2129
  </div>
2130
  <span className="text-[10px] font-mono px-2.5 py-0.5 rounded-full bg-indigo-500/10 text-indigo-400 border border-indigo-500/20 font-bold self-start sm:self-auto">
@@ -2235,36 +2250,65 @@ export default function AdminDashboard() {
2235
  </div>
2236
  </div>
2237
 
2238
- <button
2239
- onClick={async () => {
2240
- if (!newCoupon.code) return;
2241
- const res = await apiFetch('/api/admin/monetization/coupons', {
2242
- method: 'POST',
2243
- body: JSON.stringify(newCoupon)
2244
- });
2245
- if (res.ok) {
2246
- setSuccessMsg(`Coupon ${newCoupon.code} generated successfully.`);
2247
- setNewCoupon({
2248
- code: '',
2249
- price: 0,
2250
- target_plan: 'premium',
2251
- duration_hours: 0,
2252
- max_accounts: '',
2253
- max_templates: '',
2254
- max_daily_campaigns: '',
2255
- max_daily_keywords: '',
2256
- scrape_limit: ''
2257
  });
2258
- fetchMonetizationData();
2259
- } else {
2260
- const err = await res.json().catch(() => ({}));
2261
- setErrorMsg(err.detail || "Failed to create coupon");
2262
- }
2263
- }}
2264
- className="w-full py-2 bg-indigo-500 hover:bg-indigo-400 text-white font-bold rounded-lg transition-all shadow-md text-xs uppercase tracking-wider cursor-pointer active:scale-95"
2265
- >
2266
- Issue Access Coupon
2267
- </button>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2268
  </div>
2269
 
2270
  {/* Right: Active Coupon Keys Stream (4 Cols) */}
@@ -2275,7 +2319,7 @@ export default function AdminDashboard() {
2275
  </h4>
2276
  <div className="space-y-1.5 max-h-48 overflow-y-auto custom-scrollbar pr-1">
2277
  {coupons.map((c) => (
2278
- <div key={c.id || c.code} className="p-2 bg-white/5 rounded-lg border border-white/5 text-xs space-y-1">
2279
  <div className="flex items-center justify-between">
2280
  <div className="flex items-center gap-1.5">
2281
  <span className="font-mono font-bold text-indigo-400 text-xs">{c.code}</span>
@@ -2289,6 +2333,26 @@ export default function AdminDashboard() {
2289
  )}
2290
  </div>
2291
  <div className="flex items-center gap-1">
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2292
  <button
2293
  onClick={async () => {
2294
  await apiFetch(`/api/admin/monetization/coupons/${c.code}/toggle`, { method: 'POST' });
 
11
  Pause,
12
  Play,
13
  Trash2,
14
+ Edit3,
15
  Database,
16
  Search,
17
  X,
 
87
  max_daily_keywords: '',
88
  scrape_limit: ''
89
  });
90
+ const [editingCouponCode, setEditingCouponCode] = useState<string | null>(null);
91
  const [dbHealth, setDbHealth] = useState<any>(null);
92
  const [dbOptimizing, setDbOptimizing] = useState(false);
93
  const [editingPlan, setEditingPlan] = useState<any>(null);
 
2125
  <Ticket size={18} />
2126
  </div>
2127
  <div>
2128
+ <h3 className="font-bold text-base text-foreground">
2129
+ {editingCouponCode ? (
2130
+ <span className="flex items-center gap-2">
2131
+ <span>Edit Coupon:</span>
2132
+ <span className="font-mono text-indigo-400">{editingCouponCode}</span>
2133
+ </span>
2134
+ ) : (
2135
+ 'Create Coupon & Access Vouchers'
2136
+ )}
2137
+ </h3>
2138
+ <p className="text-[11px] text-foreground/45 mt-0.5">
2139
+ {editingCouponCode
2140
+ ? 'Modify limits, pricing, duration or rename coupon code'
2141
+ : 'Generate customized promotional or automatic plan activation codes'}
2142
+ </p>
2143
  </div>
2144
  </div>
2145
  <span className="text-[10px] font-mono px-2.5 py-0.5 rounded-full bg-indigo-500/10 text-indigo-400 border border-indigo-500/20 font-bold self-start sm:self-auto">
 
2250
  </div>
2251
  </div>
2252
 
2253
+ <div className="flex gap-2">
2254
+ <button
2255
+ onClick={async () => {
2256
+ if (!newCoupon.code) return;
2257
+ const url = editingCouponCode
2258
+ ? `/api/admin/monetization/coupons/${editingCouponCode}`
2259
+ : '/api/admin/monetization/coupons';
2260
+ const method = editingCouponCode ? 'PUT' : 'POST';
2261
+ const res = await apiFetch(url, {
2262
+ method,
2263
+ body: JSON.stringify(newCoupon)
 
 
 
 
 
 
 
 
2264
  });
2265
+ if (res.ok) {
2266
+ setSuccessMsg(editingCouponCode ? `Coupon ${newCoupon.code} updated successfully.` : `Coupon ${newCoupon.code} generated successfully.`);
2267
+ setEditingCouponCode(null);
2268
+ setNewCoupon({
2269
+ code: '',
2270
+ price: 0,
2271
+ target_plan: 'premium',
2272
+ duration_hours: 0,
2273
+ max_accounts: '',
2274
+ max_templates: '',
2275
+ max_daily_campaigns: '',
2276
+ max_daily_keywords: '',
2277
+ scrape_limit: ''
2278
+ });
2279
+ fetchMonetizationData();
2280
+ } else {
2281
+ const err = await res.json().catch(() => ({}));
2282
+ setErrorMsg(err.detail || (editingCouponCode ? "Failed to update coupon" : "Failed to create coupon"));
2283
+ }
2284
+ }}
2285
+ className="flex-1 py-2 bg-indigo-500 hover:bg-indigo-400 text-white font-bold rounded-lg transition-all shadow-md text-xs uppercase tracking-wider cursor-pointer active:scale-95"
2286
+ >
2287
+ {editingCouponCode ? "Save Coupon Changes" : "Issue Access Coupon"}
2288
+ </button>
2289
+ {editingCouponCode && (
2290
+ <button
2291
+ type="button"
2292
+ onClick={() => {
2293
+ setEditingCouponCode(null);
2294
+ setNewCoupon({
2295
+ code: '',
2296
+ price: 0,
2297
+ target_plan: 'premium',
2298
+ duration_hours: 0,
2299
+ max_accounts: '',
2300
+ max_templates: '',
2301
+ max_daily_campaigns: '',
2302
+ max_daily_keywords: '',
2303
+ scrape_limit: ''
2304
+ });
2305
+ }}
2306
+ className="px-3 py-2 bg-white/10 hover:bg-white/20 text-foreground font-bold rounded-lg transition-all text-xs cursor-pointer"
2307
+ >
2308
+ Cancel
2309
+ </button>
2310
+ )}
2311
+ </div>
2312
  </div>
2313
 
2314
  {/* Right: Active Coupon Keys Stream (4 Cols) */}
 
2319
  </h4>
2320
  <div className="space-y-1.5 max-h-48 overflow-y-auto custom-scrollbar pr-1">
2321
  {coupons.map((c) => (
2322
+ <div key={c.id || c.code} className={`p-2 rounded-lg border text-xs space-y-1 transition-all ${editingCouponCode === c.code ? 'bg-indigo-500/10 border-indigo-500/40' : 'bg-white/5 border-white/5'}`}>
2323
  <div className="flex items-center justify-between">
2324
  <div className="flex items-center gap-1.5">
2325
  <span className="font-mono font-bold text-indigo-400 text-xs">{c.code}</span>
 
2333
  )}
2334
  </div>
2335
  <div className="flex items-center gap-1">
2336
+ <button
2337
+ onClick={() => {
2338
+ setEditingCouponCode(c.code);
2339
+ setNewCoupon({
2340
+ code: c.code || '',
2341
+ price: c.price || 0,
2342
+ target_plan: c.target_plan || 'premium',
2343
+ duration_hours: c.duration_hours || 0,
2344
+ max_accounts: c.max_accounts ?? '',
2345
+ max_templates: c.max_templates ?? '',
2346
+ max_daily_campaigns: c.max_daily_campaigns ?? '',
2347
+ max_daily_keywords: c.max_daily_keywords ?? '',
2348
+ scrape_limit: c.scrape_limit ?? ''
2349
+ });
2350
+ }}
2351
+ className="p-1 hover:bg-indigo-500/15 text-foreground/50 hover:text-indigo-400 rounded transition-all cursor-pointer"
2352
+ title="Edit Coupon"
2353
+ >
2354
+ <Edit3 size={12} />
2355
+ </button>
2356
  <button
2357
  onClick={async () => {
2358
  await apiFetch(`/api/admin/monetization/coupons/${c.code}/toggle`, { method: 'POST' });
frontend/src/app/get-started/page.tsx CHANGED
@@ -247,7 +247,7 @@ export default function GetStartedPage() {
247
  const progressPercent = Math.round((step / totalSteps) * 100);
248
 
249
  return (
250
- <div className="h-screen max-h-screen overflow-hidden bg-[#07090E] text-white selection:bg-indigo-500/30 font-sans flex flex-col justify-between">
251
 
252
  {/* Top Navbar */}
253
  <header className="w-full px-5 sm:px-8 py-3.5 flex items-center justify-between border-b border-border/60 shrink-0">
@@ -257,14 +257,14 @@ export default function GetStartedPage() {
257
  <path strokeLinecap="round" strokeLinejoin="round" strokeWidth={2.5} d="M12 19l9 2-9-18-9 18 9-2zm0 0v-8" />
258
  </svg>
259
  </div>
260
- <span className="text-xs font-black tracking-wider text-white">ARKITEL</span>
261
  </Link>
262
 
263
  {/* Step Progress & Sign-in Link */}
264
  <div className="flex items-center gap-4">
265
  <div className="flex items-center gap-2">
266
- <span className="text-[11px] font-mono text-white/40">Step {step}/{totalSteps}</span>
267
- <div className="w-20 sm:w-28 h-1 bg-white/10 rounded-full overflow-hidden">
268
  <div
269
  className="h-full bg-indigo-500 transition-all duration-300"
270
  style={{ width: `${progressPercent}%` }}
@@ -283,7 +283,8 @@ export default function GetStartedPage() {
283
 
284
  {/* Success View */}
285
  {isSuccess ? (
286
- <div className="p-6 sm:p-8 rounded-2xl bg-[#0B0F1C] border border-emerald-500/40 text-center space-y-4 animate-in zoom-in-95 duration-300">
 
287
  <div className="w-12 h-12 rounded-2xl bg-emerald-500/10 border border-emerald-500/20 text-emerald-400 flex items-center justify-center mx-auto">
288
  <CheckCircle2 size={28} />
289
  </div>
@@ -292,18 +293,18 @@ export default function GetStartedPage() {
292
  <span className="px-2.5 py-0.5 rounded-full bg-emerald-500/10 text-emerald-300 text-[10px] font-black uppercase tracking-wider">
293
  MEMBERSHIP ACTIVE
294
  </span>
295
- <h2 className="text-xl sm:text-2xl font-bold text-white mt-2">
296
  Welcome to ArkiTel, {fullName || username}!
297
  </h2>
298
- <p className="text-xs text-white/60 mt-1">
299
  Your Free Starter Plan is ready. We&apos;ve sent your welcome email with coupon details.
300
  </p>
301
  </div>
302
 
303
  {/* Coupon Gift Box */}
304
- <div className="p-3 rounded-xl bg-white/[0.02] border border-dashed border-emerald-500/40 text-center space-y-0.5">
305
  <div className="text-[9px] uppercase font-bold text-emerald-400">Exclusive 20% Upgrade Coupon</div>
306
- <div className="text-xl font-mono font-black text-white tracking-widest">{assignedCoupon}</div>
307
  </div>
308
 
309
  <div className="flex items-center justify-center gap-2 text-xs font-mono text-indigo-400 animate-pulse pt-1">
@@ -312,7 +313,8 @@ export default function GetStartedPage() {
312
  </div>
313
  </div>
314
  ) : (
315
- <div className="p-5 sm:p-7 rounded-2xl bg-[#0B0F1C] border border-border/80 shadow-2xl relative space-y-5">
 
316
 
317
  {error && (
318
  <div className="p-2.5 rounded-xl bg-rose-500/10 border border-rose-500/20 text-rose-300 text-xs text-center animate-in fade-in">
@@ -327,10 +329,10 @@ export default function GetStartedPage() {
327
  <span className="text-[10px] font-bold text-indigo-400 uppercase tracking-widest">
328
  Step 1 of 6
329
  </span>
330
- <h2 className="text-xl font-bold text-white mt-1">
331
  What is your full name?
332
  </h2>
333
- <p className="text-xs text-white/50 mt-0.5">
334
  Personalize your ArkiTel fleet workspace.
335
  </p>
336
  </div>
@@ -342,7 +344,7 @@ export default function GetStartedPage() {
342
  onChange={(e) => setFullName(e.target.value)}
343
  onKeyDown={handleKeyDown}
344
  placeholder="e.g. Alexander Vance"
345
- className="w-full bg-[#121626] border border-border/80 focus:border-indigo-500 rounded-xl px-4 py-3 text-sm text-white placeholder:text-white/20 outline-none transition-all font-medium"
346
  />
347
  </div>
348
  )}
@@ -354,20 +356,20 @@ export default function GetStartedPage() {
354
  <span className="text-[10px] font-bold text-indigo-400 uppercase tracking-widest">
355
  Step 2 of 6
356
  </span>
357
- <h2 className="text-xl font-bold text-white mt-1">
358
  Upload your profile photo
359
  </h2>
360
- <p className="text-xs text-white/50 mt-0.5">
361
  Optional — you can add or change it later in settings.
362
  </p>
363
  </div>
364
 
365
- <div className="flex items-center gap-4 p-4 rounded-xl bg-[#121626] border border-border/70">
366
  <div className="relative w-16 h-16 rounded-full overflow-hidden bg-indigo-600/30 border border-indigo-500/40 flex items-center justify-center shrink-0">
367
  {profilePreview ? (
368
  <img src={profilePreview} alt="Preview" className="w-full h-full object-cover" />
369
  ) : (
370
- <User size={26} className="text-white/50" />
371
  )}
372
  {isUploadingPhoto && (
373
  <div className="absolute inset-0 bg-black/60 flex items-center justify-center">
@@ -387,7 +389,7 @@ export default function GetStartedPage() {
387
  className="hidden"
388
  />
389
  </label>
390
- <p className="text-[10px] text-white/40">PNG, JPG or WebP (max 5MB)</p>
391
  </div>
392
  </div>
393
  </div>
@@ -400,7 +402,7 @@ export default function GetStartedPage() {
400
  <span className="text-[10px] font-bold text-indigo-400 uppercase tracking-widest">
401
  Step 3 of 6
402
  </span>
403
- <h2 className="text-xl font-bold text-white mt-1">
404
  What is your business type?
405
  </h2>
406
  </div>
@@ -415,8 +417,8 @@ export default function GetStartedPage() {
415
  onClick={() => setBusinessType(b.id)}
416
  className={`p-2.5 rounded-xl border text-left text-xs transition-all flex items-center gap-2 cursor-pointer ${
417
  isSelected
418
- ? "bg-indigo-500/15 border-indigo-500 text-white font-bold"
419
- : "bg-[#121626] border-border/70 text-white/70 hover:text-white hover:border-border"
420
  }`}
421
  >
422
  <span className="text-sm shrink-0">{b.icon}</span>
@@ -435,7 +437,7 @@ export default function GetStartedPage() {
435
  <span className="text-[10px] font-bold text-indigo-400 uppercase tracking-widest">
436
  Step 4 of 6
437
  </span>
438
- <h2 className="text-xl font-bold text-white mt-1">
439
  What is your primary goal?
440
  </h2>
441
  </div>
@@ -450,15 +452,15 @@ export default function GetStartedPage() {
450
  onClick={() => setPlatformGoal(g.id)}
451
  className={`p-3 rounded-xl border text-left transition-all cursor-pointer ${
452
  isSelected
453
- ? "bg-indigo-500/15 border-indigo-500 text-white"
454
- : "bg-[#121626] border-border/70 text-white/70 hover:text-white"
455
  }`}
456
  >
457
  <div className="flex items-center gap-2">
458
  <span>{g.icon}</span>
459
- <span className="text-xs font-bold text-white truncate">{g.title}</span>
460
  </div>
461
- <p className="text-[10px] text-white/50 mt-1 line-clamp-2 leading-relaxed">
462
  {g.desc}
463
  </p>
464
  </button>
@@ -475,7 +477,7 @@ export default function GetStartedPage() {
475
  <span className="text-[10px] font-bold text-indigo-400 uppercase tracking-widest">
476
  Step 5 of 6
477
  </span>
478
- <h2 className="text-xl font-bold text-white mt-1">
479
  Where did you hear about us?
480
  </h2>
481
  </div>
@@ -490,8 +492,8 @@ export default function GetStartedPage() {
490
  onClick={() => setHeardAbout(s.id)}
491
  className={`p-2.5 rounded-xl border text-left text-xs transition-all cursor-pointer ${
492
  isSelected
493
- ? "bg-indigo-500/15 border-indigo-500 text-white font-bold"
494
- : "bg-[#121626] border-border/70 text-white/70 hover:text-white"
495
  }`}
496
  >
497
  {s.label}
@@ -509,7 +511,7 @@ export default function GetStartedPage() {
509
  <span className="text-[10px] font-bold text-indigo-400 uppercase tracking-widest">
510
  Step 6 of 6 • Create Account
511
  </span>
512
- <h2 className="text-xl font-bold text-white mt-0.5">
513
  Set up your credentials
514
  </h2>
515
  </div>
@@ -521,7 +523,7 @@ export default function GetStartedPage() {
521
  onChange={(e) => setEmail(e.target.value)}
522
  placeholder="Work Email Address"
523
  required
524
- className="w-full bg-[#121626] border border-border/80 focus:border-indigo-500 rounded-xl px-3.5 py-2.5 text-xs text-white placeholder:text-white/25 outline-none"
525
  />
526
 
527
  <div className="grid grid-cols-2 gap-2">
@@ -530,16 +532,16 @@ export default function GetStartedPage() {
530
  value={username}
531
  onChange={(e) => setUsername(e.target.value)}
532
  placeholder="Username"
533
- className="w-full bg-[#121626] border border-border/80 focus:border-indigo-500 rounded-xl px-3.5 py-2.5 text-xs text-white placeholder:text-white/25 outline-none"
534
  />
535
 
536
  <select
537
  value={country}
538
  onChange={(e) => setCountry(e.target.value)}
539
- className="w-full bg-[#121626] border border-border/80 focus:border-indigo-500 rounded-xl px-3 py-2.5 text-xs text-white outline-none"
540
  >
541
  {COUNTRIES.map(c => (
542
- <option key={c.code} value={c.name} className="bg-[#121626] text-white">
543
  {c.name}
544
  </option>
545
  ))}
@@ -553,12 +555,12 @@ export default function GetStartedPage() {
553
  onChange={(e) => setPassword(e.target.value)}
554
  placeholder="Create Password (min 6 chars)"
555
  required
556
- className="w-full bg-[#121626] border border-border/80 focus:border-indigo-500 rounded-xl px-3.5 py-2.5 pr-9 text-xs text-white placeholder:text-white/25 outline-none"
557
  />
558
  <button
559
  type="button"
560
  onClick={() => setShowPassword(!showPassword)}
561
- className="absolute right-3 top-1/2 -translate-y-1/2 text-white/40 hover:text-white"
562
  >
563
  {showPassword ? <EyeOff size={14} /> : <Eye size={14} />}
564
  </button>
@@ -592,7 +594,7 @@ export default function GetStartedPage() {
592
  <button
593
  type="button"
594
  onClick={handleBack}
595
- className="px-3 py-1.5 rounded-lg text-xs font-semibold text-white/60 hover:text-white hover:bg-white/5 transition-all flex items-center gap-1 cursor-pointer"
596
  >
597
  <ArrowLeft size={13} />
598
  <span>Back</span>
 
247
  const progressPercent = Math.round((step / totalSteps) * 100);
248
 
249
  return (
250
+ <div className="h-screen max-h-screen overflow-hidden bg-background text-foreground selection:bg-indigo-500/30 font-sans flex flex-col justify-between">
251
 
252
  {/* Top Navbar */}
253
  <header className="w-full px-5 sm:px-8 py-3.5 flex items-center justify-between border-b border-border/60 shrink-0">
 
257
  <path strokeLinecap="round" strokeLinejoin="round" strokeWidth={2.5} d="M12 19l9 2-9-18-9 18 9-2zm0 0v-8" />
258
  </svg>
259
  </div>
260
+ <span className="text-xs font-black tracking-wider text-foreground">ARKITEL</span>
261
  </Link>
262
 
263
  {/* Step Progress & Sign-in Link */}
264
  <div className="flex items-center gap-4">
265
  <div className="flex items-center gap-2">
266
+ <span className="text-[11px] font-mono text-foreground/40">Step {step}/{totalSteps}</span>
267
+ <div className="w-20 sm:w-28 h-1 bg-foreground/10 rounded-full overflow-hidden">
268
  <div
269
  className="h-full bg-indigo-500 transition-all duration-300"
270
  style={{ width: `${progressPercent}%` }}
 
283
 
284
  {/* Success View */}
285
  {isSuccess ? (
286
+ <div className="p-6 sm:p-8 rounded-2xl bg-card border border-emerald-500/40 text-center space-y-4 shadow-2xl relative overflow-hidden animate-in zoom-in-95 duration-300">
287
+ <div className="absolute top-0 left-1/2 -translate-x-1/2 w-1/2 h-[2px] bg-gradient-to-r from-transparent via-emerald-500 to-transparent"></div>
288
  <div className="w-12 h-12 rounded-2xl bg-emerald-500/10 border border-emerald-500/20 text-emerald-400 flex items-center justify-center mx-auto">
289
  <CheckCircle2 size={28} />
290
  </div>
 
293
  <span className="px-2.5 py-0.5 rounded-full bg-emerald-500/10 text-emerald-300 text-[10px] font-black uppercase tracking-wider">
294
  MEMBERSHIP ACTIVE
295
  </span>
296
+ <h2 className="text-xl sm:text-2xl font-bold text-foreground mt-2">
297
  Welcome to ArkiTel, {fullName || username}!
298
  </h2>
299
+ <p className="text-xs text-foreground/60 mt-1">
300
  Your Free Starter Plan is ready. We&apos;ve sent your welcome email with coupon details.
301
  </p>
302
  </div>
303
 
304
  {/* Coupon Gift Box */}
305
+ <div className="p-3 rounded-xl bg-input/40 border border-dashed border-emerald-500/40 text-center space-y-0.5">
306
  <div className="text-[9px] uppercase font-bold text-emerald-400">Exclusive 20% Upgrade Coupon</div>
307
+ <div className="text-xl font-mono font-black text-foreground tracking-widest">{assignedCoupon}</div>
308
  </div>
309
 
310
  <div className="flex items-center justify-center gap-2 text-xs font-mono text-indigo-400 animate-pulse pt-1">
 
313
  </div>
314
  </div>
315
  ) : (
316
+ <div className="p-5 sm:p-7 rounded-2xl bg-card border border-border/80 shadow-2xl relative space-y-5 overflow-hidden">
317
+ <div className="absolute top-0 left-1/2 -translate-x-1/2 w-1/2 h-[2px] bg-gradient-to-r from-transparent via-indigo-500 to-transparent"></div>
318
 
319
  {error && (
320
  <div className="p-2.5 rounded-xl bg-rose-500/10 border border-rose-500/20 text-rose-300 text-xs text-center animate-in fade-in">
 
329
  <span className="text-[10px] font-bold text-indigo-400 uppercase tracking-widest">
330
  Step 1 of 6
331
  </span>
332
+ <h2 className="text-xl font-bold text-foreground mt-1">
333
  What is your full name?
334
  </h2>
335
+ <p className="text-xs text-foreground/50 mt-0.5">
336
  Personalize your ArkiTel fleet workspace.
337
  </p>
338
  </div>
 
344
  onChange={(e) => setFullName(e.target.value)}
345
  onKeyDown={handleKeyDown}
346
  placeholder="e.g. Alexander Vance"
347
+ className="w-full bg-input border border-border/70 focus:border-indigo-500 rounded-xl px-4 py-3 text-sm text-foreground placeholder:text-foreground/30 outline-none transition-all font-medium"
348
  />
349
  </div>
350
  )}
 
356
  <span className="text-[10px] font-bold text-indigo-400 uppercase tracking-widest">
357
  Step 2 of 6
358
  </span>
359
+ <h2 className="text-xl font-bold text-foreground mt-1">
360
  Upload your profile photo
361
  </h2>
362
+ <p className="text-xs text-foreground/50 mt-0.5">
363
  Optional — you can add or change it later in settings.
364
  </p>
365
  </div>
366
 
367
+ <div className="flex items-center gap-4 p-4 rounded-xl bg-input/40 border border-border/70">
368
  <div className="relative w-16 h-16 rounded-full overflow-hidden bg-indigo-600/30 border border-indigo-500/40 flex items-center justify-center shrink-0">
369
  {profilePreview ? (
370
  <img src={profilePreview} alt="Preview" className="w-full h-full object-cover" />
371
  ) : (
372
+ <User size={26} className="text-foreground/50" />
373
  )}
374
  {isUploadingPhoto && (
375
  <div className="absolute inset-0 bg-black/60 flex items-center justify-center">
 
389
  className="hidden"
390
  />
391
  </label>
392
+ <p className="text-[10px] text-foreground/40">PNG, JPG or WebP (max 5MB)</p>
393
  </div>
394
  </div>
395
  </div>
 
402
  <span className="text-[10px] font-bold text-indigo-400 uppercase tracking-widest">
403
  Step 3 of 6
404
  </span>
405
+ <h2 className="text-xl font-bold text-foreground mt-1">
406
  What is your business type?
407
  </h2>
408
  </div>
 
417
  onClick={() => setBusinessType(b.id)}
418
  className={`p-2.5 rounded-xl border text-left text-xs transition-all flex items-center gap-2 cursor-pointer ${
419
  isSelected
420
+ ? "bg-indigo-500/15 border-indigo-500 text-foreground font-bold"
421
+ : "bg-input/50 border-border/70 text-foreground/70 hover:text-foreground hover:bg-input/80 hover:border-border"
422
  }`}
423
  >
424
  <span className="text-sm shrink-0">{b.icon}</span>
 
437
  <span className="text-[10px] font-bold text-indigo-400 uppercase tracking-widest">
438
  Step 4 of 6
439
  </span>
440
+ <h2 className="text-xl font-bold text-foreground mt-1">
441
  What is your primary goal?
442
  </h2>
443
  </div>
 
452
  onClick={() => setPlatformGoal(g.id)}
453
  className={`p-3 rounded-xl border text-left transition-all cursor-pointer ${
454
  isSelected
455
+ ? "bg-indigo-500/15 border-indigo-500 text-foreground"
456
+ : "bg-input/50 border-border/70 text-foreground/70 hover:text-foreground hover:bg-input/80"
457
  }`}
458
  >
459
  <div className="flex items-center gap-2">
460
  <span>{g.icon}</span>
461
+ <span className="text-xs font-bold text-foreground truncate">{g.title}</span>
462
  </div>
463
+ <p className="text-[10px] text-foreground/50 mt-1 line-clamp-2 leading-relaxed">
464
  {g.desc}
465
  </p>
466
  </button>
 
477
  <span className="text-[10px] font-bold text-indigo-400 uppercase tracking-widest">
478
  Step 5 of 6
479
  </span>
480
+ <h2 className="text-xl font-bold text-foreground mt-1">
481
  Where did you hear about us?
482
  </h2>
483
  </div>
 
492
  onClick={() => setHeardAbout(s.id)}
493
  className={`p-2.5 rounded-xl border text-left text-xs transition-all cursor-pointer ${
494
  isSelected
495
+ ? "bg-indigo-500/15 border-indigo-500 text-foreground font-bold"
496
+ : "bg-input/50 border-border/70 text-foreground/70 hover:text-foreground hover:bg-input/80"
497
  }`}
498
  >
499
  {s.label}
 
511
  <span className="text-[10px] font-bold text-indigo-400 uppercase tracking-widest">
512
  Step 6 of 6 • Create Account
513
  </span>
514
+ <h2 className="text-xl font-bold text-foreground mt-0.5">
515
  Set up your credentials
516
  </h2>
517
  </div>
 
523
  onChange={(e) => setEmail(e.target.value)}
524
  placeholder="Work Email Address"
525
  required
526
+ className="w-full bg-input border border-border/70 focus:border-indigo-500 rounded-xl px-3.5 py-2.5 text-xs text-foreground placeholder:text-foreground/30 outline-none"
527
  />
528
 
529
  <div className="grid grid-cols-2 gap-2">
 
532
  value={username}
533
  onChange={(e) => setUsername(e.target.value)}
534
  placeholder="Username"
535
+ className="w-full bg-input border border-border/70 focus:border-indigo-500 rounded-xl px-3.5 py-2.5 text-xs text-foreground placeholder:text-foreground/30 outline-none"
536
  />
537
 
538
  <select
539
  value={country}
540
  onChange={(e) => setCountry(e.target.value)}
541
+ className="w-full bg-input border border-border/70 focus:border-indigo-500 rounded-xl px-3 py-2.5 text-xs text-foreground outline-none"
542
  >
543
  {COUNTRIES.map(c => (
544
+ <option key={c.code} value={c.name} className="bg-card text-foreground">
545
  {c.name}
546
  </option>
547
  ))}
 
555
  onChange={(e) => setPassword(e.target.value)}
556
  placeholder="Create Password (min 6 chars)"
557
  required
558
+ className="w-full bg-input border border-border/70 focus:border-indigo-500 rounded-xl px-3.5 py-2.5 pr-9 text-xs text-foreground placeholder:text-foreground/30 outline-none"
559
  />
560
  <button
561
  type="button"
562
  onClick={() => setShowPassword(!showPassword)}
563
+ className="absolute right-3 top-1/2 -translate-y-1/2 text-foreground/40 hover:text-foreground"
564
  >
565
  {showPassword ? <EyeOff size={14} /> : <Eye size={14} />}
566
  </button>
 
594
  <button
595
  type="button"
596
  onClick={handleBack}
597
+ className="px-3 py-1.5 rounded-lg text-xs font-semibold text-foreground/60 hover:text-foreground hover:bg-foreground/5 transition-all flex items-center gap-1 cursor-pointer"
598
  >
599
  <ArrowLeft size={13} />
600
  <span>Back</span>
frontend/src/components/Header.tsx CHANGED
@@ -215,13 +215,14 @@ export function Header({ user, status, onOpenSupport, onOpenEntitlements }: Head
215
 
216
  {/* Notifications Dropdown Panel */}
217
  {isNotificationsOpen && (
218
- <div className="absolute right-0 mt-2 w-80 sm:w-96 rounded-2xl bg-[#0B0F1C] border border-border/80 p-4 shadow-2xl text-foreground z-50 animate-in fade-in zoom-in-95 duration-150">
 
219
  <div className="flex items-center justify-between pb-3 border-b border-border/60 mb-2">
220
  <div className="flex items-center gap-2">
221
  <div className="p-1 rounded-lg bg-indigo-500/10 text-indigo-400">
222
  <Bell size={14} />
223
  </div>
224
- <span className="text-xs font-bold text-white">Notifications</span>
225
  {unreadCount > 0 && (
226
  <span className="px-1.5 py-0.2 rounded-full bg-indigo-500/20 text-indigo-300 text-[10px] font-bold">
227
  {unreadCount} new
@@ -250,8 +251,8 @@ export function Header({ user, status, onOpenSupport, onOpenEntitlements }: Head
250
  key={notif.id}
251
  className={`p-3 rounded-xl border transition-all ${
252
  notif.read
253
- ? 'bg-white/[0.02] border-white/5 opacity-70'
254
- : 'bg-white/[0.05] border-indigo-500/20 shadow-xs'
255
  }`}
256
  >
257
  <div className="flex items-start justify-between gap-2">
@@ -263,7 +264,7 @@ export function Header({ user, status, onOpenSupport, onOpenEntitlements }: Head
263
  ) : (
264
  <Info size={14} className="text-indigo-400 shrink-0 mt-0.5" />
265
  )}
266
- <h4 className="text-xs font-bold text-white leading-tight">
267
  {notif.title}
268
  </h4>
269
  </div>
@@ -321,7 +322,8 @@ export function Header({ user, status, onOpenSupport, onOpenEntitlements }: Head
321
 
322
  {/* Profile Dropdown Menu */}
323
  {isProfileOpen && (
324
- <div className="absolute right-0 mt-2 w-72 rounded-2xl bg-[#0B0F1C] border border-border/80 p-4 shadow-2xl text-foreground z-50 animate-in fade-in zoom-in-95 duration-150 space-y-3.5">
 
325
 
326
  {/* User Identity Header Card */}
327
  <div className="flex items-center gap-3 pb-3 border-b border-border/60">
@@ -337,7 +339,7 @@ export function Header({ user, status, onOpenSupport, onOpenEntitlements }: Head
337
  )}
338
  </div>
339
  <div className="min-w-0 flex-1">
340
- <h3 className="text-xs font-bold text-white truncate">
341
  {user?.full_name || user?.username}
342
  </h3>
343
  <p className="text-[10px] text-indigo-400 font-mono truncate">
@@ -350,7 +352,7 @@ export function Header({ user, status, onOpenSupport, onOpenEntitlements }: Head
350
  </div>
351
 
352
  {/* Plan Status Pill */}
353
- <div className="p-2.5 rounded-xl bg-white/[0.03] border border-white/5 flex items-center justify-between">
354
  <div>
355
  <div className="text-[9px] font-bold text-foreground/40 uppercase tracking-wider">Current Membership</div>
356
  <div className="text-xs font-black text-indigo-400 flex items-center gap-1 mt-0.5">
@@ -381,7 +383,7 @@ export function Header({ user, status, onOpenSupport, onOpenEntitlements }: Head
381
  if (onOpenEntitlements) onOpenEntitlements();
382
  else window.dispatchEvent(new Event('open-entitlements-modal'));
383
  }}
384
- className="w-full flex items-center gap-2.5 px-3 py-2 rounded-xl text-foreground/70 hover:text-white hover:bg-white/[0.06] transition-colors cursor-pointer text-left"
385
  >
386
  <Sparkles size={14} className="text-indigo-400" />
387
  <span>View Plan Entitlements</span>
@@ -393,7 +395,7 @@ export function Header({ user, status, onOpenSupport, onOpenEntitlements }: Head
393
  setIsProfileOpen(false);
394
  if (onOpenSupport) onOpenSupport();
395
  }}
396
- className="w-full flex items-center gap-2.5 px-3 py-2 rounded-xl text-foreground/70 hover:text-white hover:bg-white/[0.06] transition-colors cursor-pointer text-left"
397
  >
398
  <HelpCircle size={14} className="text-foreground/40" />
399
  <span>Support Desk</span>
@@ -403,7 +405,7 @@ export function Header({ user, status, onOpenSupport, onOpenEntitlements }: Head
403
  <Link
404
  href="/admin"
405
  onClick={() => setIsProfileOpen(false)}
406
- className="w-full flex items-center gap-2.5 px-3 py-2 rounded-xl text-foreground/70 hover:text-white hover:bg-white/[0.06] transition-colors text-left"
407
  >
408
  <Shield size={14} className="text-rose-400" />
409
  <span>Admin Control Panel</span>
@@ -412,7 +414,7 @@ export function Header({ user, status, onOpenSupport, onOpenEntitlements }: Head
412
  </div>
413
 
414
  {/* Log Out Button */}
415
- <div className="pt-2 border-t border-white/10">
416
  <button
417
  type="button"
418
  onClick={handleLogout}
 
215
 
216
  {/* Notifications Dropdown Panel */}
217
  {isNotificationsOpen && (
218
+ <div className="absolute right-0 mt-2 w-80 sm:w-96 rounded-2xl bg-card border border-border/80 p-4 shadow-2xl text-foreground z-50 animate-in fade-in zoom-in-95 duration-150 relative overflow-hidden">
219
+ <div className="absolute top-0 left-1/2 -translate-x-1/2 w-1/2 h-[2px] bg-gradient-to-r from-transparent via-indigo-500 to-transparent"></div>
220
  <div className="flex items-center justify-between pb-3 border-b border-border/60 mb-2">
221
  <div className="flex items-center gap-2">
222
  <div className="p-1 rounded-lg bg-indigo-500/10 text-indigo-400">
223
  <Bell size={14} />
224
  </div>
225
+ <span className="text-xs font-bold text-foreground">Notifications</span>
226
  {unreadCount > 0 && (
227
  <span className="px-1.5 py-0.2 rounded-full bg-indigo-500/20 text-indigo-300 text-[10px] font-bold">
228
  {unreadCount} new
 
251
  key={notif.id}
252
  className={`p-3 rounded-xl border transition-all ${
253
  notif.read
254
+ ? 'bg-input/30 border-border/40 opacity-70'
255
+ : 'bg-input/60 border-indigo-500/20 shadow-xs'
256
  }`}
257
  >
258
  <div className="flex items-start justify-between gap-2">
 
264
  ) : (
265
  <Info size={14} className="text-indigo-400 shrink-0 mt-0.5" />
266
  )}
267
+ <h4 className="text-xs font-bold text-foreground leading-tight">
268
  {notif.title}
269
  </h4>
270
  </div>
 
322
 
323
  {/* Profile Dropdown Menu */}
324
  {isProfileOpen && (
325
+ <div className="absolute right-0 mt-2 w-72 rounded-2xl bg-card border border-border/80 p-4 shadow-2xl text-foreground z-50 animate-in fade-in zoom-in-95 duration-150 space-y-3.5 relative overflow-hidden">
326
+ <div className="absolute top-0 left-1/2 -translate-x-1/2 w-1/2 h-[2px] bg-gradient-to-r from-transparent via-indigo-500 to-transparent"></div>
327
 
328
  {/* User Identity Header Card */}
329
  <div className="flex items-center gap-3 pb-3 border-b border-border/60">
 
339
  )}
340
  </div>
341
  <div className="min-w-0 flex-1">
342
+ <h3 className="text-xs font-bold text-foreground truncate">
343
  {user?.full_name || user?.username}
344
  </h3>
345
  <p className="text-[10px] text-indigo-400 font-mono truncate">
 
352
  </div>
353
 
354
  {/* Plan Status Pill */}
355
+ <div className="p-2.5 rounded-xl bg-input/50 border border-border/60 flex items-center justify-between">
356
  <div>
357
  <div className="text-[9px] font-bold text-foreground/40 uppercase tracking-wider">Current Membership</div>
358
  <div className="text-xs font-black text-indigo-400 flex items-center gap-1 mt-0.5">
 
383
  if (onOpenEntitlements) onOpenEntitlements();
384
  else window.dispatchEvent(new Event('open-entitlements-modal'));
385
  }}
386
+ className="w-full flex items-center gap-2.5 px-3 py-2 rounded-xl text-foreground/70 hover:text-foreground hover:bg-foreground/5 transition-colors cursor-pointer text-left"
387
  >
388
  <Sparkles size={14} className="text-indigo-400" />
389
  <span>View Plan Entitlements</span>
 
395
  setIsProfileOpen(false);
396
  if (onOpenSupport) onOpenSupport();
397
  }}
398
+ className="w-full flex items-center gap-2.5 px-3 py-2 rounded-xl text-foreground/70 hover:text-foreground hover:bg-foreground/5 transition-colors cursor-pointer text-left"
399
  >
400
  <HelpCircle size={14} className="text-foreground/40" />
401
  <span>Support Desk</span>
 
405
  <Link
406
  href="/admin"
407
  onClick={() => setIsProfileOpen(false)}
408
+ className="w-full flex items-center gap-2.5 px-3 py-2 rounded-xl text-foreground/70 hover:text-foreground hover:bg-foreground/5 transition-colors text-left"
409
  >
410
  <Shield size={14} className="text-rose-400" />
411
  <span>Admin Control Panel</span>
 
414
  </div>
415
 
416
  {/* Log Out Button */}
417
+ <div className="pt-2 border-t border-border/60">
418
  <button
419
  type="button"
420
  onClick={handleLogout}
frontend/src/components/MonetizationOverlay.tsx CHANGED
@@ -397,10 +397,11 @@ export const MonetizationOverlay: React.FC<MonetizationOverlayProps> = ({ childr
397
  {/* IN-PAGE LOCK SHOWCASE: Confined strictly within the content container, keeping the sidebar & navbar accessible */}
398
  <div className="absolute inset-0 z-20 flex items-start justify-center pt-3 sm:pt-6 pb-12 px-2 sm:px-4 overflow-y-auto">
399
  {/* Subtle dark backdrop over the locked content */}
400
- <div className="absolute inset-0 bg-[#070A12]/80 backdrop-blur-[2px] rounded-2xl pointer-events-none" />
401
 
402
  {/* Modern Showcase Card */}
403
- <div className="relative w-full max-w-4xl bg-[#0C101D] border border-indigo-500/30 rounded-2xl p-5 sm:p-7 lg:p-8 shadow-2xl shadow-indigo-950/60 flex flex-col z-10 animate-in fade-in zoom-in-95 duration-200">
 
404
 
405
  {/* Header: Clean, Human & High-Contrast */}
406
  <div className="text-center mb-6 shrink-0">
@@ -409,11 +410,11 @@ export const MonetizationOverlay: React.FC<MonetizationOverlayProps> = ({ childr
409
  <span>Locked Feature • {featureName}</span>
410
  </div>
411
 
412
- <h2 className="text-2xl sm:text-3xl font-extrabold text-white tracking-tight">
413
  Supercharge Your Automation Fleet
414
  </h2>
415
- <p className="text-xs sm:text-sm text-slate-400 max-w-xl mx-auto mt-1.5 leading-relaxed">
416
- Choose an active tier to unlock <span className="text-white font-semibold">{featureName}</span>, run simultaneous campaign dispatches, and lift scraping limits.
417
  </p>
418
  </div>
419
 
@@ -421,7 +422,7 @@ export const MonetizationOverlay: React.FC<MonetizationOverlayProps> = ({ childr
421
  <div className="space-y-5">
422
  {status?.has_proof ? (
423
  /* Verification Pending State */
424
- <div className="bg-[#101526] border border-emerald-500/30 p-8 rounded-2xl text-center space-y-4">
425
  <div className="w-14 h-14 mx-auto rounded-xl bg-emerald-500/10 border border-emerald-500/25 flex items-center justify-center text-emerald-400">
426
  <CheckCircle2 size={32} />
427
  </div>
@@ -478,8 +479,8 @@ export const MonetizationOverlay: React.FC<MonetizationOverlayProps> = ({ childr
478
  onClick={() => setSelectedPlan(plan.key)}
479
  className={`w-full h-full flex flex-col justify-between text-left p-5 rounded-xl border transition-all cursor-pointer group ${
480
  isSelected
481
- ? 'bg-[#151A2C] border-indigo-500/80 ring-1 ring-indigo-500/50 shadow-xl shadow-indigo-950/40'
482
- : 'bg-[#0E121E] border-white/[0.08] hover:border-indigo-500/30 hover:bg-[#121626]'
483
  }`}
484
  >
485
  <div>
@@ -575,7 +576,7 @@ export const MonetizationOverlay: React.FC<MonetizationOverlayProps> = ({ childr
575
  </button>
576
 
577
  {/* Coupon Input */}
578
- <div className="md:col-span-4 flex items-center bg-[#0C101D] border border-white/10 p-1.5 rounded-xl">
579
  <input
580
  type="text"
581
  placeholder="COUPON / VIP CODE"
@@ -629,12 +630,13 @@ export const MonetizationOverlay: React.FC<MonetizationOverlayProps> = ({ childr
629
  <div className="absolute inset-0 z-40 flex items-start justify-center p-2 sm:p-4 md:p-6 overflow-y-auto min-h-full">
630
  {/* Frosted deep dark backdrop constrained within content area */}
631
  <div
632
- className="absolute inset-0 bg-[#060810]/85 backdrop-blur-md rounded-2xl transition-opacity"
633
  onClick={() => setShowPaymentModal(false)}
634
  />
635
 
636
  {/* Centered Modal Container (Side-by-Side 2-Column Desktop Layout) */}
637
- <div className="relative my-auto w-full max-w-5xl bg-[#0B0F1C] border border-white/15 rounded-2xl p-5 sm:p-7 lg:p-8 shadow-2xl animate-in fade-in zoom-in-95 duration-200 overflow-hidden flex flex-col max-h-[92vh] z-10">
 
638
 
639
  {/* Floating Copied Toast Alert */}
640
  {copiedNotification && (
@@ -711,15 +713,15 @@ export const MonetizationOverlay: React.FC<MonetizationOverlayProps> = ({ childr
711
  onClick={() => setPaymentMethod('bank')}
712
  className={`flex flex-col p-3.5 rounded-xl border transition-all text-left cursor-pointer ${
713
  paymentMethod === 'bank'
714
- ? 'bg-indigo-600/20 border-indigo-500 text-white shadow-md ring-1 ring-indigo-500/50'
715
- : 'bg-[#0E121E] border-white/[0.08] text-slate-400 hover:bg-[#121626] hover:border-white/20'
716
  }`}
717
  >
718
- <div className={`w-8 h-8 rounded-lg flex items-center justify-center mb-2 ${paymentMethod === 'bank' ? 'bg-indigo-600 text-white' : 'bg-white/5 text-slate-400'}`}>
719
  <Building2 size={16} />
720
  </div>
721
- <span className="font-bold text-xs text-white">Bank Transfer</span>
722
- <span className="text-[10px] text-slate-400 mt-0.5">NGN, USD, GBP, EUR</span>
723
  </button>
724
 
725
  <button
@@ -727,15 +729,15 @@ export const MonetizationOverlay: React.FC<MonetizationOverlayProps> = ({ childr
727
  onClick={() => setPaymentMethod('crypto')}
728
  className={`flex flex-col p-3.5 rounded-xl border transition-all text-left cursor-pointer ${
729
  paymentMethod === 'crypto'
730
- ? 'bg-indigo-600/20 border-indigo-500 text-white shadow-md ring-1 ring-indigo-500/50'
731
- : 'bg-[#0E121E] border-white/[0.08] text-slate-400 hover:bg-[#121626] hover:border-white/20'
732
  }`}
733
  >
734
- <div className={`w-8 h-8 rounded-lg flex items-center justify-center mb-2 ${paymentMethod === 'crypto' ? 'bg-indigo-600 text-white' : 'bg-white/5 text-slate-400'}`}>
735
  <Coins size={16} />
736
  </div>
737
- <span className="font-bold text-xs text-white">Crypto Deposit</span>
738
- <span className="text-[10px] text-slate-400 mt-0.5">USDT, BTC, Solana</span>
739
  </button>
740
  </div>
741
  </div>
@@ -759,13 +761,13 @@ export const MonetizationOverlay: React.FC<MonetizationOverlayProps> = ({ childr
759
  onClick={() => setSelectedCurrency(currKey)}
760
  className={`flex items-center gap-2.5 p-2.5 rounded-xl border text-left transition-all cursor-pointer ${
761
  isSel
762
- ? 'bg-[#151A2C] border-indigo-500/80 ring-1 ring-indigo-500/40 text-white shadow-sm'
763
- : 'bg-[#0E121E] border-white/[0.08] text-slate-300 hover:border-white/20 hover:bg-[#121626]'
764
  }`}
765
  >
766
  <CurrencyFlag currency={currKey} />
767
  <div className="min-w-0">
768
- <div className="text-xs font-bold text-white">{currKey}</div>
769
  <div className="text-[10px] font-semibold text-emerald-400 truncate">{getConvertedPrice(currKey)}</div>
770
  </div>
771
  </button>
@@ -791,12 +793,12 @@ export const MonetizationOverlay: React.FC<MonetizationOverlayProps> = ({ childr
791
  onClick={() => setSelectedCrypto(cKey)}
792
  className={`flex flex-col items-center py-2.5 px-2 rounded-xl border text-center transition-all cursor-pointer ${
793
  isSel
794
- ? 'bg-[#151A2C] border-indigo-500/80 ring-1 ring-indigo-500/40 text-white shadow-sm'
795
- : 'bg-[#0E121E] border-white/[0.08] text-slate-300 hover:border-white/20 hover:bg-[#121626]'
796
  }`}
797
  >
798
  <CurrencyFlag currency={cKey} />
799
- <span className="text-xs font-bold text-white mt-1">{cw.symbol}</span>
800
  <span className="text-[10px] font-semibold text-emerald-400 truncate max-w-full">{getConvertedPrice(cKey)}</span>
801
  </button>
802
  );
@@ -806,17 +808,17 @@ export const MonetizationOverlay: React.FC<MonetizationOverlayProps> = ({ childr
806
  )}
807
 
808
  {/* Summary Recap Card */}
809
- <div className="bg-[#0E121E] border border-white/10 rounded-xl p-3.5 space-y-2">
810
  <div className="flex items-center justify-between text-xs">
811
- <span className="text-slate-400">Selected Tier</span>
812
- <span className="text-white font-semibold">{plans.find(p => p.key === selectedPlan)?.name}</span>
813
  </div>
814
  <div className="flex items-center justify-between text-xs">
815
- <span className="text-slate-400">Billing Term</span>
816
- <span className="text-white font-medium">Monthly Access (30 Days)</span>
817
  </div>
818
- <div className="pt-2 border-t border-white/[0.08] flex items-center justify-between">
819
- <span className="text-xs font-bold text-white">Total Due</span>
820
  <span className="text-sm font-extrabold text-emerald-400">
821
  {getConvertedPrice(paymentMethod === 'bank' ? selectedCurrency : selectedCrypto)}
822
  </span>
@@ -828,7 +830,7 @@ export const MonetizationOverlay: React.FC<MonetizationOverlayProps> = ({ childr
828
  <div className="lg:col-span-7 space-y-4 lg:overflow-y-auto lg:max-h-[calc(92vh-140px)] custom-scrollbar pr-2 pb-2">
829
 
830
  {/* Prominent Amount Card with 1-Click Copy */}
831
- <div className="bg-[#121727] border border-emerald-500/30 rounded-xl p-4 flex items-center justify-between gap-3 shadow-xs">
832
  <div>
833
  <div className="text-[10px] uppercase font-bold tracking-wider text-emerald-400 flex items-center gap-1">
834
  <Sparkles size={11} />
@@ -866,8 +868,8 @@ export const MonetizationOverlay: React.FC<MonetizationOverlayProps> = ({ childr
866
  key={idx}
867
  className={`p-3 rounded-xl border flex items-center justify-between gap-3 ${
868
  field.isPrimary
869
- ? 'bg-[#151B2E] border-indigo-500/60 ring-1 ring-indigo-500/30'
870
- : 'bg-[#0E121E] border-white/[0.08]'
871
  }`}
872
  >
873
  <div className="min-w-0 flex-1">
@@ -926,7 +928,7 @@ export const MonetizationOverlay: React.FC<MonetizationOverlayProps> = ({ childr
926
  </div>
927
 
928
  {/* Deposit Address Box */}
929
- <div className="p-4 rounded-xl bg-[#0E121E] border border-white/10 space-y-2">
930
  <div className="flex items-center justify-between text-xs">
931
  <span className="text-slate-400 font-medium">
932
  Deposit Address ({cw.network})
@@ -1001,7 +1003,7 @@ export const MonetizationOverlay: React.FC<MonetizationOverlayProps> = ({ childr
1001
  </div>
1002
 
1003
  {/* Luxury Digital Voucher / Clearing Pass */}
1004
- <div className="relative bg-[#0d1222] border border-indigo-500/40 ring-1 ring-indigo-500/20 rounded-2xl shadow-2xl overflow-hidden">
1005
  {/* Top Holographic Watermark Bar */}
1006
  <div className="bg-gradient-to-r from-indigo-950/80 via-[#151c34] to-indigo-950/80 px-4 py-3 border-b border-white/10 flex flex-wrap items-center justify-between gap-2">
1007
  <div className="flex items-center gap-2">
@@ -1057,9 +1059,9 @@ export const MonetizationOverlay: React.FC<MonetizationOverlayProps> = ({ childr
1057
 
1058
  {/* Perforated Voucher Tear Line */}
1059
  <div className="relative flex items-center justify-between px-2 py-1">
1060
- <div className="w-4 h-4 rounded-full bg-[#0B0F1C] -ml-4 border-r border-white/10" />
1061
- <div className="flex-1 border-t-2 border-dashed border-white/10 mx-2" />
1062
- <div className="w-4 h-4 rounded-full bg-[#0B0F1C] -mr-4 border-l border-white/10" />
1063
  </div>
1064
 
1065
  {/* Interactive Proof Submission Controls */}
 
397
  {/* IN-PAGE LOCK SHOWCASE: Confined strictly within the content container, keeping the sidebar & navbar accessible */}
398
  <div className="absolute inset-0 z-20 flex items-start justify-center pt-3 sm:pt-6 pb-12 px-2 sm:px-4 overflow-y-auto">
399
  {/* Subtle dark backdrop over the locked content */}
400
+ <div className="absolute inset-0 bg-black/75 backdrop-blur-sm rounded-2xl pointer-events-none" />
401
 
402
  {/* Modern Showcase Card */}
403
+ <div className="relative w-full max-w-4xl bg-card border border-border/80 rounded-2xl p-5 sm:p-7 lg:p-8 shadow-2xl flex flex-col z-10 animate-in fade-in zoom-in-95 duration-200 overflow-hidden">
404
+ <div className="absolute top-0 left-1/2 -translate-x-1/2 w-1/2 h-[2px] bg-gradient-to-r from-transparent via-indigo-500 to-transparent"></div>
405
 
406
  {/* Header: Clean, Human & High-Contrast */}
407
  <div className="text-center mb-6 shrink-0">
 
410
  <span>Locked Feature • {featureName}</span>
411
  </div>
412
 
413
+ <h2 className="text-2xl sm:text-3xl font-extrabold text-foreground tracking-tight">
414
  Supercharge Your Automation Fleet
415
  </h2>
416
+ <p className="text-xs sm:text-sm text-foreground/60 max-w-xl mx-auto mt-1.5 leading-relaxed">
417
+ Choose an active tier to unlock <span className="text-foreground font-semibold">{featureName}</span>, run simultaneous campaign dispatches, and lift scraping limits.
418
  </p>
419
  </div>
420
 
 
422
  <div className="space-y-5">
423
  {status?.has_proof ? (
424
  /* Verification Pending State */
425
+ <div className="bg-input/50 border border-emerald-500/30 p-8 rounded-2xl text-center space-y-4">
426
  <div className="w-14 h-14 mx-auto rounded-xl bg-emerald-500/10 border border-emerald-500/25 flex items-center justify-center text-emerald-400">
427
  <CheckCircle2 size={32} />
428
  </div>
 
479
  onClick={() => setSelectedPlan(plan.key)}
480
  className={`w-full h-full flex flex-col justify-between text-left p-5 rounded-xl border transition-all cursor-pointer group ${
481
  isSelected
482
+ ? 'bg-input border-indigo-500/80 ring-1 ring-indigo-500/50 shadow-xl'
483
+ : 'bg-card/90 border-border/70 hover:border-indigo-500/30 hover:bg-input/40'
484
  }`}
485
  >
486
  <div>
 
576
  </button>
577
 
578
  {/* Coupon Input */}
579
+ <div className="md:col-span-4 flex items-center bg-input/60 border border-border/70 p-1.5 rounded-xl">
580
  <input
581
  type="text"
582
  placeholder="COUPON / VIP CODE"
 
630
  <div className="absolute inset-0 z-40 flex items-start justify-center p-2 sm:p-4 md:p-6 overflow-y-auto min-h-full">
631
  {/* Frosted deep dark backdrop constrained within content area */}
632
  <div
633
+ className="absolute inset-0 bg-black/75 backdrop-blur-sm rounded-2xl transition-opacity"
634
  onClick={() => setShowPaymentModal(false)}
635
  />
636
 
637
  {/* Centered Modal Container (Side-by-Side 2-Column Desktop Layout) */}
638
+ <div className="relative my-auto w-full max-w-5xl bg-card border border-border/80 rounded-2xl p-5 sm:p-7 lg:p-8 shadow-2xl animate-in fade-in zoom-in-95 duration-200 overflow-hidden flex flex-col max-h-[92vh] z-10">
639
+ <div className="absolute top-0 left-1/2 -translate-x-1/2 w-1/2 h-[2px] bg-gradient-to-r from-transparent via-indigo-500 to-transparent"></div>
640
 
641
  {/* Floating Copied Toast Alert */}
642
  {copiedNotification && (
 
713
  onClick={() => setPaymentMethod('bank')}
714
  className={`flex flex-col p-3.5 rounded-xl border transition-all text-left cursor-pointer ${
715
  paymentMethod === 'bank'
716
+ ? 'bg-indigo-600/20 border-indigo-500 text-foreground shadow-md ring-1 ring-indigo-500/50'
717
+ : 'bg-input/40 border-border/70 text-foreground/70 hover:bg-input/70 hover:border-border'
718
  }`}
719
  >
720
+ <div className={`w-8 h-8 rounded-lg flex items-center justify-center mb-2 ${paymentMethod === 'bank' ? 'bg-indigo-600 text-white' : 'bg-input/50 text-foreground/50'}`}>
721
  <Building2 size={16} />
722
  </div>
723
+ <span className="font-bold text-xs text-foreground">Bank Transfer</span>
724
+ <span className="text-[10px] text-foreground/50 mt-0.5">NGN, USD, GBP, EUR</span>
725
  </button>
726
 
727
  <button
 
729
  onClick={() => setPaymentMethod('crypto')}
730
  className={`flex flex-col p-3.5 rounded-xl border transition-all text-left cursor-pointer ${
731
  paymentMethod === 'crypto'
732
+ ? 'bg-indigo-600/20 border-indigo-500 text-foreground shadow-md ring-1 ring-indigo-500/50'
733
+ : 'bg-input/40 border-border/70 text-foreground/70 hover:bg-input/70 hover:border-border'
734
  }`}
735
  >
736
+ <div className={`w-8 h-8 rounded-lg flex items-center justify-center mb-2 ${paymentMethod === 'crypto' ? 'bg-indigo-600 text-white' : 'bg-input/50 text-foreground/50'}`}>
737
  <Coins size={16} />
738
  </div>
739
+ <span className="font-bold text-xs text-foreground">Crypto Deposit</span>
740
+ <span className="text-[10px] text-foreground/50 mt-0.5">USDT, BTC, Solana</span>
741
  </button>
742
  </div>
743
  </div>
 
761
  onClick={() => setSelectedCurrency(currKey)}
762
  className={`flex items-center gap-2.5 p-2.5 rounded-xl border text-left transition-all cursor-pointer ${
763
  isSel
764
+ ? 'bg-input border-indigo-500/80 ring-1 ring-indigo-500/40 text-foreground shadow-sm'
765
+ : 'bg-input/30 border-border/60 text-foreground/70 hover:border-border hover:bg-input/60'
766
  }`}
767
  >
768
  <CurrencyFlag currency={currKey} />
769
  <div className="min-w-0">
770
+ <div className="text-xs font-bold text-foreground">{currKey}</div>
771
  <div className="text-[10px] font-semibold text-emerald-400 truncate">{getConvertedPrice(currKey)}</div>
772
  </div>
773
  </button>
 
793
  onClick={() => setSelectedCrypto(cKey)}
794
  className={`flex flex-col items-center py-2.5 px-2 rounded-xl border text-center transition-all cursor-pointer ${
795
  isSel
796
+ ? 'bg-input border-indigo-500/80 ring-1 ring-indigo-500/40 text-foreground shadow-sm'
797
+ : 'bg-input/30 border-border/60 text-foreground/70 hover:border-border hover:bg-input/60'
798
  }`}
799
  >
800
  <CurrencyFlag currency={cKey} />
801
+ <span className="text-xs font-bold text-foreground mt-1">{cw.symbol}</span>
802
  <span className="text-[10px] font-semibold text-emerald-400 truncate max-w-full">{getConvertedPrice(cKey)}</span>
803
  </button>
804
  );
 
808
  )}
809
 
810
  {/* Summary Recap Card */}
811
+ <div className="bg-input/40 border border-border/70 rounded-xl p-3.5 space-y-2">
812
  <div className="flex items-center justify-between text-xs">
813
+ <span className="text-foreground/50">Selected Tier</span>
814
+ <span className="text-foreground font-semibold">{plans.find(p => p.key === selectedPlan)?.name}</span>
815
  </div>
816
  <div className="flex items-center justify-between text-xs">
817
+ <span className="text-foreground/50">Billing Term</span>
818
+ <span className="text-foreground font-medium">Monthly Access (30 Days)</span>
819
  </div>
820
+ <div className="pt-2 border-t border-border/60 flex items-center justify-between">
821
+ <span className="text-xs font-bold text-foreground">Total Due</span>
822
  <span className="text-sm font-extrabold text-emerald-400">
823
  {getConvertedPrice(paymentMethod === 'bank' ? selectedCurrency : selectedCrypto)}
824
  </span>
 
830
  <div className="lg:col-span-7 space-y-4 lg:overflow-y-auto lg:max-h-[calc(92vh-140px)] custom-scrollbar pr-2 pb-2">
831
 
832
  {/* Prominent Amount Card with 1-Click Copy */}
833
+ <div className="bg-input/50 border border-emerald-500/30 rounded-xl p-4 flex items-center justify-between gap-3 shadow-xs">
834
  <div>
835
  <div className="text-[10px] uppercase font-bold tracking-wider text-emerald-400 flex items-center gap-1">
836
  <Sparkles size={11} />
 
868
  key={idx}
869
  className={`p-3 rounded-xl border flex items-center justify-between gap-3 ${
870
  field.isPrimary
871
+ ? 'bg-input/70 border-indigo-500/60 ring-1 ring-indigo-500/30'
872
+ : 'bg-input/40 border-border/60'
873
  }`}
874
  >
875
  <div className="min-w-0 flex-1">
 
928
  </div>
929
 
930
  {/* Deposit Address Box */}
931
+ <div className="p-4 rounded-xl bg-input/40 border border-border/70 space-y-2">
932
  <div className="flex items-center justify-between text-xs">
933
  <span className="text-slate-400 font-medium">
934
  Deposit Address ({cw.network})
 
1003
  </div>
1004
 
1005
  {/* Luxury Digital Voucher / Clearing Pass */}
1006
+ <div className="relative bg-card border border-border/80 ring-1 ring-indigo-500/20 rounded-2xl shadow-2xl overflow-hidden">
1007
  {/* Top Holographic Watermark Bar */}
1008
  <div className="bg-gradient-to-r from-indigo-950/80 via-[#151c34] to-indigo-950/80 px-4 py-3 border-b border-white/10 flex flex-wrap items-center justify-between gap-2">
1009
  <div className="flex items-center gap-2">
 
1059
 
1060
  {/* Perforated Voucher Tear Line */}
1061
  <div className="relative flex items-center justify-between px-2 py-1">
1062
+ <div className="w-4 h-4 rounded-full bg-card -ml-4 border-r border-border/60" />
1063
+ <div className="flex-1 border-t-2 border-dashed border-border/60 mx-2" />
1064
+ <div className="w-4 h-4 rounded-full bg-card -mr-4 border-l border-border/60" />
1065
  </div>
1066
 
1067
  {/* Interactive Proof Submission Controls */}
frontend/src/components/Sidebar.tsx CHANGED
@@ -522,24 +522,25 @@ export function Sidebar({ children }: { children: React.ReactNode }) {
522
  {showEntitlementsFlyout && (
523
  <div className="fixed inset-0 z-[80] flex items-end sm:items-center justify-center p-3 sm:p-4">
524
  <div
525
- className="fixed inset-0 bg-[#05060b]/80 backdrop-blur-sm transition-opacity"
526
  onClick={() => setShowEntitlementsFlyout(false)}
527
  />
528
- <div className="relative my-auto w-full max-w-md bg-[#0B0F1C]/98 backdrop-blur-2xl border border-indigo-500/40 rounded-2xl p-5 shadow-2xl text-foreground space-y-4 animate-in fade-in zoom-in-95 duration-150 z-[81]">
529
- <div className="flex items-center justify-between pb-3 border-b border-white/10">
 
530
  <div className="flex items-center gap-2">
531
  <div className="p-1.5 rounded-lg bg-indigo-500/10 text-indigo-400">
532
  <ShieldCheck size={16} />
533
  </div>
534
  <div>
535
- <div className="text-xs font-bold text-white">Full Plan Entitlements</div>
536
  <div className="text-[10px] text-foreground/50">Active Tier: <span className="text-indigo-400 font-bold uppercase">{status?.plan || 'Free'}</span></div>
537
  </div>
538
  </div>
539
  <button
540
  type="button"
541
  onClick={() => setShowEntitlementsFlyout(false)}
542
- className="text-foreground/40 hover:text-white p-1 rounded-lg hover:bg-white/5 transition-colors cursor-pointer"
543
  >
544
  <X size={15} />
545
  </button>
@@ -547,60 +548,60 @@ export function Sidebar({ children }: { children: React.ReactNode }) {
547
 
548
  {/* 10 Package Features Matrix */}
549
  <div className="space-y-2 text-xs max-h-[55vh] overflow-y-auto custom-scrollbar pr-1">
550
- <div className="p-2.5 rounded-xl bg-white/[0.03] border border-white/5 flex items-center justify-between">
551
  <span className="text-foreground/60 text-[11px]">1. Telegram Accounts</span>
552
- <span className="font-bold text-white text-[11px] font-mono">{status?.max_accounts || 1} Allowed</span>
553
  </div>
554
 
555
- <div className="p-2.5 rounded-xl bg-white/[0.03] border border-white/5 flex items-center justify-between">
556
  <span className="text-foreground/60 text-[11px]">2. Daily Campaigns</span>
557
- <span className="font-bold text-white text-[11px] font-mono">{status?.daily_campaign_count || 0} / {status?.max_daily_campaigns || 20}</span>
558
  </div>
559
 
560
- <div className="p-2.5 rounded-xl bg-white/[0.03] border border-white/5 flex items-center justify-between">
561
  <span className="text-foreground/60 text-[11px]">3. Scraper Power</span>
562
- <span className="font-bold text-white text-[11px] font-mono">{status?.scrape_limit || 50} groups / search</span>
563
  </div>
564
 
565
- <div className="p-2.5 rounded-xl bg-white/[0.03] border border-white/5 flex items-center justify-between">
566
  <span className="text-foreground/60 text-[11px]">4. AI Keyword Suggestions</span>
567
- <span className="font-bold text-white text-[11px] font-mono">{status?.ai_keyword_cap || 5} per prompt</span>
568
  </div>
569
 
570
- <div className="p-2.5 rounded-xl bg-white/[0.03] border border-white/5 flex items-center justify-between">
571
  <span className="text-foreground/60 text-[11px]">5. Saved Templates</span>
572
- <span className="font-bold text-white text-[11px] font-mono">{status?.template_count || 0} / {status?.max_templates || 1}</span>
573
  </div>
574
 
575
- <div className="p-2.5 rounded-xl bg-white/[0.03] border border-white/5 flex items-center justify-between">
576
  <span className="text-foreground/60 text-[11px]">6. Fleet Compare & Audit</span>
577
  <span className={`font-bold text-[11px] ${status?.has_fleet_compare ? 'text-emerald-400' : 'text-foreground/30'}`}>
578
  {status?.has_fleet_compare ? '✓ Unlocked' : '🔒 Locked (Basic+)'}
579
  </span>
580
  </div>
581
 
582
- <div className="p-2.5 rounded-xl bg-white/[0.03] border border-white/5 flex items-center justify-between">
583
  <span className="text-foreground/60 text-[11px]">7. Delivery Speed Modes</span>
584
  <span className="font-bold text-indigo-300 text-[11px] capitalize truncate max-w-[170px] text-right">
585
  {status?.allowed_speeds?.join(', ') || 'Balanced'}
586
  </span>
587
  </div>
588
 
589
- <div className="p-2.5 rounded-xl bg-white/[0.03] border border-white/5 flex items-center justify-between">
590
  <span className="text-foreground/60 text-[11px]">8. Spintax Generator</span>
591
  <span className={`font-bold text-[11px] ${status?.has_spintax ? 'text-emerald-400' : 'text-foreground/30'}`}>
592
  {status?.has_spintax ? '✓ Unlocked' : '🔒 Locked (Basic+)'}
593
  </span>
594
  </div>
595
 
596
- <div className="p-2.5 rounded-xl bg-white/[0.03] border border-white/5 flex items-center justify-between">
597
  <span className="text-foreground/60 text-[11px]">9. Bulk Join Minimizer</span>
598
  <span className={`font-bold text-[11px] ${status?.has_fleet_compare ? 'text-emerald-400' : 'text-foreground/30'}`}>
599
  {status?.has_fleet_compare ? '✓ Unlocked' : '🔒 Locked (Basic+)'}
600
  </span>
601
  </div>
602
 
603
- <div className="p-2.5 rounded-xl bg-white/[0.03] border border-white/5 flex items-center justify-between">
604
  <span className="text-foreground/60 text-[11px]">10. Leads CSV Export</span>
605
  <span className="font-bold text-emerald-400 text-[11px]">✓ Full Export</span>
606
  </div>
@@ -628,23 +629,24 @@ export function Sidebar({ children }: { children: React.ReactNode }) {
628
  {showSupportModal && (
629
  <div className="fixed inset-0 z-[70] flex items-center justify-center p-4 overflow-y-auto">
630
  <div
631
- className="fixed inset-0 bg-[#05060b]/85 backdrop-blur-xl"
632
  onClick={() => setShowSupportModal(false)}
633
  />
634
- <div className="relative my-auto w-full max-w-[480px] bg-gradient-to-b from-[#101322] to-[#0a0c14] border border-white/10 rounded-[30px] p-6 sm:p-7 shadow-[0_0_60px_rgba(99,102,241,0.2)] animate-in fade-in zoom-in-95 duration-200">
635
- <div className="flex items-center justify-between pb-4 border-b border-white/10 mb-4">
 
636
  <div className="flex items-center gap-2.5">
637
  <div className="w-9 h-9 rounded-xl bg-indigo-500/15 border border-indigo-500/30 flex items-center justify-center text-indigo-400">
638
  <HelpCircle size={20} />
639
  </div>
640
  <div>
641
- <h3 className="font-black text-sm text-white">ArkiTel Support Desk</h3>
642
  <p className="text-[10px] text-foreground/40 font-semibold">Choose your preferred support channel</p>
643
  </div>
644
  </div>
645
  <button
646
  onClick={() => setShowSupportModal(false)}
647
- className="p-1.5 rounded-lg text-foreground/40 hover:text-white hover:bg-white/5 transition-colors cursor-pointer"
648
  >
649
  <X size={18} />
650
  </button>
 
522
  {showEntitlementsFlyout && (
523
  <div className="fixed inset-0 z-[80] flex items-end sm:items-center justify-center p-3 sm:p-4">
524
  <div
525
+ className="fixed inset-0 bg-black/75 backdrop-blur-sm transition-opacity"
526
  onClick={() => setShowEntitlementsFlyout(false)}
527
  />
528
+ <div className="relative my-auto w-full max-w-md bg-card border border-border/80 rounded-2xl p-5 shadow-2xl text-foreground space-y-4 animate-in fade-in zoom-in-95 duration-150 z-[81] overflow-hidden">
529
+ <div className="absolute top-0 left-1/2 -translate-x-1/2 w-1/2 h-[2px] bg-gradient-to-r from-transparent via-indigo-500 to-transparent"></div>
530
+ <div className="flex items-center justify-between pb-3 border-b border-border/60">
531
  <div className="flex items-center gap-2">
532
  <div className="p-1.5 rounded-lg bg-indigo-500/10 text-indigo-400">
533
  <ShieldCheck size={16} />
534
  </div>
535
  <div>
536
+ <div className="text-xs font-bold text-foreground">Full Plan Entitlements</div>
537
  <div className="text-[10px] text-foreground/50">Active Tier: <span className="text-indigo-400 font-bold uppercase">{status?.plan || 'Free'}</span></div>
538
  </div>
539
  </div>
540
  <button
541
  type="button"
542
  onClick={() => setShowEntitlementsFlyout(false)}
543
+ className="text-foreground/40 hover:text-foreground p-1 rounded-lg hover:bg-foreground/5 transition-colors cursor-pointer"
544
  >
545
  <X size={15} />
546
  </button>
 
548
 
549
  {/* 10 Package Features Matrix */}
550
  <div className="space-y-2 text-xs max-h-[55vh] overflow-y-auto custom-scrollbar pr-1">
551
+ <div className="p-2.5 rounded-xl bg-input/40 border border-border/60 flex items-center justify-between">
552
  <span className="text-foreground/60 text-[11px]">1. Telegram Accounts</span>
553
+ <span className="font-bold text-foreground text-[11px] font-mono">{status?.max_accounts || 1} Allowed</span>
554
  </div>
555
 
556
+ <div className="p-2.5 rounded-xl bg-input/40 border border-border/60 flex items-center justify-between">
557
  <span className="text-foreground/60 text-[11px]">2. Daily Campaigns</span>
558
+ <span className="font-bold text-foreground text-[11px] font-mono">{status?.daily_campaign_count || 0} / {status?.max_daily_campaigns || 20}</span>
559
  </div>
560
 
561
+ <div className="p-2.5 rounded-xl bg-input/40 border border-border/60 flex items-center justify-between">
562
  <span className="text-foreground/60 text-[11px]">3. Scraper Power</span>
563
+ <span className="font-bold text-foreground text-[11px] font-mono">{status?.scrape_limit || 50} groups / search</span>
564
  </div>
565
 
566
+ <div className="p-2.5 rounded-xl bg-input/40 border border-border/60 flex items-center justify-between">
567
  <span className="text-foreground/60 text-[11px]">4. AI Keyword Suggestions</span>
568
+ <span className="font-bold text-foreground text-[11px] font-mono">{status?.ai_keyword_cap || 5} per prompt</span>
569
  </div>
570
 
571
+ <div className="p-2.5 rounded-xl bg-input/40 border border-border/60 flex items-center justify-between">
572
  <span className="text-foreground/60 text-[11px]">5. Saved Templates</span>
573
+ <span className="font-bold text-foreground text-[11px] font-mono">{status?.template_count || 0} / {status?.max_templates || 1}</span>
574
  </div>
575
 
576
+ <div className="p-2.5 rounded-xl bg-input/40 border border-border/60 flex items-center justify-between">
577
  <span className="text-foreground/60 text-[11px]">6. Fleet Compare & Audit</span>
578
  <span className={`font-bold text-[11px] ${status?.has_fleet_compare ? 'text-emerald-400' : 'text-foreground/30'}`}>
579
  {status?.has_fleet_compare ? '✓ Unlocked' : '🔒 Locked (Basic+)'}
580
  </span>
581
  </div>
582
 
583
+ <div className="p-2.5 rounded-xl bg-input/40 border border-border/60 flex items-center justify-between">
584
  <span className="text-foreground/60 text-[11px]">7. Delivery Speed Modes</span>
585
  <span className="font-bold text-indigo-300 text-[11px] capitalize truncate max-w-[170px] text-right">
586
  {status?.allowed_speeds?.join(', ') || 'Balanced'}
587
  </span>
588
  </div>
589
 
590
+ <div className="p-2.5 rounded-xl bg-input/40 border border-border/60 flex items-center justify-between">
591
  <span className="text-foreground/60 text-[11px]">8. Spintax Generator</span>
592
  <span className={`font-bold text-[11px] ${status?.has_spintax ? 'text-emerald-400' : 'text-foreground/30'}`}>
593
  {status?.has_spintax ? '✓ Unlocked' : '🔒 Locked (Basic+)'}
594
  </span>
595
  </div>
596
 
597
+ <div className="p-2.5 rounded-xl bg-input/40 border border-border/60 flex items-center justify-between">
598
  <span className="text-foreground/60 text-[11px]">9. Bulk Join Minimizer</span>
599
  <span className={`font-bold text-[11px] ${status?.has_fleet_compare ? 'text-emerald-400' : 'text-foreground/30'}`}>
600
  {status?.has_fleet_compare ? '✓ Unlocked' : '🔒 Locked (Basic+)'}
601
  </span>
602
  </div>
603
 
604
+ <div className="p-2.5 rounded-xl bg-input/40 border border-border/60 flex items-center justify-between">
605
  <span className="text-foreground/60 text-[11px]">10. Leads CSV Export</span>
606
  <span className="font-bold text-emerald-400 text-[11px]">✓ Full Export</span>
607
  </div>
 
629
  {showSupportModal && (
630
  <div className="fixed inset-0 z-[70] flex items-center justify-center p-4 overflow-y-auto">
631
  <div
632
+ className="fixed inset-0 bg-black/75 backdrop-blur-sm"
633
  onClick={() => setShowSupportModal(false)}
634
  />
635
+ <div className="relative my-auto w-full max-w-[480px] bg-card border border-border/80 rounded-2xl p-6 sm:p-7 shadow-2xl relative overflow-hidden animate-in fade-in zoom-in-95 duration-200">
636
+ <div className="absolute top-0 left-1/2 -translate-x-1/2 w-1/2 h-[2px] bg-gradient-to-r from-transparent via-indigo-500 to-transparent"></div>
637
+ <div className="flex items-center justify-between pb-4 border-b border-border/60 mb-4">
638
  <div className="flex items-center gap-2.5">
639
  <div className="w-9 h-9 rounded-xl bg-indigo-500/15 border border-indigo-500/30 flex items-center justify-center text-indigo-400">
640
  <HelpCircle size={20} />
641
  </div>
642
  <div>
643
+ <h3 className="font-black text-sm text-foreground">ArkiTel Support Desk</h3>
644
  <p className="text-[10px] text-foreground/40 font-semibold">Choose your preferred support channel</p>
645
  </div>
646
  </div>
647
  <button
648
  onClick={() => setShowSupportModal(false)}
649
+ className="p-1.5 rounded-lg text-foreground/40 hover:text-foreground hover:bg-foreground/5 transition-colors cursor-pointer"
650
  >
651
  <X size={18} />
652
  </button>
frontend/src/components/TemplatePreviewModal.tsx CHANGED
@@ -119,18 +119,19 @@ export function TemplatePreviewModal({ isOpen, onClose, template, onEdit }: Temp
119
  };
120
 
121
  return (
122
- <div className="fixed inset-0 z-50 flex items-center justify-center p-3 sm:p-5 overflow-y-auto">
123
  {/* Backdrop */}
124
  <div
125
- className="fixed inset-0 bg-[#060810]/85 backdrop-blur-md transition-opacity"
126
  onClick={onClose}
127
  />
128
 
129
  {/* Modal Dialog Card */}
130
- <div className="relative my-auto w-full max-w-2xl bg-[#0B0F1C] border border-border/80 rounded-2xl shadow-2xl p-5 sm:p-6 text-foreground space-y-4 animate-in fade-in zoom-in-95 duration-150 z-50">
 
131
 
132
  {/* Header */}
133
- <div className="flex items-start justify-between gap-3 pb-3 border-b border-border/60">
134
  <div className="flex items-center gap-3">
135
  <div className="w-9 h-9 rounded-xl bg-indigo-500/10 border border-indigo-500/20 flex items-center justify-center text-indigo-400 shrink-0">
136
  <Eye size={18} />
@@ -159,7 +160,7 @@ export function TemplatePreviewModal({ isOpen, onClose, template, onEdit }: Temp
159
  </div>
160
 
161
  {/* Tab Switcher */}
162
- <div className="flex items-center gap-1.5 p-1 bg-foreground/[0.03] border border-border/70 rounded-xl text-xs font-semibold">
163
  <button
164
  type="button"
165
  onClick={() => setActiveTab('preview')}
@@ -200,6 +201,9 @@ export function TemplatePreviewModal({ isOpen, onClose, template, onEdit }: Temp
200
  </button>
201
  </div>
202
 
 
 
 
203
  {/* Tab 1: Content & Media */}
204
  {activeTab === 'preview' && (
205
  <div className="space-y-4">
@@ -255,7 +259,7 @@ export function TemplatePreviewModal({ isOpen, onClose, template, onEdit }: Temp
255
  <span>{copiedRaw ? 'Copied' : 'Copy Payload'}</span>
256
  </button>
257
  </div>
258
- <div className="p-3.5 rounded-xl bg-foreground/[0.02] border border-border/70 font-mono text-xs leading-relaxed text-foreground/90 max-h-56 overflow-y-auto custom-scrollbar select-all whitespace-pre-wrap">
259
  {template.content}
260
  </div>
261
  </div>
@@ -310,7 +314,7 @@ export function TemplatePreviewModal({ isOpen, onClose, template, onEdit }: Temp
310
  return (
311
  <div
312
  key={idx}
313
- className="p-3.5 rounded-xl bg-foreground/[0.02] hover:bg-foreground/[0.04] border border-border/70 hover:border-indigo-500/40 transition-all text-xs space-y-2 group"
314
  >
315
  <div className="flex items-center justify-between pb-1.5 border-b border-border/40">
316
  <div className="flex items-center gap-2">
@@ -364,11 +368,11 @@ export function TemplatePreviewModal({ isOpen, onClose, template, onEdit }: Temp
364
  </button>
365
  </div>
366
 
367
- {/* Chat Box Container */}
368
- <div className="p-4 sm:p-5 rounded-2xl bg-[#0e1621] border border-[#2b3a4a] shadow-inner flex flex-col justify-end min-h-[200px]">
369
 
370
  {/* Telegram Message Bubble */}
371
- <div className="max-w-[88%] self-start rounded-2xl bg-[#182533] border border-[#232e3c] p-3 text-white shadow-md space-y-2">
372
 
373
  {/* Sender Title */}
374
  <div className="text-[11px] font-bold text-[#56b0f5]">
@@ -377,7 +381,7 @@ export function TemplatePreviewModal({ isOpen, onClose, template, onEdit }: Temp
377
 
378
  {/* Attached media preview if any */}
379
  {mediaUrls.length > 0 && (
380
- <div className="rounded-xl overflow-hidden border border-white/10 max-h-48 aspect-video bg-black/60">
381
  {mediaUrls[0].includes('.mp4') ? (
382
  <div className="h-full flex items-center justify-center text-indigo-400 gap-2">
383
  <Film size={28} />
@@ -394,7 +398,7 @@ export function TemplatePreviewModal({ isOpen, onClose, template, onEdit }: Temp
394
  )}
395
 
396
  {/* Message Body with strictly preserved paragraphs */}
397
- <div className="text-xs leading-relaxed text-slate-100 whitespace-pre-wrap">
398
  {applySampleVariables(currentSpun || spinText(template.content))}
399
  </div>
400
 
@@ -409,6 +413,7 @@ export function TemplatePreviewModal({ isOpen, onClose, template, onEdit }: Temp
409
  </div>
410
  )}
411
 
 
412
  </div>
413
  </div>
414
  );
 
119
  };
120
 
121
  return (
122
+ <div className="fixed inset-0 z-50 flex items-center justify-center p-3 sm:p-5">
123
  {/* Backdrop */}
124
  <div
125
+ className="fixed inset-0 bg-black/75 backdrop-blur-sm transition-opacity"
126
  onClick={onClose}
127
  />
128
 
129
  {/* Modal Dialog Card */}
130
+ <div className="relative my-auto w-full max-w-2xl bg-card border border-border/80 rounded-2xl shadow-2xl p-5 sm:p-6 text-foreground space-y-4 animate-in fade-in zoom-in-95 duration-150 z-50 overflow-hidden max-h-[85vh] flex flex-col">
131
+ <div className="absolute top-0 left-1/2 -translate-x-1/2 w-1/2 h-[2px] bg-gradient-to-r from-transparent via-indigo-500 to-transparent"></div>
132
 
133
  {/* Header */}
134
+ <div className="flex items-start justify-between gap-3 pb-3 border-b border-border/60 shrink-0">
135
  <div className="flex items-center gap-3">
136
  <div className="w-9 h-9 rounded-xl bg-indigo-500/10 border border-indigo-500/20 flex items-center justify-center text-indigo-400 shrink-0">
137
  <Eye size={18} />
 
160
  </div>
161
 
162
  {/* Tab Switcher */}
163
+ <div className="flex items-center gap-1.5 p-1 bg-input/50 border border-border/70 rounded-xl text-xs font-semibold shrink-0">
164
  <button
165
  type="button"
166
  onClick={() => setActiveTab('preview')}
 
201
  </button>
202
  </div>
203
 
204
+ {/* Tab Bodies Container */}
205
+ <div className="overflow-y-auto custom-scrollbar flex-1 pr-1 space-y-4">
206
+
207
  {/* Tab 1: Content & Media */}
208
  {activeTab === 'preview' && (
209
  <div className="space-y-4">
 
259
  <span>{copiedRaw ? 'Copied' : 'Copy Payload'}</span>
260
  </button>
261
  </div>
262
+ <div className="p-3.5 rounded-xl bg-input/50 border border-border/70 font-mono text-xs leading-relaxed text-foreground/90 max-h-56 overflow-y-auto custom-scrollbar select-all whitespace-pre-wrap">
263
  {template.content}
264
  </div>
265
  </div>
 
314
  return (
315
  <div
316
  key={idx}
317
+ className="p-3.5 rounded-xl bg-input/40 hover:bg-input/60 border border-border/70 hover:border-indigo-500/40 transition-all text-xs space-y-2 group"
318
  >
319
  <div className="flex items-center justify-between pb-1.5 border-b border-border/40">
320
  <div className="flex items-center gap-2">
 
368
  </button>
369
  </div>
370
 
371
+ {/* Chat Box Container with internal scroll so modal stays fixed in size and position */}
372
+ <div className="p-4 sm:p-5 rounded-2xl bg-[#0e1621] border border-[#2b3a4a] shadow-inner flex flex-col h-[340px] max-h-[340px] overflow-y-auto custom-scrollbar">
373
 
374
  {/* Telegram Message Bubble */}
375
+ <div className="max-w-[88%] self-start rounded-2xl bg-[#182533] border border-[#232e3c] p-3 text-white shadow-md space-y-2 shrink-0">
376
 
377
  {/* Sender Title */}
378
  <div className="text-[11px] font-bold text-[#56b0f5]">
 
381
 
382
  {/* Attached media preview if any */}
383
  {mediaUrls.length > 0 && (
384
+ <div className="rounded-xl overflow-hidden border border-white/10 max-h-44 aspect-video bg-black/60 shrink-0">
385
  {mediaUrls[0].includes('.mp4') ? (
386
  <div className="h-full flex items-center justify-center text-indigo-400 gap-2">
387
  <Film size={28} />
 
398
  )}
399
 
400
  {/* Message Body with strictly preserved paragraphs */}
401
+ <div className="text-xs leading-relaxed text-slate-100 whitespace-pre-wrap break-words">
402
  {applySampleVariables(currentSpun || spinText(template.content))}
403
  </div>
404
 
 
413
  </div>
414
  )}
415
 
416
+ </div>
417
  </div>
418
  </div>
419
  );