/* ==========================================================================
   Japanese Shikhi Kanji Portal — Paywall & Pricing Modal
   ========================================================================== */

.paywall-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(10, 12, 24, 0.82);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  overflow-y: auto;
}

.paywall-backdrop.hidden {
  display: none !important;
}

.paywall-dialog {
  background: var(--bg-card);
  border: 1px solid rgba(230, 57, 70, 0.35);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6), 0 0 30px rgba(230, 57, 70, 0.15);
  border-radius: var(--radius-xl);
  width: 100%;
  max-width: 600px;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
  padding: 2rem;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  animation: modalPop 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.paywall-close-btn {
  position: absolute;
  top: 1.25rem;
  right: 1.25rem;
  background: var(--bg-subtle);
  border: 1px solid var(--border-color);
  color: var(--text-muted);
  width: 32px;
  height: 32px;
  border-radius: var(--radius-pill);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 0.9rem;
  transition: all 0.15s ease;
}

.paywall-close-btn:hover {
  background: rgba(230, 57, 70, 0.15);
  color: var(--js-crimson);
  border-color: var(--js-crimson);
}

.paywall-header {
  text-align: center;
}

.pro-crown-badge {
  display: inline-block;
  background: linear-gradient(135deg, #e63946, #f4a261);
  color: #ffffff;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  padding: 0.25rem 0.85rem;
  border-radius: var(--radius-pill);
  margin-bottom: 0.75rem;
  box-shadow: 0 2px 10px rgba(230, 57, 70, 0.4);
}

.paywall-header h2 {
  font-size: 1.45rem;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 0.4rem;
}

.paywall-subtitle {
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

/* Currency Switcher */
.currency-toggle-wrapper {
  display: grid;
  grid-template-columns: 1fr 1fr;
  background: var(--bg-subtle);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-pill);
  padding: 3px;
  gap: 4px;
}

.curr-tab {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  font-size: 0.78rem;
  font-weight: 700;
  padding: 0.5rem 0.75rem;
  border-radius: var(--radius-pill);
  cursor: pointer;
  transition: all 0.15s ease;
  text-align: center;
}

.curr-tab.active {
  background: var(--bg-card);
  color: var(--js-crimson);
  box-shadow: var(--shadow-sm);
}

/* Plans Grid */
.plans-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.plan-card {
  background: var(--bg-subtle);
  border: 2px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 1.25rem 1rem;
  cursor: pointer;
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  transition: all 0.2s ease;
}

.plan-card:hover {
  border-color: rgba(230, 57, 70, 0.4);
  transform: translateY(-2px);
}

.plan-card.selected {
  border-color: var(--js-crimson);
  background: rgba(230, 57, 70, 0.06);
}

.plan-badge-tag {
  position: absolute;
  top: -10px;
  right: 12px;
  background: var(--js-crimson);
  color: #ffffff;
  font-size: 0.65rem;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: var(--radius-pill);
}

.plan-name {
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--text-primary);
}

.plan-price {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--js-crimson);
}

.plan-price small {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 500;
}

.plan-desc {
  font-size: 0.75rem;
  color: var(--text-muted);
  line-height: 1.4;
}

/* Features List */
.paywall-features-list {
  background: var(--bg-subtle);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 0.85rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.feat-item {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

/* Payment Flows */
.payment-action-box {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.gateway-logos {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.pay-logo-badge {
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.25rem 0.65rem;
  border-radius: var(--radius-sm);
  background: var(--bg-subtle);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
}

.pay-logo-badge.bkash { color: #d12053; border-color: rgba(209, 32, 83, 0.3); }
.pay-logo-badge.nagad { color: #f58220; border-color: rgba(245, 130, 32, 0.3); }
.pay-logo-badge.rocket { color: #8c3494; border-color: rgba(140, 52, 148, 0.3); }
.pay-logo-badge.stripe { color: #635bff; border-color: rgba(99, 91, 255, 0.3); }

.manual-pay-instructions {
  background: var(--bg-subtle);
  border-left: 3px solid var(--js-crimson);
  padding: 0.85rem 1rem;
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  font-size: 0.8rem;
  color: var(--text-secondary);
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.copy-number-box {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.copy-number-box code {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  padding: 0.35rem 0.75rem;
  border-radius: var(--radius-sm);
  font-size: 1rem;
  font-weight: 700;
  color: var(--js-crimson);
  letter-spacing: 0.05em;
}

.btn-copy-num {
  background: var(--js-crimson);
  color: #ffffff;
  border: none;
  border-radius: var(--radius-sm);
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.35rem 0.75rem;
  cursor: pointer;
}

.trx-input-row {
  display: flex;
  gap: 0.5rem;
}

.trx-input-row input {
  flex: 1;
  background: var(--bg-subtle);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 0.65rem 0.85rem;
  color: var(--text-primary);
  font-size: 0.85rem;
  font-family: inherit;
}

.btn-pay-action {
  background: linear-gradient(135deg, #e63946, #d42e3a);
  color: #ffffff;
  border: none;
  border-radius: var(--radius-md);
  padding: 0.75rem 1.25rem;
  font-size: 0.9rem;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(230, 57, 70, 0.4);
  transition: all 0.15s ease;
}

.btn-pay-action:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(230, 57, 70, 0.5);
}

.btn-large-stripe {
  width: 100%;
  padding: 0.9rem;
  font-size: 1rem;
}

/* Promo code */
.promo-code-row {
  display: flex;
  gap: 0.5rem;
}

.promo-code-row input {
  flex: 1;
  background: var(--bg-subtle);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 0.5rem 0.85rem;
  color: var(--text-primary);
  font-size: 0.82rem;
}

.btn-apply-promo {
  background: var(--bg-subtle);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  border-radius: var(--radius-md);
  padding: 0.5rem 1rem;
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
}

.promo-feedback-msg {
  font-size: 0.78rem;
  font-weight: 600;
  text-align: center;
}

.promo-feedback-msg.success { color: var(--js-teal); }
.promo-feedback-msg.error { color: var(--js-crimson); }

.paywall-footer-note {
  text-align: center;
  font-size: 0.75rem;
  color: var(--text-muted);
}

@media (max-width: 600px) {
  .paywall-dialog {
    padding: 1.25rem;
  }
  .plans-grid {
    grid-template-columns: 1fr;
  }
}
