/* SmartType: suggestions under the line being written, like the toolbar's menus. */
.smart-type {
  position: fixed;
  inset: auto;
  margin: 0;
  border: 0;
  min-width: 12rem;
  max-width: min(24rem, calc(100vw - 16px));
  padding: 0.3rem;
  border-radius: 6px;
  background: var(--chrome);
  box-shadow: 0 8px 24px rgb(0 0 0 / 0.4);
  color: var(--desk);
  font: 0.9rem/1.3 var(--font-typed);
}

.smart-type ul { margin: 0; padding: 0; list-style: none; }

.smart-type [role=option] {
  padding: 0.4em 0.6em;
  border-radius: 4px;
  cursor: pointer;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.smart-type [role=option]:hover { background: var(--chrome-muted); }
.smart-type [role=option][aria-selected=true] { background: var(--accent); }

.smart-type__keys {
  margin: 0.3rem 0.6rem 0.1rem;
  color: var(--pencil);
  font-size: 0.75rem;
}

/* Touch screens take a tap, and have no Tab key to mention. */
@media (pointer: coarse) {
  .smart-type [role=option] { padding: 0.7em 0.8em; }
  .smart-type__keys { display: none; }
}
