@charset "UTF-8";
/* Palette page — 取色/色卡专属：预览舞台 / 主色板药丸 / 取色记录 / 当前取色；其余复用 compress.css */
/* ── 预览舞台 ── */
.pl-stage {
  position: relative;
  margin-top: 20px;
  border: 1px solid #eceae4;
  border-radius: 16px;
  background: linear-gradient(45deg, rgba(28, 28, 28, 0.03) 25%, transparent 25%, transparent 75%, rgba(28, 28, 28, 0.03) 75%), linear-gradient(45deg, rgba(28, 28, 28, 0.03) 25%, transparent 25%, transparent 75%, rgba(28, 28, 28, 0.03) 75%), #fcfbf8;
  background-size: 20px 20px;
  background-position: 0 0, 10px 10px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  min-height: 260px;
}

.pl-stage__canvas {
  max-width: 100%;
  max-height: 56vh;
  width: auto;
  height: auto;
  border-radius: 6px;
  box-shadow: 0 6px 24px rgba(28, 28, 28, 0.1);
}
.pl-stage__canvas:not([hidden]) {
  display: block;
}
.pl-stage__canvas.is-eye {
  cursor: crosshair;
}
.pl-stage__canvas:focus-visible {
  outline: 2px solid rgba(28, 28, 28, 0.9);
  outline-offset: 3px;
}

.pl-stage__placeholder {
  text-align: center;
  color: rgba(28, 28, 28, 0.62);
  font-size: 14px;
  line-height: 1.7;
}
.pl-stage__placeholder svg {
  width: 40px;
  height: 40px;
  opacity: 0.5;
  margin-bottom: 10px;
}

.pl-srcinfo {
  font-family: ui-monospace, "SF Mono", "Cascadia Mono", Consolas, monospace;
  font-size: 12px;
  color: #5f5f5d;
  letter-spacing: 0.01em;
  min-height: 1em;
  text-align: center;
}

/* 取色放大镜（悬停跟随光标的像素放大窗，绝对定位于舞台内） */
.pl-mag {
  position: absolute;
  z-index: 6;
  left: 0;
  top: 0;
  width: 158px;
  padding: 4px 4px 2px;
  background: #fcfbf8;
  border: 1px solid #dcd8cc;
  border-radius: 10px;
  box-shadow: 0 8px 24px rgba(28, 28, 28, 0.2);
  pointer-events: none;
}
.pl-mag[hidden] {
  display: none;
}

.pl-mag__canvas {
  display: block;
  width: 150px;
  height: 150px;
  border-radius: 6px;
  image-rendering: pixelated;
  image-rendering: crisp-edges;
  background: linear-gradient(45deg, rgba(28, 28, 28, 0.06) 25%, transparent 25%, transparent 75%, rgba(28, 28, 28, 0.06) 75%), linear-gradient(45deg, rgba(28, 28, 28, 0.06) 25%, transparent 25%, transparent 75%, rgba(28, 28, 28, 0.06) 75%), #f7f4ed;
  background-size: 16px 16px;
  background-position: 0 0, 8px 8px;
}

.pl-mag__cap {
  font-family: ui-monospace, "SF Mono", "Cascadia Mono", Consolas, monospace;
  font-size: 11px;
  color: #5f5f5d;
  text-align: center;
  padding: 4px 2px 1px;
  white-space: nowrap;
}

/* ── 结果区（主色板 / 取色记录） ── */
.pl-results {
  margin-top: 22px;
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.pl-results__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}
.pl-results__head h2 {
  font-size: 15px;
  font-weight: 600;
  color: #1c1c1c;
  margin: 0;
}

.pl-results__copy {
  border: none;
  background: none;
  padding: 0;
  font-size: 12.5px;
  color: #5f5f5d;
  cursor: pointer;
  font-family: inherit;
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-color: rgba(28, 28, 28, 0.3);
}
.pl-results__copy:hover {
  color: #1c1c1c;
}
.pl-results__copy:disabled {
  opacity: 0.45;
  cursor: progress;
  text-decoration: none;
}

/* 取色记录头部的多按钮组 */
.pl-results__acts {
  display: flex;
  align-items: baseline;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 12px;
}

/* ── 色板药丸网格 ── */
.pl-palette {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(104px, 1fr));
  gap: 10px;
}

