/* ============================================
   OptimalDial Pricing Page Styles
   ============================================ */

/* ----------------------------------------
   Pricing Page Header Overrides
   ---------------------------------------- */
.header-visible {
  transform: translateY(0) !important;
}

/* ----------------------------------------
   Pricing Hero
   ---------------------------------------- */
.pricing-hero {
  padding: 120px 0 48px;
  text-align: center;
  background:
    radial-gradient(ellipse 100% 80% at 50% -20%, rgba(10, 4, 54, 0.08) 0%, transparent 50%),
    linear-gradient(180deg, var(--bg-subtle) 0%, var(--bg-white) 100%);
}

.pricing-hero-content {
  max-width: 680px;
  margin: 0 auto 40px;
}

.pricing-headline {
  font-size: clamp(36px, 6vw, 56px);
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--primary);
  margin-bottom: 16px;
  line-height: 1.1;
}

.pricing-subheadline {
  font-size: 19px;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 24px;
}

.guarantee-badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 28px;
  background: var(--success-light);
  border: 2px solid var(--success-border);
  border-radius: 999px;
  font-size: 16px;
  font-weight: 700;
  color: var(--success);
  box-shadow: 0 2px 8px rgba(34, 197, 94, 0.15);
}

.guarantee-badge svg {
  color: var(--success);
  width: 22px;
  height: 22px;
}

/* ----------------------------------------
   Billing Toggle
   ---------------------------------------- */
.billing-toggle-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin-bottom: 8px;
}

.billing-toggle {
  display: inline-flex;
  position: relative;
  background: var(--bg-soft);
  border-radius: var(--radius-lg);
  padding: 4px;
  gap: 4px;
}

.billing-option {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  font-size: 15px;
  font-weight: 500;
  color: var(--text-secondary);
  background: transparent;
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: color 0.2s ease;
}

.billing-option:hover {
  color: var(--text-primary);
}

.billing-option.active {
  color: var(--text-primary);
  font-weight: 600;
  background: var(--bg-white);
  box-shadow: var(--shadow-sm);
}

.billing-save-badge {
  display: inline-flex;
  padding: 3px 8px;
  background: var(--success);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  border-radius: 999px;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.billing-option:not(.active) .billing-save-badge {
  background: var(--text-light);
}

/* Upfront Credits Badge */
.upfront-credits-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin-top: 12px;
  padding: 8px 16px;
  background: var(--success-light);
  border: 1px solid var(--success-border);
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
  color: var(--success);
}

.upfront-credits-badge svg {
  flex-shrink: 0;
}

/* ----------------------------------------
   Pricing Tiers
   ---------------------------------------- */
.pricing-tiers {
  padding: 48px 0 80px;
}

.tiers-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  max-width: 1100px;
  margin: 0 auto;
  align-items: stretch;
}

.us-only-note {
  text-align: center;
  margin-top: 24px;
  font-size: 14px;
  color: var(--text-muted);
  opacity: 0.8;
}

.tier-card {
  position: relative;
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 32px;
  display: flex;
  flex-direction: column;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.tier-card:hover {
  border-color: var(--text-light);
  box-shadow: var(--shadow-lg);
}

/* Featured tier (Professional) */
.tier-featured {
  border: 2px solid var(--primary);
  box-shadow: 0 8px 32px rgba(10, 4, 54, 0.12);
  z-index: 2;
}

.tier-featured:hover {
  border-color: var(--primary);
  box-shadow: 0 12px 40px rgba(10, 4, 54, 0.16);
}

.tier-badge {
  position: absolute;
  top: -14px;
  left: 50%;
  transform: translateX(-50%);
  padding: 6px 16px;
  background: var(--primary);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-radius: 999px;
  box-shadow: 0 4px 12px rgba(10, 4, 54, 0.25);
}

.tier-header {
  margin-bottom: 24px;
  min-height: 85px;
}

.tier-name {
  font-size: 24px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.tier-description {
  font-size: 15px;
  color: var(--text-muted);
  line-height: 1.5;
}

/* ----------------------------------------
   Tier Volume Row (consistent across cards)
   ---------------------------------------- */
.tier-volume-row {
  margin-bottom: 24px;
  min-height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Static volume value for Starter and Enterprise */
.tier-volume-value {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 52px;
  font-size: 16px;
  font-weight: 600;
  color: var(--primary);
  text-align: center;
  background: var(--bg-subtle);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
}

/* Volume Dropdown for Professional */
.volume-dropdown-wrapper {
  position: relative;
  display: block;
  width: 100%;
}

.volume-dropdown {
  width: 100%;
  height: 52px;
  padding: 0 44px 0 16px;
  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 600;
  color: var(--primary);
  background: var(--bg-white);
  border: 2px solid var(--primary);
  border-radius: var(--radius-md);
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  transition: all 0.15s ease;
}

.volume-dropdown:hover {
  background: var(--bg-subtle);
}

.volume-dropdown:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(10, 4, 54, 0.1);
}

.dropdown-arrow {
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  width: 20px;
  height: 20px;
  color: var(--primary);
  pointer-events: none;
}

/* ----------------------------------------
   Tier Pricing
   ---------------------------------------- */
.tier-pricing {
  margin-bottom: 24px;
  min-height: 130px;
}

.tier-pricing-custom {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
}

.price-display {
  display: flex;
  align-items: baseline;
  gap: 2px;
  min-height: 56px;
}

.price-currency {
  font-size: 24px;
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1;
}

.price-amount {
  font-size: 56px;
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1;
  letter-spacing: -0.02em;
}

.price-period {
  font-size: 18px;
  font-weight: 500;
  color: var(--text-muted);
  margin-left: 4px;
}

.price-custom {
  font-size: 48px;
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1;
}

.price-billing-note {
  font-size: 14px;
  color: var(--text-muted);
  margin-top: 8px;
}

.price-savings {
  margin-top: 12px;
  transition: opacity 0.2s ease;
}

.savings-badge {
  display: inline-flex;
  padding: 4px 10px;
  background: var(--success-light);
  color: var(--success);
  font-size: 13px;
  font-weight: 600;
  border-radius: 999px;
}

/* ----------------------------------------
   Tier Features
   ---------------------------------------- */
.tier-features {
  flex-grow: 1;
  margin-bottom: 24px;
}

.features-intro {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-muted);
  margin: 0 0 16px 0;
}

.feature-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.feature-list li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 10px 0;
  font-size: 15px;
  color: var(--text-secondary);
  border-bottom: 1px solid var(--border-light);
}

