/**
 * Landing — agent / WhatsApp motion & visuals
 * Requires tokens.css + components.css
 */

.hero-orbit {
  position: absolute;
  inset: -12% -8%;
  background:
    radial-gradient(ellipse 55% 45% at 70% 40%, rgba(125, 211, 252, 0.18), transparent 60%),
    radial-gradient(ellipse 40% 35% at 20% 70%, rgba(200, 160, 240, 0.12), transparent 55%);
  pointer-events: none;
  z-index: 0;
}

.agent-stage {
  position: relative;
  isolation: isolate;
}

.agent-bot {
  width: min(280px, 70vw);
  height: auto;
  filter: drop-shadow(0 0 40px rgba(125, 211, 252, 0.25));
  animation: agent-float 5s ease-in-out infinite;
}

.agent-bot .visor {
  fill: rgba(125, 211, 252, 0.25);
  stroke: #7dd3fc;
}

.agent-bot .eye {
  fill: #7dd3fc;
  animation: agent-blink 4s ease-in-out infinite;
}

.agent-bot .ring {
  fill: none;
  stroke: rgba(125, 211, 252, 0.35);
  stroke-dasharray: 6 10;
  animation: agent-spin 18s linear infinite;
  transform-origin: center;
}

@keyframes agent-float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-14px); }
}

@keyframes agent-blink {
  0%, 92%, 100% { opacity: 1; }
  94%, 96% { opacity: 0.15; }
}

@keyframes agent-spin {
  to { transform: rotate(360deg); }
}

.wa-thread {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  max-width: 360px;
}

.wa-bubble {
  max-width: 90%;
  padding: 0.75rem 1rem;
  border-radius: 1rem;
  font-size: 0.8125rem;
  line-height: 1.45;
  animation: bubble-in 0.5s var(--ease-out) both;
}

.wa-bubble--lead {
  align-self: flex-start;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-top-left-radius: 0.25rem;
  color: var(--color-on-surface);
}

.wa-bubble--agent {
  align-self: flex-end;
  background: rgba(125, 211, 252, 0.12);
  border: 1px solid rgba(125, 211, 252, 0.28);
  border-top-right-radius: 0.25rem;
  color: #e8eef8;
}

.wa-bubble--agent .agent-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-family: var(--font-mono);
  font-size: 0.625rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-primary);
  margin-bottom: 0.35rem;
}

.wa-bubble:nth-child(1) { animation-delay: 0.1s; }
.wa-bubble:nth-child(2) { animation-delay: 0.45s; }
.wa-bubble:nth-child(3) { animation-delay: 0.85s; }
.wa-bubble:nth-child(4) { animation-delay: 1.2s; }

html.gsap-ready .wa-bubble {
  animation: none;
  opacity: 0;
}

html.gsap-ready .agent-bot {
  animation: none;
}

html.gsap-ready .hero-line {
  perspective: 600px;
}

@keyframes bubble-in {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.agent-card {
  position: relative;
  overflow: hidden;
  transition: border-color var(--duration-base) var(--ease-out),
    transform var(--duration-base) var(--ease-out);
}

.agent-card:hover {
  border-color: var(--border-primary-strong);
  transform: translateY(-4px);
}

.agent-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(125, 211, 252, 0.08), transparent 45%);
  pointer-events: none;
}

.agent-status {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--font-mono);
  font-size: 0.625rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #5eead4;
}

.agent-status::before {
  content: "";
  width: 0.45rem;
  height: 0.45rem;
  border-radius: 999px;
  background: #5eead4;
  box-shadow: 0 0 10px rgba(94, 234, 212, 0.7);
  animation: pulse-dot 2s ease-in-out infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.55; transform: scale(0.85); }
}

.flow-rail {
  position: relative;
}

.flow-rail::before {
  content: "";
  position: absolute;
  left: 1.15rem;
  top: 2.5rem;
  bottom: 2.5rem;
  width: 1px;
  background: linear-gradient(to bottom, transparent, rgba(125, 211, 252, 0.5), transparent);
}

@media (min-width: 768px) {
  .flow-rail::before {
    left: 0;
    right: 0;
    top: 2rem;
    bottom: auto;
    height: 1px;
    width: auto;
    background: linear-gradient(to right, transparent, rgba(125, 211, 252, 0.45), transparent);
  }
}

.stat-glow {
  text-shadow: 0 0 28px rgba(125, 211, 252, 0.35);
}

.section-kicker {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-primary);
}

.marquee {
  overflow: hidden;
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}

.marquee-track {
  display: flex;
  gap: 2.5rem;
  width: max-content;
  animation: marquee 28s linear infinite;
}

.marquee-track span {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--color-on-surface-muted);
  white-space: nowrap;
}

@keyframes marquee {
  to { transform: translateX(-50%); }
}

@media (prefers-reduced-motion: reduce) {
  .agent-bot,
  .agent-bot .eye,
  .agent-bot .ring,
  .wa-bubble,
  .agent-status::before,
  .marquee-track {
    animation: none !important;
  }
}
