:root {
  --bg: #ffffff;
  --card: #ffffff;
  --ink: #15171a;
  --soft: rgba(21, 23, 26, 0.5);
  --line: rgba(21, 23, 26, 0.09);
  --accent: #17b26a;
  --ok: 0; /* 0 waiting, 1 verified: the script moves it */
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; }
body {
  background: var(--bg);
  color: var(--ink);
  font-family: "Mona Sans Variable", "Mona Sans", system-ui, -apple-system, sans-serif;
  -webkit-font-smoothing: antialiased;
  overflow: hidden;
}

.stage {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  place-items: center;
  padding: 12px 16px;
}

.cp {
  width: min(320px, 100%);
  padding: 13px 14px 11px;
  border-radius: 24px;
  background: var(--card);
  box-shadow:
    0 0 0 1px rgba(21, 23, 26, 0.07),
    0 1px 2px rgba(21, 23, 26, 0.05),
    0 14px 28px -12px rgba(21, 23, 26, 0.16),
    0 44px 70px -34px rgba(21, 23, 26, 0.3);
}
.cp__head { display: flex; align-items: center; justify-content: space-between; height: 26px; }
.cp__title { font-size: 15px; font-weight: 680; font-stretch: 108%; letter-spacing: -0.008em; }
.cp__new {
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border: 0;
  border-radius: 50%;
  background: rgba(21, 23, 26, 0.055);
  color: var(--ink);
  cursor: pointer;
  outline: none;
  -webkit-tap-highlight-color: transparent;
}
.cp__new svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 1.600; stroke-linecap: round; stroke-linejoin: round; }
.cp__new:focus-visible { box-shadow: 0 0 0 2px #ffffff, 0 0 0 4px var(--ink); }

.cp__art { position: relative; margin-top: 9px; border-radius: 15px; overflow: hidden; box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.08); }
.cp__art svg { display: block; width: 100%; height: auto; max-height: 40vh; }
.cp__lines path { fill: none; stroke: rgba(255, 255, 255, 0.34); stroke-width: 1; }
.cp__hole { fill: rgba(8, 10, 20, 0.5); stroke: rgba(255, 255, 255, 0.5); stroke-width: 1; }
.cp__edge { fill: none; stroke: rgba(255, 255, 255, 0.9); stroke-width: 1.200; }
.cp__sheen {
  position: absolute;
  inset: 0;
  background: linear-gradient(105deg, transparent 38%, rgba(255, 255, 255, 0.5) 50%, transparent 62%);
  pointer-events: none;
}

.cp__track {
  position: relative;
  height: 46px;
  margin-top: 10px;
  border-radius: 14px;
  background: color-mix(in srgb, var(--accent) calc(var(--ok) * 12%), rgba(21, 23, 26, 0.055));
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--accent) calc(var(--ok) * 45%), rgba(21, 23, 26, 0.06));
  overflow: hidden;
}
.cp__fill {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 0;
  border-radius: 14px;
  background: color-mix(in srgb, var(--accent) calc(10% + var(--ok) * 12%), rgba(21, 23, 26, 0.07));
}
.cp__hint {
  position: absolute;
  inset: 0 12px 0 52px;
  display: grid;
  place-items: center;
  overflow: hidden;
  font-size: 13px;
  font-weight: 560;
  color: color-mix(in srgb, var(--accent) calc(var(--ok) * 78%), var(--soft));
  pointer-events: none;
}
.cp__hint span { display: block; white-space: nowrap; }
.cp__knob {
  position: absolute;
  left: 4px;
  top: 4px;
  display: grid;
  place-items: center;
  width: 44px;
  height: 38px;
  border-radius: 11px;
  background: color-mix(in srgb, var(--accent) calc(var(--ok) * 100%), #ffffff);
  color: color-mix(in srgb, #ffffff calc(var(--ok) * 100%), var(--ink));
  box-shadow: 0 0 0 1px rgba(21, 23, 26, 0.07), 0 1px 2px rgba(21, 23, 26, 0.1), 0 6px 12px -4px rgba(21, 23, 26, 0.25);
  pointer-events: none;
}
.cp__knob svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.800; stroke-linecap: round; stroke-linejoin: round; overflow: visible; }
.cp__tick { stroke-dasharray: 1; stroke-dashoffset: 1; stroke-width: 2.200; }
.cp__range {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  opacity: 0;
  cursor: grab;
  touch-action: pan-y;
  -webkit-tap-highlight-color: transparent;
}
.cp__range:active { cursor: grabbing; }
.cp__track:has(.cp__range:focus-visible) { box-shadow: inset 0 0 0 2px var(--ink); }
.cp.is-done .cp__range { pointer-events: none; }
.cp__foot { margin-top: 8px; font-size: 11px; font-weight: 480; color: var(--soft); text-align: center; }

.ghost {
  position: fixed;
  left: 0;
  top: 0;
  width: 22px;
  height: 22px;
  pointer-events: none;
  fill: #15171a;
  stroke: #ffffff;
  stroke-width: 1.4;
  stroke-linejoin: round;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
  opacity: 0;
  visibility: hidden;
  z-index: 5;
}

@media (hover: hover) {
  .cp__new:hover { background: rgba(21, 23, 26, 0.1); }
}