.feature-list li:last-child {
  border-bottom: none;
}

.feature-icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  color: var(--success);
  margin-top: 1px;
}

.feature-list li span strong {
  color: var(--text-primary);
  font-weight: 600;
}

/* ----------------------------------------
   Tier CTA
   ---------------------------------------- */
.tier-cta {
  margin-top: auto;
}

.btn-tier {
  display: block;
  width: 100%;
  padding: 14px 24px;
  font-size: 16px;
  font-weight: 600;
  text-align: center;
  border-radius: var(--radius-md);
  transition: all 0.2s ease;
  text-decoration: none;
}

.btn-tier:hover {
  text-decoration: none;
}

.tier-starter .btn-tier,
.tier-enterprise .btn-tier {
  color: var(--primary);
  background: var(--bg-white);
  border: 2px solid var(--border);
}

.tier-starter .btn-tier:hover,
.tier-enterprise .btn-tier:hover {
  background: var(--bg-subtle);
  border-color: var(--text-light);
}

.btn-tier-primary {
  color: #fff !important;
  background: var(--primary) !important;
  border: 2px solid var(--primary) !important;
  box-shadow: var(--shadow-md);
}

.btn-tier-primary:hover {
  background: var(--primary-hover) !important;
  border-color: var(--primary-hover) !important;
  box-shadow: var(--shadow-lg);
  transform: translateY(-2px);
}

.btn-tier-outline {
  color: var(--primary);
  background: var(--bg-white);
  border: 2px solid var(--border);
}

.btn-tier-outline:hover {
  background: var(--bg-subtle);
  border-color: var(--primary);
}

/* ----------------------------------------
   All Plans Include
   ---------------------------------------- */
.all-plans-section {
  padding: 0 0 80px;
}

.all-plans-card {
  max-width: 900px;
  margin: 0 auto;
  padding: 48px;
  background: linear-gradient(135deg, rgba(10, 4, 54, 0.03) 0%, rgba(10, 4, 54, 0.06) 100%);
  border: 1px solid rgba(10, 4, 54, 0.08);
  border-radius: var(--radius-xl);
}

.all-plans-title {
  font-size: 24px;
  font-weight: 700;
  color: var(--text-primary);
  text-align: center;
  margin-bottom: 32px;
}

.all-plans-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px 32px;
}

.all-plans-item {
  display: flex;
  align-items: center;
  gap: 12px;
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.4s ease, transform 0.4s ease;
}

.all-plans-item.visible {
  opacity: 1;
  transform: translateY(0);
}

.all-plans-icon {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  flex-shrink: 0;
}

.all-plans-icon svg {
  width: 20px;
  height: 20px;
  color: var(--primary);
}

.all-plans-item span {
  font-size: 15px;
  font-weight: 500;
  color: var(--text-secondary);
}

/* ----------------------------------------
   Flex Credits Top-Up Module
   ---------------------------------------- */
.topup-module {
  margin-top: 32px;
  display: flex;
  justify-content: center;
}

.topup-module-inner {
  display: flex;
  align-items: flex-start;
  gap: 20px;
  max-width: 520px;
  padding: 24px 28px;
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  box-shadow:
    0 1px 3px rgba(0, 0, 0, 0.04),
    0 4px 12px rgba(10, 4, 54, 0.03);
  position: relative;
  overflow: hidden;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.topup-module-inner::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, #F59E0B 0%, #FBBF24 50%, #FCD34D 100%);
}

