/* ============================================================
   FIXEO V5 — PAYMENT SYSTEM CSS
   Secure Payment Integration · Stripe · PayPal · CMI
   ============================================================ */

/* ── STRIPE ELEMENTS CONTAINER ────────────────────────────── */
.stripe-element-container {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  transition: border-color .25s, box-shadow .25s;
  min-height: 44px;
  display: flex;
  align-items: center;
}
.stripe-element-container.StripeElement--focus,
.stripe-element-container:focus-within {
  border-color: var(--primary) !important;
  box-shadow: 0 0 0 3px rgba(225,48,108,0.2) !important;
  outline: none;
}
.stripe-element-container.StripeElement--invalid {
  border-color: var(--danger) !important;
  box-shadow: 0 0 0 3px rgba(255,71,87,0.2) !important;
}
.StripeElement { width: 100%; }

/* ── PAYMENT MODAL FULL OVERRIDE ──────────────────────────── */
#payment-modal,
#booking-payment-modal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 2000;
  align-items: center;
  justify-content: center;
  padding: 16px;
}
#payment-modal.open,
#booking-payment-modal.open {
  display: flex;
}
.payment-modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.75);
  backdrop-filter: blur(8px);
  z-index: 1999;
}
.payment-modal-dialog {
  background: linear-gradient(145deg, #1a1a2e 0%, #16213e 100%);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: var(--radius-xl);
  width: 100%;
  max-width: 620px;
  max-height: 92vh;
  overflow-y: auto;
  overflow-x: visible;
  position: relative;
  z-index: 2001;
  animation: payModalIn .35s cubic-bezier(.34,1.56,.64,1);
  scrollbar-width: thin;
  scrollbar-color: var(--primary) transparent;
}
@keyframes payModalIn {
  from { opacity:0; transform: scale(0.88) translateY(32px); }
  to   { opacity:1; transform: scale(1) translateY(0); }
}
.payment-modal-dialog::-webkit-scrollbar { width: 6px; }
.payment-modal-dialog::-webkit-scrollbar-thumb {
  background: var(--grad-primary); border-radius: 3px;
}

.pay-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 28px 18px;
  border-bottom: 1px solid rgba(255,255,255,0.07);
  position: sticky;
  top: 0;
  background: linear-gradient(145deg, #1a1a2e 0%, #16213e 100%);
  z-index: 10;
  border-radius: var(--radius-xl) var(--radius-xl) 0 0;
}
.pay-modal-header h3 {
  font-size: 1.1rem;
  font-weight: 800;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 10px;
}
.pay-modal-close {
  background: rgba(255,255,255,0.07);
  border: 1px solid rgba(255,255,255,0.1);
  color: var(--text-muted);
  cursor: pointer;
  width: 34px; height: 34px;
  border-radius: 50%;
  font-size: 1rem;
  display: flex; align-items: center; justify-content: center;
  transition: all .2s;
}
.pay-modal-close:hover {
  background: rgba(255,71,87,0.2);
  color: var(--danger);
  border-color: rgba(255,71,87,0.3);
}
.pay-modal-body { padding: 24px 28px 28px; }

/* ── PLAN SUMMARY BANNER ───────────────────────────────────── */
.pay-plan-summary {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: var(--radius-lg);
  padding: 16px 20px;
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.pay-plan-summary-info { flex: 1; }
.pay-plan-summary-name {
  font-weight: 800;
  font-size: 1rem;
  margin-bottom: 3px;
}
.pay-plan-summary-sub {
  font-size: .78rem;
  color: var(--text-muted);
}
.pay-plan-summary-price {
  font-size: 1.8rem;
  font-weight: 900;
  background: var(--grad-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  white-space: nowrap;
}
.pay-plan-summary-price small {
  font-size: .7rem;
  -webkit-text-fill-color: var(--text-muted);
  color: var(--text-muted);
  font-weight: 400;
}

/* Reservation summary variant */
.pay-booking-summary {
  background: rgba(32,201,151,0.06);
  border: 1px solid rgba(32,201,151,0.2);
  border-radius: var(--radius-lg);
  padding: 16px 20px;
  margin-bottom: 24px;
}
.pay-booking-summary-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: .88rem;
  padding: 5px 0;
  border-bottom: 1px solid rgba(255,255,255,0.05);
}
.pay-booking-summary-row:last-child { border-bottom: none; }
.pay-booking-summary-row span:first-child { color: var(--text-muted); }
.pay-booking-summary-row span:last-child { font-weight: 600; }
.pay-booking-total {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid rgba(255,255,255,0.1);
  font-weight: 800;
}
.pay-booking-total-amount {
  font-size: 1.4rem;
  font-weight: 900;
  background: var(--grad-success);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ── PAYMENT METHODS TABS ──────────────────────────────────── */
.pay-methods-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}
.pay-method-tab {
  flex: 1;
  min-width: 100px;
  padding: 10px 12px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: var(--radius-md);
  color: var(--text-muted);
  cursor: pointer;
  font-size: .82rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  transition: all .25s;
  font-family: var(--font-main);
}
.pay-method-tab:hover {
  background: rgba(255,255,255,0.08);
  color: #fff;
  border-color: rgba(255,255,255,0.2);
}
.pay-method-tab.active {
  background: rgba(225,48,108,0.15);
  border-color: rgba(225,48,108,0.5);
  color: #fff;
  box-shadow: 0 0 16px rgba(225,48,108,0.15);
}
.pay-method-tab .tab-icon { font-size: 1rem; }

/* ── PAYMENT FORMS ─────────────────────────────────────────── */
.pay-form-panel { display: none; }
.pay-form-panel.active { display: block; }

.secure-badge-v5 {
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(32,201,151,0.08);
  border: 1px solid rgba(32,201,151,0.2);
  border-radius: var(--radius-md);
  padding: 10px 14px;
  font-size: .78rem;
  color: var(--success);
  font-weight: 600;
  margin-bottom: 18px;
}
.secure-badge-v5 .lock-icon { font-size: 1rem; }

/* Form groups in payment modal */
.pay-form-group {
  margin-bottom: 16px;
}
.pay-form-label {
  display: block;
  font-size: .8rem;
  font-weight: 600;
  color: rgba(255,255,255,0.7);
  margin-bottom: 7px;
  letter-spacing: .02em;
}
.pay-form-input {
  width: 100%;
  padding: 12px 16px;
  background: rgba(255,255,255,0.06) !important;
  border: 1px solid rgba(255,255,255,0.12) !important;
  border-radius: var(--radius-md) !important;
  color: #fff !important;
  font-family: var(--font-main);
  font-size: .9rem;
  transition: all .25s;
  box-sizing: border-box;
}
.pay-form-input:focus {
  outline: none !important;
  border-color: var(--primary) !important;
  box-shadow: 0 0 0 3px rgba(225,48,108,0.18) !important;
}
.pay-form-input::placeholder { color: rgba(255,255,255,0.3); }
.pay-form-input.error {
  border-color: var(--danger) !important;
  box-shadow: 0 0 0 3px rgba(255,71,87,0.18) !important;
}

.pay-form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

/* Card number with brand icon */
.card-number-wrap { position: relative; }
.card-number-wrap .pay-form-input { padding-right: 50px !important; }
.card-brand-badge {
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.2rem;
  pointer-events: none;
}

/* ── PAYPAL FORM ───────────────────────────────────────────── */
.paypal-redirect-box {
  text-align: center;
  padding: 28px 20px;
}
.paypal-logo-big {
  font-size: 3rem;
  margin-bottom: 12px;
  display: block;
}
.paypal-redirect-box p {
  color: var(--text-secondary);
  font-size: .88rem;
  margin-bottom: 8px;
}
.paypal-redirect-box small {
  color: var(--text-muted);
  font-size: .77rem;
}
.btn-paypal-v5 {
  background: linear-gradient(135deg, #003087 0%, #009CDE 100%) !important;
  color: #fff !important;
  border: none !important;
  width: 100%;
  padding: 14px !important;
  font-size: 1rem !important;
  font-weight: 700 !important;
  border-radius: var(--radius-md) !important;
  cursor: pointer;
  transition: all .25s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-family: var(--font-main);
  margin-top: 16px;
}
.btn-paypal-v5:hover { opacity: .9; transform: translateY(-1px); }

/* ── CMI FORM ──────────────────────────────────────────────── */
.cmi-banks-strip {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}
.cmi-bank-chip {
  font-size: .7rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: var(--radius-full);
  background: rgba(255,255,255,0.07);
  border: 1px solid rgba(255,255,255,0.12);
  color: rgba(255,255,255,0.7);
}

/* ── PAY BUTTON ────────────────────────────────────────────── */
.btn-pay-now {
  width: 100%;
  padding: 15px 24px;
  background: var(--grad-primary);
  color: #fff;
  border: none;
  border-radius: var(--radius-md);
  font-size: 1rem;
  font-weight: 800;
  cursor: pointer;
  transition: all .25s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-family: var(--font-main);
  margin-top: 20px;
  position: relative;
  overflow: hidden;
}
.btn-pay-now::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(255,255,255,0);
  transition: background .2s;
}
.btn-pay-now:hover::before { background: rgba(255,255,255,0.08); }
.btn-pay-now:hover { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(225,48,108,0.4); }
.btn-pay-now:disabled {
  opacity: .6;
  cursor: not-allowed;
  transform: none !important;
  box-shadow: none !important;
}
.btn-pay-now .pay-spinner {
  width: 18px; height: 18px;
  border: 2px solid rgba(255,255,255,0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin .7s linear infinite;
  display: none;
}
.btn-pay-now.loading .pay-spinner { display: block; }
.btn-pay-now.loading .btn-text { opacity: .7; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ── PAYMENT MESSAGE ───────────────────────────────────────── */
.pay-message-box {
  display: none;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  border-radius: var(--radius-md);
  font-size: .85rem;
  font-weight: 600;
  margin-top: 14px;
  animation: fadeSlideIn .3s ease;
}
@keyframes fadeSlideIn {
  from { opacity:0; transform:translateY(-8px); }
  to   { opacity:1; transform:translateY(0); }
}
.pay-message-box.show { display: flex; }
.pay-message-box.success {
  background: rgba(32,201,151,0.12);
  border: 1px solid rgba(32,201,151,0.3);
  color: var(--success);
}
.pay-message-box.error {
  background: rgba(255,71,87,0.1);
  border: 1px solid rgba(255,71,87,0.3);
  color: var(--danger);
}
.pay-message-box.loading {
  background: rgba(64,93,230,0.1);
  border: 1px solid rgba(64,93,230,0.25);
  color: #a0b0ff;
}
.pay-message-box .msg-icon { font-size: 1.1rem; flex-shrink: 0; }

/* ── SUCCESS MODAL ─────────────────────────────────────────── */
#pay-success-modal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 2100;
  align-items: center;
  justify-content: center;
  padding: 16px;
}
#pay-success-modal.open { display: flex; }
.pay-success-dialog {
  background: linear-gradient(145deg, #1a1a2e 0%, #16213e 100%);
  border: 1px solid rgba(32,201,151,0.25);
  border-radius: var(--radius-xl);
  width: 100%;
  max-width: 440px;
  padding: 40px 32px;
  text-align: center;
  position: relative;
  z-index: 2101;
  animation: successPop .5s cubic-bezier(.34,1.56,.64,1);
  box-shadow: 0 0 60px rgba(32,201,151,0.15);
}
@keyframes successPop {
  from { opacity:0; transform: scale(0.7); }
  to   { opacity:1; transform: scale(1); }
}
.pay-success-icon {
  font-size: 4rem;
  display: block;
  margin-bottom: 16px;
  animation: bounceIn .6s .1s cubic-bezier(.34,1.56,.64,1) both;
}
@keyframes bounceIn {
  from { transform: scale(0); opacity:0; }
  to   { transform: scale(1); opacity:1; }
}
.pay-success-title {
  font-size: 1.5rem;
  font-weight: 900;
  margin-bottom: 8px;
  background: var(--grad-success);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.pay-success-msg { color: var(--text-secondary); font-size: .9rem; margin-bottom: 6px; }
.pay-success-ref {
  font-size: .75rem;
  color: var(--text-muted);
  font-family: monospace;
  background: rgba(255,255,255,0.06);
  padding: 6px 14px;
  border-radius: var(--radius-full);
  display: inline-block;
  margin: 12px 0;
  letter-spacing: .05em;
}
.pay-success-divider {
  height: 1px;
  background: rgba(255,255,255,0.08);
  margin: 20px 0;
}
.pay-success-notification {
  background: rgba(32,201,151,0.07);
  border: 1px solid rgba(32,201,151,0.18);
  border-radius: var(--radius-md);
  padding: 12px 16px;
  font-size: .8rem;
  color: var(--text-secondary);
  margin-bottom: 20px;
  text-align: left;
}
.pay-success-notification strong { color: var(--success); }
.confetti-container {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  border-radius: var(--radius-xl);
}
.confetti-piece {
  position: absolute;
  width: 8px;
  height: 8px;
  border-radius: 2px;
  opacity: 0;
  animation: confettiFall var(--duration) var(--delay) ease-in forwards;
}
@keyframes confettiFall {
  0%   { transform: translateY(-20px) rotate(0deg); opacity: 1; }
  100% { transform: translateY(300px) rotate(720deg); opacity: 0; }
}

/* ── RESERVATION PAYMENT STEP ──────────────────────────────── */
.booking-step {
  display: none;
  animation: stepFadeIn .3s ease;
}
.booking-step.active { display: block; }
@keyframes stepFadeIn {
  from { opacity:0; transform:translateX(20px); }
  to   { opacity:1; transform:translateX(0); }
}

.booking-steps-indicator {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  margin-bottom: 24px;
}
.booking-step-dot {
  width: 32px; height: 32px;
  border-radius: 50%;
  background: rgba(255,255,255,0.07);
  border: 2px solid rgba(255,255,255,0.12);
  display: flex; align-items: center; justify-content: center;
  font-size: .78rem;
  font-weight: 700;
  color: var(--text-muted);
  transition: all .3s;
  position: relative;
  z-index: 2;
}
.booking-step-dot.active {
  background: var(--grad-primary);
  border-color: var(--primary);
  color: #fff;
  box-shadow: 0 0 16px rgba(225,48,108,0.4);
}
.booking-step-dot.done {
  background: var(--grad-success);
  border-color: var(--success);
  color: #fff;
}
.booking-step-line {
  flex: 1;
  height: 2px;
  background: rgba(255,255,255,0.08);
  max-width: 60px;
  position: relative;
}
.booking-step-line.done {
  background: var(--grad-success);
}
.booking-step-label {
  position: absolute;
  top: 38px;
  left: 50%;
  transform: translateX(-50%);
  font-size: .65rem;
  white-space: nowrap;
  color: var(--text-muted);
  font-weight: 600;
}
.booking-step-dot.active .booking-step-label { color: var(--primary); }
.booking-step-dot.done .booking-step-label { color: var(--success); }

/* ── 3D SECURE SIMULATION ──────────────────────────────────── */
.tds-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.85);
  z-index: 3000;
  align-items: center;
  justify-content: center;
}
.tds-overlay.show { display: flex; }
.tds-box {
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 36px 40px;
  text-align: center;
  max-width: 360px;
  width: 90%;
  color: #1a1a2e;
}
.tds-logo { font-size: 2.5rem; margin-bottom: 12px; }
.tds-title { font-size: 1.1rem; font-weight: 800; margin-bottom: 8px; color: #1a1a2e; }
.tds-subtitle { font-size: .82rem; color: #666; margin-bottom: 20px; }
.tds-code-input {
  width: 100%;
  padding: 14px;
  border: 2px solid #e0e0e0;
  border-radius: 12px;
  text-align: center;
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: .3em;
  color: #1a1a2e;
  background: #f5f5f5;
  margin-bottom: 16px;
  font-family: monospace;
  box-sizing: border-box;
}
.tds-code-input:focus { outline: none; border-color: #E1306C; }
.tds-hint { font-size: .75rem; color: #999; margin-bottom: 16px; }
.btn-tds-confirm {
  background: linear-gradient(135deg, #E1306C, #833AB4);
  color: #fff;
  border: none;
  padding: 13px 32px;
  border-radius: 12px;
  font-size: .95rem;
  font-weight: 700;
  cursor: pointer;
  width: 100%;
}

/* ── BOOKING MODAL (ARTISAN PAGE) ──────────────────────────── */
#booking-payment-modal .payment-modal-dialog {
  max-width: 580px;
}

/* ── EXPRESS PAYMENT BADGE ─────────────────────────────────── */
.express-pay-banner {
  display: flex;
  align-items: center;
  gap: 10px;
  background: rgba(255,107,53,0.1);
  border: 1px solid rgba(255,107,53,0.3);
  border-radius: var(--radius-md);
  padding: 12px 16px;
  margin-bottom: 16px;
}
.express-pay-banner .express-icon { font-size: 1.3rem; }
.express-pay-banner-text { font-size: .82rem; }
.express-pay-banner-text strong { color: #FF6B35; }
.express-pay-banner-text small { color: var(--text-muted); display: block; }

/* ── SECURITY LOGOS ROW ────────────────────────────────────── */
.payment-security-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid rgba(255,255,255,0.06);
  flex-wrap: wrap;
}
.security-badge-item {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: .7rem;
  color: var(--text-muted);
  font-weight: 600;
}
.security-badge-item .sec-icon { font-size: .9rem; }

/* ── PAYMENT HISTORY IN DASHBOARD ──────────────────────────── */
.pay-history-table {
  width: 100%;
  border-collapse: collapse;
}
.pay-history-table th, .pay-history-table td {
  padding: 12px 16px;
  text-align: left;
  font-size: .83rem;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
.pay-history-table th {
  color: var(--text-muted);
  font-weight: 700;
  font-size: .75rem;
  text-transform: uppercase;
  letter-spacing: .05em;
  background: rgba(255,255,255,0.03);
}
.pay-history-table tr:last-child td { border-bottom: none; }
.pay-history-table tr:hover td { background: rgba(255,255,255,0.02); }
.pay-status-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 10px;
  border-radius: var(--radius-full);
  font-size: .7rem;
  font-weight: 700;
}
.pay-status-badge.success {
  background: rgba(32,201,151,0.12);
  color: var(--success);
}
.pay-status-badge.pending {
  background: rgba(255,165,2,0.12);
  color: var(--warning);
}
.pay-status-badge.failed {
  background: rgba(255,71,87,0.12);
  color: var(--danger);
}
.pay-method-logo {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: .82rem;
  font-weight: 600;
}

/* ── NOTIFICATIONS TOAST ───────────────────────────────────── */
.pay-toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 5000;
  display: flex;
  flex-direction: column;
  gap: 10px;
  pointer-events: none;
}
.pay-toast-item {
  background: rgba(13,13,26,0.95);
  border: 1px solid rgba(255,255,255,0.1);
  border-left: 4px solid var(--success);
  border-radius: var(--radius-md);
  padding: 14px 18px;
  min-width: 280px;
  max-width: 360px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.5);
  animation: toastSlideIn .4s cubic-bezier(.34,1.56,.64,1);
  pointer-events: auto;
  display: flex;
  gap: 12px;
  align-items: flex-start;
}
.pay-toast-item.error { border-left-color: var(--danger); }
.pay-toast-item.warning { border-left-color: var(--warning); }
@keyframes toastSlideIn {
  from { opacity:0; transform: translateX(100%); }
  to   { opacity:1; transform: translateX(0); }
}
@keyframes toastSlideOut {
  from { opacity:1; transform: translateX(0); }
  to   { opacity:0; transform: translateX(100%); }
}
.pay-toast-icon { font-size: 1.3rem; flex-shrink: 0; margin-top: 1px; }
.pay-toast-content { flex: 1; }
.pay-toast-title { font-weight: 700; font-size: .88rem; margin-bottom: 2px; }
.pay-toast-sub { font-size: .77rem; color: var(--text-muted); }

/* ── IN-APP NOTIFICATION BELL BADGE ───────────────────────── */
.notif-count-badge {
  background: var(--danger);
  color: #fff;
  border-radius: 50%;
  font-size: .6rem;
  font-weight: 800;
  width: 16px; height: 16px;
  display: flex; align-items: center; justify-content: center;
  position: absolute;
  top: -4px; right: -4px;
}

/* ── RESPONSIVE ────────────────────────────────────────────── */
@media (max-width: 600px) {
  .pay-modal-body { padding: 20px 16px 24px; }
  .pay-modal-header { padding: 18px 16px 14px; }
  .payment-modal-dialog { border-radius: var(--radius-lg); }
  .pay-form-row { grid-template-columns: 1fr; }
  .pay-methods-tabs { gap: 6px; }
  .pay-method-tab { font-size: .75rem; padding: 9px 8px; }
  .pay-plan-summary-price { font-size: 1.4rem; }
  .pay-success-dialog { padding: 28px 20px; }
  .pay-success-title { font-size: 1.3rem; }
  .pay-toast { bottom: 16px; right: 16px; left: 16px; }
  .pay-toast-item { min-width: unset; max-width: 100%; }
  .tds-box { padding: 24px 20px; }
}

/* ── CARD SELECTED HIGHLIGHT ───────────────────────────────── */
.pricing-card.selected {
  border-color: var(--primary) !important;
  box-shadow: 0 0 0 2px rgba(225,48,108,0.3), 0 20px 60px rgba(225,48,108,0.2) !important;
}

/* ── PLAN BTN LOADING STATE ────────────────────────────────── */
.plan-btn.loading {
  opacity: .7;
  pointer-events: none;
}

/* ── V5 FIX: Dynamic modal overlay class support ─────────── */
.payment-modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 2000;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(8px);
}
.payment-modal-overlay.open {
  display: flex !important;
}
.booking-payment-modal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 2000;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(8px);
}
.booking-payment-modal.open {
  display: flex !important;
}
#payment-modal.open,
#booking-payment-modal.open {
  display: flex !important;
}
#pay-success-modal.open {
  display: flex !important;
}

/* ══════════════════════════════════════════════════════════════
   FIXEO V13 — PAYPAL SANDBOX STYLES
   Styles pour le SDK PayPal réel (boutons + états + admin)
   ══════════════════════════════════════════════════════════════ */

/* ── Wrapper des boutons PayPal SDK ────────────────────────── */
.paypal-buttons-wrapper {
  width: 100%;
  min-height: 60px;
  padding: 8px 0;
  border-radius: 12px;
  /* FIX-6 : overflow visible pour ne pas couper les iframes PayPal SDK */
  overflow: visible;
}

/* ── Info sandbox PayPal ───────────────────────────────────── */
.paypal-sandbox-info {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  background: rgba(0, 112, 186, 0.1);
  border: 1px solid rgba(0, 112, 186, 0.3);
  border-radius: 10px;
  margin-bottom: 16px;
}
.paypal-pp-logo {
  font-size: 2rem;
  line-height: 1;
  flex-shrink: 0;
}
.paypal-info-text strong {
  display: block;
  font-size: .88rem;
  color: #5bc0f8;
  font-weight: 700;
  margin-bottom: 2px;
}
.paypal-info-text small {
  font-size: .76rem;
  color: rgba(255,255,255,.6);
  line-height: 1.4;
}

/* ── Loading spinner SDK ───────────────────────────────────── */
.paypal-sdk-loading {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 16px;
  color: rgba(255,255,255,.55);
  font-size: .84rem;
  justify-content: center;
}
.paypal-sdk-spinner {
  width: 20px;
  height: 20px;
  border: 2px solid rgba(255,255,255,.15);
  border-top-color: #0070ba;
  border-radius: 50%;
  animation: ppSpin .8s linear infinite;
  flex-shrink: 0;
}
@keyframes ppSpin {
  to { transform: rotate(360deg); }
}

/* ── Erreur chargement PayPal ──────────────────────────────── */
.paypal-load-error {
  padding: 16px;
  background: rgba(255, 71, 87, 0.1);
  border: 1px solid rgba(255, 71, 87, 0.3);
  border-radius: 10px;
  text-align: center;
  color: rgba(255,255,255,.75);
}
.paypal-error-icon { font-size: 1.5rem; display: block; margin-bottom: 6px; }
.paypal-load-error p { font-size: .85rem; margin: 0 0 4px; }
.paypal-load-error small { font-size: .75rem; color: rgba(255,255,255,.45); }

/* ── Message box PayPal ────────────────────────────────────── */
.paypal-msg-box {
  display: none;
  padding: 10px 14px;
  border-radius: 8px;
  font-size: .84rem;
  margin-top: 10px;
  font-weight: 600;
}
.paypal-msg-box.show  { display: block; }
.paypal-msg-box.loading {
  background: rgba(91, 192, 248, 0.12);
  border: 1px solid rgba(91, 192, 248, 0.3);
  color: #5bc0f8;
}
.paypal-msg-box.success {
  background: rgba(32, 201, 151, 0.12);
  border: 1px solid rgba(32, 201, 151, 0.3);
  color: #20C997;
}
.paypal-msg-box.error {
  background: rgba(255, 71, 87, 0.12);
  border: 1px solid rgba(255, 71, 87, 0.3);
  color: #ff4757;
}
.paypal-msg-box.warning {
  background: rgba(255, 185, 0, 0.12);
  border: 1px solid rgba(255, 185, 0, 0.3);
  color: #ffb900;
}

/* ── Admin : badge méthode PayPal ──────────────────────────── */
.paypal-method-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  background: rgba(0, 112, 186, 0.18);
  border: 1px solid rgba(0, 112, 186, 0.4);
  border-radius: 20px;
  color: #5bc0f8;
  font-size: .76rem;
  font-weight: 700;
}

