/**
 * InsidePiano - CBSubs Payment Page  
 * Styles for /component/comprofiler/pluginclass/cbpaidsubscriptions payment checkout
 */

/* Alert danger - ghost style with red tint */
body div.alert.alert-danger {
  background-color: rgba(234, 84, 85, 0.1) !important;
  background-image: none !important;
  border: 1px solid rgba(234, 84, 85, 0.3) !important;
  border-left: 3px solid #ea5455 !important;
  border-radius: 0.5rem !important;
  color: rgb(234, 84, 85) !important;
  padding: 1rem 1.25rem !important;
  margin-bottom: 1.5rem !important;
}

/* Alert warning (yellow) - ghost style with amber tint */
body div.alert.alert-warning#cbregTermsError {
  background-color: rgba(245, 158, 11, 0.1) !important;
  background-image: none !important;
  border: 1px solid rgba(245, 158, 11, 0.3) !important;
  border-left: 3px solid #f59e0b !important;
  border-radius: 0.5rem !important;
  color: rgb(245, 158, 11) !important;
  padding: 0.75rem 1.25rem !important;
  margin-bottom: 1.5rem !important;
  margin-top: 12px !important;
}

/* Yellow warning button (when visible) - ghost style with amber tint */
.cb_template body button#cbTermsAccept.btn.btn-light.border,
body .cb_template button#cbTermsAccept.btn.btn-light.border,
body button#cbTermsAccept.btn.btn-light.border {
  background-color: rgba(245, 158, 11, 0.1) !important;
  background-image: none !important;
  border: 1px solid rgba(245, 158, 11, 0.3) !important;
  border-left: 3px solid #f59e0b !important;
  color: rgb(245, 158, 11) !important;
  padding: 0.75rem 1.25rem !important;
  border-radius: 0.5rem !important;
  font-weight: 500 !important;
  margin-bottom: 1.5rem !important;
  width: 100% !important;
  text-align: left !important;
}

/* Coupon input group */
.cb_template .form-auto .input-group {
  padding-top: 10px !important;
}

/* Input group button alignment fix */
.input-group > :not(:first-child):not(.dropdown-menu):not(.valid-tooltip):not(.valid-feedback):not(.invalid-tooltip):not(.invalid-feedback) {
  margin-top: -2px !important;
}

/* Summary table */
body table {
  background: rgb(31, 31, 33) !important;
  border: 1px solid rgba(228, 230, 252, 0.12) !important;
  border-radius: 0.5rem !important;
  overflow: hidden !important;
  width: 100% !important;
  margin-bottom: 1.5rem !important;
}

body table th,
body table td {
  background: transparent !important;
  border-bottom: 1px solid rgba(228, 230, 252, 0.08) !important;
  color: #d0d2d6 !important;
  padding: 0.75rem 1rem !important;
}

body table th {
  font-weight: 600 !important;
  color: #e4e6fc !important;
  background: rgb(22, 22, 24) !important;
}

body table tr:last-child td {
  border-bottom: none !important;
}

.cb_template .table td,
.cb_template .table th {
  border-top: 1px solid #333 !important;
}

/* Coupon input */
body .cbregCouponInput input[type="text"] {
  background: rgb(22, 22, 24) !important;
  border: 1px solid rgba(228, 230, 252, 0.12) !important;
  border-radius: 0.375rem !important;
  color: rgb(200, 200, 205) !important;
  padding: 0.5rem 0.75rem !important;
}

body .cbregCouponInput input[type="text"]:focus {
  border-color: rgba(115, 103, 240, 0.5) !important;
  outline: none !important;
  box-shadow: 0 0 0 2px rgba(115, 103, 240, 0.15) !important;
}

/* Coupon button - ghost purple with left margin */
body .input-group-append button[name="addcouponcode"] {
  background: rgba(115, 103, 240, 0.15) !important;
  border: 1px solid rgba(115, 103, 240, 0.55) !important;
  color: #7367f0 !important;
  padding: 0.5rem 1.25rem !important;
  border-radius: 0.5rem !important;
  font-weight: 500 !important;
  transition: all 0.2s !important;
  margin-left: 0.75rem !important;
}

