:root {
  --bg: #ffffff;
  --ink: #17171a;
  --soft: rgba(23, 23, 26, 0.58);
  --line: rgba(23, 23, 26, 0.1);
  --floor: #eeeef1;
  --accent: #f0a01e;
}

*, *::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: 10px 12px;
}
button { font: inherit; color: inherit; border: 0; background: none; cursor: pointer; outline: none; touch-action: manipulation; -webkit-tap-highlight-color: transparent; }
.live { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

.se { position: relative; display: grid; grid-template-columns: minmax(0, 1fr); gap: 10px; width: min(348px, 100%); padding: 14px 16px 16px; border-radius: 26px; background: #ffffff; box-shadow: inset 0 0 0 1.500px var(--line), 0 30px 44px -30px rgba(23, 23, 26, 0.4); }
.se__head { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 0 0 0 2px; }
.se__head strong { font-size: 16px; line-height: 20px; font-weight: 740; letter-spacing: -0.01em; }
.se__copy { display: flex; align-items: center; gap: 6px; height: 30px; padding: 0 12px 0 10px; border-radius: 15px; font-size: 12.500px; font-weight: 700; white-space: nowrap; box-shadow: inset 0 0 0 1.500px rgba(23, 23, 26, 0.16); }
.se__copy svg { display: block; width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 1.600; stroke-linecap: round; stroke-linejoin: round; }
.se__tick { stroke-width: 2; stroke-dasharray: 1; stroke-dashoffset: 1; }
.se__copyclip { display: block; height: 16px; line-height: 16px; overflow: hidden; }
.se__copyclip span { display: block; }
.se__copy.is-done { background: var(--ink); color: #ffffff; box-shadow: none; }

/* the floor the tile sits on: the light is dragged anywhere over it */
.se__view { position: relative; height: min(124px, 30vh); border-radius: 18px; background: var(--floor); box-shadow: inset 0 0 0 1px rgba(23, 23, 26, 0.04); overflow: hidden; touch-action: none; cursor: crosshair; }
.se__ray { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.se__ray line { stroke: var(--ink); stroke-opacity: 0.22; stroke-width: 1; stroke-dasharray: 2 4; stroke-linecap: round; }
.se__lift { position: absolute; left: 50%; top: 50%; width: 64px; height: 64px; margin: -32px 0 0 -32px; pointer-events: none; }
.se__tile { width: 100%; height: 100%; border-radius: 18px; background: #ffffff; }
.se__sun { position: absolute; left: 0; top: 0; width: 44px; height: 44px; margin: -22px 0 0 -22px; display: grid; place-items: center; border-radius: 50%; cursor: grab; touch-action: none; }
.se__sun.is-held { cursor: grabbing; }
.se__knob { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: #ffffff; color: var(--accent); box-shadow: inset 0 0 0 1.500px rgba(23, 23, 26, 0.08), 0 6px 10px -4px rgba(23, 23, 26, 0.35), 0 0 0 5px color-mix(in srgb, var(--accent) 16%, transparent); transition: box-shadow 0.25s ease; }
.se__sun.is-held .se__knob { box-shadow: inset 0 0 0 1.500px rgba(23, 23, 26, 0.08), 0 10px 14px -6px rgba(23, 23, 26, 0.4), 0 0 0 8px color-mix(in srgb, var(--accent) 22%, transparent); }
.se__knob svg { display: block; width: 18px; height: 18px; fill: currentColor; stroke: currentColor; stroke-width: 1.700; stroke-linecap: round; }
.se__sun:focus-visible .se__knob { box-shadow: 0 0 0 2px #ffffff, 0 0 0 4px var(--ink); }

.se__row { display: grid; grid-template-columns: 66px minmax(0, 1fr) auto; align-items: center; gap: 10px; height: 30px; padding: 0 2px; }
.se__name { font-size: 12.500px; font-weight: 680; color: var(--soft); white-space: nowrap; }
.se__val { min-width: 22px; text-align: right; font-size: 12.500px; font-weight: 700; font-variant-numeric: tabular-nums; }
.se__range { --p: 60%; -webkit-appearance: none; appearance: none; display: block; width: 100%; height: 30px; background: transparent; cursor: pointer; outline: none; touch-action: pan-y; }
.se__range::-webkit-slider-runnable-track { height: 4px; border-radius: 2px; background: linear-gradient(to right, var(--ink) var(--p), rgba(23, 23, 26, 0.14) var(--p)); }
.se__range::-moz-range-track { height: 4px; border-radius: 2px; background: linear-gradient(to right, var(--ink) var(--p), rgba(23, 23, 26, 0.14) var(--p)); }
.se__range::-webkit-slider-thumb { -webkit-appearance: none; width: 18px; height: 18px; margin-top: -7px; border-radius: 50%; background: #ffffff; box-shadow: inset 0 0 0 1.500px var(--ink), 0 4px 8px -3px rgba(23, 23, 26, 0.45); }
.se__range::-moz-range-thumb { width: 18px; height: 18px; border: 0; border-radius: 50%; background: #ffffff; box-shadow: inset 0 0 0 1.500px var(--ink), 0 4px 8px -3px rgba(23, 23, 26, 0.45); }
.se__range:focus-visible::-webkit-slider-thumb { box-shadow: inset 0 0 0 1.500px var(--ink), 0 0 0 3px #ffffff, 0 0 0 5px var(--ink); }

.se__seg { position: relative; grid-column: 2 / 4; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); height: 30px; padding: 3px; border-radius: 15px; background: rgba(23, 23, 26, 0.06); }
.se__seg button { position: relative; z-index: 1; height: 24px; border-radius: 12px; font-size: 12.500px; font-weight: 700; font-variant-numeric: tabular-nums; color: var(--soft); transition: color 0.2s ease; }
.se__seg button[aria-checked="true"] { color: var(--ink); }
.se__seg button:focus-visible { box-shadow: 0 0 0 2px var(--ink); }
.se__thumb { position: absolute; left: 3px; top: 3px; width: calc((100% - 6px) / 3); height: 24px; border-radius: 12px; background: #ffffff; box-shadow: 0 1px 0 rgba(23, 23, 26, 0.06), 0 4px 8px -4px rgba(23, 23, 26, 0.35); }

.se__code { display: grid; grid-template-columns: minmax(0, 1fr); padding: 9px 12px 10px; border-radius: 14px; background: #17171a; color: rgba(255, 255, 255, 0.92); font-family: ui-monospace, "SF Mono", SFMono-Regular, Menlo, Consolas, monospace; font-size: 11px; line-height: 15px; font-variant-numeric: tabular-nums; white-space: pre; overflow: hidden; }
.se__prop { display: block; color: rgba(255, 255, 255, 0.5); }
.se__line { display: block; height: 15px; overflow: hidden; text-overflow: ellipsis; }
.se__line b { font-weight: inherit; color: color-mix(in srgb, var(--accent) 70%, #ffffff); }

.ghost { position: absolute; left: 0; top: 0; width: 24px; height: 24px; margin: -3px 0 0 -5px; transform-origin: 20% 15%; pointer-events: none; opacity: 0; fill: #17171a; stroke: #ffffff; stroke-width: 1.300; stroke-linejoin: round; filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3)); z-index: 6; }

@media (hover: hover) { .se__copy:not(.is-done):hover { box-shadow: inset 0 0 0 1.500px var(--ink); } }
@media (max-width: 350px) { .se { padding: 12px 13px 14px; } .se__code { font-size: 10.500px; padding: 9px 10px 10px; } .se__row { grid-template-columns: 60px minmax(0, 1fr) auto; gap: 8px; } }
@media (max-height: 400px) { .se { gap: 8px; } .se__view { height: min(108px, 28vh); } }
.se__knob { transition: box-shadow 0.25s ease, transform 0.3s cubic-bezier(0.3, 1.6, 0.5, 1); }
.se__sun.is-held .se__knob { transform: scale(1.12); }
@media (prefers-reduced-motion: reduce) { .se__knob, .se__seg button { transition: none; } }
