* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen',
    'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue',
    sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.navbar {
  background: linear-gradient(135deg, #4f46e5 0%, #4338ca 100%);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  position:sticky;
  top: 0;
  z-index: 1000;
}

.nav-container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 1rem 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nav-brand {
  font-size: 1.5rem;
  font-weight: bold;
  color: white;
  text-decoration: none;
  transition: opacity 0.3s;
}

.nav-brand:hover {
  opacity: 0.9;
}

.nav-links {
  display: flex;
  gap: 2rem;
}

.nav-link {
  color: rgba(255, 255, 255, 0.9);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.3s;
}

.nav-link:hover,
.nav-link.active {
  color: white;
}

.min-h-screen {
  min-height: 100vh;
  background: linear-gradient(to bottom right, #f8fafc, #e2e8f0);
  padding-bottom: 2rem;
}

.container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 2rem 1rem;
}

.header {
  text-align: center;
  margin-bottom: 2rem;
}

.main-title {
  font-size: 2.25rem;
  font-weight: bold;
  color: #1f2937;
  margin-bottom: 0.5rem;
}

.subtitle {
  color: #4b5563;
}

.tabs-container {
  display: flex;
  justify-content: center;
  gap: 1rem;
  margin-bottom: 2rem;
}

.tab-button {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  border-radius: 0.5rem;
  font-weight: 600;
  border: none;
  cursor: pointer;
  transition: all 0.3s;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  background: white;
  color: #374151;
}

.tab-button:hover {
  background: #f3f4f6;
  transform: translateY(-2px);
  box-shadow: 0 6px 12px -2px rgba(0, 0, 0, 0.15);
}

.tab-button.active {
  background: #2563eb;
  color: white;
  transform: scale(1.05);
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

.icon {
  width: 1.25rem;
  height: 1.25rem;
}

.icon-large {
  width: 2rem;
  height: 2rem;
  color: #2563eb;
}

.icon-small {
  width: 1rem;
  height: 1rem;
}

.main-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}

@media (min-width: 1024px) {
  .main-grid {
    grid-template-columns: 1fr 2fr;
  }
}

.loan-form {
  background: white;
  border-radius: 0.75rem;
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
  padding: 2rem;
}

.form-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
}

.form-title {
  font-size: 1.5rem;
  font-weight: bold;
  color: #1f2937;
}

.form-fields {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.field-group {
  display: flex;
  flex-direction: column;
}

.field-label {
  display: block;
  font-size: 0.875rem;
  font-weight: 600;
  color: #374151;
  margin-bottom: 0.5rem;
}

.field-input {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 2px solid #e5e7eb;
  border-radius: 0.5rem;
  font-size: 1rem;
  transition: all 0.3s;
}

.field-input:focus {
  outline: none;
  border-color: transparent;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.5);
}