.topup-module-inner:hover {
  border-color: rgba(245, 158, 11, 0.3);
  box-shadow:
    0 2px 8px rgba(0, 0, 0, 0.06),
    0 8px 24px rgba(245, 158, 11, 0.08);
  transform: translateY(-2px);
}

.topup-module-icon {
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #FEF3C7 0%, #FDE68A 100%);
  border-radius: 12px;
  flex-shrink: 0;
  box-shadow: 0 2px 8px rgba(245, 158, 11, 0.2);
}

.topup-module-icon svg {
  width: 22px;
  height: 22px;
  color: #D97706;
}

.topup-module-content {
  flex: 1;
  min-width: 0;
}

.topup-module-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 8px;
}

.topup-module-label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #B45309;
  background: linear-gradient(135deg, #FEF3C7 0%, #FDE68A 100%);
  padding: 4px 10px;
  border-radius: 999px;
}

.topup-module-price {
  font-size: 22px;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -0.02em;
}

.topup-module-price span {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-muted);
}

.topup-module-text {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.5;
  margin: 0;
}

.topup-module-minimum {
  color: var(--text-muted);
  font-style: italic;
}

/* ----------------------------------------
   Pricing FAQ
   ---------------------------------------- */
.pricing-faq {
  padding: 80px 0;
  background: var(--bg-subtle);
}

.pricing-faq .section-headline {
  margin-bottom: 48px;
}

.pricing-faq .faq-list {
  max-width: 720px;
  margin: 0 auto;
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 0 32px;
}

.pricing-faq .faq-item {
  border-bottom: 1px solid var(--border-light);
}

.pricing-faq .faq-item:last-child {
  border-bottom: none;
}

/* ----------------------------------------
   Responsive Design
   ---------------------------------------- */
@media (max-width: 1024px) {
  .tiers-grid {
    grid-template-columns: 1fr;
    max-width: 480px;
    gap: 32px;
  }
}

@media (max-width: 768px) {
  .pricing-hero {
    padding: 100px 0 32px;
  }

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

  .pricing-subheadline {
    font-size: 18px;
  }

  .billing-option {
    padding: 10px 16px;
    font-size: 14px;
  }

  .billing-save-badge {
    font-size: 10px;
    padding: 2px 6px;
  }

  .upfront-credits-badge {
    font-size: 12px;
    padding: 6px 12px;
  }

  .pricing-tiers {
    padding: 32px 0 64px;
  }

  .tier-card {
    padding: 24px;
  }

  .tier-featured {
    padding-top: 32px;
  }

  .price-amount {
    font-size: 44px;
  }

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

  .tier-header {
    min-height: auto;
  }

  .tier-volume-row {
    min-height: 48px;
  }

  .tier-volume-value {
    height: 48px;
    font-size: 15px;
  }

  .volume-dropdown {
    height: 48px;
    font-size: 15px;
  }

  .all-plans-section {
    padding: 0 0 64px;
  }

  .all-plans-card {
    padding: 32px 24px;
  }

  .all-plans-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .pricing-faq {
    padding: 64px 0;
  }

  .pricing-faq .faq-list {
    padding: 0 20px;
  }

  .header-nav {
    display: none;
  }

  /* Top-up module responsive */
  .topup-module {
    margin-top: 24px;
  }

  .topup-module-inner {
    padding: 20px;
    gap: 16px;
  }

  .topup-module-icon {
    width: 40px;
    height: 40px;
  }

  .topup-module-icon svg {
    width: 20px;
    height: 20px;
  }

  .topup-module-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }

  .topup-module-price {
    font-size: 20px;
  }

  .topup-module-text {
    font-size: 13px;
  }
}

@media (max-width: 480px) {
  .pricing-hero {
    padding: 88px 0 24px;
  }

  .pricing-headline {
    font-size: 34px;
  }

  .billing-toggle {
    flex-direction: column;
    width: 100%;
    max-width: 280px;
  }

  .billing-option {
    justify-content: center;
    width: 100%;
  }

  .guarantee-badge {
    padding: 8px 16px;
    font-size: 13px;
  }

  .tier-name {
    font-size: 20px;
  }

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

  .all-plans-card {
    padding: 24px 16px;
  }

  .all-plans-item span {
    font-size: 14px;
  }

  .topup-module-inner {
    flex-direction: column;
    text-align: center;
    padding: 20px 16px;
  }

  .topup-module-header {
    align-items: center;
  }

  .topup-module-label {
    font-size: 10px;
  }

  .topup-module-price {
    font-size: 18px;
  }

  .topup-module-text {
    font-size: 13px;
  }
}

/* ----------------------------------------
   Animations
   ---------------------------------------- */
@media (prefers-reduced-motion: no-preference) {
  .billing-option {
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  }

  .volume-option {
    transition: all 0.15s cubic-bezier(0.4, 0, 0.2, 1);
  }

  .tier-card {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  }

  .price-amount {
    transition: all 0.2s ease;
  }
}
