/* ── Doodle Trace ─────────────────────────────────────────────────────────
   The whole game in one stroke: a target shape shown once, traced over
   before its guide fades away. Drawn as a plain two-segment peak (a single
   line doodle, not a board or a scribble) — one segment already retraced
   solid, the other still just dashed guide. Amber is the game's own fading
   signal (display/games/doodletrace: timer bar gradient #F59E0B → #E11D48);
   green is its own scored-correct color (phone/games/doodletrace:
   .dtr-check and the best-attempt canvas border, both #22C55E). */
.game-art--doodletrace { --ga-trace: #22C55E; }
/* The retraced segment gets a small sine wobble along its length (clip-path
   ribbon, since a straight div can't bend) — a real hand's retrace is never
   perfectly straight, and it keeps this stroke visually distinct from the
   dead-straight dashed guide underneath it. */
.game-art--doodletrace .ga-l1 {
  --x: 25%; --y: 75%; --len: 35.4%; --rot: -45deg;
  height: 18%;
  clip-path: polygon(
    0% 32%, 12.5% 46.1%, 25% 52%, 37.5% 46.1%, 50% 32%,
    62.5% 17.9%, 75% 12%, 87.5% 17.9%, 100% 32%,
    100% 68%, 87.5% 53.9%, 75% 48%, 62.5% 53.9%, 50% 68%,
    37.5% 82.1%, 25% 88%, 12.5% 82.1%, 0% 68%
  );
}

.game-art--doodletrace .dtr-guide {
  position: absolute;
  height: max(1px, 3.2cqmin);
  border-top: max(1px, 3.2cqmin) dashed color-mix(in srgb, #F59E0B 65%, transparent);
  transform-origin: 0 50%;
}
.game-art--doodletrace .dtr-g1 { left: 25%; top: 75%; width: 35.4%; transform: rotate(-45deg); }
.game-art--doodletrace .dtr-g2 { left: 50%; top: 50%; width: 35.4%; transform: rotate(45deg); }

.game-art--doodletrace .dtr-pen {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 12%;
  height: 12%;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background: #22C55E;
  z-index: 3;
}
.game-art--doodletrace .dtr-end {
  position: absolute;
  left: 75%;
  top: 75%;
  width: 10%;
  height: 10%;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background: transparent;
  border: max(1px, 2.6cqmin) dashed color-mix(in srgb, #F59E0B 65%, transparent);
  z-index: 2;
}
/* Thumbnail tier: the hollow "still to reach" dot is the fine detail —
   what has to survive small is "a peak, half solid" alone. */
@container ga-stage (max-width: 70px) {
  .game-art--doodletrace .dtr-end { display: none; }
}
