/* ===== BuyNow-specific header padding ===== */
.buynow-header {
  padding: 30px 20px;
}

/* ===== Page Wrapper ===== */
.buynow-wrapper {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: #f3f4f6;  /* softer modern grey */
}

/* ===== Content Layout — common white outer card ===== */
.buynow-content {
  display: flex;
  gap: 20px;
  max-width: 2000px;
  margin: 40px 40px 40px 40px;
  background: #ffffff;
  border-radius: 16px;
  /* border: 1px solid #e5e7eb;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.08); */
  padding: 24px;
}

/* ===== Left: Pricing Card (own white card) ===== */
.buynow-pricing-card {
  background: #ffffff;
  /* padding: 18px 36px; */
  width: 340px;
  /* border-radius: 14px;
  border: 1px solid #e5e7eb;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.06); */

  /* NEW */
  min-height: 520px;
  position: sticky;
  top: 24px;
}

.buynow-pricing-title {
  font-size: 13px;
  font-weight: 700;
  color: #888;
  margin: 0 0 28px 0;
  padding-bottom: 18px;
  text-transform: uppercase;
  letter-spacing: 1px;
  border-bottom: 1px solid #e5e7eb;
}

.buynow-pricing-price {
  margin-bottom: 32px;
  padding: 20px 22px;
  background: linear-gradient(135deg, #667eea, #764ba2);
  border-radius: 12px;
  border: none;
  color: white;
}

.buynow-price-label {
  color: rgba(255, 255, 255, 0.85);
}

.buynow-price-amount {
  color: white;
  font-size: 30px;
}

.buynow-pricing-features {
  list-style: none;
  padding: 0;
  margin: 0;
}

.buynow-pricing-features li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 18px;
  font-size: 14px;
  color: #555;
  line-height: 1.5;
}

.buynow-pricing-features li:last-child {
  margin-bottom: 0;
}

.buynow-check-icon {
  flex-shrink: 0;
  margin-top: 2px;
}

/* ===== Right Panel (own white card) ===== */
.buynow-right {
  flex: 1;
  background: #ffffff;
  /* border-radius: 14px;
  border: 1px solid #e5e7eb;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.06); */
  overflow: hidden;
  min-height: 520px;
  display: flex;
  flex-direction: column;
  position: relative;
}

/* ===== Scoped Panel Loader ===== */
.buynow-panel-loader {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(255, 255, 255, 0.92);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 10;
}

.buynow-panel-loader-gif {
  width: 80px;
  height: 80px;
  object-fit: contain;
}

.buynow-panel-loader-msg {
  margin: 12px 0 0;
  font-size: 14px;
  color: #555;
  font-weight: 500;
}

/* ===== Tab Header ===== */
.buynow-tabs-header {
  display: flex;
  background: #f9fafb;
  border-bottom: 1px solid #e5e7eb;
}

.buynow-tab-btn {
  flex: 1;
  padding: 18px 24px;
  background: #ffffff;
  color: #999;
  border: none;
  border-bottom: 3px solid transparent;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s, background 0.2s;
  letter-spacing: 0.3px;
  text-transform: uppercase;
}

.buynow-tab-btn.buynow-tab-active {
  background: #ffffff;
  color: #667eea;
  border-bottom: 3px solid #667eea;
}

.buynow-tab-btn.buynow-tab-disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

/* ===== Tab Content Panel ===== */
.buynow-tab-panel {
  background: #ffffff;
  padding: 20px 10px;
  flex: 1;
  overflow-y: auto;
}

/* ===== Form Section ===== */
.buynow-form-heading {
  font-size: 22px;
  font-weight: 700;
  color: #1a1a1a;
  margin: 0 0 28px 0;
  /* text-align: center; */
}

/* ===== Payment Section ===== */
.buynow-payment-header {
  text-align: center;
  margin-bottom: 32px;
}

.buynow-payment-header h1 {
  font-size: 24px;
  font-weight: 700;
  color: #1a1a1a;
  margin: 0 0 8px 0;
}

.buynow-payment-description {
  font-size: 14px;
  color: #888;
  margin: 0;
}

/* ===== Loading State ===== */
.bn-loading-container {
  text-align: center;
  padding: 48px 20px;
}

.bn-spinner {
  width: 44px;
  height: 44px;
  border: 4px solid #f3f3f3;
  border-top: 4px solid #667eea;
  border-radius: 50%;
  animation: bn-spin 0.9s linear infinite;
  margin: 0 auto 16px;
}

/* Keep profile content width controlled */
.buynow-tab-panel {
  max-width: 800px;   /* prevents over-expansion */
  width: 100%;
}

/* Optional: center content inside panel */
.buynow-tab-panel > * {
  max-width: 100%;
}

.buynow-tab-panel {
  max-width: 560px;
}

