/* Two-Column Grid Layout */
.financing-calculator-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 30px;
  margin-bottom: 30px;
}

.aw-financing-calculator {
  color: #000;
}

.financing-controls-column {
  background: #fff;
  padding: 20px;
  border-radius: 0;
  box-shadow: 0 1.5rem 4rem rgba(25, 25, 30, 0.1);
}

.financing-results-column {
  background: #fff;
  padding: 20px;
  border-radius: 0;
  box-shadow: 0 1.5rem 4rem rgba(25, 25, 30, 0.1);
}

/* Financing Type Selector */
.financing-type-selector {
  margin-bottom: 25px;
}

.financing-type-selector label {
  display: block;
  margin-bottom: 10px;
  font-weight: 700;
}

.financing-type-buttons {
  display: flex;
  gap: 10px;
}

.financing-type-btn {
  flex: 1;
  padding: 7px 20px;
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 1px;
  font-size: 14px;
  font-weight: 400;
  color: #666;
  cursor: pointer;
  transition: all 0.3s ease;
}

.financing-type-btn:hover {
  border-color: #999;
  background: #f9f9f9;
}

.financing-type-btn.active {
  background: #333;
  border-color: #333;
  color: #fff;
}

/* Financing Controls */
.financing-controls {
  margin-bottom: 0;
}

.financing-control-group {
  margin-bottom: 20px;
}

.financing-control-group label {
  display: block;
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 5px;
}

.control-value-display {
  display: flex;
  align-items: center;
  gap: 5x;
}

.value-display {
  display: inline-block;
  font-size: 14px;
  font-weight: 600;
}

.value-helper {
  font-size: 14px;
  color: #666;
}

.financing-slider {
  margin: 15px 0;
  height: 6px; /* Reduce slider track height */
}

/* Customize noUiSlider for financing calculator */
.financing-slider .noUi-target {
  height: 6px; /* Compact slider track */
}

.financing-slider .noUi-connect {
  background: #333;
}

.financing-slider .noUi-handle {
  height: 18px; /* Smaller handle */
  width: 18px; /* Smaller handle */
  top: -6px; /* Center the handle on the track */
  right: -9px; /* Center the handle */
  background: #333;
  border: 2px solid #fff;
  border-radius: 50%; /* Make handle circular */
  cursor: pointer;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

.financing-slider .noUi-handle:before,
.financing-slider .noUi-handle:after {
  display: none; /* Remove the default handle bars */
}

.financing-slider .noUi-handle:hover {
  background: #555;
}

/* Results Display */
.financing-results {
  background: transparent;
  padding: 0;
  border-radius: 0;
  position: relative;
}

.financing-results.calculating {
  opacity: 0.6;
  pointer-events: none;
}

.monthly-payment {
  text-align: center;
}

.monthly-label {
  font-size: 14px;
  margin-bottom: 10px;
}

.monthly-value {
  font-size: 24px;
  font-weight: 700;
}

.per-month {
  font-size: 16px;
  font-weight: 400;
  margin-left: 5px;
}

/* Financing Details */
.financing-details {
  margin-bottom: 15px;
}

.detail-row {
  display: flex;
  justify-content: space-between;
  padding: 5px 0;
  border-bottom: 1px solid #e0e0e0;
}

.detail-row:last-child {
  border-bottom: none;
}

.detail-label {
  font-size: 14px;
}

.detail-value {
  font-size: 14px;
  font-weight: 600;
}

/* Disclaimer */
.financing-disclaimer {
  margin-top: 0;
  padding: 20px;
  background: #fff;
  border-radius: 0;
  box-shadow: 0 1.5rem 4rem rgba(25, 25, 30, 0.1);
  font-size: 12px;
  color: #999;
  line-height: 1.6;
}

.financing-disclaimer strong {
  color: #000;
  font-size: 26px;
  font-weight: 700;
}

.financing-disclaimer p {
  margin: 0;
}

/* Loading State */
.financing-loading {
  text-align: center;
  padding: 20px;
  color: #666;
}

.financing-loading .spinner {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 3px solid #f0f0f0;
  border-top: 3px solid #333;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin-right: 10px;
  vertical-align: middle;
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

/* Error State */
.financing-error {
  background: #fee;
  border: 1px solid #fcc;
  color: #c33;
  padding: 15px;
  border-radius: 4px;
  margin-top: 15px;
  text-align: center;
}

/* Responsive Design */
@media (max-width: 768px) {
  .financing-calculator-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .financing-type-buttons {
    flex-direction: column;
  }

  .monthly-value {
    font-size: 32px;
  }

  .detail-row {
    flex-direction: column;
    gap: 5px;
  }

  .detail-value {
    text-align: left;
  }
}
