/* Calculator Main Styles */
.calculator-section {
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    padding: 30px;
    margin-bottom: 30px;
    transition: all 0.3s ease;
}

.calculator-section:hover {
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

.billing_title h2 {
    color: #2a2a2a;
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 25px;
    padding-bottom: 15px;
    position: relative;
}

.billing_title h2::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 60px;
    height: 3px;
    background: #0f3667;
}

/* Input Fields */
.calculator_input_box {
    margin-bottom: 20px;
    position: relative;
}

.calculator_input_box label {
    display: block;
    font-size: 14px;
    color: #555;
    margin-bottom: 2px;
    font-weight: 500;
}

.calculator_input_box input[type="text"],
.calculator_input_box input[type="number"],
.calculator_input_box select {
    width: 100%;
    height: 40px;
    border: 1px solid #e0e0e0;
    border-radius: 0px;
    padding: 0 15px;
    font-size: 15px;
    color: #333;
    transition: all 0.3s ease;
    background-color: #f9f9f9;
}

/* Input with dollar sign on the left */
.input-with-dollar,
.input-with-percent {
    position: relative;
}

.input-with-dollar:before,
.input-with-percent:before {
    position: absolute;
    left: 12px;
    font-size: 15px;
    top: 69%;
    transform: translateY(-50%);
    color: #666;
    font-weight: 500;
    z-index: 1;
}

.input-with-dollar2:before {
    position: absolute;
    left: 20px;
    top: 70%;
    font-size: 15px;
    transform: translateY(-50%);
    color: #666;
    font-weight: 500;
    z-index: 1;
}

.input-with-percent2:before {
    position: absolute;
    left: 18px;
    top: 70%;
    transform: translateY(-50%);
    color: #666;
    font-weight: 500;
    z-index: 1;
}

.input-with-dollar:before {
    content: "$";
}
.input-with-dollar2:before {
    content: "$";
}

.input-with-percent:before {
    content: "%";
}
.input-with-percent2:before {
    content: "%";
}

.input-with-dollar input,
.input-with-percent input {
    padding-left: 25px !important;
}

/* Remove any right padding for percentage signs */
.input-with-percent input {
    padding-right: 15px !important;
}

/* For input groups with both dollar and percent */
.input-group {
    position: relative;
    display: flex;
    align-items: center;
}

.input-group .dollar-icon2 {
    position: absolute;
    left: 12px;
    font-size: 15px;
    color: #666;
    font-weight: 500;
    z-index: 1;
}

.input-group .input-with-percent {
    flex: 1;
}

.input-group input {
    width: 100%;
    padding-left: 25px !important;
}

.calculator_input_box input[type="text"]:focus,
.calculator_input_box input[type="number"]:focus,
.calculator_input_box select:focus {
    border-color: #0f3667;
    box-shadow: 0 0 0 3px rgba(243, 111, 34, 0.2);
    outline: none;
    background-color: #fff;
}

/* Slider Styling */
.range-slider {
    width: 100%;
    margin-top: 10px;
}

.range-slider input[type="range"] {
    -webkit-appearance: none;
    appearance: none; /* Standard property */
    width: 100%;
    height: 6px;
    border-radius: 3px;
    background: #e0e0e0;
    outline: none;
}

.range-slider input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #0f3667;
    cursor: pointer;
    transition: all 0.2s ease;
}

.range-slider input[type="range"]:hover::-webkit-slider-thumb {
    transform: scale(1.1);
    box-shadow: 0 0 10px rgba(243, 111, 34, 0.3);
}

/* Results Section */
.results-container {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 12px;
    padding: 25px;
    height: 100%;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

.result-item {
    display: flex;
    justify-content: space-between;
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid #e0e0e0;
}

.result-item:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.result-label {
    font-size: 15px;
    color: #555;
}

.result-value {
    font-size: 18px;
    font-weight: 600;
    color: #2a2a2a;
}

/* Chart Container */
.chart-container {
    width: 100%;
    height: 300px;
    margin: 25px 0;
    background: #fff;
    border-radius: 8px;
    padding: 15px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

/* Toggle Buttons */
.calculator-tabs {
    display: flex;
    margin-bottom: 25px;
    border-bottom: 1px solid #e0e0e0;
    flex-wrap: wrap;
}

.calculator-tab {
    padding: 12px 20px;
    background: none;
    border: none;
    font-size: 15px;
    font-weight: 500;
    color: #666;
    cursor: pointer;
    transition: all 0.3s ease;
    border-bottom: 3px solid transparent;
}

.calculator-tab.active, .calculator-tab:hover {
    color: #0f3667;
    border-bottom: 3px solid #0f3667;
}

/* Responsive Design */
@media (max-width: 768px) {
    .calculator-section {
        padding: 20px 15px;
    }
    
    .billing_title h2 {
        font-size: 24px;
    }
    
    .result-value {
        font-size: 16px;
    }
    
    .chart-container {
        height: 250px;
    }
}

/* Animation */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.calculator-section {
    animation: fadeIn 0.5s ease-out;
}


/* Remove padding & margin everywhere */
.loan-summary,
.loan-summary .row,
.loan-summary p,
.loan-summary h6,
.summary-item {
  margin: 0;
  padding: 0;
}
.loan-summary{
    background-color: #f9f9f9;
    padding: 10px;
}

/* Number of Payments — left aligned */
.payments-row {
  gap: 10px;                      /* label & value ke beech spacing */
  text-align: right;
  width: 100%;
}

.calculate-btn {
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;

  position: relative;
  overflow: hidden;
  border: none;
  outline: none !important;

  padding: 12px 40px; /* equal padding */
  background-color: var(--insuba-black3, #19232b);

  font-family: var(--insuba-font, "Roboto", sans-serif);
  font-size: 17px;
  color: #fff;
  font-weight: 500;

  border-radius: 100px;
  z-index: 1;
  transition: all 500ms ease;
}

.calculate-btn::after {
  content: "";
  width: 0%;
  height: 100%;
  position: absolute;
  top: 0;
  right: 0;
  border-radius: inherit;
  background-color: var(--insuba-base, #0365d3);
  z-index: -1;
  transition: all 500ms ease;
}
.calculate-btn:hover::after {
  width: 100%;
  left: 0;
}
.calculate-btn {
  text-align: center;
}


/* Small font for number + label */
.value-small {
  font-size: 12px;
}

.summary-item {
  display: flex;
  flex-direction: column;
  align-items: center;  
  justify-content: center;
  text-align: center;    
  font-size: 18px;
  padding: 15px;
}

.summary-value {
  font-size: 25px;
  font-weight: bold;
}

#amortizationTable tbody tr td:not([colspan]) {
  text-align: center;
  vertical-align: middle;
}


.calculator_input_dti input[type="text"],
.calculator_input_dti input[type="number"],
.calculator_input_dti select {
    width: 100%;
    height: 30px;
    border: 1px solid #e0e0e0;
    border-radius: 0px;
    padding: 0 10px;
    font-size: 14px;
    color: #333;
    transition: all 0.3s ease;
    background-color: #f9f9f9;
}

.calculator_input_dti {
    margin-bottom: 5px;
    position: relative;
}

.calculator_input_dti label {
    display: block;
    font-size: 13px;
    color: #555;
    margin-bottom: 2px;
    font-weight: 500;
}