.hlm {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--mf, #e4d2b0);
}

.hlm .mask-face {
  position: relative;
  width: 168px;
  height: 176px;
}

.hlm .mf-ink {
  position: absolute;
  left: 50%;
  top: 8px;
  z-index: 1;
  width: 112px;
  height: 148px;
  transform: translateX(-50%);
  background: var(--mf, #e4d2b0);
  -webkit-mask: url("/face-outline.svg") center / contain no-repeat;
  mask: url("/face-outline.svg") center / contain no-repeat;
  pointer-events: none;
}

.hlm .mask-corners {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.hlm .mask-scan {
  position: absolute;
  z-index: 3;
  left: 18px;
  right: 18px;
  height: 1.5px;
  background: linear-gradient(90deg, transparent, var(--mf, #e4d2b0) 20%, var(--mf, #e4d2b0) 80%, transparent);
  box-shadow: 0 0 10px rgba(var(--mf-rgb, 228, 210, 176), 0.55);
  animation: hlm-scan 2.2s ease-in-out infinite;
}

.hlm .mf-ring svg,
.hlm .mf-sight svg,
.hlm .mf-well svg {
  display: block;
}

.hlm .mf-ring svg { width: 150px; height: 192px; }
.hlm .mf-sight svg { width: 156px; height: 156px; }
.hlm .mf-well svg { width: 136px; height: 136px; }

.hlm .mf-ring-arc {
  filter: drop-shadow(0 0 4px rgba(var(--mf-rgb, 246, 239, 228), 0.75));
  animation: hlm-ring-arc 3.2s linear infinite;
}

.hlm .mf-ring-bar,
.hlm .mf-sight-bar {
  transform-box: fill-box;
  transform-origin: center;
}

.hlm .mf-ring-bar { animation: hlm-ring-scan 2.4s ease-in-out infinite; }
.hlm .mf-sight-bar { animation: hlm-sight 2.2s ease-in-out infinite; }

.hlm .mf-sector {
  transform-box: view-box;
  transform-origin: center;
  animation: hlm-spin 3.8s linear infinite;
}

.hlm .mf-band {
  position: relative;
  width: 168px;
  height: 108px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 16px;
  overflow: hidden;
}

.hlm .mf-band i {
  display: block;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--mf, #e4d2b0) 18%, var(--mf, #e4d2b0) 82%, transparent);
  animation: hlm-band 2.2s ease-in-out infinite;
}

.hlm .mf-band i:nth-child(2) {
  height: 5px;
  box-shadow: 0 0 16px rgba(var(--mf-rgb, 228, 210, 176), 0.65);
  animation-delay: 0.25s;
}

.hlm .mf-band i:nth-child(3) {
  opacity: 0.55;
  animation-delay: 0.5s;
}

.hlm .mf-pad {
  width: 132px;
  height: 132px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--mf, #e4d2b0);
  border-radius: 50%;
  background: radial-gradient(circle, rgba(var(--mf-rgb, 244, 239, 230), 0.08), transparent 72%);
  box-shadow: inset 0 0 0 1px rgba(var(--mf-rgb, 244, 239, 230), 0.22);
}

.hlm .mf-pad svg { width: 92px; height: 92px; display: block; }

.hlm .mf-sensor {
  position: relative;
  width: 148px;
  height: 148px;
  color: var(--mf, #e4d2b0);
}

.hlm .mf-sensor-ring,
.hlm .mf-sensor-print {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
}

.hlm .mf-sensor-ring { width: 148px; height: 148px; }
.hlm .mf-sensor-print { width: 76px; height: 76px; }

.hlm .mf-pulse {
  position: relative;
  width: 148px;
  height: 148px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hlm .mf-pulse i {
  position: absolute;
  inset: 18px;
  border-radius: 50%;
  border: 1px solid rgba(var(--mf-rgb, 228, 210, 176), 0.7);
  animation: hlm-pulse 2.6s ease-out infinite;
}

.hlm .mf-pulse i:nth-child(2) { animation-delay: 0.7s; }
.hlm .mf-pulse i:nth-child(3) { animation-delay: 1.4s; }

.hlm .mf-pulse b {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 8px;
  height: 8px;
  margin: -4px 0 0 -4px;
  border-radius: 50%;
  background: var(--mf, #e4d2b0);
}

.hlm-tpls {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.hlm-tpls button {
  min-height: 72px;
  padding: 8px 4px 6px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border-radius: 4px;
  border: 1px solid #2a241c;
  background: #000;
  color: #b7aa98;
  cursor: pointer;
}

.hlm-tpls button.is-on {
  border-color: #e4d2b0;
  color: #f4efe6;
}

.hlm-tpls button span {
  font-size: 12px;
  line-height: 1.2;
}

.hlm-thumb {
  display: block;
  box-sizing: border-box;
}

.hlm-thumb-frame {
  width: 28px;
  height: 32px;
  background:
    linear-gradient(#e4d2b0, #e4d2b0) 0 0 / 9px 2px no-repeat,
    linear-gradient(#e4d2b0, #e4d2b0) 0 0 / 2px 9px no-repeat,
    linear-gradient(#e4d2b0, #e4d2b0) 100% 0 / 9px 2px no-repeat,
    linear-gradient(#e4d2b0, #e4d2b0) 100% 0 / 2px 9px no-repeat,
    linear-gradient(#e4d2b0, #e4d2b0) 0 100% / 9px 2px no-repeat,
    linear-gradient(#e4d2b0, #e4d2b0) 0 100% / 2px 9px no-repeat,
    linear-gradient(#e4d2b0, #e4d2b0) 100% 100% / 9px 2px no-repeat,
    linear-gradient(#e4d2b0, #e4d2b0) 100% 100% / 2px 9px no-repeat;
}

.hlm-thumb-ring {
  width: 16px;
  height: 24px;
  border: 2.5px solid #c9b28a;
  border-right-color: rgba(201, 178, 138, 0.28);
  border-radius: 12px;
}

.hlm-thumb-gate {
  width: 24px;
  height: 24px;
  border: 1.5px solid #c9b28a;
  border-radius: 50%;
  background: conic-gradient(from -16deg, rgba(201, 178, 138, 0.95) 0 58deg, transparent 58deg);
}

.hlm-thumb-sweep {
  width: 26px;
  height: 26px;
  border: 1px solid #c9b28a;
  border-radius: 50%;
}

.hlm-thumb-arc {
  width: 26px;
  height: 22px;
  border: 1.5px solid #e4d2b0;
  border-bottom: 0;
  border-radius: 16px 16px 0 0;
}

.hlm-thumb-well {
  width: 26px;
  height: 26px;
  border: 2px solid #c9b28a;
  border-radius: 50%;
  box-shadow: inset 0 0 0 6px rgba(201, 178, 138, 0.28);
}

.hlm-thumb-seal {
  width: 24px;
  height: 24px;
  border: 1.5px solid #c9b28a;
  border-radius: 50%;
  background: radial-gradient(circle, transparent 42%, rgba(201, 178, 138, 0.85) 43% 48%, transparent 49%);
  box-shadow: inset 0 0 0 1px rgba(201, 178, 138, 0.35);
}

.hlm-thumb-pulse {
  width: 16px;
  height: 16px;
  border: 1.5px solid #c9b28a;
  border-radius: 50%;
  box-shadow: 0 0 0 4px rgba(201, 178, 138, 0.35);
}

.hlm-tints {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.hlm-tints button {
  width: 26px;
  height: 26px;
  padding: 0;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: var(--swatch);
  cursor: pointer;
}

.hlm-tints button.is-on {
  box-shadow: 0 0 0 2px #100e0c, 0 0 0 4px var(--swatch);
}

.hlm-mix {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 8px;
}

.hlm-mix > span {
  color: #b7aa98;
  font-size: 12px;
}

.hlm-sv {
  position: relative;
  height: 108px;
  border-radius: 6px;
  background: hsl(var(--hue, 39), 100%, 50%);
  cursor: crosshair;
  touch-action: none;
  user-select: none;
}

.hlm-sv::before,
.hlm-sv::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
}

.hlm-sv::before { background: linear-gradient(to right, #fff, transparent); }
.hlm-sv::after { background: linear-gradient(to top, #000, transparent); }

.hlm-sv i {
  position: absolute;
  z-index: 1;
  width: 14px;
  height: 14px;
  margin: -7px 0 0 -7px;
  border: 2px solid #fff;
  border-radius: 50%;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.65);
  pointer-events: none;
}

.hlm-mix input[type="range"] {
  width: 100%;
  height: 14px;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 7px;
  background: linear-gradient(to right, #f00, #ff0, #0f0, #0ff, #00f, #f0f, #f00);
  appearance: none;
  -webkit-appearance: none;
  cursor: pointer;
}

.hlm-mix input[type="range"]::-webkit-slider-thumb {
  appearance: none;
  -webkit-appearance: none;
  width: 16px;
  height: 16px;
  border: 2px solid #1a140c;
  border-radius: 50%;
  background: #fff;
}

.hlm-mix input[type="range"]::-moz-range-thumb {
  width: 16px;
  height: 16px;
  border: 2px solid #1a140c;
  border-radius: 50%;
  background: #fff;
}

@keyframes hlm-scan {
  0% { top: 18px; }
  50% { top: 148px; }
  100% { top: 18px; }
}

@keyframes hlm-ring-arc { to { stroke-dashoffset: -530; } }

@keyframes hlm-ring-scan {
  0% { transform: translateY(-64px); opacity: 0; }
  14% { opacity: 1; }
  86% { opacity: 1; }
  100% { transform: translateY(64px); opacity: 0; }
}

@keyframes hlm-sight {
  0% { transform: translateY(-42px); opacity: 0; }
  14% { opacity: 1; }
  86% { opacity: 1; }
  100% { transform: translateY(42px); opacity: 0; }
}

@keyframes hlm-band {
  0%, 100% { transform: translateX(-28%); opacity: 0.35; }
  50% { transform: translateX(28%); opacity: 1; }
}

@keyframes hlm-spin { to { transform: rotate(360deg); } }

@keyframes hlm-pulse {
  0% { transform: scale(0.62); opacity: 0.75; }
  100% { transform: scale(1.18); opacity: 0; }
}
