.calculator-section { padding: 62px 0; background: #0b1b45; color: #fff; }
.calculator-heading { display: flex; justify-content: space-between; align-items: end; gap: 24px; margin-bottom: 27px; }
.calculator-heading h2 { margin: 0; max-width: 680px; font-size: 36px; line-height: 1.25; letter-spacing: -2px; }
.calculator-heading p:last-child { max-width: 360px; margin: 0; color: #d8e2f0; font-size: 14px; line-height: 1.7; }
.calculator-heading .eyebrow { color: #f08cff; }
.calculator-shell { overflow: hidden; border-radius: 18px; background: #fff; color: #211823; }
.calculator-tabs { display: grid; grid-template-columns: 1fr 1fr; border-bottom: 1px solid #dbe4ed; }
.calculator-tabs button { border: 0; background: #eef3f8; padding: 17px; color: #594f5b; font: inherit; font-size: 14px; font-weight: 900; cursor: pointer; }
.calculator-tabs button[aria-pressed="true"] { background: #D255E1; color: #211823; }
.calculator-body { display: grid; grid-template-columns: .8fr 1.2fr; }
.calculator-form { padding: 32px; border-right: 1px solid #dbe4ed; }
.calculator-fields { display: grid; gap: 18px; }
.calculator-field { display: grid; gap: 8px; }
.calculator-field[hidden] { display: none; }
.calculator-field span { color: #413644; font-size: 13px; font-weight: 800; }
.calculator-field small { color: #746a76; font-size: 11px; font-weight: 400; }
.calculator-input-wrap { display: grid; grid-template-columns: 1fr auto; align-items: center; border: 1px solid #b9c7d6; border-radius: 9px; background: #fff; }
.calculator-input-wrap:focus-within { border-color: #9f2caf; box-shadow: 0 0 0 3px rgba(210,85,225,.18); }
.calculator-input-wrap input { min-width: 0; width: 100%; border: 0; outline: 0; padding: 13px 5px 13px 14px; background: transparent; color: #0b1b45; font: inherit; font-size: 17px; font-weight: 800; }
.calculator-input-wrap select { min-width: 0; width: 100%; border: 0; outline: 0; padding: 13px 38px 13px 14px; background: transparent; color: #0b1b45; font: inherit; font-size: 15px; font-weight: 800; }
.calculator-input-wrap b { padding: 0 14px 0 8px; color: #746a76; font-size: 12px; }
.calculator-check { display: flex; align-items: center; gap: 10px; padding: 13px 14px; border: 1px solid #b9c7d6; border-radius: 9px; color: #413644; font-size: 13px; font-weight: 800; cursor: pointer; }
.calculator-check input { width: 19px; height: 19px; accent-color: #D255E1; }
.calculator-assumption { margin: 21px 0 0; padding: 16px; border-radius: 10px; background: #f6eff8; color: #665b68; font-size: 12px; line-height: 1.7; }
.calculator-error { margin: 15px 0 0; padding: 12px 14px; border-radius: 8px; background: #fff0f0; color: #8c1f2c; font-size: 13px; line-height: 1.6; }
.calculator-output { padding: 32px; min-width: 0; }
.calculator-result { padding-bottom: 23px; border-bottom: 1px solid #dbe4ed; }
.calculator-result > span { color: #9f2caf; font-size: 11px; font-weight: 900; letter-spacing: .08em; }
.calculator-result h3 { margin: 8px 0 7px; color: #0b1b45; font-size: 34px; line-height: 1.25; letter-spacing: -1.8px; }
.calculator-result p { margin: 0; color: #746a76; font-size: 13px; }
.calculator-metrics { display: grid; grid-template-columns: repeat(3, 1fr); gap: 9px; margin: 18px 0 22px; }
.calculator-metrics-four { grid-template-columns: repeat(2, 1fr); }
.calculator-metric { padding: 14px; border-radius: 10px; background: #eef3f8; }
.calculator-metric span { display: block; color: #746a76; font-size: 11px; }
.calculator-metric strong { display: block; overflow-wrap: anywhere; margin-top: 7px; color: #0b1b45; font-size: 14px; }
.calculator-chart-wrap { min-width: 0; }
.calculator-chart-wrap svg { width: 100%; height: auto; min-height: 250px; display: block; }
.calc-chart-frame { fill: #fbfdff; stroke: #ccd7e4; }
.calc-grid-line { stroke: #dfe7ef; stroke-width: 1; }
.calc-total-area { fill: rgba(210,85,225,.14); }
.calc-total-line { fill: none; stroke: #b12cc1; stroke-width: 4; stroke-linecap: round; stroke-linejoin: round; }
.calc-principal-line { fill: none; stroke: #0b1b45; stroke-width: 2.5; stroke-dasharray: 7 6; stroke-linecap: round; }
.calc-simple-line { fill: none; stroke: #0b1b45; stroke-width: 3; stroke-dasharray: 8 7; stroke-linecap: round; stroke-linejoin: round; }
.calc-final-dot { fill: #b12cc1; stroke: #fff; stroke-width: 3; }
.calc-axis-label { fill: #746a76; font-size: 11px; }
.calc-axis-title { fill: #413644; font-size: 12px; font-weight: 800; }
.calculator-legend { display: flex; gap: 18px; flex-wrap: wrap; margin-top: 4px; color: #5c525e; font-size: 11px; }
.calculator-legend span { display: inline-flex; align-items: center; gap: 7px; }
.calculator-legend i { width: 20px; height: 3px; background: #b12cc1; }
.calculator-legend i.principal { height: 0; border-top: 2px dashed #0b1b45; background: transparent; }
.calculator-legend i.simple { height: 0; border-top: 3px dashed #0b1b45; background: transparent; }
.calculator-bars { display: grid; gap: 14px; margin: 24px 0 8px; }
.calculator-bar { display: grid; grid-template-columns: 96px 1fr auto; align-items: center; gap: 12px; color: #5c525e; font-size: 12px; }
.calculator-bar strong { color: #0b1b45; font-size: 12px; }
.calculator-bar span { color: #0b1b45; font-weight: 900; }
.calculator-bar-track { overflow: hidden; height: 18px; border-radius: 999px; background: #eef3f8; }
.calculator-bar-track::before { content: ""; display: block; width: var(--bar-width, 10%); height: 100%; border-radius: inherit; background: #D255E1; transition: width .25s ease; }
.calculator-bar:nth-child(2) .calculator-bar-track::before { background: #0b1b45; }
.calculator-related { padding: 0 0 76px; }
.calculator-related h2 { margin: 0 0 18px; color: var(--ink); font-size: 27px; letter-spacing: -1px; }
.calculator-related-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.calculator-related-grid a { padding: 20px; border: 1px solid var(--line); border-radius: 12px; color: var(--ink); font-size: 14px; font-weight: 900; line-height: 1.55; }
.calculator-related-grid span { display: block; margin-bottom: 7px; color: #9f2caf; font-size: 10px; letter-spacing: .08em; }
.home-tools { padding-top: 54px; padding-bottom: 28px; }
.home-tools .calculator-related-grid { grid-template-columns: repeat(5, 1fr); }
.listing .post-card h2 { margin: 13px 0 9px; color: #0b1b45; font-size: 22px; line-height: 1.35; letter-spacing: -1px; }
.calculator-actions { display: flex; align-items: center; gap: 15px; margin-top: 24px; }
.calculator-actions button { border: 0; border-radius: 8px; background: #211823; color: #fff; padding: 13px 17px; font: inherit; font-size: 12px; font-weight: 900; cursor: pointer; }
.calculator-actions a { color: #8d239d; font-size: 12px; font-weight: 900; text-decoration: underline; text-underline-offset: 3px; }
.calculator-detail { padding: 45px 0 80px; }
.calculator-detail-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.calculator-detail article { padding: 27px; border: 1px solid var(--line); border-radius: 14px; background: #fff; }
.calculator-detail h2 { margin: 0 0 13px; color: var(--ink); font-size: 25px; letter-spacing: -1px; }
.calculator-detail h3 { margin: 0 0 10px; color: var(--ink); font-size: 18px; }
.calculator-detail p,.calculator-detail li { color: var(--muted); font-size: 15px; line-height: 1.85; }
.calculator-detail ul { margin: 0; padding-left: 20px; }
.calculator-source { margin-top: 18px; padding: 22px; border: 1px solid #cfddea; border-left: 5px solid var(--point); border-radius: 12px; color: var(--muted); font-size: 13px; line-height: 1.8; }
.calculator-source a { color: #8d239d; font-weight: 800; text-decoration: underline; }
.calculator-section .sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
@media(max-width:800px){
  .calculator-section { padding: 45px 0; }
  .calculator-heading { display: block; }
  .calculator-heading h2 { font-size: 30px; }
  .calculator-heading p:last-child { margin-top: 14px; }
  .calculator-body { grid-template-columns: 1fr; }
  .calculator-form { border-right: 0; border-bottom: 1px solid #dbe4ed; padding: 24px 20px; }
  .calculator-output { padding: 25px 20px; }
  .calculator-result h3 { font-size: 29px; }
  .calculator-metrics { grid-template-columns: 1fr; }
  .calculator-chart-wrap svg { min-height: 210px; }
  .calculator-actions { align-items: flex-start; flex-direction: column; }
  .calculator-detail-grid { grid-template-columns: 1fr; }
  .calculator-bar { grid-template-columns: 75px 1fr; }
  .calculator-bar span { grid-column: 2; }
  .calculator-related-grid { grid-template-columns: 1fr; }
  .home-tools .calculator-related-grid { grid-template-columns: 1fr; }
}