/* ── Admin : transaction ID PayPal ────────────────────────── */
.res-txn-id {
  font-family: 'Courier New', Courier, monospace;
  font-size: .72rem;
  letter-spacing: .03em;
  color: rgba(255,255,255,.65);
  word-break: break-all;
  max-width: 260px;
  display: block;
}

/* ── Override : s'assurer que le conteneur PayPal SDK
      ne soit pas masqué par overflow: hidden ──────────────── */
#payment-modal .paypal-buttons-wrapper,
#booking-payment-modal .paypal-buttons-wrapper {
  overflow: visible;
}

/* ── Neutraliser l'ancien bouton PayPal statique ──────────── */
.btn-paypal-v5 { display: none !important; }
.paypal-redirect-box { display: none !important; }


/* ── Admin : badge méthode Stripe ──────────────────────────── */
.stripe-method-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  background: rgba(99, 91, 255, 0.18);
  border: 1px solid rgba(99, 91, 255, 0.4);
  border-radius: 20px;
  color: #a29bfe;
  font-size: .76rem;
  font-weight: 700;
}

/* ── Admin : badge méthode CMI ─────────────────────────────── */
.cmi-method-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  background: rgba(0, 150, 80, 0.18);
  border: 1px solid rgba(0, 150, 80, 0.4);
  border-radius: 20px;
  color: #55efc4;
  font-size: .76rem;
  font-weight: 700;
}

