/* Shared bottom-sheet modals — How to Play, Deposit pay, Txn detail */

.ra-sheet-modal {
  padding: 0 !important;
}

.ra-sheet-modal .modal-dialog.ra-sheet-dialog {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  margin: 0 auto !important;
  max-width: 520px;
  width: 100%;
}

.ra-sheet-modal.fade .modal-dialog.ra-sheet-dialog {
  transform: translate3d(0, 100%, 0) !important;
  transition: transform 0.28s cubic-bezier(0.22, 1, 0.36, 1) !important;
}

.ra-sheet-modal.show .modal-dialog.ra-sheet-dialog,
.ra-sheet-modal.ra-sheet-open .modal-dialog.ra-sheet-dialog {
  transform: translate3d(0, 0, 0) !important;
}

.ra-sheet-content {
  background: linear-gradient(160deg, #141e38 0%, #0d1525 55%, #0a101e 100%) !important;
  border: 1px solid rgba(255, 255, 255, 0.09) !important;
  border-bottom: 0 !important;
  border-radius: 18px 18px 0 0 !important;
  color: #e8eaf6 !important;
  box-shadow: 0 -20px 60px rgba(0, 0, 0, 0.55);
  max-height: min(88vh, 720px);
  max-height: min(88dvh, 720px);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.ra-sheet-handle {
  width: 40px;
  height: 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  margin: 10px auto 4px;
  flex-shrink: 0;
}

.ra-sheet-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 18px 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
  flex-shrink: 0;
}

.ra-sheet-header h5,
.ra-sheet-title {
  margin: 0;
  font-size: 16px;
  font-weight: 800;
  color: #e8eaf6;
}

.ra-sheet-close {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.04);
  color: #94a3b8;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 0;
}

.ra-sheet-close:hover {
  color: #e8eaf6;
  background: rgba(255, 255, 255, 0.08);
}

.ra-sheet-body {
  padding: 16px 18px;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  flex: 1 1 auto;
  min-height: 0;
}

.ra-sheet-footer {
  padding: 12px 18px calc(14px + env(safe-area-inset-bottom, 0px));
  border-top: 1px solid rgba(255, 255, 255, 0.07);
  flex-shrink: 0;
  background: rgba(8, 12, 24, 0.55);
}

body.ra-sheet-open {
  overflow: hidden !important;
}

/* Keep sheet interactive above backdrop */
#ra-dep-pay-sheet.modal {
  z-index: 1065;
  pointer-events: auto;
}

#ra-dep-pay-sheet .modal-dialog,
#ra-dep-pay-sheet .modal-content,
#ra-dep-pay-sheet .ra-sheet-body,
#ra-dep-pay-sheet .ra-sheet-footer,
#ra-dep-pay-sheet input,
#ra-dep-pay-sheet button {
  pointer-events: auto !important;
}

#ra-dep-pay-sheet .ra-dep-submit-btn,
#ra-dep-pay-sheet #ra-dep-submit {
  width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 16px;
  border: 0;
  border-radius: 10px;
  background: linear-gradient(135deg, #ff6a35, #cc1a00);
  color: #fff;
  font-weight: 800;
  font-size: 14px;
}

#ra-dep-pay-sheet #ra-dep-submit:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  filter: grayscale(0.2);
}

#ra-dep-pay-sheet #ra-dep-utr-wrap .ra-dep-input {
  width: 100%;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #e8eaf6;
  border-radius: 10px;
  padding: 12px 14px;
}

#ra-dep-pay-sheet #ra-dep-payto-error:not([hidden]) {
  display: block;
  padding: 10px 12px;
  border-radius: 8px;
  background: rgba(239, 68, 68, 0.12);
  border: 1px solid rgba(239, 68, 68, 0.28);
  color: #fca5a5;
  font-size: 13px;
}

/* Deposit pay sheet specifics */
#ra-dep-pay-sheet .ra-sheet-amount {
  font-size: 22px;
  font-weight: 900;
  color: #ff7a4d;
  margin-bottom: 12px;
}

#ra-dep-pay-sheet .ra-dep-utr-steps {
  margin-bottom: 12px;
}

#ra-dep-pay-sheet #ra-dep-payto-loading {
  padding: 18px 0;
  text-align: center;
  color: #94a3b8;
  font-size: 13px;
}

/* How-to-play sheet */
#ra-how-modal .ra-how-steps {
  display: grid;
  gap: 12px;
}

@media (min-width: 768px) {
  #ra-how-modal .ra-how-steps {
    grid-template-columns: repeat(3, 1fr);
  }
}

#ra-how-modal .ra-how-step {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  padding: 14px;
}

#ra-how-modal .ra-how-step h4 {
  color: #ff5f2e;
  font-weight: 900;
  font-size: 20px;
  margin: 0 0 4px;
}

/* Txn detail as sheet */
#ra-txn-detail-modal.ra-sheet-modal .ra-txn-modal-content {
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
}

@media (min-width: 992px) {
  .ra-sheet-modal .modal-dialog.ra-sheet-dialog {
    max-width: 480px;
  }
}
