/* Shared presentation layer for both property calculators. */
body {
  font-size: 14px;
}

.app-shell {
  padding: 20px;
}

.topbar {
  gap: 20px;
  padding: 12px 0 18px;
}

h1 {
  font-size: 30px;
}

.subtitle {
  margin-top: 7px;
  font-size: 14px;
  line-height: 1.4;
}

.source-line {
  font-size: 11px;
  padding: 9px 11px;
}

.summary-grid {
  gap: 10px;
  margin-bottom: 14px;
}

.metric {
  min-height: 108px;
  padding: 14px;
}

.metric .label {
  font-size: 11px;
}

.metric .value {
  margin-top: 8px;
  font-size: 25px;
}

.metric.primary .value {
  font-size: 31px;
}

.metric .note {
  margin-top: 7px;
  font-size: 12px;
  line-height: 1.3;
}

.top-recommendation {
  margin-bottom: 14px;
}

.recommendation {
  padding: 13px 15px;
}

.recommendation h3 {
  font-size: 15px;
}

.recommendation p {
  font-size: 13px;
  line-height: 1.4;
}

.panel-header {
  min-height: 48px;
  padding: 12px 15px;
}

.panel-header h2 {
  font-size: 14px;
}

.panel-body {
  padding: 13px 15px 15px;
}

.controls {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.controls > .group.section-wide {
  grid-column: 1 / -1;
}

.controls > .group:not(.section-wide) .field-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.group {
  gap: 9px;
  padding: 12px;
}

.group-title {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 28px;
  justify-content: space-between;
  color: #26343d;
  cursor: default;
}

.group-title-text {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.group-title-text::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: var(--teal);
  flex: 0 0 auto;
}

.group-title::before {
  display: none;
}

.section-toggle,
.panel-toggle,
.section-batch-action {
  border: 1px solid #cbd4d0;
  border-radius: 6px;
  background: #fff;
  color: #34424c;
  cursor: pointer;
  font-size: 11px;
  font-weight: 750;
  line-height: 1;
}

.section-toggle,
.panel-toggle {
  min-width: 60px;
  min-height: 28px;
  padding: 6px 8px;
}

.section-toggle:hover,
.panel-toggle:hover,
.section-batch-action:hover {
  border-color: var(--teal);
  background: var(--soft-teal);
  color: var(--teal);
}

.panel-header-actions {
  display: flex;
  align-items: center;
  gap: 7px;
}

.section-batch-action {
  min-height: 30px;
  padding: 7px 9px;
}

.group.is-collapsed {
  padding-bottom: 12px;
}

.group.is-collapsed > :not(.group-title),
.details-grid > .panel.is-collapsed > .panel-body {
  display: none !important;
}

.details-grid > .panel.is-collapsed {
  align-self: start;
}

.field-grid {
  gap: 9px;
}

.field {
  gap: 5px;
}

.field:not(.full) > label,
.field:not(.full) > .inline-row,
.investment-group .field:not(.full) > label,
.investment-group .field:not(.full) > .inline-row {
  min-height: 30px;
}

label,
.switch-label {
  font-size: 12px;
  line-height: 1.25;
}

input[type="number"],
input.formatted-number,
select,
.investment-group input[type="number"],
.investment-group input.formatted-number,
.investment-group select {
  height: 40px;
  font-size: 13px;
  padding-top: 7px;
  padding-bottom: 7px;
}

.prefix,
.suffix,
.badge,
.derived-inline,
.table-note,
.fx-date,
.footer-note,
.investment-note {
  font-size: 11px;
}

.quick-buttons button {
  min-height: 30px;
  font-size: 11px;
}

.input-subsection,
.investment-group .input-subsection,
.controls .group.investment-group .input-subsection {
  padding: 11px;
}

.subsection-title {
  font-size: 12px;
}

.details-grid {
  gap: 12px;
  margin-top: 2px;
}

.table {
  font-size: 13px;
}

.table th,
.table td {
  padding: 9px 8px;
}

.table th {
  font-size: 11px;
}

.rule-box,
.callout p,
.footer-note {
  font-size: 12px;
}

@media (max-width: 980px) {
  .app-shell {
    padding: 14px;
  }

  .controls {
    grid-template-columns: 1fr;
  }

  .controls > .group,
  .controls > .group.section-wide {
    grid-column: 1;
  }
}

@media (max-width: 680px) {
  h1 {
    font-size: 25px;
  }

  .controls > .group:not(.section-wide) .field-grid {
    grid-template-columns: 1fr;
  }

  .section-batch-action {
    display: none;
  }
}