/* ── Admin : indicateur mode backend PayPal ────────────────── */
.paypal-server-mode-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  background: rgba(0, 200, 120, 0.12);
  border: 1px solid rgba(0, 200, 120, 0.3);
  border-radius: 20px;
  color: #20C997;
  font-size: .72rem;
  font-weight: 700;
  margin-left: 8px;
}

.paypal-server-mode-badge::before {
  content: '●';
  font-size: .6rem;
  color: #20C997;
  animation: pulse-dot 1.5s ease infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0.3; }
}

/* ── Table réservations admin : colonnes ajoutées ──────────── */
#reservations-admin-table th:nth-child(11),
#reservations-admin-table td:nth-child(11) {
  white-space: nowrap;
}

#reservations-admin-table th:nth-child(12),
#reservations-admin-table td:nth-child(12) {
  max-width: 140px;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ── Sandbox warning dans modal paiement ───────────────────── */
.paypal-sandbox-badge {
  display: inline-block;
  padding: 2px 7px;
  background: rgba(255, 185, 0, 0.15);
  border: 1px solid rgba(255, 185, 0, 0.35);
  border-radius: 4px;
  color: #ffb900;
  font-size: .68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .05em;
  vertical-align: middle;
  margin-left: 6px;
}

/* ══════════════════════════════════════════════════════════
   FIXEO V14 ULTIMATE — PayPal Demo Section (Homepage)
══════════════════════════════════════════════════════════ */