body .input-group-append button[name="addcouponcode"]:hover {
  background: rgba(115, 103, 240, 0.28) !important;
  border-color: rgba(115, 103, 240, 0.7) !important;
  color: rgb(159, 146, 254) !important;
  box-shadow: 0 0 0 1px rgba(115, 103, 240, 0.25) !important;
}

/* Payment button containers background */
.cb_template .cbpaidCCimage.cbpaidCCimageIcon,
.cb_template .cbpaidCCimage.cbpaidCCimageButton,
.cb_template .cbpaidCCimageInput.cbpaidCCimageIcon,
.cb_template .cbpaidCCimageInput.cbpaidCCimageButton {
  background-color: #000 !important;
}

/* Custom payment buttons - hide images inside */
.payment-btn-paypal input[type="image"],
.payment-btn-stripe input[type="image"],
.payment-btn-paypal img,
.payment-btn-stripe img {
  display: none !important;
}

.payment-btn-paypal,
.payment-btn-stripe {
  display: inline-block !important;
  padding: 0.75rem 2rem !important;
  font-size: 1rem !important;
  font-weight: 600 !important;
  text-align: center !important;
  border-radius: 0.5rem !important;
  cursor: pointer !important;
  transition: all 0.2s ease !important;
  border: none !important;
  min-width: 200px !important;
  margin: 0.5rem !important;
}

.payment-btn-paypal {
  background: #0070ba !important;
  color: white !important;
}

.payment-btn-paypal:hover {
  background: #005a92 !important;
  transform: translateY(-1px) !important;
  box-shadow: 0 4px 12px rgba(0, 112, 186, 0.3) !important;
}

.payment-btn-stripe {
  background: #635bff !important;
  color: white !important;
}

.payment-btn-stripe:hover {
  background: #4f46e5 !important;
  transform: translateY(-1px) !important;
  box-shadow: 0 4px 12px rgba(99, 91, 255, 0.3) !important;
}

/* Checkbox */
body input[type="checkbox"] {
  width: 1.125rem !important;
  height: 1.125rem !important;
  background: rgb(22, 22, 24) !important;
  border: 1px solid rgba(228, 230, 252, 0.25) !important;
  border-radius: 0.25rem !important;
  cursor: pointer !important;
  appearance: none !important;
  -webkit-appearance: none !important;
  position: relative !important;
}

body input[type="checkbox"]:checked {
  background: #7367f0 !important;
  border-color: #7367f0 !important;
}

body input[type="checkbox"]:checked::after {
  content: '✓' !important;
  position: absolute !important;
  top: 50% !important;
  left: 50% !important;
  transform: translate(-50%, -50%) !important;
  color: white !important;
  font-size: 0.875rem !important;
  font-weight: bold !important;
}

/* Payment gateway buttons (fallback for image buttons) */
body .cbpaidCCimageButton {
  background: rgb(31, 31, 33) !important;
  border: 1px solid rgba(228, 230, 252, 0.12) !important;
  border-radius: 0.5rem !important;
  padding: 0.75rem 1.5rem !important;
  transition: all 0.2s !important;
}

body .cbpaidCCimageButton:hover {
  background: rgb(22, 22, 24) !important;
  border-color: rgba(228, 230, 252, 0.2) !important;
}

body input[type="image"] {
  border: 1px solid rgba(228, 230, 252, 0.12) !important;
  border-radius: 0.5rem !important;
  padding: 0.5rem !important;
  background: rgb(31, 31, 33) !important;
  transition: all 0.2s !important;
}

body input[type="image"]:hover {
  background: rgb(22, 22, 24) !important;
  border-color: rgba(228, 230, 252, 0.2) !important;
}

/* Cancel link */
body a[href*="cancelpay"] {
  color: #7367f0 !important;
  text-decoration: none !important;
  font-weight: 500 !important;
}

body a[href*="cancelpay"]:hover {
  color: rgb(159, 146, 254) !important;
  text-decoration: underline !important;
}
