/* The kit's one colour picker: Figma's fill picker, ported from Ares (DEOS 15.1563, 15.2653). 240 wide, 11 px, fields 24 high, the square edge to edge. */
.cp-pop:has(> .fg) {
  width: 240px;
  padding: 0;
  max-height: calc(100vh - 16px);
  border-radius: 13px;
  overflow: hidden auto;
}
.fg {
  --fg-fill: color-mix(in srgb, var(--ink) 8%, transparent);
  --fg-hover: color-mix(in srgb, var(--ink) 11%, transparent);
  --fg-quiet: color-mix(in srgb, var(--ink) 62%, transparent);
  --fg-line: color-mix(in srgb, var(--ink) 10%, transparent);
  position: relative;
  outline: 0;
  font-size: 11px;
  line-height: 16px;
  font-weight: 450;
  color: var(--ink);
  user-select: none;
}
.fg [hidden] {
  display: none !important;
}
.fg-head {
  display: flex;
  align-items: center;
  gap: 2px;
  height: 40px;
  padding: 0 8px 0 8px;
  border-bottom: 1px solid var(--fg-line);
  cursor: var(--cur-grab);
}
.fg-grow {
  flex: 1 1 auto;
}
.fg-head-title {
  padding-left: 4px;
  font-weight: 550;
}
.fg-icon {
  flex: none;
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  padding: 0;
  border: 0;
  border-radius: 5px;
  background: none;
  color: var(--ink);
  cursor: pointer;
}
.fg-icon:hover:not(:disabled) {
  background: var(--fg-fill);
}
.fg-icon:disabled {
  opacity: 0.35;
  cursor: default;
}
.fg-types {
  display: flex;
  gap: 2px;
  padding: 8px;
}
.fg-type {
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  padding: 0;
  border: 0;
  border-radius: 5px;
  background: none;
  cursor: pointer;
}
.fg-type.on,
.fg-type:hover {
  background: var(--fg-fill);
}
.fg-type span {
  display: block;
  width: 14px;
  height: 14px;
  border-radius: 3px;
  border: 1px solid var(--ink);
}
.fg-type-solid {
  background: var(--ink);
}
.fg-type-gradient {
  background: linear-gradient(90deg, var(--ink), transparent);
}
.fg-gradient {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 0 12px 12px;
}
.fg-way {
  display: flex;
  align-items: center;
  gap: 4px;
}
.fg-way-pick,
.fg-format {
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 4px;
  height: 24px;
  padding: 0 6px;
  border: 0;
  border-radius: 5px;
  background: var(--fg-fill);
  color: var(--ink);
  font: inherit;
  cursor: pointer;
}
.fg-way-pick {
  flex: 1 1 auto;
  min-width: 0;
}
.fg-format {
  flex: none;
  width: 56px;
}
.fg-way .fg-field {
  flex: 0 0 52px;
}
.fg-tool {
  flex: none;
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  padding: 0;
  border: 0;
  border-radius: 5px;
  background: none;
  color: var(--ink);
  cursor: pointer;
}
.fg-tool:hover {
  background: var(--fg-fill);
}
.fg-track {
  position: relative;
  height: 24px;
  margin: 0 7px;
}
.fg-bar {
  position: absolute;
  inset: 4px -7px;
  border-radius: 4px;
  box-shadow: inset 0 0 0 1px var(--fg-line);
  cursor: copy;
}
.fg-marks {
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.fg-mark {
  position: absolute;
  top: 3px;
  width: 14px;
  height: 18px;
  margin-left: -7px;
  padding: 0;
  border: 2px solid var(--knob);
  border-radius: 4px;
  box-shadow: var(--sh-knob);
  cursor: ew-resize;
  pointer-events: auto;
  touch-action: none;
}
.fg-mark.on {
  box-shadow: 0 0 0 1px var(--knob-edge), 0 0 0 3px var(--acc);
}
.fg-area {
  position: relative;
  height: 240px;
  cursor: crosshair;
  touch-action: none;
}
/* 15.2653: a low screen (a phone on its side) keeps the hue and the code in sight - the square gives way */
@media (max-height: 500px) {
  .fg-area { height: 120px; }
}
.fg-dot {
  position: absolute;
  width: 16px;
  height: 16px;
  margin: -8px 0 0 -8px;
  border: 3px solid var(--knob);
  border-radius: 50%;
  box-shadow: var(--sh-knob);
  pointer-events: none;
}
.fg-control {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
}
.fg-hue {
  position: relative;
  flex: 1 1 auto;
  height: 16px;
  border-radius: 8px;
  background: var(--hue-scale);
  cursor: ew-resize;
  touch-action: none;
}
.fg-thumb {
  position: absolute;
  top: 0;
  width: 16px;
  height: 16px;
  margin-left: -8px;
  border: 3px solid var(--knob);
  border-radius: 50%;
  box-shadow: var(--sh-knob);
  pointer-events: none;
}
.fg-row {
  display: flex;
  gap: 4px;
  padding: 0 12px 12px;
}
.fg-values {
  flex: 1 1 auto;
  display: flex;
  gap: 2px;
  min-width: 0;
}
.fg-field {
  flex: 1 1 0;
  display: flex;
  align-items: center;
  min-width: 0;
  height: 24px;
  padding: 0 6px;
  border-radius: 5px;
  background: var(--fg-fill);
}
.fg-field:focus-within {
  box-shadow: inset 0 0 0 1px var(--acc);
}
.fg-unit {
  flex: none;
  color: var(--fg-quiet);
}
.fg
  input:not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="range"]):not(
    [type="color"]
  ):not(.wp-num):not(.pin-input).fg-input {
  flex: 1 1 auto;
  width: 100%;
  min-width: 0;
  height: 24px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: none;
  box-shadow: none;
  color: var(--ink);
  font: inherit;
  font-variant-numeric: tabular-nums;
  outline: 0;
}
.fg-stops {
  padding: 8px 12px 12px;
  border-top: 1px solid var(--fg-line);
}
.fg-stops-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 24px;
  margin-bottom: 4px;
  font-weight: 550;
}
.fg-stop {
  display: flex;
  align-items: center;
  gap: 4px;
  margin: 0 -4px;
  padding: 2px 4px;
  border-radius: 5px;
}
.fg-stop.on {
  background: var(--fg-fill);
}
.fg-stop .fg-field {
  flex: 0 0 52px;
}
.fg-stop-color {
  flex: 1 1 auto;
  display: flex;
  align-items: center;
  gap: 6px;
  height: 24px;
  padding: 0 6px;
  border: 0;
  border-radius: 5px;
  background: var(--fg-fill);
  color: var(--ink);
  font: inherit;
  cursor: pointer;
}
.fg-sample {
  display: inline-block;
  flex: none;
  width: 14px;
  height: 14px;
  border-radius: 3px;
  box-shadow: inset 0 0 0 1px var(--fg-line);
}
.fg-page {
  padding: 8px 12px 12px;
  border-top: 1px solid var(--fg-line);
}
.fg-page-title {
  height: 24px;
  line-height: 24px;
  font-weight: 550;
}
.fg-grid {
  display: grid;
  grid-template-columns: repeat(8, 20px);
  gap: 6px;
}
.fg-swatch {
  width: 20px;
  height: 20px;
  padding: 0;
  border: 0;
  border-radius: 4px;
  box-shadow: inset 0 0 0 1px var(--fg-line);
  cursor: pointer;
}
.rg-with-sample > .fg-sample {
  margin-right: 6px;
  vertical-align: -2px;
}
.fg-foot {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 8px 12px 12px;
  border-top: 1px solid var(--fg-line);
}