.submit-button {
  width: 100%;
  background: #2563eb;
  color: white;
  font-weight: 600;
  padding: 0.75rem 1.5rem;
  border-radius: 0.5rem;
  border: none;
  cursor: pointer;
  transition: all 0.3s;
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

.submit-button:hover {
  background: #1d4ed8;
  transform: translateY(-2px);
  box-shadow: 0 12px 20px -5px rgba(37, 99, 235, 0.4);
}

.adds {
  background: rgb(255, 255, 255);
  border-radius: 0.75rem;
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
  padding: 2rem;
  margin-top: 2px;
  visibility:hidden;
}

.results-section {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.placeholder {
  background: white;
  border-radius: 0.75rem;
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
  padding: 3rem;
  text-align: center;
}

.placeholder-icon {
  width: 4rem;
  height: 4rem;
  color: #d1d5db;
  margin: 0 auto 1rem;
}

.placeholder-text {
  color: #4b5563;
  font-size: 1.125rem;
}

.results-container {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.summary-cards {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

@media (min-width: 768px) {
  .summary-cards {
    grid-template-columns: repeat(3, 1fr);
  }
}

.summary-card {
  border-radius: 0.75rem;
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
  padding: 1.5rem;
  color: white;
  transition: all 0.3s;
}

.summary-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.2);
}

.summary-card.blue {
  background: linear-gradient(to bottom right, #3b82f6, #2563eb);
}

.summary-card.green {
  background: linear-gradient(to bottom right, #10b981, #059669);
}

.summary-card.orange {
  background: linear-gradient(to bottom right, #f97316, #ea580c);
}

.summary-icon {
  width: 2rem;
  height: 2rem;
  opacity: 0.8;
  margin-bottom: 0.5rem;
}

.card-label {
  font-size: 0.875rem;
  font-weight: 500;
  opacity: 0.9;
}

.card-value {
  font-size: 1.875rem;
  font-weight: bold;
  margin-top: 0.5rem;
}

.pie-chart-container {
  background: white;
  border-radius: 0.75rem;
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
  padding: 2rem;
}

.section-title {
  font-size: 1.25rem;
  font-weight: bold;
  color: #1f2937;
  margin-bottom: 1.5rem;
}

.pie-chart-content {
  display: flex;
  flex-direction: column;
  align-items: center;
}

#pieChart {
  max-width: 300px;
  height: auto;
}

.legend {
  margin-top: 1.5rem;
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.legend-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.legend-color-principal,
.legend-color-interest {
  width: 1rem;
  height: 1rem;
  border-radius: 0.25rem;
  margin-right: 0.5rem;
}

.legend-color-principal {
  background: #3b82f6;
}

.legend-color-interest {
  background: #ef4444;
}

.legend-label {
  color: #374151;
  font-weight: 500;
  flex: 1;
}

.legend-values {
  text-align: right;
}

.legend-amount {
  font-weight: bold;
  color: #1f2937;
}

.legend-percent {
  font-size: 0.875rem;
  color: #6b7280;
}

.schedule-container {
  background: white;
  border-radius: 0.75rem;
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
  padding: 2rem;
}

.schedule-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
  gap: 1rem;
}

.export-buttons {
  display: flex;
  gap: 0.75rem;
}

.export-button {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: white;
  font-weight: 600;
  padding: 0.5rem 1rem;
  border-radius: 0.5rem;
  border: none;
  cursor: pointer;
  transition: all 0.3s;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.export-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.2);
}

.export-button.pdf {
  background: #dc2626;
}

.export-button.pdf:hover {
  background: #b91c1c;
}

.export-button.excel {
  background: #16a34a;
}

.export-button.excel:hover {
  background: #15803d;
}

.table-wrapper {
  overflow-x: auto;
  max-height: 24rem;
  overflow-y: auto;
}

.schedule-table {
  width: 100%;
  border-collapse: collapse;
}

.schedule-table thead {
  background: #f9fafb;
  position: sticky;
  top: 0;
  z-index: 10;
}

.schedule-table th {
  padding: 0.75rem 1rem;
  text-align: left;
  font-size: 0.75rem;
  font-weight: 600;
  color: #374151;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.schedule-table th.text-right {
  text-align: right;
}

.schedule-table tbody tr {
  border-bottom: 1px solid #e5e7eb;
}

.schedule-table tbody tr:nth-child(even) {
  background: #f9fafb;
}

.schedule-table td {
  padding: 0.75rem 1rem;
  font-size: 0.875rem;
  color: #374151;
}

.schedule-table td.text-right {
  text-align: right;
}

.schedule-table td.principal {
  color: #2563eb;
  font-weight: 500;
}

.schedule-table td.interest {
  color: #dc2626;
  font-weight: 500;
}

.schedule-table td.balance {
  font-weight: 600;
}

.tenure-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
}

.currency-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
}

.toggle-container {
  display: flex;
  gap: 0.25rem;
  background: #f3f4f6;
  border-radius: 0.375rem;
  padding: 0.25rem;
}

.toggle-button {
  padding: 0.25rem 0.75rem;
  border: none;
  background: transparent;
  color: #6b7280;
  font-size: 0.75rem;
  font-weight: 500;
  cursor: pointer;
  border-radius: 0.25rem;
  transition: all 0.3s;
  text-transform: capitalize;
}

.toggle-button.active {
  background: white;
  color: #2563eb;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.footer {
  background: #1f2937;
  color: white;
  padding: 3rem 1rem 1rem;
}

.footer-container {
  max-width: 1280px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
  margin-bottom: 2rem;
}

@media (min-width: 768px) {
  .footer-container {
    grid-template-columns: repeat(3, 1fr);
  }
}

.footer-title {
  font-size: 1.125rem;
  font-weight: 600;
  margin-bottom: 1rem;
}

.footer-text {
  color: #d1d5db;
  line-height: 1.6;
}

.footer-links {
  list-style: none;
}

.footer-links li {
  margin-bottom: 0.5rem;
}

.footer-links a {
  color: #d1d5db;
  text-decoration: none;
  transition: color 0.3s;
}

.footer-links a:hover {
  color: white;
}

.footer-bottom {
  max-width: 1280px;
  margin: 0 auto;
  padding-top: 2rem;
  border-top: 1px solid #374151;
  text-align: center;
  color: #9ca3af;
}

.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  z-index: 2000;
  align-items: center;
  justify-content: center;
}

