.payment_container {
  display: flex;
  justify-content: center;
  align-items: flex-end;
  min-height: 80vh;
}

.pay-box {
  text-align: center;
  padding: 20px;
  font-family: sans-serif;
  background: var(--background_white);
  border-radius: 12px;
}

#qrcode {
  margin: 20px auto;
  display: flex;
  justify-content: center;
}

.amount {
  font-size: 1.5rem;
  font-weight: bold;
  color: #0066ff;
}

.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(15, 23, 42, 0.75);
  backdrop-filter: blur(4px);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 999;
  padding: 16px;
}

.modal-overlay.active {
  display: flex;
}

/* Modal Card */
.webhooks_container,
.modal-card {
  background: var(--background_white);
  border-radius: 16px;
  width: 100%;
  max-width: 500px;
  padding: 24px;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.2);
  position: relative;
}

.webhooks_container li {
  background: #f8f9fa;
  border: 1px solid #e9ecef;
  padding: 12px;
  margin-bottom: 8px;
  border-radius: 6px;
}

.close-btn {
  position: absolute;
  top: 12px;
  right: 16px;
  background: none;
  border: none;
  font-size: 1.8rem;
  color: #64748b;
  cursor: pointer;
}

.modal-header {
  text-align: center;
  margin-bottom: 20px;
}

.modal-header h3 {
  font-size: 1.25rem;
  color: #0f172a;
  margin-bottom: 4px;
}

.modal-header p {
  font-size: 1.1rem;
  font-weight: 700;
  color: #2563eb;
}

/* Grid Options */
.options-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.pay-option {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 18px 12px;
  border-radius: 12px;
  border: 2px solid #e2e8f0;
  background: #f8fafc;
  cursor: pointer;
  transition: all 0.2s ease;
}

.pay-option:active {
  transform: scale(0.97);
  background: #f1f5f9;
}

.pay-option .icon {
  font-size: 1.8rem;
  margin-bottom: 6px;
}

.pay-option .label {
  font-weight: 600;
  font-size: 0.9rem;
  color: #1e293b;
}

/* Specific highlights */
.pay-option.cash:hover {
  border-color: #22c55e;
}

.pay-option.qr:hover {
  border-color: #2563eb;
}

.pay-option.terminal:hover {
  border-color: #f59e0b;
}

.pay-option.tap:hover {
  border-color: #8b5cf6;
}

/* QR Container */
.qr-container {
  text-align: center;
}

.qr-instruction {
  font-size: 0.85rem;
  color: #64748b;
  margin-bottom: 12px;
}

#modalQrCode {
  display: flex;
  justify-content: center;
  margin-bottom: 16px;
}

.back-btn {
  background: #f1f5f9;
  color: #334155;
  border: none;
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
}

/*  ========================================== */

.checkout-card {
  background: var(--background_white);
  border-radius: 16px;
  padding: 30px 30px;
  max-width: 580px;
  margin: 0 auto;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.08);
}

.checkout-header {
  text-align: center;
  /* background-color: var(--background_cream); */
  border-radius: 18px;
  padding: 20px;
}

.checkout-header h2 {
  margin: 0;
  font-size: 1.75rem;
  color: #667eea;
  /* color: #0f172a; */
}

.cost-summary {
  display: flex;
  justify-content: space-between;
  background: var(--background_cream);
  padding: 0.3rem;
  border-radius: 10px;
  margin: 0.25rem 0;
}

.checkout-header p {
  color: var(--text_color);
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 5px;
}

.cost-amount {
  color: #2563eb;
  font-size: 1.1rem;
}

.form-select {
  width: 100%;
  padding: 0.25rem;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  margin: 0;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--text_color);
}

.form-select option {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--text_color);
}

.total-payable-container {
  text-align: center;
  margin: 0.25rem 0;
}

.custom-time-box {
  margin: 0;
}

.total-payable-container h1 {
  font-size: 2.5rem;
  color: #16a34a;
  margin: 0.25rem 0 0 0;
}

.payment-actions {
  display: flex;
  gap: 1rem;
  /* background-color: #22c55e; */
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
}

.payment-actions button {
  width: 45%;
}

.btn-cash {
  background: #0f172a;
  color: var(--text_white);
}

.btn-yoco {
  background: var(--primary_color);
  color: var(--text_white);
}

/*  */
.btn-end-session {
  background: #ef4444;
  /* Alert / Danger Red */
  color: #ffffff;
}

.btn-end-session:hover {
  background: #dc2626;
}

.payment-actions span.icon {
  color: var(--text_white);
  font-size: xx-large;
}