.pl-sw {
  position: relative;
  display: flex;
  flex-direction: column;
  border: 1px solid #eceae4;
  border-radius: 12px;
  overflow: hidden;
  background: #fcfbf8;
  cursor: pointer;
  padding: 0;
  text-align: left;
  font-family: inherit;
  transition: transform 0.15s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.15s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.15s cubic-bezier(0.16, 1, 0.3, 1);
}
.pl-sw:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(28, 28, 28, 0.12);
  border-color: #dcd8cc;
}

.pl-sw__block {
  display: block;
  height: 56px;
  background: var(--sw, #ddd);
}

.pl-sw__name {
  font-size: 12.5px;
  font-weight: 600;
  color: #1c1c1c;
  padding: 7px 10px 0;
  line-height: 1.3;
}

.pl-sw__hex {
  font-family: ui-monospace, "SF Mono", "Cascadia Mono", Consolas, monospace;
  font-size: 12px;
  font-weight: 600;
  color: #5f5f5d;
  padding: 1px 10px 0;
}

.pl-sw__rgb {
  font-family: ui-monospace, "SF Mono", "Cascadia Mono", Consolas, monospace;
  font-size: 11px;
  color: rgba(28, 28, 28, 0.62);
  padding: 1px 10px 9px;
}

/* 对比度徽章（叠在色块左上，与黑/白文本最佳对比度等级） */
.pl-sw__badge {
  position: absolute;
  top: 6px;
  left: 6px;
  font-family: ui-monospace, "SF Mono", "Cascadia Mono", Consolas, monospace;
  font-size: 9.5px;
  font-weight: 600;
  letter-spacing: 0.01em;
  padding: 1px 5px;
  border-radius: 999px;
  background: rgba(252, 251, 248, 0.9);
  color: #1c1c1c;
  box-shadow: 0 1px 2px rgba(28, 28, 28, 0.18);
  pointer-events: none;
}

/* 权重占比条（仅主色板） */
.pl-sw__bar {
  display: block;
  height: 4px;
  margin: 6px 10px 0;
  border-radius: 2px;
  background: rgba(28, 28, 28, 0.08);
  overflow: hidden;
}
.pl-sw__bar > i {
  display: block;
  height: 100%;
  background: #5f5f5d;
  border-radius: 2px;
}

.pl-sw__pct {
  font-family: ui-monospace, "SF Mono", "Cascadia Mono", Consolas, monospace;
  font-size: 10px;
  color: rgba(28, 28, 28, 0.62);
  padding: 3px 10px 9px;
}

/* ── 取色记录可删除色块：外层 div 包裹，复制按钮 + 删除按钮平级 ── */
.pl-sw-wrap {
  position: relative;
}
.pl-sw-wrap .pl-sw {
  width: 100%;
}

.pl-sw__remove {
  position: absolute;
  top: 5px;
  right: 5px;
  width: 22px;
  height: 22px;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.82);
  color: #1c1c1c;
  font-size: 16px;
  line-height: 20px;
  text-align: center;
  cursor: pointer;
  opacity: 0;
  transition: opacity 0.15s cubic-bezier(0.16, 1, 0.3, 1), background 0.15s cubic-bezier(0.16, 1, 0.3, 1);
}
.pl-sw-wrap:hover .pl-sw__remove, .pl-sw-wrap:focus-within .pl-sw__remove, .pl-sw__remove:focus, .pl-sw__remove:focus-visible {
  opacity: 1;
}
.pl-sw__remove:hover {
  background: #fff;
}
.pl-sw__remove:focus-visible {
  outline: 2px solid rgba(28, 28, 28, 0.9);
  outline-offset: 1px;
}

.pl-empty {
  grid-column: 1/-1;
  font-size: 13px;
  color: rgba(28, 28, 28, 0.62);
  padding: 14px 2px;
}

/* ── 当前取色 chips ── */
.pl-current {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 14px;
  padding: 12px 14px;
  border: 1px solid #eceae4;
  border-radius: 12px;
  background: #f7f4ed;
}
.pl-current[hidden] {
  display: none;
}

