/* ===============================================
   PRICING SECTION - Formules Tarifaires
   =============================================== */

.pricing {
  padding: var(--space-3xl) 0;
  background: linear-gradient(180deg, var(--bg-primary) 0%, var(--bg-secondary) 100%);
  position: relative;
}

/* Currency Selector */
.currency-selector {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  margin-top: 1.5rem;
  padding: 1rem;
  background: rgba(139, 92, 246, 0.1);
  border: 1px solid rgba(139, 92, 246, 0.3);
  border-radius: 12px;
  max-width: 400px;
  margin-left: auto;
  margin-right: auto;
}

.currency-selector label {
  color: var(--text-primary);
  font-weight: 600;
  font-size: 0.95rem;
}

.currency-selector select {
  padding: 0.5rem 1rem;
  background: rgba(17, 24, 39, 0.8);
  border: 1px solid rgba(139, 92, 246, 0.3);
  border-radius: 8px;
  color: var(--text-primary);
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 0.3s;
  min-width: 200px;
}

.currency-selector select:hover {
  border-color: #8b5cf6;
}

.currency-selector select:focus {
  outline: none;
  border-color: #8b5cf6;
  box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.2);
}

.currency-selector select option {
  background: #1f2937;
  color: var(--text-primary);
  padding: 0.5rem;
}

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: var(--space-xl);
  margin-top: var(--space-2xl);
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
}

/* Loading state */
.pricing-loading {
  grid-column: 1 / -1;
  text-align: center;
  padding: var(--space-3xl) 0;
  color: var(--text-secondary);
}

.spinner {
  width: 48px;
  height: 48px;
  border: 4px solid rgba(255, 255, 255, 0.1);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin: 0 auto var(--space-md);
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* Pricing Cards */
.pricing-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: var(--space-xl);
  position: relative;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  backdrop-filter: blur(10px);
  display: flex;
  flex-direction: column;
}

.pricing-card:hover {
  transform: translateY(-8px);
  border-color: var(--primary);
  box-shadow: 0 20px 40px rgba(99, 102, 241, 0.2);
}

/* Popular badge */
.pricing-card.popular {
  border-color: var(--primary);
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.1) 0%, rgba(139, 92, 246, 0.1) 100%);
}

.popular-badge {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--gradient-primary);
  color: white;
  padding: var(--space-sm) var(--space-lg);
  border-radius: 20px;
  font-size: var(--font-size-xs);
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  white-space: nowrap;
  box-shadow: 0 4px 12px rgba(99, 102, 241, 0.4);
}

/* Pricing Header */
.pricing-header {
  text-align: center;
  padding-bottom: var(--space-lg);
  border-bottom: 1px solid var(--border);
}

.plan-icon {
  font-size: 3rem;
  margin-bottom: var(--space-md);
  display: inline-block;
  animation: float 3s ease-in-out infinite;
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

.pricing-title {
  font-size: var(--font-size-2xl);
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: var(--space-md);
}

.pricing-price {
  display: flex;
  align-items: baseline;
  justify-content: center;
  margin-bottom: var(--space-md);
  gap: 4px;
}

.price-currency {
  font-size: var(--font-size-xl);
  font-weight: 600;
  color: var(--text-secondary);
}

.price-amount {
  font-size: var(--font-size-5xl);
  font-weight: 800;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.price-period {
  font-size: var(--font-size-sm);
  color: var(--text-secondary);
}

.pricing-description {
  color: var(--text-secondary);
  font-size: var(--font-size-sm);
  line-height: 1.5;
}

/* Features List */
.pricing-features {
  flex: 1;
  padding: var(--space-lg) 0;
}

.pricing-feature {
  display: flex;
  align-items: flex-start;
  gap: var(--space-md);
  padding: var(--space-sm) 0;
  color: var(--text-primary);
  font-size: var(--font-size-sm);
  line-height: 1.6;
}

.pricing-feature.disabled {
  color: var(--text-muted);
  opacity: 0.6;
}

.feature-check {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  color: var(--primary);
  stroke-width: 2.5;
}

.feature-cross {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  color: var(--text-muted);
  opacity: 0.5;
}

/* Trial badge */
.pricing-trial {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  margin-top: var(--space-md);
  padding: var(--space-sm);
  background: rgba(6, 182, 212, 0.1);
  border: 1px solid rgba(6, 182, 212, 0.3);
  border-radius: 8px;
  color: #06b6d4;
  font-size: var(--font-size-xs);
  font-weight: 600;
}

.pricing-trial svg {
  width: 16px;
  height: 16px;
}

/* Buttons */
.pricing-card button {
  margin-top: auto;
}

/* Plan-specific styles */
.pricing-card.free {
  border-color: rgba(16, 185, 129, 0.3);
}

.pricing-card.free:hover {
  border-color: #10b981;
  box-shadow: 0 20px 40px rgba(16, 185, 129, 0.2);
}

.pricing-card.premium {
  border-color: rgba(6, 182, 212, 0.3);
}

.pricing-card.premium:hover {
  border-color: #06b6d4;
  box-shadow: 0 20px 40px rgba(6, 182, 212, 0.2);
}

.pricing-card.gold {
  border-color: rgba(245, 158, 11, 0.3);
}

.pricing-card.gold:hover {
  border-color: #f59e0b;
  box-shadow: 0 20px 40px rgba(245, 158, 11, 0.2);
}

.pricing-card.platinum {
  border-color: rgba(139, 92, 246, 0.3);
}

.pricing-card.platinum:hover {
  border-color: #8b5cf6;
  box-shadow: 0 20px 40px rgba(139, 92, 246, 0.2);
}

/* Error state */
.pricing-error {
  grid-column: 1 / -1;
  text-align: center;
  padding: var(--space-2xl);
  color: var(--text-secondary);
}

.pricing-error p {
  font-size: var(--font-size-lg);
}

/* Responsive */
@media (max-width: 1024px) {
  .pricing-grid {
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: var(--space-lg);
  }
}

@media (max-width: 768px) {
  .pricing {
    padding: var(--space-2xl) 0;
  }
  
  .pricing-grid {
    grid-template-columns: 1fr;
    gap: var(--space-md);
  }
  
  .pricing-card {
    padding: var(--space-lg);
  }
  
  .price-amount {
    font-size: var(--font-size-4xl);
  }
  
  .popular-badge {
    font-size: 0.7rem;
    padding: var(--space-xs) var(--space-md);
  }
}

