/* ==========================================================================
   MODALS, BOTTOM SHEETS, RAZORPAY SIMULATOR & WHATSAPP DRAWER
   ========================================================================== */

/* Modern HTML Dialog Modal Resets */
dialog {
  border: none;
  background: transparent;
  padding: 0;
  margin: auto;
  max-width: 100%;
  max-height: 100%;
  overflow: visible;
}

dialog::backdrop {
  background: rgba(4, 7, 12, 0.78);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

/* ==========================================================================
   BOTTOM SHEET CHECKOUT MODAL (CUSTOMER MOBILE APP)
   ========================================================================== */
.bottom-sheet-dialog {
  margin-top: auto;
  margin-bottom: 0;
  width: 100%;
  max-width: 520px;
  animation: slideUpSheet 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes slideUpSheet {
  from { transform: translateY(100%); }
  to { transform: translateY(0); }
}

.bottom-sheet-content {
  background: var(--bg-sheet);
  border-top-left-radius: var(--radius-xl);
  border-top-right-radius: var(--radius-xl);
  border: 1px solid var(--border-color);
  border-bottom: none;
  padding: 20px 24px 34px 24px;
  box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.7);
  max-height: 85vh;
  overflow-y: auto;
}

.sheet-handle-bar {
  width: 44px;
  height: 5px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: var(--radius-full);
  margin: 0 auto 16px auto;
}

.sheet-lock-banner {
  background: linear-gradient(135deg, rgba(250, 204, 21, 0.15), rgba(255, 85, 0, 0.12));
  border: 1px solid rgba(250, 204, 21, 0.3);
  border-radius: var(--radius-md);
  padding: 10px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 18px;
}

.sheet-lock-label {
  font-size: 13px;
  font-weight: 700;
  color: var(--zyn-yellow);
  display: flex;
  align-items: center;
  gap: 6px;
}

.sheet-lock-timer {
  font-size: 15px;
  font-weight: 900;
  font-family: var(--font-mono);
  color: #ffffff;
  background: rgba(0, 0, 0, 0.4);
  padding: 2px 8px;
  border-radius: var(--radius-sm);
}

.checkout-summary-box {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 14px;
  margin-bottom: 18px;
}

.summary-row {
  display: flex;
  justify-content: space-between;
  font-size: 13px;
  margin-bottom: 8px;
}

.summary-row.total-row {
  border-top: 1px dashed var(--border-color);
  padding-top: 10px;
  margin-top: 10px;
  font-size: 16px;
  font-weight: 800;
}

/* Payment Mode Choice Cards */
.payment-modes-group {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 18px 0;
}

.payment-mode-option {
  border: 2px solid var(--border-color);
  background: rgba(255, 255, 255, 0.03);
  border-radius: var(--radius-md);
  padding: 14px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 14px;
  transition: all var(--transition-fast);
}

.payment-mode-option:hover {
  border-color: var(--brand-green);
  background: var(--brand-green-soft);
}

.payment-mode-option.active {
  border-color: var(--brand-green);
  background: var(--brand-green-soft);
}

.mode-radio-circle {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 2px solid var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
}
.payment-mode-option.active .mode-radio-circle {
  border-color: var(--brand-green);
}
.payment-mode-option.active .mode-radio-circle::after {
  content: '';
  width: 10px;
  height: 10px;
  background: var(--brand-green);
  border-radius: 50%;
}

.mode-info-col {
  flex: 1;
}

.mode-title {
  font-size: 14px;
  font-weight: 800;
  display: flex;
  align-items: center;
  gap: 6px;
}

.mode-subtitle {
  font-size: 12px;
  color: var(--text-secondary);
}

.mode-badge {
  font-size: 11px;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: var(--radius-full);
}
.mode-badge.recommended { background: var(--brand-green); color: #05140b; }
.mode-badge.token { background: var(--brand-green-soft); color: var(--brand-green); border: 1px solid var(--brand-green-border); }

/* ==========================================================================
   AUTHENTIC RAZORPAY CHECKOUT MODAL SIMULATION
   ========================================================================== */
.razorpay-modal-card {
  width: 390px;
  max-width: 95vw;
  background: #11141c;
  border: 1px solid #232a3b;
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.85);
  font-family: var(--font-body);
}

.razorpay-header {
  background: #0c2340;
  padding: 16px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 2px solid #0070f3;
}

.rzp-logo-badge {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 800;
  font-size: 15px;
  color: #ffffff;
}

.rzp-logo-badge svg {
  height: 22px;
  width: auto;
}

.rzp-amount-badge {
  font-size: 18px;
  font-weight: 900;
  color: #00d2ff;
}

.razorpay-body {
  padding: 20px;
}

.rzp-apps-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin: 16px 0;
}

.rzp-app-btn {
  background: #19202f;
  border: 1px solid #28334a;
  border-radius: 10px;
  padding: 10px;
  text-align: center;
  cursor: pointer;
  font-size: 12px;
  font-weight: 700;
  color: #e2e8f0;
  transition: all var(--transition-fast);
}

