html.agent-effect-building body {
  background: #fff;
  color: #222;
}

html.agent-effect-building a {
  color: #4d6208;
}

html.agent-effect-building a:hover {
  color: #263405;
}

html.agent-effect-building a:focus-visible {
  outline-color: #4d6208;
}

html.agent-effect-building h2 {
  border-color: rgba(85, 108, 30, .25);
}

.agent-effect-item {
  transition: opacity .22s ease;
}

.agent-effect-item.agent-effect-pending {
  opacity: 0;
  pointer-events: none;
}

.agent-effect-glyph {
  opacity: 0;
  transition: opacity .08s linear;
}

.agent-effect-glyph.is-typed {
  opacity: 1;
}

.agent-effect-sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.agent-effect-layer {
  position: fixed;
  inset: 0;
  z-index: 9998;
  overflow: hidden;
  pointer-events: none;
}

.agent-effect-canvas {
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle, rgba(91, 114, 41, .14) .75px, transparent 1px);
  background-size: 32px 32px;
  mask-image: linear-gradient(to bottom, transparent 1%, #000 20%, #000 80%, transparent 99%);
  animation: agent-canvas-in .8s ease both;
}

.agent-effect-trails {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: visible;
}

.agent-effect-trail {
  fill: none;
  stroke-width: 1.5;
  stroke-dasharray: 3 7;
  stroke-linecap: round;
  animation: agent-trail-fade 1.1s ease-out forwards;
}

.agent-effect-cursor {
  position: absolute;
  top: 0;
  left: 0;
  width: 20px;
  height: 26px;
  filter: drop-shadow(0 2px 3px rgba(20, 31, 47, .2));
  opacity: 0;
  transition: transform .42s cubic-bezier(.2, .75, .25, 1), opacity .18s ease;
  will-change: transform;
}

.agent-effect-cursor.is-visible {
  opacity: 1;
}

.agent-effect-cursor svg {
  display: block;
  width: 100%;
  height: 100%;
}

.agent-effect-selection {
  position: absolute;
  top: 0;
  left: 0;
  border: 1px solid var(--agent-color);
  background: var(--agent-tint);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, .85), 0 0 18px var(--agent-tint);
  opacity: 0;
  transition: opacity .18s ease;
}

.agent-effect-selection::before,
.agent-effect-selection::after {
  position: absolute;
  width: 5px;
  height: 5px;
  background: #fff;
  border: 1px solid var(--agent-color);
  content: "";
}

.agent-effect-selection::before { top: -4px; left: -4px; }
.agent-effect-selection::after { right: -4px; bottom: -4px; }
.agent-effect-selection.is-visible { opacity: 1; }

.agent-effect-caret {
  position: absolute;
  top: 0;
  left: 0;
  width: 2px;
  min-height: 13px;
  background: var(--agent-color);
  box-shadow: 0 0 5px var(--agent-color);
  opacity: 0;
}

.agent-effect-caret.is-visible {
  opacity: 1;
  animation: agent-caret-blink .7s steps(2, start) infinite;
}

.agent-effect-pulse {
  position: absolute;
  width: 15px;
  height: 15px;
  margin: -7px 0 0 -7px;
  border: 1px solid var(--agent-color);
  border-radius: 50%;
  animation: agent-pulse .6s ease-out forwards;
}

.agent-effect-progress {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  height: 3px;
  overflow: hidden;
  background: rgba(87, 116, 24, .08);
}

.agent-effect-progress span {
  display: block;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, #4d650e, #88b51e 48%, #c6f432);
  transform: scaleX(0);
  transform-origin: left;
}

@keyframes agent-canvas-in { from { opacity: 0; } to { opacity: 1; } }
@keyframes agent-trail-fade { 0% { opacity: .75; } 100% { opacity: 0; stroke-dashoffset: -24; } }
@keyframes agent-caret-blink { to { opacity: .25; } }
@keyframes agent-pulse { to { transform: scale(2.8); opacity: 0; } }

@media (max-width: 600px) {
  .agent-effect-canvas { background-size: 28px 28px; }
  .agent-effect-cursor { width: 19px; height: 25px; }
}
