/* SPDX-FileCopyrightText: 2026 Wonmor and Tilo contributors */
/* SPDX-License-Identifier: Apache-2.0 */
/* Tilo motion. One state at a time: data-state on the svg element = intro | idle | listening | captioning | connecting | loading | transition.
   Parts: .t-l (left half), .t-r (right half), .t-d (dot), .t-all (group). Coordinates: 512 artboard. */
.tilo-motion .t-l,.tilo-motion .t-r,.tilo-motion .t-d,.tilo-motion .t-all{transform-box:view-box}
.tilo-motion .t-l{transform-origin:132px 264px}
.tilo-motion .t-r{transform-origin:288px 264px}
.tilo-motion .t-d{transform-origin:444px 172px}
.tilo-motion .t-all{transform-origin:132px 264px}
.tilo-motion[data-state="intro"] .t-l{animation:tilo-in-l 760ms cubic-bezier(.16,1,.3,1) both}
.tilo-motion[data-state="intro"] .t-r{animation:tilo-in-r 760ms cubic-bezier(.16,1,.3,1) both}
.tilo-motion[data-state="intro"] .t-d{animation:tilo-in-d 520ms cubic-bezier(.34,1.56,.64,1) 560ms both}
@keyframes tilo-in-l{from{transform:translate(-70px,0) rotate(-180deg);opacity:0}to{transform:none;opacity:1}}
@keyframes tilo-in-r{from{transform:translate(70px,0) rotate(-180deg);opacity:0}to{transform:none;opacity:1}}
@keyframes tilo-in-d{from{transform:translate(0,-90px) scale(.2);opacity:0}to{transform:none;opacity:1}}
.tilo-motion[data-state="idle"] .t-l{animation:tilo-idle-l 4800ms cubic-bezier(.37,0,.63,1) infinite}
.tilo-motion[data-state="idle"] .t-r{animation:tilo-idle-r 4800ms cubic-bezier(.37,0,.63,1) infinite}
.tilo-motion[data-state="idle"] .t-d{animation:tilo-idle-d 4800ms cubic-bezier(.37,0,.63,1) infinite}
@keyframes tilo-idle-l{50%{transform:translate(-5px,0)}}
@keyframes tilo-idle-r{50%{transform:translate(5px,0)}}
@keyframes tilo-idle-d{50%{transform:translate(0,-6px)}}
.tilo-motion[data-state="listening"] .t-l{animation:tilo-level 900ms cubic-bezier(.37,0,.63,1) infinite}
.tilo-motion[data-state="listening"] .t-r{animation:tilo-level 900ms cubic-bezier(.37,0,.63,1) 150ms infinite}
.tilo-motion[data-state="listening"] .t-d{animation:tilo-pulse 900ms cubic-bezier(.37,0,.63,1) infinite}
@keyframes tilo-level{25%{transform:scale(1,.78)}50%{transform:scale(1,1.08)}75%{transform:scale(1,.9)}}
@keyframes tilo-pulse{50%{transform:scale(1.3)}}
.tilo-motion[data-state="captioning"] .t-d{animation:tilo-cursor 1000ms steps(1,end) infinite}
.tilo-motion[data-state="captioning"] .t-l{animation:tilo-type-l 1000ms cubic-bezier(.37,0,.63,1) infinite}
.tilo-motion[data-state="captioning"] .t-r{animation:tilo-type-r 1000ms cubic-bezier(.37,0,.63,1) infinite}
@keyframes tilo-cursor{0%{opacity:1}50%{opacity:.12}}
@keyframes tilo-type-l{50%{transform:translate(-3px,0)}}
@keyframes tilo-type-r{50%{transform:translate(3px,0)}}
.tilo-motion[data-state="connecting"] .t-l{animation:tilo-conn-l 1800ms cubic-bezier(.65,0,.35,1) infinite}
.tilo-motion[data-state="connecting"] .t-r{animation:tilo-conn-r 1800ms cubic-bezier(.65,0,.35,1) infinite}
.tilo-motion[data-state="connecting"] .t-d{animation:tilo-conn-d 1800ms cubic-bezier(.65,0,.35,1) infinite}
@keyframes tilo-conn-l{0%,30%{transform:rotate(0)}70%,100%{transform:rotate(360deg)}}
@keyframes tilo-conn-r{0%{transform:translate(0,0) rotate(0)}30%{transform:translate(-156px,0) rotate(0)}70%{transform:translate(-156px,0) rotate(360deg)}100%{transform:translate(0,0) rotate(360deg)}}
@keyframes tilo-conn-d{0%,100%{transform:none}30%,70%{transform:translate(-312px,92px) scale(.55)}}
.tilo-motion[data-state="loading"] .t-r{transform:translate(-156px,0)}
.tilo-motion[data-state="loading"] .t-d{transform:translate(-312px,92px) scale(.55);animation:tilo-load-d 1200ms cubic-bezier(.37,0,.63,1) infinite}
.tilo-motion[data-state="loading"] .t-all{animation:tilo-spin 1200ms linear infinite}
@keyframes tilo-spin{to{transform:rotate(360deg)}}
@keyframes tilo-load-d{50%{transform:translate(-312px,92px) scale(.7)}}
.tilo-motion[data-state="transition"] .t-l{animation:tilo-tr-l 700ms cubic-bezier(.65,0,.35,1) both}
.tilo-motion[data-state="transition"] .t-r{animation:tilo-tr-r 700ms cubic-bezier(.65,0,.35,1) both}
.tilo-motion[data-state="transition"] .t-d{animation:tilo-tr-d 700ms cubic-bezier(.65,0,.35,1) both}
@keyframes tilo-tr-l{50%{transform:translate(-24px,0);opacity:0}}
@keyframes tilo-tr-r{50%{transform:translate(24px,0);opacity:0}}
@keyframes tilo-tr-d{50%{transform:translate(0,-40px);opacity:0}}
/* Wordmark: written as one stroke, the o closes from two halves, the i-dot lands last. */
.tilo-motion .w-ti,.tilo-motion .w-t-bar,.tilo-motion .w-l,.tilo-motion .w-o-top,.tilo-motion .w-o-bottom{stroke-dasharray:1 1}
.tilo-motion[data-state="intro"] .w-ti{animation:tilo-draw 640ms cubic-bezier(.65,0,.35,1) 200ms both}
.tilo-motion[data-state="intro"] .w-t-bar{animation:tilo-draw 260ms cubic-bezier(.65,0,.35,1) 640ms both}
.tilo-motion[data-state="intro"] .w-l{animation:tilo-draw 300ms cubic-bezier(.65,0,.35,1) 760ms both}
.tilo-motion[data-state="intro"] .w-o-top,.tilo-motion[data-state="intro"] .w-o-bottom{animation:tilo-draw 520ms cubic-bezier(.65,0,.35,1) 880ms both}
.tilo-motion[data-state="intro"] .w-i-dot{transform-box:fill-box;transform-origin:50% 50%;animation:tilo-in-d 520ms cubic-bezier(.34,1.56,.64,1) 1250ms both}
@keyframes tilo-draw{from{stroke-dashoffset:1}to{stroke-dashoffset:0}}
.tilo-motion[data-state="idle"] .w-i-dot,.tilo-motion[data-state="captioning"] .w-i-dot{animation:tilo-cursor 1000ms steps(1,end) 3 both}
@media (prefers-reduced-motion:reduce){
.tilo-motion *{animation:none!important}
.tilo-motion[data-state="loading"] .t-d{animation:tilo-cursor 1600ms steps(1,end) infinite!important}
}