.rzp-app-btn:hover {
  background: #0070f3;
  border-color: #0070f3;
}

.rzp-pay-cta {
  width: 100%;
  background: linear-gradient(135deg, #0070f3 0%, #00a6ff 100%);
  color: #ffffff;
  border: none;
  padding: 14px;
  border-radius: 10px;
  font-size: 15px;
  font-weight: 800;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 16px;
  box-shadow: 0 4px 14px rgba(0, 112, 243, 0.4);
}

/* ==========================================================================
   SLIDE-OVER WHATSAPP LIVE SIMULATOR DRAWER
   ========================================================================== */
.whatsapp-drawer-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
  z-index: 1000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

.whatsapp-drawer-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.whatsapp-drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: 380px;
  max-width: 90vw;
  background: #0b141a;
  border-left: 1px solid #222d34;
  z-index: 1001;
  transform: translateX(100%);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
}

.whatsapp-drawer-overlay.active .whatsapp-drawer {
  transform: translateX(0);
}

.wa-drawer-header {
  background: #202c33;
  padding: 16px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid #222d34;
}

.wa-profile {
  display: flex;
  align-items: center;
  gap: 10px;
}

.wa-avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: #00a884;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 900;
  color: #ffffff;
}

.wa-chat-feed {
  flex: 1;
  overflow-y: auto;
  padding: 20px 16px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  background-image: radial-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 16px 16px;
}

.wa-bubble {
  max-width: 90%;
  align-self: flex-end;
  background: #005c4b;
  color: #e9edef;
  border-radius: 12px;
  border-top-right-radius: 2px;
  padding: 10px 14px;
  font-size: 13px;
  line-height: 1.45;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
  position: relative;
  white-space: pre-line;
}

.wa-bubble-time {
  font-size: 10px;
  color: #8696a0;
  text-align: right;
  margin-top: 4px;
}

.wa-external-link-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 8px;
  background: #00a884;
  color: #ffffff;
  padding: 6px 12px;
  border-radius: 6px;
  text-decoration: none;
  font-weight: 700;
  font-size: 12px;
}

/* ==========================================================================
   INTERACTIVE MODAL CARDS & DIALOGS (PITCH, POS, CONFIRMATION & ADMIN)
   ========================================================================== */
.pitch-modal-card {
  width: 580px;
  max-width: 95vw;
  background: var(--bg-card);
  color: var(--text-primary);
  border: 1.5px solid var(--border-color);
  border-radius: var(--radius-xl);
  padding: 24px;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.35);
  transition: background-color var(--transition-normal);
}

.pitch-svg-container {
  width: 100%;
  height: 280px;
  border-radius: var(--radius-md);
  overflow: hidden;
  background: #042514;
  border: 2px solid #22c55e;
  margin: 16px 0;
  box-shadow: inset 0 0 40px rgba(0, 0, 0, 0.6);
}

/* Slot Selection Confirmation Modal */
.slot-confirm-card {
  width: 480px;
  max-width: 95vw;
  background: var(--bg-card);
  color: var(--text-primary);
  border: 1.5px solid var(--border-color);
  border-radius: var(--radius-xl);
  padding: 28px;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.45), var(--shadow-glow-cyan);
}

.slot-confirm-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
}

.slot-confirm-icon {
  font-size: 28px;
  background: rgba(0, 102, 255, 0.1);
  width: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-full);
}

.slot-confirm-details {
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 16px;
  margin: 16px 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.confirm-detail-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13.5px;
}

.confirm-lock-notice {
  font-size: 12px;
  color: var(--text-secondary);
  background: var(--brand-green-soft);
  border: 1px dashed var(--brand-green-border);
  border-radius: var(--radius-md);
  padding: 10px 14px;
  line-height: 1.45;
  margin-bottom: 22px;
  display: flex;
  align-items: flex-start;
  gap: 8px;
}

.confirm-actions-row {
  display: flex;
  gap: 12px;
}

/* Pay at Ground Pending Approval Card */
.pending-approval-card {
  background: linear-gradient(135deg, rgba(234, 88, 12, 0.12), rgba(202, 138, 4, 0.08));
  border: 1.5px solid rgba(234, 88, 12, 0.35);
  border-radius: var(--radius-lg);
  padding: 18px;
  margin-bottom: 20px;
}

/* Admin Turf Management Modals */
.admin-turf-modal-card {
  width: 620px;
  max-width: 95vw;
  background: var(--bg-card);
  color: var(--text-primary);
  border: 1.5px solid var(--border-color);
  border-radius: var(--radius-xl);
  padding: 28px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.5);
}

/* Toast Notifications */
.toast-container {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2000;
  display: flex;
  flex-direction: column;
  gap: 8px;
  pointer-events: none;
}

.toast {
  background: var(--bg-card);
  border: 1px solid var(--border-glow);
  color: var(--text-primary);
  padding: 12px 20px;
  border-radius: var(--radius-full);
  font-size: 13px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 10px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
  pointer-events: auto;
  animation: toastIn 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

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