/* ===== MODERNIZED CSS - Dark Theme Elegante ===== */

* {
  box-sizing: border-box;
}

body {
  background: linear-gradient(135deg, #0f0f1e 0%, #1a1a2e 100%);
  font-family: 'Poppins', sans-serif;
  color: #ecf0f1;
}

.header {
  text-align: center;
  font-size: 2.2em;
  font-weight: bold;
  color: #f76b45;
  text-shadow: 0 0 15px rgba(247, 107, 69, 0.2);
  margin-bottom: 15px;
  letter-spacing: 1px;
}

.header p {
  color: #999;
  font-size: 0.9em;
  margin-top: 10px;
}

.page-container {
  background: linear-gradient(135deg, #1e1e2e 0%, #2a2a3e 100%);
  border: 2px solid #f76b45;
  border-radius: 15px;
  padding: 40px;
  max-width: 800px;
  margin: 20px auto;
  box-shadow: 0 10px 40px rgba(247, 107, 69, 0.2);
  transition: all 0.3s ease;
}

.page-container:hover {
  box-shadow: 0 15px 50px rgba(247, 107, 69, 0.3);
  border-color: #ff8c42;
}

/* ===== Input Container ===== */
.input-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
  margin-bottom: 30px;
}

.input-container > div {
  display: flex;
  flex-direction: column;
}

.input-label {
  color: #f76b45;
  font-weight: bold;
  margin-bottom: 8px;
  font-size: 0.95em;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

input[type="number"],
input[type="text"],
select {
  background: #0f0f1e;
  border: 2px solid #f76b45;
  color: #ecf0f1;
  padding: 12px 15px;
  border-radius: 8px;
  font-size: 1em;
  font-family: 'Poppins', sans-serif;
  transition: all 0.3s ease;
  width: 100%;
}

input[type="number"]:focus,
input[type="text"]:focus,
select:focus {
  outline: none;
  background: #1a1a2e;
  border-color: #ff8c42;
  box-shadow: 0 0 15px rgba(247, 107, 69, 0.4);
  transform: translateY(-2px);
}

input[type="number"]::placeholder {
  color: #666;
}

select option {
  background: #1e1e2e;
  color: #ecf0f1;
  padding: 10px;
}

/* ===== Button Container ===== */
.btn-calculate {
  text-align: center;
  margin-top: 30px;
}

.btn-success {
  background: linear-gradient(135deg, #f76b45 0%, #ff8c42 100%);
  border: none;
  color: white;
  padding: 14px 50px;
  font-size: 1.1em;
  font-weight: bold;
  border-radius: 50px;
  cursor: pointer;
  transition: all 0.3s ease;
  text-transform: uppercase;
  letter-spacing: 1px;
  box-shadow: 0 5px 20px rgba(247, 107, 69, 0.3);
  display: inline-block;
  position: relative;
  overflow: hidden;
}

.btn-success::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
  transition: left 0.5s ease;
}

.btn-success:hover::before {
  left: 100%;
}

.btn-success:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 30px rgba(247, 107, 69, 0.5);
}

.btn-success:active {
  transform: translateY(-1px);
}

.btn-success:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

/* ===== Response Container ===== */
#response {
  margin-top: 30px;
}

/* ===== Loading Spinner ===== */
.spinner {
  border: 3px solid rgba(247, 107, 69, 0.2);
  border-top: 3px solid #f76b45;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  animation: spin 1s linear infinite;
  margin: 0 auto;
}

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

/* ===== Animations ===== */
@keyframes slideIn {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.7; }
}

.slide-in {
  animation: slideIn 0.5s ease forwards;
}

/* ===== Responsive Design ===== */
@media (max-width: 768px) {
  .page-container {
    padding: 25px;
    margin: 15px;
  }

  .header {
    font-size: 1.8em;
  }

  .input-container {
    grid-template-columns: 1fr;
    gap: 15px;
  }

  .btn-success {
    padding: 12px 40px;
    font-size: 1em;
  }
}

@media (max-width: 480px) {
  .page-container {
    padding: 20px;
    margin: 10px;
    border-radius: 10px;
  }

  .header {
    font-size: 1.5em;
  }

  .header p {
    font-size: 0.85em;
  }

  input[type="number"],
  input[type="text"],
  select {
    padding: 10px 12px;
    font-size: 0.95em;
  }

  .btn-success {
    padding: 10px 30px;
    font-size: 0.95em;
    width: 100%;
  }
}

/* ===== Utility Classes ===== */
.text-center {
  text-align: center;
}

.mt-3 {
  margin-top: 30px;
}

.mb-3 {
  margin-bottom: 30px;
}
/* .btn-calculate > button {
  height: 35px;
  width: 125px;
  border-radius: 10px;
  border: 2px solid #25aa78;
  background-color: #25aa78;
  border-color: #25aa78;
  font-size: 15px;
} */ 

.currency {
  background: white;
  border-radius: 5px;
  padding: 5px;
  border-color: dimgray;
}
option{
  background: white;
  border-radius: 5px ;
  padding: 5px;
  border-color: dimgray;
}
#total {
  border: 1px solid;
}
#wealth-gained {
  border: 1px solid;
}
#maturity-value {
  border: 1px solid;
}

/* #return-rate {
  height: 30px;
  border-radius: 9px;
  border-color: #333;
} */

.npv-calculate > button {
  height: 35px;
  align-items: center;
  border-radius: 10px;
  border: 2px solid #19a4cf;
  background-color: #19a4cf;
  border-color: #19a4cf;
  font-size: 15px;
  width: 125px;
  cursor: pointer;
}
.cash-flows-container {
  margin: 1% 5% 0 0;
  align-items: center;
  text-align: center;
}
#cashFlows {
  text-align: left; 
}
.cash-flow-item {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 10px;
}
.cash-flow-item input {
  text-align: left;
  align-items: center;
  width: calc(35% - 60px); 
}
.nresult {
  padding: 2% 0 0 0;
  font-size: 24px;
}
.nresult-container {
  padding-left: 60px;
  flex-direction: column;
  align-items: center;
}