.buynow-tab-panel--payment {
  max-width: 1160px;
}

/* Remove hover effect from all inputs inside profile tab (exclude OTP digit boxes) */
.buynow-tab-panel input:not(.otp-input__digit):hover,
.buynow-tab-panel textarea:hover,
.buynow-tab-panel select:hover {
  background: inherit !important;
  /* box-shadow: none !important; */
  border-color: #d1d5db !important;
}

/* Optional: make focus clean & professional */
.buynow-tab-panel input:focus,
.buynow-tab-panel textarea:focus,
.buynow-tab-panel select:focus {
  outline: none;
  /* box-shadow: none; */
  border-color: #667eea;
}

/* Vertical Divider */
.buynow-pricing-card {
  border-right: 1px solid #e5e7eb;
  padding-right: 40px;
}

.buynow-right {
  padding-left: 40px;
}

.buynow-content {
  gap: 0;   /* remove gap since divider exists */
}

@keyframes bn-spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.bn-loading-container p {
  color: #777;
  font-size: 15px;
  margin: 0;
}

/* ===== Error State ===== */
.bn-error-container {
  text-align: center;
  padding: 24px;
}

.bn-error-icon {
  font-size: 44px;
  margin-bottom: 16px;
}

.bn-error-container h2 {
  font-size: 20px;
  color: #1a1a1a;
  margin: 0 0 12px 0;
}

.bn-error-message {
  color: #df1b41;
  font-size: 14px;
  margin: 0 0 24px 0;
  padding: 12px;
  background: #fef2f2;
  border-radius: 8px;
  border: 1px solid #fecaca;
}

.bn-retry-button {
  background: #35659E;
  color: white;
  border: none;
  padding: 12px 32px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s, transform 0.1s;
}

.bn-retry-button:active {
  transform: translateY(0);
}

/* ===== OTP — Inline Mobile Edit ===== */
.bn-edit-mobile-box {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.bn-edit-mobile-label {
  font-size: 13px;
  color: #666;
  margin: 0;
  font-weight: 500;
}

.bn-edit-mobile-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.bn-edit-mobile-input {
  flex: 1;
  min-width: 0;
  margin: 0 !important;
}

.bn-edit-mobile-send {
  flex-shrink: 0;
  padding: 10px 18px;
  background: #35659E;
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s;
  white-space: nowrap;
}


.bn-edit-mobile-send:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.bn-edit-mobile-cancel {
  flex-shrink: 0;
  padding: 10px 14px;
  background: #f3f4f6;
  color: #555;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
  white-space: nowrap;
}

.bn-edit-mobile-cancel:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* ===== Inline OTP Section ===== */
.bn-otp-section {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 28px;
  padding: 8px 0;
}

.bn-otp-sent-msg {
  font-size: 14px;
  color: #555;
  text-align: center;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: center;
  line-height: 1.5;
}

.bn-otp-sent-msg strong {
  color: #1a1a1a;
}

.bn-otp-edit-btn {
  background: none;
  border: none;
  color: #667eea;
  cursor: pointer;
  padding: 2px 4px;
  display: inline-flex;
  align-items: center;
  border-radius: 6px;
  transition: color 0.15s, background 0.15s;
  flex-shrink: 0;
}

.bn-otp-form {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  width: 100%;
}

.bn-otp-verify-btn {
  width: 100%;
  max-width: 320px;
}

.bn-otp-resend {
  font-size: 14px;
  color: #777;
  text-align: center;
  margin: 0;
}

.bn-otp-resend-link {
  background: none;
  border: none;
  color: #667eea;
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  padding: 0;
  transition: color 0.15s;
}

.bn-otp-resend-link.bn-otp-resend-disabled,
.bn-otp-resend-link:disabled {
  color: #bbb;
  cursor: not-allowed;
}

.bn-otp-timer {
  font-weight: 600;
  color: #333;
}

.buynow-content {
  position: relative;
}

/* ===== Responsive ===== */
@media (max-width: 1024px) {
  .buynow-content {
    flex-direction: column;
    padding: 16px;
  }

  .buynow-pricing-card {
    width: 100%;
    position: relative;
    top: 0;
  }
}

@media (max-width: 768px) {
  .buynow-content {
    margin: 16px auto;
    width: calc(100% - 32px);
    padding: 12px;
  }

  .buynow-tab-panel {
    padding: 28px 24px;
  }

  .buynow-form-heading {
    font-size: 18px;
  }

  .buynow-payment-header h1 {
    font-size: 20px;
  }
}

@media (max-width: 480px) {
  .buynow-content {
    margin: 12px auto;
    width: calc(100% - 24px);
    padding: 10px;
  }

  .buynow-tab-panel {
    padding: 20px 16px;
  }

  .buynow-tab-btn {
    padding: 14px 12px;
    font-size: 12px;
  }
}