/* Section démo PayPal homepage */
#paypal-demo-section {
  background: transparent;
}

#paypal-demo-section .section-header h2 {
  background: linear-gradient(135deg, #009cde, #003087);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* Message box amélioré */
.paypal-msg-box {
  border-radius: 10px;
  padding: 10px 14px;
  font-size: .88rem;
  font-weight: 600;
  transition: all .3s ease;
}

.paypal-msg-box.show {
  display: block;
}

.paypal-msg-box.success {
  background: rgba(32, 201, 151, .12);
  border: 1px solid rgba(32, 201, 151, .3);
  color: #20c997;
}

.paypal-msg-box.error {
  background: rgba(255, 71, 87, .10);
  border: 1px solid rgba(255, 71, 87, .3);
  color: #ff6b7a;
}

.paypal-msg-box.warning {
  background: rgba(255, 165, 2, .10);
  border: 1px solid rgba(255, 165, 2, .3);
  color: #ffa502;
}

.paypal-msg-box.loading {
  background: rgba(255, 255, 255, .05);
  border: 1px solid rgba(255, 255, 255, .12);
  color: rgba(255, 255, 255, .7);
}

/* Spinner PayPal */
.paypal-sdk-spinner {
  width: 22px;
  height: 22px;
  border: 3px solid rgba(255, 255, 255, .15);
  border-top-color: #009cde;
  border-radius: 50%;
  animation: ppSpin .7s linear infinite;
  flex-shrink: 0;
}

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

.paypal-sdk-loading {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 18px;
  color: rgba(255, 255, 255, .55);
  font-size: .88rem;
}

/* Error container */
.paypal-load-error {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 24px;
  text-align: center;
  background: rgba(255, 71, 87, .06);
  border: 1px solid rgba(255, 71, 87, .2);
  border-radius: 12px;
}

.paypal-load-error .paypal-error-icon { font-size: 1.8rem; }
.paypal-load-error p { font-size: .85rem; margin: 0; }
.paypal-load-error small { font-size: .75rem; color: rgba(255,255,255,.45); }

/* Buttons wrapper */
.paypal-buttons-wrapper {
  width: 100%;
  min-height: 55px;
  border-radius: 12px;
  overflow: hidden;
}

/* Sandbox hint in homepage section */
.paypal-sandbox-hint {
  animation: fadeInUp .4s ease both;
}

@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}