.pl-current__swatch {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: var(--sw, #ddd);
  border: 1px solid rgba(28, 28, 28, 0.12);
  flex: 0 0 auto;
}

.pl-current__meta {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.pl-current__hex {
  font-family: ui-monospace, "SF Mono", "Cascadia Mono", Consolas, monospace;
  font-size: 16px;
  font-weight: 600;
  color: #1c1c1c;
}

.pl-current__rgb {
  font-family: ui-monospace, "SF Mono", "Cascadia Mono", Consolas, monospace;
  font-size: 12px;
  color: #5f5f5d;
}

/* ── 代码导出面板 ── */
.pl-code__row {
  display: flex;
  gap: 10px;
  margin-top: 6px;
}
.pl-code__row .cv-select {
  flex: 1 1 0;
  min-width: 0;
}

.pl-code__out {
  margin: 10px 0 0;
  padding: 12px 14px;
  max-height: 180px;
  overflow: auto;
  font-family: ui-monospace, "SF Mono", "Cascadia Mono", Consolas, monospace;
  font-size: 12px;
  line-height: 1.6;
  color: #1c1c1c;
  background: #f7f4ed;
  border: 1px solid #dcd8cc;
  border-radius: 10px;
  white-space: pre;
  tab-size: 2;
  user-select: text;
}
.pl-code__out:focus-visible {
  outline: 2px solid rgba(28, 28, 28, 0.9);
  outline-offset: 2px;
}

#pl-btn-copy-code {
  margin-top: 10px;
}

/* ── 重新提取按钮（自带样式，不依赖 .compress-actions 作用域） ── */
#pl-btn-extract {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: #f7f4ed;
  border: 1px solid #dcd8cc;
  border-radius: 10px;
  color: #1c1c1c;
  padding: 10px 14px;
  font-size: 13.5px;
  cursor: pointer;
  transition: background 0.15s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.15s cubic-bezier(0.16, 1, 0.3, 1);
}
#pl-btn-extract:hover:not(:disabled) {
  background: #f1eee6;
}
#pl-btn-extract:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}
#pl-btn-extract:focus-visible {
  outline: 2px solid rgba(28, 28, 28, 0.9);
  outline-offset: 2px;
}

/* ── 数字/勾选行（自包含） ── */
.pl-check {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: #5f5f5d;
  cursor: pointer;
  user-select: none;
}
.pl-check input {
  width: 15px;
  height: 15px;
  accent-color: #1c1c1c;
  cursor: pointer;
}

.pl-hint {
  font-size: 12px;
  color: rgba(28, 28, 28, 0.62);
  line-height: 1.6;
  margin: 8px 0 0;
}

/* ── 调和建议区 ── */
.pl-harmony__ctl {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}
.pl-harmony__ctl .cv-select {
  flex: 1 1 0;
  min-width: 0;
}

.pl-harmony__base {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
  font-size: 13px;
  color: #5f5f5d;
  cursor: pointer;
  user-select: none;
}
.pl-harmony__base input[type=color] {
  width: 34px;
  height: 34px;
  padding: 0;
  border: 1px solid #dcd8cc;
  border-radius: 8px;
  background: none;
  cursor: pointer;
}
.pl-harmony__base input[type=color]::-webkit-color-swatch-wrapper {
  padding: 3px;
}
.pl-harmony__base input[type=color]::-webkit-color-swatch {
  border: none;
  border-radius: 5px;
}
.pl-harmony__base input[type=color]::-moz-color-swatch {
  border: none;
  border-radius: 5px;
}

/* 建议色块：点击加入取色记录 */
.pl-sw--add .pl-sw__block {
  height: 48px;
}
.pl-sw--add .pl-sw__add {
  margin-top: auto;
}

.pl-sw__add {
  font-size: 11.5px;
  color: rgba(28, 28, 28, 0.62);
  padding: 5px 10px 9px;
  border-top: 1px dashed #dcd8cc;
  margin-top: 6px;
  text-align: center;
  transition: color 0.15s cubic-bezier(0.16, 1, 0.3, 1);
}

.pl-sw--add:hover .pl-sw__add {
  color: #1c1c1c;
}

/* ── 鲜艳度/明度过滤控件 ── */
.pl-range__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  margin: 8px 0 2px;
}

.pl-range__lab {
  font-size: 12.5px;
  color: #5f5f5d;
}

.pl-range__val {
  font-family: ui-monospace, "SF Mono", "Cascadia Mono", Consolas, monospace;
  font-size: 12px;
  font-weight: 600;
  color: #1c1c1c;
}

/* 明度区间双把手：上下堆叠两根滑条组成一个可拖动区间 */
.pl-dual {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.pl-dual .control-slider + .control-slider {
  margin-top: 2px;
}

/*# sourceMappingURL=palette.css.map */
