/* Dental Implants Cost Calculator — tool styles.
   Every value from a design token (§4.2). Scoped to .ftb-tool-dic.
   Inputs, radios, checkboxes, buttons and messages come from core.css.
   Kept deliberately small: core.css and style.css already transfer about
   11,000 of the 12,288-byte page budget (§10). */

.ftb-tool-dic .ftb-dic-set{margin:0 0 var(--ftb-space-5);padding:var(--ftb-space-4) var(--ftb-space-5) 0;
  border:1px solid var(--ftb-border);border-radius:var(--ftb-radius);background:var(--ftb-surface);min-width:0}
.ftb-tool-dic legend{padding:0 var(--ftb-space-2);font-size:var(--ftb-text-sm);font-weight:var(--ftb-fw-bold)}
.ftb-tool-dic .ftb-dic-grid{display:grid;gap:0 var(--ftb-space-4);
  grid-template-columns:repeat(auto-fit,minmax(min(100%,12rem),1fr))}
.ftb-tool-dic .ftb-dic-grid > *{min-width:0}
.ftb-tool-dic .ftb-dic-grid .ftb-field{margin-bottom:var(--ftb-space-4)}
.ftb-tool-dic .ftb-dic-wide{grid-column:1/-1}
.ftb-tool-dic .ftb-dic-lead{margin:0 0 var(--ftb-space-4)}
.ftb-tool-dic .ftb-dic-opts{margin-bottom:var(--ftb-space-4);padding-bottom:0;border-bottom:0}
.ftb-tool-dic input[aria-invalid=true]{border-color:var(--ftb-error)}

/* ---------------------------------------------------------------- results */

/* Height reserved so the first estimate never shifts the page (§10). */
.ftb-tool-dic .ftb-dic-results{min-height:calc(var(--ftb-space-24) + var(--ftb-space-8))}
.ftb-tool-dic .ftb-dic-h{margin:0 0 var(--ftb-space-4);font-size:var(--ftb-text-lg);font-weight:var(--ftb-fw-semi)}
.ftb-tool-dic .ftb-dic-sum{display:grid;gap:var(--ftb-space-3);
  grid-template-columns:repeat(auto-fit,minmax(min(100%,11rem),1fr))}
.ftb-tool-dic .ftb-dic-box{padding:var(--ftb-space-4);background:var(--ftb-surface-2);border-radius:var(--ftb-radius)}
.ftb-tool-dic .ftb-dic-k{margin:0;font-size:var(--ftb-text-sm);font-weight:var(--ftb-fw-semi)}
.ftb-tool-dic .ftb-dic-v{margin:var(--ftb-space-1) 0 0;font-size:var(--ftb-text-2xl);font-weight:var(--ftb-fw-bold);
  font-variant-numeric:tabular-nums}

.ftb-tool-dic .ftb-table-scroll{margin-top:var(--ftb-space-5)}
.ftb-tool-dic .ftb-dic-table{width:100%;border-collapse:collapse;font-size:var(--ftb-text-sm);font-variant-numeric:tabular-nums}
.ftb-tool-dic .ftb-dic-table th,
.ftb-tool-dic .ftb-dic-table td{padding:var(--ftb-space-2) var(--ftb-space-3);text-align:start;border-bottom:1px solid var(--ftb-border)}
.ftb-tool-dic .ftb-dic-table thead th{color:var(--ftb-text-muted);background:var(--ftb-surface-2)}
.ftb-tool-dic .ftb-dic-table tbody th{font-weight:var(--ftb-fw-medium)}
.ftb-tool-dic .ftb-dic-table .is-num{text-align:end;white-space:nowrap}
.ftb-tool-dic .ftb-dic-tag{color:var(--ftb-text-muted)}

.ftb-tool-dic .ftb-dic-notes,
.ftb-tool-dic .ftb-dic-work ol{margin:var(--ftb-space-4) 0 0;padding-inline-start:var(--ftb-space-6);
  font-size:var(--ftb-text-sm);line-height:var(--ftb-lh-snug)}
.ftb-tool-dic .ftb-dic-notes li + li,
.ftb-tool-dic .ftb-dic-work li + li{margin-top:var(--ftb-space-2)}
.ftb-tool-dic .ftb-dic-work{margin-top:var(--ftb-space-4)}
.ftb-tool-dic .ftb-dic-work summary{display:flex;align-items:center;min-height:var(--ftb-tap);cursor:pointer;
  font-size:var(--ftb-text-sm);font-weight:var(--ftb-fw-semi);color:var(--ftb-primary)}
.ftb-tool-dic .ftb-dic-work summary:focus-visible{outline:2px solid var(--ftb-primary);outline-offset:2px}

.ftb-tool-dic .ftb-dic-disclaimer{margin:var(--ftb-space-6) 0 0;padding:var(--ftb-space-4) var(--ftb-space-5);
  background:var(--ftb-surface-2);border-radius:var(--ftb-radius);font-size:var(--ftb-text-sm);
  line-height:var(--ftb-lh-snug);color:var(--ftb-text-muted)}

@media (max-width:479px){
  .ftb-tool-dic .ftb-dic-set{padding:var(--ftb-space-3) var(--ftb-space-3) 0}
  .ftb-tool-dic .ftb-tool-actions .ftb-btn{flex:1 1 auto}
}
