/* Calculator Hero Section */
.calc-hero {
  background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
  padding: 5rem 0;
  position: relative;
  overflow: hidden;
}

.calc-hero .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
  z-index: 2;
}

.calc-hero-background {
  position: absolute;
  top: 0rem;
  left: 0;
  width: 100%;
  height: 100%;
  background: url("../assets/background/sterra_bg_9.jpg") no-repeat center
    center/cover;
  z-index: -1;
  /* opacity: 0.5; */
  background-attachment: fixed;
}

.calc-hero h1 {
  font-size: 3rem;
  margin-bottom: 1.5rem;
  color: #212529;
}

.calc-hero .highlight {
  color: #0056b3;
  position: relative;
}

.calc-hero .highlight::after {
  content: "";
  position: absolute;
  bottom: 5px;
  left: 0;
  width: 100%;
  height: 10px;
  background-color: rgba(0, 86, 179, 0.2);
  z-index: -1;
  border-radius: 50px;
}

.calc-hero .hero-subtitle {
  font-size: 1.25rem;
  color: #495057;
  margin-bottom: 2rem;
  max-width: 500px;
}

.calc-hero .hero-image img {
  max-width: 100%;
  height: auto;
  max-height: 400px;
}

/* Calculator Navigation */
.calc-nav {
  background-color: #fff;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  position: sticky;
  top: 0;
  z-index: 100;
}

.calc-tabs {
  display: flex;
  gap: 0.5rem;
  overflow-x: auto;
  padding: 1rem 0;
  scrollbar-width: none; /* Firefox */
}

.calc-tabs::-webkit-scrollbar {
  display: none; /* Chrome, Safari, Opera */
}

.calc-tab-btn {
  padding: 0.75rem 1.25rem;
  background: none;
  border: none;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  white-space: nowrap;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: #495057;
  font-size: 0.9rem;
}

.calc-tab-btn.active {
  background-color: #0056b3;
  color: white;
}

.calc-tab-btn i {
  font-size: 1rem;
}

/* Calculator Main Content */
.calc-main {
  padding: 3rem 0;
  background-color: #f8f9fa;
}

.calc-content {
  display: none;
}

.calc-content.active {
  display: block;
}

.calc-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
}

.calc-form {
  background: white;
  border-radius: 12px;
  padding: 2rem;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  border: 1px solid #e9ecef;
}

.calc-form h2 {
  font-size: 1.75rem;
  margin-bottom: 1rem;
  color: #212529;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.calc-form h2 i {
  color: #0056b3;
}

.calc-form p {
  color: #6c757d;
  margin-bottom: 1.5rem;
}

.form-group {
  margin-bottom: 1.25rem;
}

.form-group label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 500;
  color: #343a40;
}

.input-group {
  display: flex;
  align-items: center;
  border: 1px solid #ced4da;
  border-radius: 8px;
  overflow: hidden;
}

.input-group .input-icon {
  padding: 0.75rem 1rem;
  background-color: #f8f9fa;
  color: #6c757d;
  border-right: 1px solid #ced4da;
}

.form-control {
  flex: 1;
  padding: 0.75rem 1rem;
  border: none;
  font-size: 1rem;
  color: #495057;
  background-color: white;
}

.form-control:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(0, 86, 179, 0.1);
}

.form-section {
  margin: 1.5rem 0;
  padding: 1rem;
  background-color: #f8f9fa;
  border-radius: 8px;
}

.form-section h4 {
  margin-bottom: 1rem;
  color: #212529;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.form-section h4 i {
  color: #0056b3;
}

.btn-block {
  width: 100%;
  display: block;
}

/* Calculator Results */
.calc-results {
  position: sticky;
  top: 1rem;
  height: fit-content;
}

.results-card {
  background: white;
  border-radius: 12px;
  padding: 2rem;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  border: 1px solid #e9ecef;
}

.results-card h3 {
  font-size: 1.5rem;
  margin-bottom: 1.5rem;
  color: #212529;
  text-align: center;
}

