.color-suggest-field {
  position: relative;
  overflow: visible;
}

.color-suggest-panel {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  left: 0;
  z-index: 80;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 0;
  max-height: min(390px, calc(100vh - 170px));
  overflow: auto;
  background: var(--panel, #ffffff);
  border: 1px solid var(--line, rgba(24, 24, 24, 0.12));
  box-shadow: var(--shadow-soft, 0 18px 40px rgba(0, 0, 0, 0.16));
  scrollbar-width: thin;
}

.color-suggest-panel[hidden] {
  display: none;
}

.color-suggest-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  min-width: 0;
  color: var(--ink, #171510);
  background: var(--panel, #f7f7f4);
  border-right: 1px solid var(--line, rgba(24, 24, 24, 0.12));
  border-bottom: 1px solid var(--line, rgba(24, 24, 24, 0.12));
}

.color-suggest-option {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  min-width: 0;
  min-height: 64px;
  padding: 10px 12px;
  color: inherit;
  background: transparent;
  border: 0;
  cursor: pointer;
  text-align: left;
  transition: color 160ms ease, background 160ms ease, transform 180ms var(--ease-out-quart, ease);
}

.color-suggest-option:hover,
.color-suggest-option:focus-visible,
.color-suggest-option[aria-selected="true"] {
  color: var(--hover-text, #f7f7f4);
  background: var(--hover-bg, #171510);
  outline: none;
}

.color-suggest-option:active {
  transform: translateY(1px);
}

.color-suggest-effect {
  width: 42px;
  height: 42px;
  background: var(--suggest-color);
  border: 0 !important;
  border-radius: 0;
  outline: 0;
  box-shadow: none;
  transition: border-radius 180ms var(--ease-out-quart, ease), transform 180ms var(--ease-out-quart, ease);
}

.color-suggest-option:hover .color-suggest-effect,
.color-suggest-option:focus-visible .color-suggest-effect,
.color-suggest-option[aria-selected="true"] .color-suggest-effect {
  border-radius: 50%;
  transform: scale(0.94);
}

.color-suggest-copy {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.color-suggest-copy strong,
.color-suggest-copy small {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.color-suggest-copy strong {
  color: currentColor;
  font-size: 0.88rem;
  font-weight: 800;
}

.color-suggest-copy small {
  color: var(--muted, rgba(23, 21, 16, 0.62));
  font-family: var(--font-rounded, inherit);
  font-size: 0.72rem;
  font-weight: 700;
  transition: color 160ms ease;
}

.color-suggest-option:hover small,
.color-suggest-option:focus-visible small,
.color-suggest-option[aria-selected="true"] small {
  color: color-mix(in srgb, currentColor 72%, transparent);
}

.color-suggest-detail {
  display: inline-flex;
  align-items: center;
  align-self: stretch;
  padding: 0 12px;
  color: var(--muted, rgba(23, 21, 16, 0.62));
  border-left: 1px solid var(--line, rgba(24, 24, 24, 0.12));
  font-size: 0.78rem;
  font-weight: 800;
  text-decoration: none;
  white-space: nowrap;
}

.color-suggest-detail:hover,
.color-suggest-detail:focus-visible {
  color: var(--hover-text, #f7f7f4);
  background: var(--hover-bg, #171510);
  outline: none;
}

.color-suggest-empty {
  grid-column: 1 / -1;
  margin: 0;
  padding: 14px 16px;
  color: var(--muted, rgba(23, 21, 16, 0.62));
  background: var(--panel, #f7f7f4);
  font-size: 0.82rem;
  font-weight: 750;
}

@media (max-width: 640px) {
  .color-suggest-panel {
    grid-template-columns: 1fr;
    max-height: min(330px, calc(100vh - 150px));
  }

  .color-suggest-option {
    min-height: 60px;
  }

  .color-suggest-detail {
    padding: 0 10px;
  }
}
