/**
 * Loan Repayment Calculator CSS
 */

/* Calculator specific styles */
.loan-repayment-calculator {
  /* Inherits common styles from lcs-calculator */
  position: relative;
}

.loan-repayment-calculator::before {
  content: "🏠";
  position: absolute;
  top: 20px;
  right: 24px;
  font-size: 24px;
  opacity: 0.1;
  z-index: 0;
}

/* Full width select */
.loan-repayment-calculator .full-width {
  width: 100%;
}

/* Enhanced chart wrapper */
.loan-repayment-calculator .lcs-chart-wrapper {
  height: 400px;
  margin-top: 16px;
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
  border: 1px solid #e2e8f0;
  padding: 10px;
}

.loan-repayment-calculator .lcs-chart-wrapper canvas {
  width: 100% !important;
  height: 100% !important;
}

/* Results section customization */
.loan-repayment-calculator .lcs-results-section {
  background: linear-gradient(135deg, #f0f9ff, #e0f2fe);
  border-left: 6px solid #0073aa;
  border-radius: 12px;
  box-shadow: 0 4px 16px rgba(0, 115, 170, 0.12);
  position: relative;
  overflow: hidden;
}

.loan-repayment-calculator .lcs-results-section::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, #0073aa, #005f8b);
}

.loan-repayment-calculator .lcs-result-details {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
  margin-top: 24px;
}

.loan-repayment-calculator .lcs-result-item {
  background: linear-gradient(135deg, #ffffff, #f8fafc);
  padding: 20px;
  border-radius: 10px;
  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.08);
  border: 1px solid #e2e8f0;
  transition: all 0.2s ease;
  display: flex;
  flex-direction: column;
  position: relative;
}

.loan-repayment-calculator .lcs-result-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.12);
}

.loan-repayment-calculator .lcs-result-item .lcs-result-label {
  font-size: 14px;
  color: #666;
  margin-bottom: 5px;
  font-weight: 600;
}

.loan-repayment-calculator .lcs-result-item .lcs-result-value {
  font-size: 24px;
  font-weight: 700;
  color: #0073aa;
  text-shadow: 0 1px 2px rgba(0, 115, 170, 0.1);
}

/* Input group styling for loan fee */
.loan-repayment-calculator .lcs-input-group {
  display: flex;
  gap: 10px;
  align-items: flex-end;
}

.loan-repayment-calculator .lcs-input-group .lcs-input-wrapper {
  flex: 1;
}

.loan-repayment-calculator .lcs-input-group select {
  min-width: 120px;
  height: 48px;
  padding: 12px 16px;
  border: 2px solid #e5e7eb;
  border-radius: 8px;
  font-size: 16px;
  background-color: #fff;
  transition: all 0.2s ease;
  cursor: pointer;
  appearance: none;
  background-image: url('data:image/svg+xml;charset=US-ASCII,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 4 5"><path fill="%23666" d="M2 0L0 2h4zm0 5L0 3h4z"/></svg>');
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 12px;
  padding-right: 40px;
}

.loan-repayment-calculator .lcs-input-group select:focus {
  outline: none;
  border-color: #0073aa;
  box-shadow: 0 0 0 3px rgba(0, 115, 170, 0.1);
}

/* Disclaimer styling */
.loan-repayment-calculator .lcs-disclaimer {
  margin-top: 20px;
  padding: 10px;
  border-top: 1px solid #eee;
}

.loan-repayment-calculator .lcs-note {
  font-size: 12px;
  color: #666;
  font-style: italic;
  line-height: 1.4;
}

/* Print styles */
@media print {
  .loan-repayment-calculator {
    box-shadow: none;
    padding: 0;
  }

  .loan-repayment-calculator .lcs-btn-group {
    display: none;
  }

  .loan-repayment-calculator .lcs-chart-wrapper {
    page-break-inside: avoid;
  }

  .loan-repayment-calculator .lcs-modal {
    display: none !important;
  }
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .loan-repayment-calculator .lcs-result-details {
    grid-template-columns: 1fr;
  }

  .loan-repayment-calculator .lcs-result-item {
    min-width: 100%;
  }

  .loan-repayment-calculator .lcs-calculator-container {
    flex-direction: column;
  }

  .loan-repayment-calculator .lcs-input-group {
    flex-direction: column;
    align-items: stretch;
  }

  .loan-repayment-calculator .lcs-input-group select {
    margin-top: 10px;
    min-width: 100%;
  }

  .loan-repayment-calculator .lcs-chart-wrapper {
    height: 300px;
  }
}