.modal.active {
  display: flex;
}

.modal-content {
  background: white;
  border-radius: 0.75rem;
  padding: 2rem;
  max-width: 500px;
  width: 90%;
  max-height: 90vh;
  overflow-y: auto;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
}

.modal-title {
  font-size: 1.5rem;
  font-weight: bold;
  color: #1f2937;
}

.modal-close {
  background: none;
  border: none;
  font-size: 2rem;
  color: #6b7280;
  cursor: pointer;
  line-height: 1;
  transition: color 0.3s;
}

.modal-close:hover {
  color: #1f2937;
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.contact-form textarea {
  resize: vertical;
}

.blog-container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 3rem 1rem;
  min-height: calc(100vh - 200px);
}

.blog-header {
  text-align: center;
  margin-bottom: 3rem;
}

.blog-main-title {
  font-size: 2.5rem;
  font-weight: bold;
  color: #1f2937;
  margin-bottom: 0.5rem;
}

.blog-subtitle {
  color: #6b7280;
  font-size: 1.125rem;
}

.blog-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}

@media (min-width: 768px) {
  .blog-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .blog-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.blog-card {
  background: white;
  border-radius: 0.75rem;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  transition: all 0.3s;
  overflow: hidden;
}

.blog-card:hover {
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
  transform: translateY(-4px);
}

.blog-card-content {
  padding: 1.5rem;
}

.blog-category {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  background: #dbeafe;
  color: #1e40af;
  font-size: 0.75rem;
  font-weight: 600;
  border-radius: 9999px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 1rem;
}

.blog-card-title {
  font-size: 1.25rem;
  font-weight: bold;
  color: #1f2937;
  margin-bottom: 0.75rem;
  line-height: 1.4;
}

.blog-card-excerpt {
  color: #6b7280;
  line-height: 1.6;
  margin-bottom: 1rem;
}

.blog-card-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 1rem;
  border-top: 1px solid #e5e7eb;
}

.blog-date {
  color: #9ca3af;
  font-size: 0.875rem;
}

.blog-read-more {
  color: #2563eb;
  font-weight: 600;
  text-decoration: none;
  transition: color 0.3s;
}

.blog-read-more:hover {
  color: #1d4ed8;
}

.about-container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 3rem 1rem;
  min-height: calc(100vh - 200px);
}

.about-hero {
  text-align: center;
  padding: 3rem 1rem;
  background: linear-gradient(135deg, #4f46e5 0%, #4338ca 100%);
  border-radius: 1rem;
  margin-bottom: 3rem;
  color: white;
}

.about-hero-title {
  font-size: 2.5rem;
  font-weight: bold;
  margin-bottom: 1rem;
}

.about-hero-subtitle {
  font-size: 1.25rem;
  opacity: 0.95;
}

.about-content {
  display: flex;
  flex-direction: column;
  gap: 3rem;
}

.about-section {
  background: white;
  border-radius: 0.75rem;
  padding: 2rem;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.about-section-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.about-icon {
  width: 2.5rem;
  height: 2.5rem;
  color: #4f46e5;
  flex-shrink: 0;
}

.about-section-title {
  font-size: 1.75rem;
  font-weight: bold;
  color: #1f2937;
}

.about-text {
  color: #4b5563;
  line-height: 1.7;
  margin-bottom: 1rem;
  font-size: 1.0625rem;
}

.about-text:last-child {
  margin-bottom: 0;
}

.features-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
  margin-top: 1.5rem;
}

@media (min-width: 768px) {
  .features-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.feature-card {
  background: #f9fafb;
  padding: 1.5rem;
  border-radius: 0.5rem;
  border-left: 4px solid #4f46e5;
  transition: all 0.3s;
}

.feature-card:hover {
  transform: translateX(8px);
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.feature-title {
  font-size: 1.125rem;
  font-weight: 600;
  color: #1f2937;
  margin-bottom: 0.75rem;
}

.feature-text {
  color: #6b7280;
  line-height: 1.6;
}

.cta-button {
  background: linear-gradient(135deg, #4f46e5 0%, #4338ca 100%);
  color: white;
  font-weight: 600;
  padding: 0.875rem 2rem;
  border-radius: 0.5rem;
  border: none;
  cursor: pointer;
  transition: all 0.3s;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  margin-top: 1rem;
}

.cta-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.2);
}
