.prosthetics-dialog,
.prosthetics-page {
  color: var(--text, #17251d);
  background: var(--surface, #fff);
  border: 1px solid var(--border, #ced4c7);
  border-radius: var(--radius, 12px);
  padding: clamp(16px, 4vw, 26px);
}

.prosthetics-dialog {
  inline-size: min(580px, calc(100% - 24px));
  max-block-size: calc(100dvh - 24px);
  overscroll-behavior: contain;
  inset: 0;
  margin: auto;
}

.prosthetics-dialog::backdrop { background: rgb(17 30 39 / .62); }
html:has(.prosthetics-dialog[open]) { overflow: hidden; }

.prosthetics-page { max-inline-size: 580px; margin-inline: auto; }
.prosthetics-heading { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.prosthetics-heading h2,
.prosthetics-page h1 { margin: 0; font-size: clamp(20px, 4vw, 24px); line-height: 1.2; }

.prosthetics-close,
.prosthetics-submit {
  min-block-size: 44px;
  border: 1px solid var(--border, #ced4c7);
  border-radius: 7px;
  font: inherit;
  cursor: pointer;
}

.prosthetics-close {
  display: grid;
  place-items: center;
  flex: 0 0 44px;
  color: inherit;
  background: transparent;
}

.prosthetics-close:hover { background: var(--bg, #f7f7f0); }
.prosthetics-form { display: grid; gap: 14px; margin-block-start: 14px; }
.prosthetics-selection {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: var(--space-1, 4px) var(--space-4, 16px);
  margin: 0;
  padding: var(--space-3, 12px);
  border: 1px solid var(--border, #ced4c7);
  border-radius: var(--radius-sm, 7px);
}
.prosthetics-selection dt { color: var(--muted, #49594c); }
.prosthetics-selection dd { margin: 0; font-weight: 600; overflow-wrap: anywhere; }
.prosthetics-form [hidden],
.prosthetics-dialog [hidden] { display: none; }
.prosthetics-contact { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(185px, 100%), 1fr)); gap: 14px; }
.prosthetics-field { display: grid; gap: 5px; min-inline-size: 0; }
.prosthetics-field label { font-weight: 600; }
.prosthetics-field p, .prosthetics-form p { margin: 0; line-height: 1.4; }
.prosthetics-field p { color: var(--muted, #49594c); font-size: 14px; }
.prosthetics-field input,
.prosthetics-field textarea {
  inline-size: 100%;
  min-block-size: 44px;
  padding: 8px;
  border: 1px solid var(--border, #818d80);
  border-radius: 7px;
  background: var(--bg, #f7f7f0);
  color: inherit;
  font: inherit;
}
.prosthetics-field textarea { resize: vertical; }
.prosthetics-form a { text-decoration: underline; }
.prosthetics-errors,
.prosthetics-form .errorlist { color: var(--danger, #a52d33); }
.prosthetics-form .errorlist { margin: 0; padding-inline-start: 20px; }
.prosthetics-submit {
  justify-self: start;
  padding-inline: 18px;
  color: var(--on-action, #fff);
  background: var(--action, #22372b);
  font-weight: 600;
}
.prosthetics-submit:hover { filter: brightness(.9); }
.prosthetics-submit:disabled { opacity: .72; cursor: wait; }
.prosthetics-dialog [data-prosthetics-success] { margin: 12px 0 0; }
.prosthetics-phone { white-space: nowrap; }
