/* Free calculators (/tools/<calculator>/). Form controls come from rent-check.css, KPI cards from market-snapshot.css. */
.calc { display: grid; grid-template-columns: minmax(280px, 380px) minmax(0, 1fr); gap: 32px; align-items: start; }
.calc-form { display: grid; gap: 16px; padding: 24px; background: var(--p-card); border-radius: var(--p-radius); box-shadow: var(--p-shadow-card); }
.calc-row { display: grid; grid-template-columns: minmax(0, 1fr) 110px; gap: 12px; }
.calc-select {
  width: 100%;
  height: 44px;
  padding: 0 10px;
  border: 1px solid var(--p-border-strong);
  border-radius: var(--p-radius);
  font: inherit;
  font-size: 15px;
  color: var(--p-text);
  background: var(--p-bg-2);
}
.calc-select:focus { outline: none; box-shadow: var(--p-focus-ring); border-color: var(--p-accent); }
.calc-result { display: grid; gap: 16px; min-width: 0; transition: opacity var(--p-fast); }
.calc-result.is-loading, .calc-result.is-stale { opacity: 0.55; }
.calc-table { width: 100%; border-collapse: collapse; background: var(--p-card); border-radius: var(--p-radius); box-shadow: var(--p-shadow-card); overflow: hidden; font-size: 15px; }
.calc-table th, .calc-table td { padding: 11px 16px; text-align: right; border-bottom: 1px solid var(--p-border); font-variant-numeric: tabular-nums; }
.calc-table th[scope="row"], .calc-table thead th:first-child { text-align: left; font-weight: 500; color: var(--p-text); }
.calc-table thead th { font-weight: 600; color: var(--p-muted); }
.calc-table tr:last-child th, .calc-table tr:last-child td { border-bottom: 0; }
.calc-total th[scope="row"], .calc-total td { font-weight: 700; color: var(--p-ink); }
.calc-subhead { margin: 8px 0 0; font-size: 18px; font-weight: 600; color: var(--p-ink); }
.calc-note, .calc-unavailable { margin: 0; font-size: 14px; line-height: 1.55; color: var(--p-muted); }
.calc-notes { font-size: 14px; line-height: 1.55; color: var(--p-muted); }
.calc-notes summary { cursor: pointer; font-weight: 600; color: var(--p-text); }
.calc-notes ul { margin: 10px 0; padding-left: 18px; }
.calc-notes a { color: var(--p-accent-deep); }
.calc-result { scroll-margin-top: 96px; }
.calc-result.is-updated { animation: calc-refresh 450ms ease-out; }
@keyframes calc-refresh { from { opacity: 0.35; transform: translateY(6px); } to { opacity: 1; transform: none; } }
/* Prose comes from the blog's .post-content; the width lines it up with the FAQ list below (.faq-section). */
.calc-explainer { max-width: calc(var(--container-narrow) - 48px); margin: 0 auto; }
.calc-explainer > :first-child { margin-top: 0; }
.calc-explainer > :last-child { margin-bottom: 0; }

@media (prefers-reduced-motion: reduce) {
  .calc-result.is-updated { animation: none; }
}

@media (max-width: 860px) {
  .calc { grid-template-columns: minmax(0, 1fr); }
  .calc-table th, .calc-table td { padding: 10px 12px; }
}
