/* Contact robot that flies to a field with a problem (/js/contact-guide.js). */
#contact-form { position: relative; }
.ya-guide { position: absolute; left: 0; top: 0; width: 62px; height: 62px; z-index: 5; pointer-events: none;
  transform-origin: 50% 50%; visibility: hidden; }
@media (max-width: 480px) { .ya-guide { width: 52px; height: 52px; } }
.ya-guide.is-on { visibility: visible; }
.ya-guide-bot { display: block; width: 100%; height: 100%; overflow: visible; }
/* faces the field (the drawing faces right by default) */
.ya-guide-face { transition: transform .25s ease; }
.ya-guide.is-left .ya-guide-face { transform: scale(-1, 1); }
.ya-guide-lean { transition: transform .35s cubic-bezier(.3, 1.6, .5, 1); }
.ya-guide.is-pointing .ya-guide-lean { transform: rotate(14deg) translate(0, 4px); }
.ya-guide.is-pointing .ya-guide-bot { animation: ya-guide-bob 1.6s ease-in-out .35s infinite; }
@keyframes ya-guide-bob { 50% { transform: translateY(-3px); } }
/* "!" above its head */
.ya-guide-mark { opacity: 0; transform: translate(-30px, -50px) scale(.2); transition: opacity .15s, transform .3s cubic-bezier(.3, 1.8, .5, 1); }
.ya-guide.is-pointing .ya-guide-mark { opacity: 1; transform: translate(-30px, -50px) scale(1); }
.ya-guide-mark circle { fill: #ff9f01; }
.ya-guide-mark text { font: 700 22px Arial, Helvetica, sans-serif; fill: #203335; }
/* speech bubble, on the field, pointing to the robot */
.ya-guide-bubble { position: absolute; right: calc(100% + 2px); top: 50%; width: max-content; max-width: 260px;
  padding: 8px 12px; border-radius: 12px; background: #203335; color: #fffaf0;
  font: 600 14px/1.35 Arial, Helvetica, sans-serif; text-align: left;
  opacity: 0; transform: translateY(-50%) scale(.8); transform-origin: 100% 50%;
  transition: opacity .18s ease, transform .28s cubic-bezier(.3, 1.6, .5, 1); }
.ya-guide-bubble::after { content: ""; position: absolute; right: -6px; top: 50%; margin-top: -6px;
  border: 6px solid transparent; border-right: 0; border-left-color: #203335; }
.ya-guide.is-pointing .ya-guide-bubble { opacity: 1; transform: translateY(-50%) scale(1); }
html[data-theme="dark"] .ya-guide-bubble { background: #fffaf0; color: #203335; }
html[data-theme="dark"] .ya-guide-bubble::after { border-left-color: #fffaf0; }
@media (prefers-reduced-motion: reduce) {
  .ya-guide *, .ya-guide-bubble { transition: none !important; animation: none !important; }
}

/* Message sent: green "✓ Sent!" bubble next to the robot, a few sparks */
.ya-sent { position: absolute; width: 0; height: 0; z-index: 5; pointer-events: none; }
.ya-sent-bubble { position: absolute; top: 0; display: flex; align-items: center; gap: 9px; white-space: nowrap;
  padding: 8px 18px 8px 9px; border-radius: 999px; background: #e6f4ea; color: #1d4d33; border: 1px solid #9fd3b0;
  font: 700 19px/1.2 Arial, Helvetica, sans-serif; box-shadow: 0 4px 14px rgba(29, 77, 51, .15);
  opacity: 0; transform: translateY(-50%) scale(.5); transform-origin: 100% 50%;
  transition: opacity .2s ease .3s, transform .45s cubic-bezier(.3, 1.7, .5, 1) .3s; }
.ya-sent.is-on .ya-sent-bubble { opacity: 1; transform: translateY(-50%) scale(1); }
.ya-sent-bubble svg { width: 32px; height: 32px; flex: none; }
.ya-sent-bubble circle { fill: #2e9e5b; transform-origin: 12px 12px; transform: scale(.3); transition: transform .4s cubic-bezier(.3, 1.8, .5, 1) .05s; }
.ya-sent-bubble path { fill: none; stroke: #fff; stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round;
  stroke-dasharray: 18; stroke-dashoffset: 18; transition: stroke-dashoffset .35s ease .3s; }
.ya-sent.is-on circle { transform: scale(1); }
.ya-sent.is-on path { stroke-dashoffset: 0; }
html[data-theme="dark"] .ya-sent-bubble { background: #173528; color: #d8f3e1; border-color: #2e6b4a; }
.ya-spark { position: absolute; left: -4px; top: -4px; width: 8px; height: 8px; border-radius: 50%; background: #ff9f01; opacity: 0; }
.ya-spark:nth-of-type(2n) { background: #2e9e5b; }
.ya-sent.is-on .ya-spark { animation: ya-spark .85s ease-out var(--d) both; }
@keyframes ya-spark { 0% { opacity: 1; transform: translate(0, 0) scale(.6); } 70% { opacity: 1; } 100% { opacity: 0; transform: translate(var(--x), var(--y)) scale(1); } }
@media (prefers-reduced-motion: reduce) {
  .ya-sent-bubble, .ya-sent-bubble circle, .ya-sent-bubble path { transition: none !important; }
  .ya-spark { display: none; }
}
