/**
 * Pricing Section Styles
 *
 * Inspired by pricing-concept.png design
 * Uses Lexend font with system font fallback
 */

@font-face {
  font-family: 'Lexend';
  src: url('/assets/fonts/Lexend-Regular.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Lexend';
  src: url('/assets/fonts/Lexend-Medium.ttf') format('truetype');
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Lexend';
  src: url('/assets/fonts/Lexend-SemiBold.ttf') format('truetype');
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

/* Pricing Section Container */
.pricing-section {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-top: 24px;
}

/* Pricing Card Wrapper (for card + disclaimer) */
.pricing-card-wrapper {
  display: flex;
  flex-direction: column;
  gap: 0;
  height: 100%; /* Fill grid cell height */
}

/* Pricing Card */
.pricing-card {
  background: white;
  border-radius: 16px;
  padding: 16px 22px 24px 22px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
  border: 1px solid #e0e0e0;
  display: flex;
  flex-direction: column;
  gap: 6px;
  position: relative;
  font-family: 'Lexend', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* Current plan styling */
.pricing-card.current {
  border: 2px solid #e0e0e0;
}

/* Pricing Header */
.pricing-header {
  display: flex;
  flex-direction: column;
}

.pricing-plan-name {
  font-size: 20px;
  font-weight: 600;
  color: #1f2937;
  margin: 0;
}

/* Badge for current plan */
.badge-current {
  display: inline-block;
  background: #f3f4f6;
  color: #6b7280;
  padding: 4px 12px;
  border-radius: 12px;
  font-size: 13px;
  font-weight: 500;
  width: fit-content;
  margin-top: 4px;
}

/* Pricing Amount */
.pricing-amount {
  display: flex;
  align-items: baseline;
  gap: 4px;
  margin: 0;
}

.pricing-price {
  font-size: 48px;
  font-weight: 600;
  color: #1f2937;
  line-height: 1;
  letter-spacing: -0.02em;
}

/* Smaller font size for EUR prices */
.pricing-price.eur {
  font-size: 42px;
}

.pricing-duration {
  font-size: 16px;
  color: #6b7280;
  font-weight: 400;
}

/* Pricing Features */
.pricing-features {
  font-size: 16px;
  color: #1f2937;
  margin: 0;
  font-weight: 400;
}

.pricing-features .period {
  color: #9ca3af;
  font-weight: 400;
}

/* Organization plan features list */
.pricing-features-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 6px;
  margin-bottom: 6px;
}

.pricing-feature-line {
  font-size: 15px;
  color: #1f2937;
  margin: 0;
  line-height: 1.5;
  font-weight: 400;
}

/* Pricing CTA */
.pricing-cta {
  padding-top: 16px;
}

/* Downgrade note for free plan (outside card, on beige background) */
.pricing-downgrade-note {
  font-size: 13px;
  color: #939393;
  margin: 8px 0 0 0;
  padding: 0 4px;
  line-height: 1.4;
  font-weight: 400;
  text-align: left;
}

.btn-pricing {
  width: 100%;
  padding: 10px 24px;
  font-size: 14px;
  font-weight: 400;
  border-radius: 12px;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: 'Lexend', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

/* Purple gradient button for paid plans */
.btn-pricing.primary {
  background: linear-gradient(135deg, #7c3aed 0%, #a855f7 100%);
  color: white;
  box-shadow: 0 2px 8px rgba(124, 58, 237, 0.3);
}

.btn-pricing.primary:hover:not(:disabled) {
  background: linear-gradient(135deg, #6d28d9 0%, #9333ea 100%);
  box-shadow: 0 4px 12px rgba(124, 58, 237, 0.4);
  transform: translateY(-1px);
}

.btn-pricing.primary:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

/* Gray button for current/free plan */
.btn-pricing.secondary {
  background: #f3f4f6;
  color: #6b7280;
  cursor: default;
}

.btn-pricing.secondary:hover {
  background: #f3f4f6;
  transform: none;
}

/* Purple downgrade button */
.btn-pricing.downgrade {
  background: linear-gradient(135deg, #9333ea 0%, #a855f7 100%);
  color: white;
  box-shadow: 0 2px 8px rgba(147, 51, 234, 0.3);
}

.btn-pricing.downgrade:hover:not(:disabled) {
  background: linear-gradient(135deg, #7e22ce 0%, #9333ea 100%);
  box-shadow: 0 4px 12px rgba(147, 51, 234, 0.4);
  transform: translateY(-1px);
}

/* Loading state */
.btn-pricing.loading {
  opacity: 0.7;
  cursor: not-allowed;
  pointer-events: none;
}

/* Arrow icon */
.pricing-arrow {
  width: 21px;
  height: 9px;
  transition: transform 0.2s ease;
}

.btn-pricing:hover:not(:disabled) .pricing-arrow {
  transform: translateX(3px);
}

/* Pricing header section */
.pricing-header-section {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
  gap: 24px;
}

.pricing-header-content {
  padding-left: 16px;
}

.pricing-header-content h2 {
  font-size: 24px;
  font-weight: 600;
  color: #111827;
  margin: 0 0 4px 0;
}

.upgrade-description {
  font-size: 14px;
  color: #6b7280;
  margin: 0;
}

/* Manage subscription button */
.btn-manage {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  font-size: 14px;
  font-weight: 500;
  color: #7c3aed;
  background: white;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: 'Lexend', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.btn-manage:hover {
  background: #faf5ff;
  border-color: #c4b5fd;
}

.btn-manage svg {
  width: 16px;
  height: 16px;
}

/* Hidden utility class */
.hidden {
  display: none !important;
}

/* Responsive Design */
@media (max-width: 1024px) {
  .pricing-section {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .pricing-header-section {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }

  .pricing-section {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .pricing-card {
    padding: 24px;
  }

  .pricing-price {
    font-size: 40px;
  }

  .pricing-duration {
    font-size: 14px;
  }

  .pricing-features {
    font-size: 14px;
  }

  .btn-pricing {
    padding: 12px 20px;
    font-size: 15px;
  }
}

@media (max-width: 480px) {
  .pricing-card {
    padding: 20px;
  }

  .pricing-price {
    font-size: 36px;
  }

  .pricing-plan-name {
    font-size: 18px;
  }
}
