@keyframes r2r-estimate-flash {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.25;
  }
}

.r2r-estimate-flash {
  animation: r2r-estimate-flash 1s infinite;
}

.r2r-estimator .checkout-btn {
  background: radial-gradient(
    at bottom center,
    #52a6c9 0%,
    #19e575 70%
  ) !important;
  border-radius: 5px !important;
  background-repeat: no-repeat;
  background-size: 150% 150%;
  color: white !important;
  font-weight: 600 !important;
  border: none !important;
  width: 150px !important;
}

.r2r-estimator .checkout-btn:disabled,
.r2r-estimator .checkout-btn[disabled] {
  background: #d1d5db !important;
  border-color: #cbd5e1 !important;
  color: #6b7280 !important;
  cursor: not-allowed !important;
  opacity: 0.75;
}

.r2r-estimator .get-estimate-btn {
  background: radial-gradient(
    at bottom center,
    #52a6c9 0%,
    #8d19e5 70%
  ) !important;
  border-radius: 5px !important;
  background-repeat: no-repeat;
  background-size: 150% 150%;
  color: white !important;
  font-weight: 600 !important;
  border: none !important;
  width: 150px !important;
  margin-top: 20px !important;
}

.r2r-estimator {
  display: flex;
  flex-direction: row;
  justify-content: flex-start;
  align-items: center;
  gap: 10px;

}

#r2r-estimate-result {
  font-weight: 600 !important;
  font-size: 16px !important;
}

/* --- R2R Checkout Confirm Modal --- */
#r2r-confirm-modal.r2r-modal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 99999;
  padding: 20px;
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}

#r2r-confirm-modal.r2r-modal.is-open {
  display: block;
}

.r2r-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
}

.r2r-modal__panel {
  display: flex;
  flex-direction: column;
  position: relative;
  max-width: 700px;
  width: min(700px, 100%);
  max-height: calc(100vh - 40px);
  max-height: calc(100svh - 40px);
  margin: 20px auto;
  background: #fff;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
  padding-bottom: 30px;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.r2r-modal__row {
  display: block;
  margin: 10px 0;
}

.r2r-modal__error {
  margin-top: 10px;
  color: #b00020;
}

#r2r-modal-confirm {
  background: radial-gradient(
    at bottom center,
    #f0ff1a 0%,
    #e97c2f 70%
  ) !important;
  border-radius: 5px !important;
  background-repeat: no-repeat;
  background-size: 150% 150%;
  color: white !important;
  font-weight: 600 !important;
  border: none !important;
  width: 150px !important;
  box-shadow: 0 3px 3px rgba(0, 0, 0, 0.2);
}

#r2r-modal-cancel {
  background: radial-gradient(
    at bottom center,
    #52a6c9 0%,
    #8d19e5 70%
  ) !important;
  border-radius: 5px !important;
  background-repeat: no-repeat;
  background-size: 150% 150%;
  color: white !important;
  font-weight: 600 !important;
  border: none !important;
  width: 150px !important;
  box-shadow: 0 3px 3px rgba(0, 0, 0, 0.2);
}

.r2r-modal__row {
  font-size: 14px;
  display: flex;
  align-items: flex-start; /* keeps long text aligned nicely */
  gap: 10px; /* space between checkbox and text */
}

.r2r-modal__header {
  text-align: center;
  background: radial-gradient(
    at bottom center,
    #52a6c9 0%,
    #8d19e5 70%
  ) !important;

  padding: 20px;
}

.r2r-modal__title {
  color: white;
  font-size: 32px;
  font-weight: 600;
}

.r2r-modal__body {
  padding-left: 40px;
  padding-right: 40px;
  padding-bottom: 30px;
  padding-top: 30px;
}

.r2r-modal__actions {
  padding-left: 40px;
  padding-right: 40px;
  padding-bottom: 20px;
}

.r2r-modal__actions {
  display: flex;
  flex-direction: row;
  justify-items: center;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.r2r-modal-top-text {
  text-align: center;
  font-size: 14px;
}

.r2r-modal__body {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.r2r-modal-links {
  display: flex;
  flex-direction: row;
  justify-items: center;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-size: 12px;
}

.r2r-modal-link-text {
  color: #52a6c9;
}

.r2r-modal-link-text-border {
  color: #52a6c9;
  border-right: 1px solid rgb(192, 192, 192);
  padding-right: 7px;
}

.r2r-modal__cb {
  accent-color: #d9d9d9;
}

@supports (height: 100dvh) {
  .r2r-modal__panel {
    max-height: calc(100dvh - 40px);
  }
}

@media (max-width: 767px) {
  #r2r-confirm-modal.r2r-modal {
    padding: 10px;
  }

  .r2r-modal__panel {
    max-height: calc(100vh - 20px);
    max-height: calc(100svh - 20px);
    margin: 10px auto;
  }

  .r2r-modal__body {
    padding-left: 20px;
    padding-right: 20px;
  }

  .r2r-modal__actions {
    padding-left: 20px;
    padding-right: 20px;
    flex-wrap: wrap;
  }

  .r2r-modal-links {
    flex-wrap: wrap;
    row-gap: 6px;
    padding: 0 20px 20px;
  }

  .r2r-modal-link-text-border {
    border-right: 0;
    padding-right: 0;
  }
}