.result-item {
  display: flex;
  justify-content: space-between;
  padding: 0.75rem 0;
  border-bottom: 1px solid #e9ecef;
}

.result-item:last-child {
  border-bottom: none;
}

.result-label {
  font-weight: 500;
  color: #495057;
}

.result-value {
  font-weight: 600;
  color: #212529;
}

.result-item.highlight .result-value {
  color: #0056b3;
  font-weight: 700;
}

.amortization-toggle {
  margin: 1.5rem 0;
  text-align: center;
}

.chart-container {
  margin-top: 2rem;
  height: 250px;
  position: relative;
}

/* Amortization Schedule */
.amortization-schedule {
  margin-top: 3rem;
  background: white;
  border-radius: 12px;
  padding: 2rem;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  border: 1px solid #e9ecef;
  display: none;
}

.amortization-schedule h3 {
  font-size: 1.5rem;
  margin-bottom: 1.5rem;
  color: #212529;
  text-align: center;
}

.table-responsive {
  overflow-x: auto;
}

.amortization-table {
  width: 100%;
  border-collapse: collapse;
}

.amortization-table th,
.amortization-table td {
  padding: 0.75rem;
  text-align: left;
  border-bottom: 1px solid #e9ecef;
}

.amortization-table th {
  background-color: #f8f9fa;
  font-weight: 600;
  color: #495057;
}

.amortization-table tr:hover {
  background-color: #f8f9fa;
}

/* Insights Section */
.cashflow-insights,
.roi-insights,
.break-even-insights,
.profit-insights {
  margin-top: 3rem;
  background: white;
  border-radius: 12px;
  padding: 2rem;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  border: 1px solid #e9ecef;
}

.cashflow-insights h3,
.roi-insights h3,
.break-even-insights h3,
.profit-insights h3 {
  font-size: 1.5rem;
  margin-bottom: 1.5rem;
  color: #212529;
  text-align: center;
}

.insight-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
}

.insight-card {
  background: #f8f9fa;
  border-radius: 8px;
  padding: 1.5rem;
  border-left: 4px solid #0056b3;
}

.insight-card i {
  font-size: 1.5rem;
  color: #0056b3;
  margin-bottom: 1rem;
}

.insight-card h4 {
  font-size: 1.1rem;
  margin-bottom: 0.75rem;
  color: #212529;
}

/* CTA Section */
.calc-cta {
  padding: 5rem 0;
  background: linear-gradient(135deg, #0056b3 0%, #003d82 100%);
  color: white;
  text-align: center;
}

.calc-cta h2 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

.calc-cta p {
  font-size: 1.25rem;
  max-width: 700px;
  margin: 0 auto 2rem;
  opacity: 0.9;
}

.cta-buttons {
  display: flex;
  gap: 1rem;
  justify-content: center;
}

/* Responsive Styles */
@media (max-width: 1024px) {
  .calc-hero .container {
    flex-direction: column;
    text-align: center;
  }

  .calc-hero .hero-content {
    margin-bottom: 3rem;
  }

  .calc-hero .hero-image {
    margin-top: 2rem;
  }

  .calc-grid {
    grid-template-columns: 1fr;
  }

  .calc-results {
    position: static;
  }
}

@media (max-width: 768px) {
  .calc-hero h1 {
    font-size: 2.5rem;
  }

  .calc-tab-btn {
    padding: 0.75rem 1rem;
    font-size: 0.85rem;
  }

  .cta-buttons {
    flex-direction: column;
    align-items: center;
  }
}

@media (max-width: 576px) {
  .calc-hero h1 {
    font-size: 2rem;
  }

  .calc-hero .hero-subtitle {
    font-size: 1.1rem;
  }

  .calc-form h2 {
    font-size: 1.5rem;
  }

  .results-card h3,
  .amortization-schedule h3,
  .cashflow-insights h3,
  .roi-insights h3,
  .break-even-insights h3,
  .profit-insights h3 {
    font-size: 1.3rem;
  }

  .calc-cta h2 {
    font-size: 2rem;
  }

  .calc-cta p {
    font-size: 1.1rem;
  }
}
