.calculator-main { padding-block: 30px 54px; }
.calculator-heading { margin: 30px 0; }
.calculator-heading h1 { font-size: 36px; letter-spacing: -1.5px; margin: 12px 0; }
.calculator-heading > p:last-of-type { font-size: 15px; color: var(--muted); line-height: 1.8; }
.calc-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.calc-tags span { padding: 6px 10px; background: #edf3ef; color: #4e7666; border-radius: 5px; font-size: 11px; }
.calculator-layout { display: grid; grid-template-columns: 360px minmax(0,1fr); gap: 24px; align-items: start; }
.calc-panel, .calc-results { background: white; border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; min-width: 0; }
.calc-panel h2, .calc-results h2 { font-size: 21px; margin-bottom: 12px; }
.calc-caption, .local-note { font-size: 12px; color: var(--muted); line-height: 1.8; }
.calc-field { margin-top: 23px; }
.calc-field label { display: block; font-size: 14px; font-weight: 700; margin-bottom: 9px; }
.number-input { display: flex; align-items: center; border: 1px solid #cddad6; border-radius: 8px; padding-right: 14px; }
.number-input:focus-within { border-color: var(--accent); box-shadow: 0 0 0 2px #227b661a; }
.number-input input { width: 100%; min-width: 0; border: 0; background: transparent; padding: 13px; font-size: 17px; color: var(--ink); border-radius: 8px; }
.number-input input[aria-invalid="true"] { outline: 2px solid #b84b43; outline-offset: -2px; }
.number-input > span { color: var(--muted); font-size: 13px; }
.field-hint { font-size: 11px; color: var(--muted); line-height: 1.7; margin-top: 7px; }
.field-error { font-size: 12px; color: #aa382f; margin-top: 7px; line-height: 1.7; }
.calculate-button { display: flex; justify-content: space-between; width: 100%; padding: 16px; margin-top: 26px; background: var(--ink); color: white; border-radius: 8px; font-size: 14px; font-weight: 700; }
.calculate-button:hover { background: #24485e; }
.calculate-button:disabled { opacity: .5; }
#form-message:not(:empty) { margin-top: 12px; }
.local-note { border-top: 1px solid var(--line); margin-top: 22px; padding-top: 17px; font-size: 11px; }
.result-placeholder { display: grid; align-content: center; text-align: center; min-height: 375px; gap: 16px; }
.result-placeholder > span { font-size: 54px; color: #80ac9b; }
.result-placeholder h3 { font-size: 19px; }
.result-placeholder p { color: var(--muted); font-size: 13px; line-height: 1.9; }
.calc-warning { border-radius: 8px; background: #f3f6f4; color: #5d7167; padding: 15px; font-size: 12px; line-height: 1.9; }
.final-amount { background: #edf5f1; border-radius: 12px; padding: 24px; margin-top: 22px; }
.final-amount p { color: #52796a; font-size: 13px; }
.final-amount strong { display: block; font-size: clamp(23px, 2.6vw, 34px); color: var(--accent); margin: 12px 0; overflow-wrap: anywhere; font-variant-numeric: tabular-nums; }
.final-amount > span { font-size: 12px; color: #607b6f; }
.result-breakdown { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; padding: 10px 0 22px; border-bottom: 1px solid var(--line); }
.result-breakdown dt { font-size: 12px; color: var(--muted); margin-bottom: 10px; }
.result-breakdown dd { margin: 0; font-size: 17px; font-weight: 700; overflow-wrap: anywhere; }
.growth-chart { margin: 25px 0; }
.growth-chart figcaption { font-weight: 700; font-size: 15px; }
.chart-legend { display: flex; gap: 20px; font-size: 11px; color: var(--muted); margin-top: 16px; }
.chart-legend span { display: flex; align-items: center; gap: 6px; }
.chart-legend i { width: 18px; height: 3px; display: inline-block; }
.principal-swatch { border-top: 3px dashed #7897b1; }
.asset-swatch { background: #227b66; }
#chart svg { width: 100%; height: auto; display: block; margin-block: 12px; }
.yearly-section { margin-top: 24px; }
.table-scroll { overflow-x: auto; }
.table-scroll table { width: 100%; border-collapse: collapse; text-align: right; font-size: 13px; white-space: nowrap; font-variant-numeric: tabular-nums; }
.table-scroll th, .table-scroll td { padding: 15px; border-bottom: 1px solid var(--line); }
.table-scroll thead { background: #f2f6f4; color: #466557; }
.table-scroll th:first-child { text-align: left; }
.table-scroll tbody th { font-weight: 500; }
.table-scroll tbody tr:last-child { background: #edf5f1; font-weight: 700; }
.calculator-explanation { margin-top: 35px; }
.calculator-explanation .info-body section:first-child { margin-top: 0; }
.formula { background: var(--canvas); padding: 15px; border-radius: 8px; color: var(--ink); }
.calc-faq details { border-bottom: 1px solid var(--line); padding: 16px 0; }
.calc-faq summary { cursor: pointer; color: var(--ink); font-weight: 600; }
.calc-faq details p { padding-top: 12px; }
.status.available { color: var(--accent); background: #eaf5ef; }
@media(max-width:850px) {
  .calculator-layout { grid-template-columns: 1fr; }
  .result-placeholder { min-height: 240px; }
}
@media(max-width:600px) {
  .calculator-main { padding-top: 24px; }
  .calculator-heading h1 { font-size: 30px; }
  .calculator-heading > p:last-of-type { font-size: 13px; }
  .calc-panel, .calc-results { padding: 22px 18px; }
  .calculator-layout { gap: 18px; }
  .final-amount { padding: 20px 16px; }
  .result-breakdown { grid-template-columns: 1fr; gap: 20px; }
  .table-scroll th, .table-scroll td { padding: 13px 12px; }
  .yearly-section .section-heading { flex-direction: column; align-items: flex-start; gap: 0; }
  .yearly-section .section-heading > p { display: block; }
}