/* ============================================================
   FIXEO V14 — COD PAYMENT STYLES (Cash on Delivery)
   ============================================================ */

/* ── Badge méthode COD dans les tables admin ─────────────── */
.cod-method-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 9px;
  border-radius: 20px;
  font-size: 0.72rem;
  font-weight: 700;
  background: rgba(32, 201, 151, 0.15);
  color: #20C997;
  border: 1px solid rgba(32, 201, 151, 0.3);
  white-space: nowrap;
}

/* ── Badge COD dans la colonne ID réservation ───────────── */
.cod-res-badge {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 1px 6px;
  border-radius: 12px;
  font-size: 0.63rem;
  font-weight: 700;
  background: rgba(32, 201, 151, 0.2);
  color: #20C997;
  border: 1px solid rgba(32, 201, 151, 0.25);
  margin-left: 4px;
  vertical-align: middle;
}

/* ── Section sélecteur de paiement dans reservation.js ──── */
.fixeo-res-payment-section {
  margin: 16px 0 8px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 16px;
}

.fixeo-res-payment-title {
  font-weight: 700;
  font-size: 0.88rem;
  color: rgba(255, 255, 255, 0.8);
  margin-bottom: 12px;
  letter-spacing: 0.02em;
}

/* ── Options de paiement (radio cards) ──────────────────── */
.fixeo-pay-options {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 8px 0;
}

