/* Custom Gradient Range Slider Styles */
.gr-glow {
  --gradient: var(--gradient-primary);
  --percent: 50%;
  display: flex;
  align-items: center;
  position: relative;
  margin: 0 0 0.5em 0;
  width: 100%;
  height: 1.5em;
}

.gr-glow:before {
  background-image: var(--gradient);
  border-radius: 0.5em;
  content: '';
  display: block;
  filter: blur(0.6em);
  position: absolute;
  top: 25%;
  left: 0;
  width: var(--percent);
  height: 50%;
  z-index: -1;
}

.gr-input {
  background: #dcdcdc var(--gradient) no-repeat;
  background-size: var(--percent) 100%;
  border-radius: 0.375em;
  width: 100%;
  height: 0.75em;
  -webkit-appearance: none;
  appearance: none;
  -webkit-tap-highlight-color: transparent;
  cursor: pointer;
}

.gr-input:focus {
  outline: transparent;
}

/* WebKit Slider Thumb */
.gr-input::-webkit-slider-thumb {
  background-color: #ffffff;
  border: 0;
  border-radius: 50%;
  box-shadow: 0 0 0 0.0625em #dcdcdc inset, 0 2px 8px rgba(0, 0, 0, 0.15);
  width: 1.5em;
  height: 1.5em;
  transition: all 0.15s ease;
  -webkit-appearance: none;
  appearance: none;
  cursor: pointer;
}

.gr-input:focus::-webkit-slider-thumb,
.gr-input::-webkit-slider-thumb:hover {
  background-color: #f4f4f4;
  transform: scale(1.1);
  box-shadow: 0 0 0 0.0625em #dcdcdc inset, 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* Firefox Slider Thumb */
.gr-input::-moz-range-thumb {
  background-color: #ffffff;
  border: 0;
  border-radius: 50%;
  box-shadow: 0 0 0 0.0625em #dcdcdc inset, 0 2px 8px rgba(0, 0, 0, 0.15);
  width: 1.5em;
  height: 1.5em;
  transition: all 0.15s ease;
  cursor: pointer;
}

.gr-input:focus::-moz-range-thumb,
.gr-input::-moz-range-thumb:hover {
  background-color: #f4f4f4;
  transform: scale(1.1);
  box-shadow: 0 0 0 0.0625em #dcdcdc inset, 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* Firefox track */
.gr-input::-moz-range-track {
  background: transparent;
  border: none;
  height: 0.75em;
}

/* Accessibility */
.sr-only {
  clip: rect(1px, 1px, 1px, 1px);
  overflow: hidden;
  position: absolute;
  width: 1px;
  height: 1px;
}

/* Focus-visible support */
@supports selector(:focus-visible) {
  .gr-input:focus::-webkit-slider-thumb {
    background-color: #ffffff;
    transform: none;
    box-shadow: 0 0 0 0.0625em #dcdcdc inset, 0 2px 8px rgba(0, 0, 0, 0.15);
  }
  .gr-input:focus-visible::-webkit-slider-thumb,
  .gr-input::-webkit-slider-thumb:hover {
    background-color: #f4f4f4;
    transform: scale(1.1);
    box-shadow: 0 0 0 0.0625em #dcdcdc inset, 0 4px 12px rgba(0, 0, 0, 0.2);
  }
  .gr-input:focus::-moz-range-thumb {
    background-color: #ffffff;
    transform: none;
    box-shadow: 0 0 0 0.0625em #dcdcdc inset, 0 2px 8px rgba(0, 0, 0, 0.15);
  }
  .gr-input:focus-visible::-moz-range-thumb,
  .gr-input::-moz-range-thumb:hover {
    background-color: #f4f4f4;
    transform: scale(1.1);
    box-shadow: 0 0 0 0.0625em #dcdcdc inset, 0 4px 12px rgba(0, 0, 0, 0.2);
  }
}

/* Revenue Calculator Animation */
#total-revenue {
  transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
  transform-origin: center;
  will-change: transform, filter;
}

#scans-input,
#current-value {
  transition: all 0.3s ease;
}

/* Add subtle glow effect to the total revenue section */
.flex.flex-col.items-center.justify-center.border.rounded-lg.p-8.bg-white:has(
    #total-revenue
  ) {
  transition: box-shadow 0.3s ease;
}

/* Revenue Calculator Input Styling */
#scans-input {
  border: none;
  background: transparent;
  outline: none;
  font-weight: bold;
  color: var(--color-gray-8);
  width: 100%;
}

#scans-input:focus {
  background-color: rgba(255, 255, 255, 0.5);
  border-radius: 4px;
  padding: 2px 4px;
}

#scans-input::-webkit-outer-spin-button,
#scans-input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

#scans-input[type='number'] {
  margin: 0;
  padding: 0;
  -moz-appearance: textfield;
  border: 1px solid var(--color-gray-3);
  border-radius: 6px;
  padding: 4px 12px !important;
}
#scans-input[type='number']:focus {
  border: 1px solid var(--color-primary);
  border-radius: 6px;
  padding: 4px 12px !important;
}

/* Validation Message Styling */
#scans-validation {
  font-size: 12px;
  color: var(--color-primary);
  margin-top: 4px;
  opacity: 0;
  transition: opacity 0.3s ease;
}

#scans-validation:not(.hidden) {
  opacity: 1;
}

.hidden {
  display: none;
}

.price-calculator-overlay-top-right {
  background: #c2d3d2;
  border-radius: 81.927px 0 0 81.927px;
  height: 128px;
  opacity: 0.2;
  position: absolute;
  right: 0;
  top: -55px;
  width: 215px;
}

.price-calculator-overlay-bottom-left {
  background: #c1c8e6;
  border-radius: 0 100% 0 0 / 100% 100% 0 0;
  bottom: 0;
  height: 108px;
  left: 0px;
  opacity: 0.2;
  position: absolute;
  width: 150px;
}

@media (max-width: 768px) {
  .price-calculator-overlay-top-right {
    width: 64px;
  }

  .price-calculator-overlay-bottom-left {
    width: 52px;
    height: 52px;
  }
}
