/* --- Calculator Container --- */
.calculator {
  max-width: 650px;
  margin: 40px auto;
  padding: 30px;
  background: #ffffff;
  border-radius: 12px;
  box-shadow: 0 4px 18px rgba(0,0,0,0.08);
  font-family: 'Inter', 'Segoe UI', sans-serif;
}

/* --- Headings --- */
.calculator h2 {
  margin-top: 0;
  margin-left: 20px;
  font-size: 1.8rem;
  color: #003366;
  font-weight: 600;
  border-bottom: 2px solid #e6e6e6;
  padding-bottom: 10px;
}

/* --- Labels & Inputs --- */
.calculator label {
  display: block;
  margin: 18px 0 6px;
  font-weight: 500;
  color: #333;
}

.calculator input[type="number"] {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid #ccc;
  border-radius: 6px;
  font-size: 1rem;
  transition: border-color 0.2s ease;
}

.calculator input[type="number"]:focus {
  border-color: #c89b3c; /* your gold accent */
  outline: none;
}

/* --- Buttons --- */
.calculator button {
  margin-top: 0px;
  padding: 12px 20px;
  background: #c89b3c; /* gold */
  color: #fff;
  border: none;
  border-radius: 6px;
  font-size: 1rem;
  cursor: pointer;
  transition: background 0.2s ease;
}

.calculator button:hover {
  background: #a67f2f;
}

/* --- Results --- */
.calc-results {
  margin-top: 25px;
  padding: 20px;
  background: #f7f7f7;
  border-radius: 8px;
  border: 1px solid #e0e0e0;
}

.calc-results p {
  margin: 10px 0;
  font-size: 1.1rem;
  color: #222;
}

.calc-results strong {
  font-weight: 600;
  color: #000;
}

/* --- Disclaimer --- */
.calc-disclaimer {
  margin-top: 20px;
  font-size: 0.85rem;
  color: #666;
  line-height: 1.4;
}

/* --- Responsive --- */
@media (max-width: 600px) {
  .calculator {
    padding: 20px;
  }
  .calculator h2 {
    font-size: 1.5rem;
  }
}
.calc-list {
  list-style: none;
  padding: 0;
}

.calc-list li {
  margin: 12px 0;
}

.calc-list a {
  font-size: 1.2rem;
  color: #003366;
  text-decoration: none;
}

.calc-list a:hover {
  text-decoration: underline;
}
.return-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  margin-left: 20px;
  background: #f7f7f7;
  border: 1px solid #ddd;
  border-radius: 6px;
  color: #333;
  text-decoration: none;
  font-size: 0.95rem;
  transition: background 0.2s ease, border-color 0.2s ease;
}

.return-link:hover {
  background: #eee;
  border-color: #c89b3c;
}
.return-link .arrow {
  font-size: 1.1rem;
  margin-right: 4px;
}



.stepper {
  display: flex;
  flex-direction: column;
}
.calculator .num-wrap {
  display: inline-flex !important;
  align-items: center !important;
  gap: 4px !important;
}

.calculator .num-wrap input[inputmode="numeric"] {
    width: 100% !important;
    min-width: 0 !important;
    padding: 6px 8px !important;
    font-size: .85rem !important;          /* matches label size */
    font-family: 'Inter', sans-serif !important;  /* matches labels */
    box-sizing: border-box !important;
}


.calculator .num-wrap .stepper button {
  width: 20px !important;
  height: 16px !important;
  padding: 0 !important;
  margin: 0 !important;
  font-size: 12px !important;
  line-height: 12px !important;
  font-family: Arial, sans-serif !important;
  border: 1px solid #ccc !important;
  background: #c89b3c;
  cursor: pointer !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
}
.stepper button:hover {
  background: #a67f2f;
}
 body {
  /*background: linear-gradient(135deg, #003366 0%, #c89b3c 100%) !important;*/
  margin: 0;
  paddiong 0;
  background-attachment: fixed;
  color: #fff;
}
.chart-hidden {
  display: none;
}
.chart-container {
  background: #fff;
  padding: 20px;
  border-radius: 12px;
  box-shadow: 0 4px 18px rgba(0,0,0,0.15);
  margin-top: 30px;
}
#amort-container table,
#amort-container th,
#amort-container td {
  color: #003366; /* dark navy text */
  background-color: #ffffff; /* white background */
}

#amort-container th {
  font-weight: bold;
  border-bottom: 2px solid #c89b3c; /* gold accent */
}

#amort-container td {
  border-bottom: 1px solid #eee;
  padding: 6px 8px;
}

.amort-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
  color: #003366;
}

.amort-header h3 {
  margin-left: 20px;
}

#download-csv {
  background: #c89b3c;
  color: white;
  border: none;
  padding: 8px 14px;
  border-radius: 6px;
  cursor: pointer;
  font-weight: bold;
}