.fixeo-pay-option {
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(255, 255, 255, 0.04);
  border: 1.5px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 13px 15px;
  cursor: pointer;
  transition: border-color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
  position: relative;
  user-select: none;
}

.fixeo-pay-option:hover {
  background: rgba(255, 255, 255, 0.07);
  border-color: rgba(255, 255, 255, 0.2);
}

.fixeo-pay-option.selected {
  border-color: #20C997;
  background: rgba(32, 201, 151, 0.08);
  box-shadow: 0 0 0 3px rgba(32, 201, 151, 0.15);
}

.fixeo-pay-option input[type="radio"] {
  width: 18px;
  height: 18px;
  accent-color: #20C997;
  flex-shrink: 0;
  cursor: pointer;
}

.fixeo-pay-option-icon {
  font-size: 1.4rem;
  flex-shrink: 0;
  line-height: 1;
}

.fixeo-pay-option-info {
  flex: 1;
  min-width: 0;
}

.fixeo-pay-option-label {
  font-weight: 700;
  font-size: 0.9rem;
  color: #fff;
  line-height: 1.3;
}

.fixeo-pay-option-desc {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.5);
  margin-top: 2px;
  line-height: 1.3;
}

.fixeo-pay-option-badge {
  font-size: 0.67rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 20px;
  white-space: nowrap;
  flex-shrink: 0;
}

