PluginProbe
AI Builder – Generate pages, blocks, images & translate with AI / 2.3.0
AI Builder – Generate pages, blocks, images & translate with AI v2.3.0
2.7.10 2.7.9 2.7.8 2.0.8 2.0.9 2.1.0 2.1.1 2.1.10 2.1.11 2.1.12 2.1.2 2.1.3 2.1.4 2.1.5 2.1.6 2.1.7 2.1.8 2.1.9 2.2.0 2.2.1 2.2.2 2.2.3 2.2.4 2.3.0 2.3.10 All 122 releases
ai-builder / admin / pages / credits.php

credits.php in AI Builder – Generate pages, blocks, images & translate with AI 2.3.0, at admin/pages/credits.php

715 lines 29.0 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 if (!defined('ABSPATH'))
3 exit; // Exit if accessed directly
4
5 // Vérifier si l'utilisateur a un token JWT
6 $jwt_token = get_option('aibui_jwt_token', '');
7 if (empty($jwt_token)) {
8 echo '<div class="ai-auth-container"><div class="ai-message error">' . esc_html__('Please sign in to access your credits.', 'ai-builder') . '</div></div>';
9 return;
10 }
11 ?>
12
13 <div class="ai-credits-container ai-fade-in">
14 <!-- Header -->
15 <div class="ai-credits-header">
16 <h1>AI Credits & Subscription</h1>
17 <p>Manage your AI credits and subscription plan</p>
18 </div>
19
20 <!-- Current Status -->
21 <div class="ai-status-section">
22 <div class="ai-status-card">
23 <div class="ai-status-icon">
24 <svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
25 <circle cx="12" cy="12" r="10" stroke="currentColor" stroke-width="2" />
26 <path d="M12 6V12L16 14" stroke="currentColor" stroke-width="2" stroke-linecap="round"
27 stroke-linejoin="round" />
28 </svg>
29 </div>
30 <div class="ai-status-content">
31 <h3>Current Credits</h3>
32 <div class="ai-credits-display" id="current-credits">
33 <span class="ai-loading" style="display: none;"></span>
34 Loading...
35 </div>
36 </div>
37 </div>
38
39 <div class="ai-status-card">
40 <div class="ai-status-icon">
41 <svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
42 <path d="M12 2L2 7L12 12L22 7L12 2Z" stroke="currentColor" stroke-width="2"
43 stroke-linejoin="round" />
44 <path d="M2 17L12 22L22 17" stroke="currentColor" stroke-width="2" stroke-linejoin="round" />
45 <path d="M2 12L12 17L22 12" stroke="currentColor" stroke-width="2" stroke-linejoin="round" />
46 </svg>
47 </div>
48 <div class="ai-status-content">
49 <h3>Subscription Plan</h3>
50 <div class="ai-plan-display" id="current-plan">
51 <span class="ai-loading" style="display: none;"></span>
52 Loading...
53 </div>
54 </div>
55 </div>
56 </div>
57
58 <!-- Subscription Management -->
59 <div class="ai-section">
60 <div class="ai-section-header">
61 <h2>Subscription Management</h2>
62 <p>Choose the perfect plan for your AI needs</p>
63 </div>
64
65 <div class="ai-subscription-actions" id="subscription-plans-container">
66 <!-- Plan Essential -->
67 <div class="ai-plan-card-wrapper" data-plan="essential">
68 <div class="ai-plan-card ai-plan-essential">
69 <div class="ai-plan-badge">Essential</div>
70 <div class="ai-plan-header">
71 <div class="ai-plan-title">
72 <h3>Essential</h3>
73 </div>
74 </div>
75
76 <div class="ai-plan-features">
77 <div class="ai-feature-item">
78 <div class="ai-feature-icon">
79 <svg width="18" height="18" viewBox="0 0 24 24" fill="none"
80 xmlns="http://www.w3.org/2000/svg">
81 <path d="M20 6L9 17L4 12" stroke="currentColor" stroke-width="2.5"
82 stroke-linecap="round" stroke-linejoin="round" />
83 </svg>
84 </div>
85 <span class="ai-feature-text">750 credits every month</span>
86 </div>
87
88 <div class="ai-feature-item">
89 <div class="ai-feature-icon">
90 <svg width="18" height="18" viewBox="0 0 24 24" fill="none"
91 xmlns="http://www.w3.org/2000/svg">
92 <path d="M20 6L9 17L4 12" stroke="currentColor" stroke-width="2.5"
93 stroke-linecap="round" stroke-linejoin="round" />
94 </svg>
95 </div>
96 <span class="ai-feature-text">Generation of pages, blocks, images & texts</span>
97 </div>
98
99 <div class="ai-feature-item">
100 <div class="ai-feature-icon">
101 <svg width="18" height="18" viewBox="0 0 24 24" fill="none"
102 xmlns="http://www.w3.org/2000/svg">
103 <path d="M20 6L9 17L4 12" stroke="currentColor" stroke-width="2.5"
104 stroke-linecap="round" stroke-linejoin="round" />
105 </svg>
106 </div>
107 <span class="ai-feature-text">Extra credits available on demand</span>
108 </div>
109 </div>
110
111 <div class="ai-plan-header">
112 <div class="ai-plan-title">
113 <div class="ai-plan-price">
114 <span class="ai-price-amount">$9</span>
115 <span class="ai-price-period">/month</span>
116 </div>
117 <span class="ai-price-credit">$0.012 per credit</span>
118 </div>
119 </div>
120
121 <div class="ai-plan-cta">
122 <button type="button" class="ai-cta-btn ai-plan-btn" data-subscription-type="essential">
123 <span class="ai-loading" style="display: none;"></span>
124 <span class="btn-text">Choose Essential</span>
125 </button>
126 </div>
127 </div>
128 </div>
129
130 <!-- Plan Premium -->
131 <div class="ai-plan-card-wrapper" data-plan="premium">
132 <div class="ai-plan-card ai-plan-premium ai-plan-popular">
133 <div class="ai-plan-badge ai-plan-badge-popular">Most Popular</div>
134 <div class="ai-plan-header">
135 <div class="ai-plan-title">
136 <h3>Premium</h3>
137 </div>
138 </div>
139
140 <div class="ai-plan-features">
141 <div class="ai-feature-item">
142 <div class="ai-feature-icon">
143 <svg width="18" height="18" viewBox="0 0 24 24" fill="none"
144 xmlns="http://www.w3.org/2000/svg">
145 <path d="M20 6L9 17L4 12" stroke="currentColor" stroke-width="2.5"
146 stroke-linecap="round" stroke-linejoin="round" />
147 </svg>
148 </div>
149 <span class="ai-feature-text">2000 credits every month</span>
150 </div>
151
152 <div class="ai-feature-item">
153 <div class="ai-feature-icon">
154 <svg width="18" height="18" viewBox="0 0 24 24" fill="none"
155 xmlns="http://www.w3.org/2000/svg">
156 <path d="M20 6L9 17L4 12" stroke="currentColor" stroke-width="2.5"
157 stroke-linecap="round" stroke-linejoin="round" />
158 </svg>
159 </div>
160 <span class="ai-feature-text">Generation of pages, blocks, images & texts</span>
161 </div>
162
163 <div class="ai-feature-item">
164 <div class="ai-feature-icon">
165 <svg width="18" height="18" viewBox="0 0 24 24" fill="none"
166 xmlns="http://www.w3.org/2000/svg">
167 <path d="M20 6L9 17L4 12" stroke="currentColor" stroke-width="2.5"
168 stroke-linecap="round" stroke-linejoin="round" />
169 </svg>
170 </div>
171 <span class="ai-feature-text">Extra credits available on demand</span>
172 </div>
173 </div>
174
175 <div class="ai-plan-header">
176 <div class="ai-plan-title">
177 <div class="ai-plan-price">
178 <span class="ai-price-amount">$19</span>
179 <span class="ai-price-period">/month</span>
180 </div>
181 <span class="ai-price-credit">$0.009 per credit</span>
182 </div>
183 </div>
184
185 <div class="ai-plan-cta">
186 <button type="button" class="ai-cta-btn ai-plan-btn" data-subscription-type="premium">
187 <span class="ai-loading" style="display: none;"></span>
188 <span class="btn-text">Choose Premium</span>
189 </button>
190 </div>
191 </div>
192 </div>
193
194 <!-- Plan Creator -->
195 <div class="ai-plan-card-wrapper" data-plan="creator">
196 <div class="ai-plan-card ai-plan-creator">
197 <div class="ai-plan-badge">Creator</div>
198 <div class="ai-plan-header">
199 <div class="ai-plan-title">
200 <h3>Creator</h3>
201 </div>
202 </div>
203
204 <div class="ai-plan-features">
205 <div class="ai-feature-item">
206 <div class="ai-feature-icon">
207 <svg width="18" height="18" viewBox="0 0 24 24" fill="none"
208 xmlns="http://www.w3.org/2000/svg">
209 <path d="M20 6L9 17L4 12" stroke="currentColor" stroke-width="2.5"
210 stroke-linecap="round" stroke-linejoin="round" />
211 </svg>
212 </div>
213 <span class="ai-feature-text">6000 credits every month</span>
214 </div>
215
216 <div class="ai-feature-item">
217 <div class="ai-feature-icon">
218 <svg width="18" height="18" viewBox="0 0 24 24" fill="none"
219 xmlns="http://www.w3.org/2000/svg">
220 <path d="M20 6L9 17L4 12" stroke="currentColor" stroke-width="2.5"
221 stroke-linecap="round" stroke-linejoin="round" />
222 </svg>
223 </div>
224 <span class="ai-feature-text">Generation of pages, blocks, images & texts</span>
225 </div>
226
227 <div class="ai-feature-item">
228 <div class="ai-feature-icon">
229 <svg width="18" height="18" viewBox="0 0 24 24" fill="none"
230 xmlns="http://www.w3.org/2000/svg">
231 <path d="M20 6L9 17L4 12" stroke="currentColor" stroke-width="2.5"
232 stroke-linecap="round" stroke-linejoin="round" />
233 </svg>
234 </div>
235 <span class="ai-feature-text">Extra credits available on demand</span>
236 </div>
237 </div>
238
239 <div class="ai-plan-header">
240 <div class="ai-plan-title">
241 <div class="ai-plan-price">
242 <span class="ai-price-amount">$49</span>
243 <span class="ai-price-period">/month</span>
244 </div>
245 <span class="ai-price-credit">$0.008 per credit</span>
246 </div>
247 </div>
248
249 <div class="ai-plan-cta">
250 <button type="button" class="ai-cta-btn ai-plan-btn" data-subscription-type="creator">
251 <span class="ai-loading" style="display: none;"></span>
252 <span class="btn-text">Choose Creator</span>
253 </button>
254 </div>
255 </div>
256 </div>
257 </div>
258
259 <div class="ai-section-header" style="margin-bottom: 120px;">
260 </div>
261 </div>
262
263
264
265 <!-- Credit Purchase -->
266 <div class="ai-section" id="credit-purchase-section">
267 <div class="ai-section-header">
268 <h2></h2>
269 <p></p>
270 </div>
271
272 <div class="ai-credit-actions">
273 <div class="ai-action-card" id="credit-purchase-card">
274 <div class="ai-action-icon">
275 <svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
276 <path d="M12 1V23" stroke="currentColor" stroke-width="2" stroke-linecap="round"
277 stroke-linejoin="round" />
278 <path
279 d="M17 5H9.5C8.57174 5 7.6815 5.36875 7.02513 6.02513C6.36875 6.6815 6 7.57174 6 8.5C6 9.42826 6.36875 10.3185 7.02513 10.9749C7.6815 11.6313 8.57174 12 9.5 12H14.5C15.4283 12 16.3185 12.3687 16.9749 13.0251C17.6313 13.6815 18 14.5717 18 15.5C18 16.4283 17.6313 17.3185 16.9749 17.9749C16.3185 18.6313 15.4283 19 14.5 19H6"
280 stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" />
281 </svg>
282 </div>
283 <div class="ai-action-content">
284 <h3>Purchase 750 Credits</h3>
285 <p>Buy credits immediately, pay once.</p>
286
287 <!-- Message pour utilisateurs sans abonnement -->
288 <div id="subscription-required-message" class="ai-subscription-required" style="display: none;">
289 <div class="ai-warning-icon">
290 <svg width="20" height="20" viewBox="0 0 24 24" fill="none"
291 xmlns="http://www.w3.org/2000/svg">
292 <path
293 d="M10.29 3.86L1.82 18A2 2 0 0 0 3.54 21H20.46A2 2 0 0 0 22.18 18L13.71 3.86A2 2 0 0 0 10.29 3.86Z"
294 stroke="currentColor" stroke-width="2" stroke-linecap="round"
295 stroke-linejoin="round" />
296 <path d="M12 9V13" stroke="currentColor" stroke-width="2" stroke-linecap="round"
297 stroke-linejoin="round" />
298 <circle cx="12" cy="17" r="1" stroke="currentColor" stroke-width="2" />
299 </svg>
300 </div>
301 <div class="ai-warning-content">
302 <strong>Active subscription required</strong>
303 <p>You need an active subscription to purchase additional credits. Get a subscription first
304 to unlock this feature.</p>
305 </div>
306 </div>
307
308 <button type="button" class="ai-primary-btn" id="buy-credits-btn" onclick="handleCreditPurchase()">
309 <svg width="16" height="16" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
310 <path d="M12 2V6" stroke="currentColor" stroke-width="2" stroke-linecap="round"
311 stroke-linejoin="round" />
312 <path d="M12 18V22" stroke="currentColor" stroke-width="2" stroke-linecap="round"
313 stroke-linejoin="round" />
314 <path d="M4.93 4.93L7.76 7.76" stroke="currentColor" stroke-width="2" stroke-linecap="round"
315 stroke-linejoin="round" />
316 <path d="M16.24 16.24L19.07 19.07" stroke="currentColor" stroke-width="2"
317 stroke-linecap="round" stroke-linejoin="round" />
318 <path d="M2 12H6" stroke="currentColor" stroke-width="2" stroke-linecap="round"
319 stroke-linejoin="round" />
320 <path d="M18 12H22" stroke="currentColor" stroke-width="2" stroke-linecap="round"
321 stroke-linejoin="round" />
322 <path d="M4.93 19.07L7.76 16.24" stroke="currentColor" stroke-width="2"
323 stroke-linecap="round" stroke-linejoin="round" />
324 <path d="M16.24 7.76L19.07 4.93" stroke="currentColor" stroke-width="2"
325 stroke-linecap="round" stroke-linejoin="round" />
326 </svg>
327 Buy Credits
328 </button>
329 </div>
330 </div>
331 </div>
332 </div>
333
334 <!-- Account Management -->
335 <div class="ai-section">
336 <div class="ai-section-header">
337 <h2>Account Management</h2>
338 <p>Manage your billing and account settings</p>
339 </div>
340
341 <div class="ai-account-actions">
342 <div class="ai-action-card">
343 <div class="ai-action-icon">
344 <svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
345 <path
346 d="M20 21V19C20 17.9391 19.5786 16.9217 18.8284 16.1716C18.0783 15.4214 17.0609 15 16 15H8C6.93913 15 5.92172 15.4214 5.17157 16.1716C4.42143 16.9217 4 17.9391 4 19V21"
347 stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" />
348 <circle cx="12" cy="7" r="4" stroke="currentColor" stroke-width="2" stroke-linecap="round"
349 stroke-linejoin="round" />
350 </svg>
351 </div>
352 <div class="ai-action-content">
353 <h3>Stripe Account</h3>
354 <p>Access your Stripe dashboard for billing management</p>
355 <button type="button" class="ai-secondary-btn" onclick="handleStripeAccount()">
356 <svg width="16" height="16" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
357 <path d="M18 13V19A2 2 0 0 1 16 21H8A2 2 0 0 1 6 19V13" stroke="currentColor"
358 stroke-width="2" stroke-linecap="round" stroke-linejoin="round" />
359 <path d="M12 3V15" stroke="currentColor" stroke-width="2" stroke-linecap="round"
360 stroke-linejoin="round" />
361 <path d="M9 6L12 3L15 6" stroke="currentColor" stroke-width="2" stroke-linecap="round"
362 stroke-linejoin="round" />
363 </svg>
364 View Stripe Account
365 </button>
366 </div>
367 </div>
368 </div>
369 </div>
370
371 <!-- Manage Subscription (shown when user has active subscription) -->
372 <div class="ai-section">
373 <div class="ai-action-card" id="cancel-subscription-card" style="display: none;">
374 <div class="ai-action-icon">
375 <svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
376 <path d="M12 2V6" stroke="currentColor" stroke-width="2" stroke-linecap="round"
377 stroke-linejoin="round" />
378 <path d="M12 18V22" stroke="currentColor" stroke-width="2" stroke-linecap="round"
379 stroke-linejoin="round" />
380 <path d="M4.93 4.93L7.76 7.76" stroke="currentColor" stroke-width="2" stroke-linecap="round"
381 stroke-linejoin="round" />
382 <path d="M16.24 16.24L19.07 19.07" stroke="currentColor" stroke-width="2" stroke-linecap="round"
383 stroke-linejoin="round" />
384 <path d="M2 12H6" stroke="currentColor" stroke-width="2" stroke-linecap="round"
385 stroke-linejoin="round" />
386 <path d="M18 12H22" stroke="currentColor" stroke-width="2" stroke-linecap="round"
387 stroke-linejoin="round" />
388 <path d="M4.93 19.07L7.76 16.24" stroke="currentColor" stroke-width="2" stroke-linecap="round"
389 stroke-linejoin="round" />
390 <path d="M16.24 7.76L19.07 4.93" stroke="currentColor" stroke-width="2" stroke-linecap="round"
391 stroke-linejoin="round" />
392 </svg>
393 </div>
394 <div class="ai-action-content">
395 <h3>Manage Subscription</h3>
396 <button type="button" class="ai-cancel-subscription-btn" id="subscription-btn" style="opacity: 0.7; font-weight: 400;">
397 <span class="ai-loading" style="display: none;"></span>
398 <span class="btn-text">Cancel Subscription</span>
399 </button>
400 </div>
401 </div>
402 </div>
403
404 <!-- Messages -->
405 <div id="message-container"></div>
406 </div>
407
408 <!-- Confirmation Modal -->
409 <div id="confirmation-modal" class="ai-modal" style="display: none;">
410 <div class="ai-modal-content">
411 <div class="ai-modal-header">
412 <h3>Cancel Subscription</h3>
413 <button type="button" class="ai-modal-close" onclick="closeModal()">×</button>
414 </div>
415 <div class="ai-modal-body">
416 <p>Are you sure you want to cancel your subscription? You will lose access to monthly credits at the end of
417 your current billing period.</p>
418 <p style="margin-top: 16px; padding: 12px; background: #fef3c7; border-left: 3px solid #f59e0b; border-radius: 4px; color: #92400e;">
419 <strong>Important:</strong> Once your credits are used up, you will no longer be able to use AI features such as page translation and AI-powered content creation.
420 </p>
421 </div>
422 <div class="ai-modal-footer">
423 <button type="button" class="ai-secondary-btn" onclick="closeModal()">Keep Subscription</button>
424 <button type="button" class="ai-danger-btn" onclick="confirmCancelSubscription()">
425 <span class="ai-loading" style="display: none;"></span>
426 Yes, Cancel Subscription
427 </button>
428 </div>
429 </div>
430 </div>
431
432 <style>
433 /* Subscription Plans Container */
434 .ai-subscription-actions {
435 display: grid;
436 grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
437 gap: 24px;
438 margin-bottom: 24px;
439 }
440
441 .ai-plan-card-wrapper {
442 position: relative;
443 }
444
445 /* Modern Plan Card Styles */
446 .ai-plan-card {
447 --plan-accent: #4f46e5;
448 background: #ffffff;
449 border-radius: 16px;
450 padding: 32px;
451 color: #0f172a;
452 box-shadow: 0 18px 30px rgba(15, 23, 42, 0.07);
453 border: 1px solid #e4e8ef;
454 position: relative;
455 overflow: hidden;
456 transition: all 0.3s ease;
457 height: 100%;
458 display: flex;
459 flex-direction: column;
460 }
461
462 .ai-plan-card:hover {
463 transform: translateY(-4px);
464 box-shadow: 0 24px 45px rgba(15, 23, 42, 0.12);
465 }
466
467 .ai-plan-card::before {
468 content: '';
469 position: absolute;
470 top: 0;
471 left: 16px;
472 right: 16px;
473 height: 3px;
474 border-radius: 999px;
475 background: linear-gradient(90deg, var(--plan-accent), rgba(79, 70, 229, 0.1));
476 }
477
478 .ai-plan-card>* {
479 position: relative;
480 z-index: 1;
481 }
482
483 /* Plan Badge */
484 .ai-plan-badge {
485 position: absolute;
486 top: 18px;
487 right: 18px;
488 background: rgba(15, 23, 42, 0.08);
489 color: #0f172a;
490 padding: 6px 14px;
491 border-radius: 999px;
492 font-size: 11px;
493 font-weight: 600;
494 text-transform: uppercase;
495 letter-spacing: 0.6px;
496 }
497
498 .ai-plan-badge-popular {
499 background: rgba(79, 70, 229, 0.12);
500 color: #4338ca;
501 }
502
503 /* Plan Colors */
504 .ai-plan-essential {
505 --plan-accent: #1d4ed8;
506 }
507
508 .ai-plan-premium {
509 --plan-accent: #7c3aed;
510 }
511
512 .ai-plan-creator {
513 --plan-accent: #db2777;
514 }
515
516 .ai-plan-popular {
517 box-shadow: 0 24px 45px rgba(76, 29, 149, 0.18);
518 border-color: rgba(76, 29, 149, 0.2);
519 }
520
521 .ai-plan-header {
522 text-align: center;
523 margin-bottom: 24px;
524 }
525
526 .ai-plan-header:first-of-type {
527 margin-top: 16px;
528 }
529
530 .ai-plan-title h3 {
531 font-size: 26px;
532 font-weight: 600;
533 margin: 0 0 6px 0;
534 color: #0f172a;
535 }
536
537 .ai-plan-price {
538 display: flex;
539 align-items: baseline;
540 justify-content: center;
541 gap: 4px;
542 }
543
544 .ai-price-amount {
545 font-size: 38px;
546 font-weight: 600;
547 color: #0f172a;
548 margin-top: 12px;
549 }
550
551 .ai-price-period {
552 font-size: 16px;
553 font-weight: 500;
554 color: #6b7280;
555 }
556
557 .ai-plan-features {
558 margin-bottom: 24px;
559 flex-grow: 1;
560 }
561
562 .ai-feature-item {
563 display: flex;
564 align-items: center;
565 gap: 12px;
566 margin-bottom: 16px;
567 padding: 12px 16px;
568 background: #f8fafc;
569 border-radius: 12px;
570 border: 1px solid #e2e8f0;
571 transition: all 0.3s ease;
572 }
573
574 .ai-feature-item:hover {
575 border-color: rgba(79, 70, 229, 0.4);
576 transform: translateX(4px);
577 }
578
579 .ai-feature-icon {
580 flex-shrink: 0;
581 width: 32px;
582 height: 32px;
583 background: rgba(79, 70, 229, 0.12);
584 border-radius: 50%;
585 display: flex;
586 align-items: center;
587 justify-content: center;
588 color: var(--plan-accent);
589 border: 1px solid rgba(79, 70, 229, 0.2);
590 }
591
592 .ai-feature-text {
593 font-size: 16px;
594 font-weight: 500;
595 color: #0f172a;
596 line-height: 1.4;
597 }
598
599 .ai-plan-cta {
600 text-align: center;
601 }
602
603 .ai-cta-btn {
604 background: var(--plan-accent);
605 color: #fff;
606 border: 2px solid var(--plan-accent);
607 padding: 14px 28px;
608 border-radius: 12px;
609 font-size: 16px;
610 font-weight: 600;
611 display: inline-flex;
612 align-items: center;
613 justify-content: center;
614 gap: 8px;
615 cursor: pointer;
616 transition: all 0.3s ease;
617 box-shadow: 0 10px 25px rgba(79, 70, 229, 0.25);
618 text-transform: none;
619 letter-spacing: 0;
620 width: 100%;
621 backdrop-filter: none;
622 }
623
624 .ai-cta-btn:hover {
625 background: #fff;
626 color: var(--plan-accent);
627 transform: translateY(-2px);
628 box-shadow: 0 12px 30px rgba(15, 23, 42, 0.12);
629 }
630
631 .ai-cta-btn:active {
632 transform: translateY(0);
633 }
634
635 .ai-cta-btn:disabled {
636 opacity: 0.6;
637 cursor: not-allowed;
638 transform: none;
639 }
640
641 .ai-plan-btn.current-plan {
642 background: rgba(79, 70, 229, 0.08);
643 border-color: rgba(79, 70, 229, 0.2);
644 cursor: default;
645 }
646
647 .ai-plan-btn.current-plan:hover {
648 transform: none;
649 }
650
651 /* Action Card Container */
652 .ai-action-card {
653 background: white;
654 border-radius: 16px;
655 padding: 32px;
656 box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
657 border: 1px solid rgba(0, 0, 0, 0.06);
658 transition: all 0.3s ease;
659 }
660
661 .ai-action-card:hover {
662 transform: translateY(-4px);
663 box-shadow: 0 16px 48px rgba(0, 0, 0, 0.12);
664 }
665
666 /* Current Plan Indicator */
667 .ai-plan-card-wrapper[data-current-plan="true"] .ai-plan-card {
668 border: 3px solid rgba(255, 255, 255, 0.8);
669 box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.3), 0 24px 48px rgba(102, 126, 234, 0.3);
670 }
671
672 /* Responsive Design */
673 @media (max-width: 768px) {
674 .ai-subscription-actions {
675 grid-template-columns: 1fr;
676 }
677
678 .ai-plan-card {
679 padding: 24px;
680 }
681
682 .ai-price-amount {
683 font-size: 36px;
684 }
685
686 .ai-feature-item {
687 padding: 10px 12px;
688 }
689
690 .ai-cta-btn {
691 padding: 12px 24px;
692 font-size: 15px;
693 }
694
695 .ai-plan-badge {
696 font-size: 10px;
697 padding: 4px 8px;
698 }
699 }
700
701 /* Animation for loading states */
702 .ai-loading {
703 animation: spin 1s linear infinite;
704 }
705
706 @keyframes spin {
707 from {
708 transform: rotate(0deg);
709 }
710
711 to {
712 transform: rotate(360deg);
713 }
714 }
715 </style>