#download-csv:hover {
  background: #b38733;
}

.tooltip {
  display: inline-block;
  background: #c89b3c;
  color: white;
  border-radius: 50%;
  width: 18px;
  height: 18px;
  text-align: center;
  line-height: 18px;
  font-size: 12px;
  cursor: pointer;
  margin-left: 6px;
  position: relative;
}

.tooltip:hover::after {
  content: attr(data-tip);
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  top: 24px;
  background: #003366;
  color: white;
  padding: 8px 10px;
  border-radius: 6px;
  white-space: normal;
  width: 220px;
  font-size: 12px;
  z-index: 10;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.advanced-toggle {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #f7f7f7;
  padding: 10px 12px;
  border-radius: 6px;
  cursor: pointer;
  margin-top: 12px;
  font-weight: bold;
  color: #003366;
}

.advanced-toggle:hover {
  background: #ececec;
}

#adv-arrow {
  transition: transform 0.25s ease;
}

.card-advanced-section {
  max-height: 0;
  visibility: hidden;
  transition: max-height 0.35s ease;
  padding-left: 4px;
}
#calc-life label {
  margin-bottom: 8px; /* was probably 16–20px */
}

#calc-life h3 {
  margin-top: 20px;
  margin-bottom: 8px;
  color: #003366
}
/* Cards */

.section-beige .card {
  background-color: var(--color-white);
}

.card h3 {
  font-family: var(--font-heading);
  margin-top: 0.75rem;
}
.calculator h2,
.calculator h3 {
  margin-left: 20px;
  color: #003366;
}

.mode-select {
  display: flex;
  gap: 20px;
  margin-bottom: 10px;
}


/* Grid layout for calculator cards */
.calc-menu .cards-6 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
  margin-top: 20px;
  margin-left: 20px;
  margin-right: 20px;
}

/* Card container */
.calc-menu .card {
  display: block;
  background: #ffffff;
  border-radius: 10px;
  padding: 24px;
  text-decoration: none;
  color: #003366;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  border: 1px solid #e5e5e5;
}

/* Hover effect */
.calc-menu .card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 20px rgba(0,0,0,0.12);
}

/* Card title */
.calc-menu .card h3 {
  margin-top: 0;
  margin-bottom: 10px;
  font-size: 1.2rem;
  color: #003366;
}

/* Card description */
.calc-menu .card p {
  margin: 0;
  color: #444;
  font-size: 0.95rem;
  line-height: 1.4;
}

/* Remove bullets if any <li> remain */
.calc-menu li {
  list-style: none;
}
.mt-10 { margin-top: 10px; }
.mt-20 { margin-top: 20px; }
.mt-30 { margin-top: 30px; }
.mt-40 { margin-top: 40px; }

.mb-10 { margin-bottom: 10px; }
.mb-20 { margin-bottom: 20px; }

.flex-row { display:flex; gap:10px; align-items:center; flex-wrap:wrap; }
.grid-2 {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 20px;
  align-items: start;
}

#rc-chart-container h2,
#rc-chart-container,
#rc-chart-container canvas {
    color: #003366 !important;
    display: none;
}
.gradient-wrapper {
  background: linear-gradient(135deg, #003366 0%, #c89b3c 100%);
  min-height: 100vh;
  padding: 40px 0;
}
.help-icon-wrapper {
    position: relative;
    display: inline-block;
    margin-left: 10px;
}

.help-icon {
    background: #c89b3c;
    color: #0b1b33;
    font-size: 14px;
    padding: 4px 7px;
    border-radius: 50%;
    cursor: pointer;
    font-weight: bold;
    box-shadow: 0 2px 6px rgba(0,0,0,0.3);
}

.help-tooltip {
    position: absolute;
    top: 28px;
    left: 0;
    width: 260px;
    background: rgba(15, 23, 42, 0.95);
    color: #e0e7ff;
    padding: 12px 14px;
    border-radius: 10px;
    border: 1px solid rgba(148,163,184,0.4);
    font-size: 13px;
    line-height: 1.45;
    box-shadow: 0 8px 20px rgba(0,0,0,0.4);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.15s ease;
    z-index: 9999;
}

/* Hover for desktop */
.help-icon-wrapper:hover .help-tooltip {
    opacity: 1;
    visibility: visible;
}

/* Tap-to-open for mobile */
.help-icon-wrapper .help-icon:active + .help-tooltip {
    opacity: 1;
    visibility: visible;
}
.cta-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    margin-left: 10px;
    background: #c89b3c;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    color: #0b1b33;
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 600;
    transition: background 0.2s ease, border-color 0.2s ease;
}

.cta-link:hover {
    background: #d4a64a;
    border-color: #f0f0f0;
}