.payment-actions span {
  color: var(--text_white);
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.7);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10000;
}

.modal-card {
  background: #ffffff;
  padding: 1.5rem;
  border-radius: 12px;
  width: 90%;
  max-width: 380px;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.2);
}

.calc-row {
  display: flex;
  justify-content: space-between;
  margin: 1rem 0;
  font-size: 1.1rem;
}

.form-input {
  width: 100%;
  padding: 0.75rem;
  font-size: 1.25rem;
  border: 2px solid #cbd5e1;
  border-radius: 8px;
  margin-top: 0.25rem;
}

.change-amount {
  color: #026e2a;
  font-size: 1.3rem;
  font-weight: 800;
}

.change-amount.negative {
  color: #b80404;
  font-size: 1rem;
}

.modal-actions {
  display: flex;
  gap: 0.75rem;
  margin-top: 1.25rem;
}

.duration-selector label {
  color: var(--text_color);
}

.custom-time-inputs {
  display: flex;
  gap: 0.5rem;
  margin-top: 0.5rem;
}

/* Modal Backdrop & Centering */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.75);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  padding: 1rem;
  box-sizing: border-box;
  animation: fadeIn 0.2s ease-out;
}

/* Modal Card Container */
.modal-card {
  background: var(--background_white);
  color: var(--text_color);
  width: 100%;
  max-width: 380px;
  border-radius: 16px;
  padding: 1.5rem;
  box-shadow:
    0 20px 25px -5px rgba(0, 0, 0, 0.4),
    0 8px 10px -6px rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-sizing: border-box;
}

.modal-card h3 {
  margin: 0 0 1.25rem 0;
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--text_color);
  text-align: center;
}

.modal-card h3 {
  margin: 0 0 1.25rem 0;
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--text_color);
  text-align: center;
}

/* Row Display Styling */
.calc-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.75rem 1rem;
  background: var(--background_cream);
  border-radius: 10px;
  font-size: 1rem;
  color: var(--text_color);
  margin-bottom: 1rem;
}

.calc-row strong {
  font-size: 1.2rem;
  color: #38bdf8;
}

/* Input Group */
.input-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-bottom: 0;
}

.input-group label {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text_color);
}

.form-input {
  width: 100%;
  padding: 0.25rem 0.8rem;
  font-size: 1.5rem;
  font-weight: 700;
  /* text-align: right; */
  /* background-color: #0f172a; */
  color: var(--text_color, #fff);
  border: var(--border);
  border-radius: 8px;
  box-sizing: border-box;
  outline: none;
  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease;
}

.form-input:focus {
  border-color: #38bdf8;
  box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.2);
}

/* Change Due Highlight */
.change-row {
  background: #0f172a;
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.change-amount {
  font-size: 1.35rem;
  color: #008a32;
  /* Success Green */
}

.change-amount.negative {
  color: #c70000;
  /* Warning Red */
  font-size: 1rem;
}

/* Modal Buttons */
.modal-actions {
  display: flex;
  gap: 0.75rem;
  margin-top: 1.5rem;
}

.btn-primary:disabled {
  background-color: #1e293b;
  color: #d0dae7;
  border: 1px solid #334155;
  cursor: not-allowed;
  opacity: 0.6;
}

.btn:active:not(:disabled) {
  transform: scale(0.98);
}

/* Container alignment */
.calc-row.change-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.85rem 1rem;
  cursor: pointer;
}

/* Enlarge checkbox and set modern accent color */
.form-checkbox {
  width: 1.5rem;
  /* Larger width */
  height: 1.5rem;
  /* Larger height */
  min-width: 1.5rem;
  min-height: 1.5rem;
  accent-color: #2563eb;
  /* Primary theme blue */
  cursor: pointer;
  border-radius: 6px;
}

/* Label text adjustment */
.calc-row.change-row label {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text_color);
  cursor: pointer;
  user-select: none;
  line-height: 1.3;
}

.ended-actions {
  display: flex;
}

.custom-time-box h2 {
  color: var(--text_color);
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
}

.custom-time-box h2 span {
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--text_red);
}

.modal-content {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-direction: column;
}

.spinner {
  width: 42px;
  height: 42px;
  border: 4px solid #f3f3f3;
  border-top: 4px solid #007bff;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin-bottom: 16px;
}

/* Entry Animation */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: scale(0.95);
  }

  to {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }

  100% {
    transform: rotate(360deg);
  }
}

@media (max-width: 768px) {
  .checkout-card {
    padding: 10px;
    /* background-color: #ff0000; */
  }
}