.fixeo-pay-option-badge.default {
  background: rgba(32, 201, 151, 0.2);
  color: #20C997;
  border: 1px solid rgba(32, 201, 151, 0.3);
}

.fixeo-pay-option-badge.secondary {
  background: rgba(100, 149, 237, 0.15);
  color: #6495ed;
  border: 1px solid rgba(100, 149, 237, 0.3);
}

.fixeo-pay-option-badge.future {
  background: rgba(255, 165, 0, 0.1);
  color: rgba(255, 165, 0, 0.8);
  border: 1px solid rgba(255, 165, 0, 0.25);
}

.fixeo-pay-option.disabled,
.fixeo-pay-option:has(input[disabled]) {
  opacity: 0.5;
  cursor: not-allowed;
  pointer-events: none;
}

/* ── Statut COD dans les badges admin ───────────────────── */
.res-pay-pending_cod {
  background: rgba(255, 193, 7, 0.15) !important;
  color: #ffc107 !important;
  border: 1px solid rgba(255, 193, 7, 0.3) !important;
}

.res-pay-cod_paid {
  background: rgba(32, 201, 151, 0.15) !important;
  color: #20C997 !important;
  border: 1px solid rgba(32, 201, 151, 0.3) !important;
}

/* ── Modal confirmation COD ─────────────────────────────── */
#fixeo-cod-confirm-modal {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(6px);
}

/* ── Animation bounce pour l'icône COD ──────────────────── */
@keyframes codIconBounce {
  0%, 100% { transform: scale(1); }
  50%       { transform: scale(1.12); }
}

.cod-success-icon {
  animation: codIconBounce 0.6s ease 0.2s both;
}

/* ── Table COD admin : row highlight on hover ────────────── */
#cod-admin-table tbody tr:hover {
  background: rgba(32, 201, 151, 0.04);
  transition: background 0.15s;
}

/* Responsive : masquer colonnes secondaires sur mobile */
@media (max-width: 768px) {
  .fixeo-pay-option-badge { display: none; }
  .fixeo-pay-option-desc  { display: none; }
}
