body {
  font-family: 'Poppins', sans-serif;
  background: linear-gradient(to bottom right, #f0f8ff, #ffe6f2);
  color: #333;
  margin: 0;
}

.sub-row {
  margin-left: 2em;
  font-size: 0.9em;
  color: #555;
  text-align: left; /* 👈 ensures they align left like the parent labels */
  display: block;
}


#costSummary .sub-row {
  margin-left: 2em;
  font-size: 0.9em;
  color: #555;
}

.group-sum {
  font-weight: normal;
  font-size: 0.9em;
  color: #555;
  margin-left: 8px;
}

.gear-group-title {
  font-size: 1.3em;
  margin-top: 1.5em;
  margin-bottom: 0.5em;
  color: #4e77c7;
  border-bottom: 2px solid #e0e0e0;
  padding-bottom: 4px;
}
.subdivider {
  border: none;
  border-bottom: 1px dashed #ccc;
  margin: 1em 0;
}

.input-field {
  width: 100%;
  padding: 0.5rem;
  border: 1px solid #ccc;
  border-radius: 8px;
}
.help-text {
  font-size: 0.85em;
  color: #666;
  margin-top: 0.25rem;
}

.recs ul {
  margin-top: 4px;
  margin-bottom: 10px;
  padding-left: 20px;
  list-style-type: disc;
}

.recs ul li {
  margin-bottom: 4px;
  font-weight: normal;
}

.recs > ul > li {
  margin-bottom: 10px;
}

.cost-summary {
  margin-top: 12px;
  padding-top: 8px;
  border-top: 1px solid #ddd;
  font-family: Poppins, sans-serif;
  font-size: 15px;
  line-height: 1.6;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.cost-summary .row {
  display: flex;
  align-items: center;
}

.cost-summary .color-box {
  width: 18px;
  height: 18px;
  border-radius: 3px;
  margin-right: 8px;
  flex-shrink: 0;
}

.action-buttons {
  display: flex;
  gap: 10px;
  justify-content: center;
  margin-top: 20px;
}

.action-buttons button {
  background: #ffb6c1;
  color: #333;
  border: none;
  padding: 10px 16px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 15px;
  transition: background 0.2s ease-in-out;
}

.action-buttons button:hover {
  background: #ffa6b2;
}

.action-buttons button#pdfResults {
  background: #add8e6;
}

.action-buttons button#pdfResults:hover {
  background: #9acbe0;
}

canvas#budgetChart {
  display: block;
  width: 100%;
  max-width: 480px;
  height: 380px;       /* add this line */
  margin: 18px auto;
}

.wrapper {
  max-width: 760px;
  margin: 40px auto;
  background: #fff;
  padding: 28px;
  border-radius: 20px;
  box-shadow: 0 6px 28px rgba(0,0,0,0.08);
}
h1 { color: #4e77c7; text-align: center; margin-top: 0; }
.intro { text-align: center; color: #666; margin-bottom: 18px; }
label { display: block; font-weight: 600; margin: 14px 0 6px; }
select {
  width: 100%; padding: 10px; border: 1px solid #e2e2e2; border-radius: 10px; background: #fafafa;
}
button {
  margin-top: 22px; width: 100%; padding: 12px 16px;
  background: #4e77c7; color: #fff; border: none; border-radius: 10px;
  font-size: 16px; cursor: pointer; transition: background .15s ease-in-out;
}
button:hover { background: #3a5fab; }
.hidden { display: none; }
.section-title { margin: 18px 0 6px; color: #4e77c7; }
.hint { color: #777; margin-top: 0; }
.item-row { margin-bottom: 10px; }
.divider { margin: 22px 0; border: 0; border-top: 1px dashed #ddd; }

#results { margin-top: 26px; text-align: center; }
#monthly, #yearly { font-weight: 700; color: #333; }
canvas { display: block; margin: 18px auto; max-width: 480px; }

.legend { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; font-size: 14px; margin-bottom: 10px; }
.legend-box { width: 14px; height: 14px; display: inline-block; border-radius: 3px; margin-right: 6px; }
.c1 { background: #b3d9ff; } /* childcare */
.c2 { background: #ffd6e8; } /* feeding */
.c3 { background: #c8f7c5; } /* diapers */
.c4 { background: #ffe6b3; } /* gear */
.c5 { background: #e0c8ff; } /* misc */

.recommendations { text-align: left; margin: 18px auto 0; max-width: 680px; }
.recommendations a { color: #4e77c7; text-decoration: none; }
.recommendations a:hover { text-decoration: underline; }
