/* The embed spec, Part B: the framed supplier calculator (src/embeds.js).
   Layout only, on top of provitly.css (never edited here). Every colour,
   size and space is a provitly.css token. Light and dark come from
   provitly.css (prefers-color-scheme): the page has no script. */

.embed { min-height: 0; }
.embed-page {
  width: 100%;
  max-width: var(--col-max);
  margin-inline: auto;
  padding: var(--s-4) var(--s-3) var(--s-3);
  min-width: 0;
}
.embed-title { font-size: var(--t-head); font-weight: 750; letter-spacing: -0.01em; line-height: 1.25; }

.embed-form { display: grid; gap: var(--s-4); margin-top: var(--s-4); counter-reset: field; }

/* the material picker: a select in the field style, chevron drawn inline
   (kept inline so the page needs no extra file) */
.embed-select select {
  flex: 1 1 auto; min-width: 0; width: 100%;
  min-height: 3.25rem;
  padding: 0 var(--s-2) 0 var(--s-4);
  border: 0; background: transparent; outline: none;
  color: var(--ink);
  font-size: var(--t-field);   /* >= 16px: no zoom on focus */
  font-weight: 700;
  appearance: none; -webkit-appearance: none;
  cursor: pointer;
}
.embed-select option, .embed-select optgroup { color: var(--text); background: var(--surface); }
.embed-chev { display: inline-flex; flex: none; padding-right: var(--s-4); color: var(--muted); pointer-events: none; }
.embed-chev svg { width: 20px; height: 20px; }

/* length, width, depth: three across when there is room, else stacked */
.embed-dims { display: grid; grid-template-columns: repeat(auto-fit, minmax(6.5rem, 1fr)); gap: var(--s-3); min-width: 0; }
.embed-dims .field { align-content: start; }

.embed-answer { margin-top: var(--s-4); }
.embed-lead { margin-top: var(--s-1); font-size: var(--t-stat); font-weight: 750; letter-spacing: -0.01em; line-height: 1.25; font-variant-numeric: tabular-nums; }
.embed-units { list-style: none; margin: var(--s-3) 0 0; padding: 0; display: grid; gap: var(--s-2); }
.embed-units li { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0 var(--s-2); padding-top: var(--s-2); border-top: 1px solid var(--line); }
.embed-units b { white-space: nowrap; font-size: var(--t-head); font-weight: 750; font-variant-numeric: tabular-nums; }
.embed-units span { color: var(--muted); font-size: var(--t-small); }
.embed-call { margin-top: var(--s-3); font-size: var(--t-head); font-weight: 750; }

.embed-credit { margin-top: var(--s-3); text-align: center; font-size: var(--t-tiny); }
.embed-credit a {
  display: inline-flex; align-items: center; min-height: var(--tap); padding-inline: var(--s-2);
  color: var(--muted);
}
