/* Sage Universe: compact, readable analytics RPG surface. */
.sage-world {
  --sw-ink:#f8f3ff; --sw-muted:#cbc2df; --sw-quiet:#988dab; --sw-violet:#b88cff;
  --sw-mint:#64f1ce; --sw-gold:#ffd36a; --sw-coral:#ff839e; --sw-deep:#090b16;
  --sw-line:rgba(210,187,255,.26); --sw-surface:rgba(19,22,43,.98);
  --sw-safe-top:max(10px,env(safe-area-inset-top,0px)); --sw-safe-right:max(10px,env(safe-area-inset-right,0px)); --sw-safe-bottom:max(10px,env(safe-area-inset-bottom,0px)); --sw-safe-left:max(10px,env(safe-area-inset-left,0px));
  position:fixed; z-index:90; right:var(--sw-safe-right); bottom:var(--sw-safe-bottom); color:var(--sw-ink);
  font:500 14px/1.45 ui-rounded,"Avenir Next",Avenir,system-ui,sans-serif; letter-spacing:.01em;
}
.sage-world *,.sage-world *::before,.sage-world *::after{box-sizing:border-box}
.sage-world button,.sage-world a{font:inherit}.sage-world [hidden]{display:none!important}
.sage-world__dock{width:52px;min-width:44px;min-height:44px;display:grid;place-items:center;border:1px solid rgba(220,205,255,.45);border-radius:999px;color:var(--sw-ink);background:linear-gradient(145deg,#30235a,#121936);box-shadow:0 12px 28px rgba(1,2,12,.34);cursor:pointer}
.sage-world__dock::before{content:"✦";color:var(--sw-gold);font-size:21px;text-shadow:0 0 12px rgba(255,211,106,.72)}
.sage-world__dock:hover{border-color:var(--sw-mint);transform:translateY(-2px)}
.sage-world__dock:focus-visible,.sage-world :is(button,a,[tabindex]):focus-visible{outline:3px solid var(--sw-gold);outline-offset:3px}
.sage-world__panel{position:absolute;right:0;bottom:calc(100% + 10px);width:min(472px,calc(100vw - var(--sw-safe-left) - var(--sw-safe-right)));max-height:min(780px,calc(100dvh - var(--sw-safe-top) - var(--sw-safe-bottom) - 62px));overflow:auto;overscroll-behavior:contain;border:1px solid rgba(220,205,255,.38);border-radius:18px;background:var(--sw-surface);box-shadow:0 20px 44px rgba(0,0,0,.42);contain:layout paint}
.sage-world__panel::-webkit-scrollbar{width:10px}.sage-world__panel::-webkit-scrollbar-thumb{background:#544575;border-radius:20px;border:3px solid var(--sw-surface)}
.sage-world__header{position:sticky;top:0;z-index:20;display:grid;grid-template-columns:1fr auto;gap:8px;padding:15px 16px 12px;border-bottom:1px solid var(--sw-line);background:rgba(19,22,43,.98)}
.sage-world__eyebrow{margin:0;color:var(--sw-mint);font-size:10px;font-weight:800;letter-spacing:.13em;text-transform:uppercase}.sage-world__title{margin:2px 0 0;font-size:17px;line-height:1.16;letter-spacing:-.02em}.sage-world__active{margin:4px 0 0;color:var(--sw-muted);font-size:12px}
.sage-world__header-actions,.sage-world__controls{display:flex;align-items:center;gap:6px}
.sage-world__control,.sage-world__header button,.sage-world__quest-action{min-width:44px;min-height:44px;display:inline-grid;place-items:center;padding:8px 10px;border:1px solid var(--sw-line);border-radius:12px;color:var(--sw-ink);background:#202442;cursor:pointer}
.sage-world__control:hover,.sage-world__header button:hover,.sage-world__quest-action:hover{border-color:var(--sw-mint);background:#2a2e51}.sage-world__control[aria-pressed="true"],.sage-world__control.is-active{color:#0a1d1d;border-color:var(--sw-mint);background:var(--sw-mint)}
/* Layers animate only opacity and transforms. */
.sage-world__universe{position:relative;isolation:isolate;min-height:222px;height:clamp(222px,30vh,276px);overflow:hidden;border-bottom:1px solid var(--sw-line);background:radial-gradient(circle at 13% 28%,rgba(184,140,255,.25) 0 2px,transparent 3px),radial-gradient(circle at 79% 68%,rgba(100,241,206,.2) 0 1px,transparent 2px),radial-gradient(circle at 63% 18%,rgba(255,211,106,.25) 0 1px,transparent 2px),linear-gradient(150deg,#17132f 0%,#0b1024 47%,#11102a 100%);contain:layout paint}
.sage-world__universe::before,.sage-world__universe::after{position:absolute;inset:0;z-index:-3;content:"";pointer-events:none}.sage-world__universe::before{opacity:.55;background-image:radial-gradient(rgba(255,255,255,.68) 1px,transparent 1.6px),radial-gradient(rgba(184,140,255,.55) 1px,transparent 1.7px);background-position:6px 11px,29px 35px;background-size:47px 47px,71px 71px}.sage-world__universe::after{z-index:-2;opacity:.74;background:conic-gradient(from 215deg at 66% 49%,transparent 0 15%,rgba(100,241,206,.1) 19%,transparent 26% 58%,rgba(184,140,255,.13) 65%,transparent 76%);transform:scale(1.18);animation:sw-aurora 16s ease-in-out infinite alternate}
.sage-world__nebula,.sage-world__aurora{position:absolute;inset:-26% -18%;z-index:-1;pointer-events:none;opacity:.5;background:radial-gradient(ellipse at 30% 67%,rgba(255,131,158,.24),transparent 34%),radial-gradient(ellipse at 74% 28%,rgba(100,241,206,.21),transparent 30%);transform-origin:50% 50%;animation:sw-aurora 18s ease-in-out infinite alternate-reverse}
.sage-world__dust,.sage-world__star-dust{position:absolute;inset:0;z-index:1;pointer-events:none;opacity:.55;background-image:radial-gradient(circle,rgba(255,255,255,.9) 0 1px,transparent 1.5px);background-size:38px 38px;animation:sw-drift 17s linear infinite}
.sage-world__comet{position:absolute;z-index:2;top:20%;left:-18%;width:72px;height:2px;border-radius:99px;background:linear-gradient(90deg,transparent,rgba(255,255,255,.95));transform:rotate(-19deg);opacity:0;pointer-events:none;animation:sw-comet 13s ease-in-out infinite}.sage-world__comet:nth-of-type(2){top:72%;animation-delay:-7s;animation-duration:17s}
.sage-world__orbit{position:absolute;z-index:0;left:50%;top:51%;width:78%;height:56%;border:1px solid rgba(189,171,255,.24);border-radius:50%;transform:translate(-50%,-50%) rotate(-12deg);pointer-events:none}.sage-world__orbit--one{width:47%;height:35%;border-color:rgba(100,241,206,.26);animation:sw-orbit 20s linear infinite}.sage-world__orbit--two{width:104%;height:74%;border-style:dashed;opacity:.55;animation:sw-orbit 28s linear infinite reverse}
.sage-world__threads,.sage-world__constellation{position:absolute;inset:0;z-index:2;width:100%;height:100%;pointer-events:none;overflow:visible}.sage-world__threads :is(path,line),.sage-world__constellation :is(path,line){fill:none;stroke:rgba(184,140,255,.48);stroke-width:1.5;stroke-dasharray:3 6;vector-effect:non-scaling-stroke;animation:sw-thread 5s linear infinite}.sage-world__threads .is-hot,.sage-world__constellation .is-hot{stroke:var(--sw-gold);stroke-width:2}
/* Eight residents: 48px target, illustrated 30px face, halo and tail. */
.sage-world__sage{--sage-color:var(--sw-violet);--sage-glow:rgba(184,140,255,.62);position:absolute;z-index:5;width:48px;height:48px;min-width:44px;min-height:44px;margin:0;padding:0;border:0;border-radius:50%;color:var(--sw-ink);background:transparent;cursor:grab;touch-action:none;user-select:none;-webkit-user-select:none;transform:translate(-50%,-50%);transition:transform 180ms ease,opacity 180ms ease}
.sage-world__sage::before{position:absolute;left:9px;top:9px;width:30px;height:30px;content:"";border:2px solid rgba(255,255,255,.86);border-radius:50% 50% 45% 45%;background:radial-gradient(circle at 38% 46%,#15142c 0 1.5px,transparent 2px),radial-gradient(circle at 63% 46%,#15142c 0 1.5px,transparent 2px),radial-gradient(ellipse at 50% 67%,#15142c 0 2px,transparent 2.7px),radial-gradient(circle at 50% 40%,rgba(255,255,255,.58) 0 17%,transparent 18%),var(--sage-color);box-shadow:0 0 0 4px rgba(9,11,22,.72),0 0 0 6px var(--sage-glow)}
.sage-world__sage::after{position:absolute;left:33px;top:33px;width:20px;height:7px;content:"";border-radius:0 12px 12px 0;background:linear-gradient(90deg,var(--sage-color),transparent);opacity:.8;transform:rotate(-26deg);transform-origin:left center}
.sage-world__sage>:is(.sage-world__sage-halo,.sage-world__halo,.sage-world__ring){position:absolute;inset:2px;border:1px solid var(--sage-color);border-radius:50%;opacity:.8;pointer-events:none;animation:sw-halo 3.6s ease-in-out infinite}.sage-world__sage>:is(.sage-world__sage-face,.sage-world__face){display:none}.sage-world__sage>:is(.sage-world__sage-tail,.sage-world__tail){position:absolute;left:30px;top:31px;width:26px;height:8px;border-radius:50%;border-top:2px solid var(--sage-color);transform:rotate(-28deg);opacity:.85;pointer-events:none}
.sage-world__sage:nth-of-type(2),.sage-world__sage[data-sage="signal"]{--sage-color:#64f1ce;--sage-glow:rgba(100,241,206,.52)}.sage-world__sage:nth-of-type(3),.sage-world__sage[data-sage="orbit"]{--sage-color:#ffd36a;--sage-glow:rgba(255,211,106,.54)}.sage-world__sage:nth-of-type(4),.sage-world__sage[data-sage="pulse"]{--sage-color:#ff839e;--sage-glow:rgba(255,131,158,.54)}.sage-world__sage:nth-of-type(5),.sage-world__sage[data-sage="vector"]{--sage-color:#9db6ff;--sage-glow:rgba(157,182,255,.56)}.sage-world__sage:nth-of-type(6),.sage-world__sage[data-sage="prism"]{--sage-color:#ec9bff;--sage-glow:rgba(236,155,255,.54)}.sage-world__sage:nth-of-type(7),.sage-world__sage[data-sage="ember"]{--sage-color:#ffab69;--sage-glow:rgba(255,171,105,.54)}.sage-world__sage:nth-of-type(8),.sage-world__sage[data-sage="tide"]{--sage-color:#74d8ff;--sage-glow:rgba(116,216,255,.55)}
.sage-world__sage:hover{--sage-scale:1.13;z-index:9}.sage-world__sage:hover::before{box-shadow:0 0 0 4px rgba(9,11,22,.72),0 0 0 7px var(--sage-glow),0 0 22px var(--sage-glow)}.sage-world__sage:active,.sage-world__sage.is-dragging{cursor:grabbing}.sage-world__sage.is-dragging{z-index:16;--sage-scale:1.19;opacity:.94}.sage-world__sage.is-selected,.sage-world__sage.is-active,.sage-world__sage.is-awake{z-index:10}.sage-world__sage.is-selected::before,.sage-world__sage.is-active::before,.sage-world__sage.is-awake::before{box-shadow:0 0 0 4px rgba(9,11,22,.76),0 0 0 8px var(--sage-glow),0 0 25px var(--sage-glow)}.sage-world__sage.is-direct-activation,.sage-world__sage.is-activated{animation:sw-sage-breathe 920ms cubic-bezier(.18,.8,.26,1) both}.sage-world__sage.is-roaming{animation:none}.sage-world__sage.is-roaming:nth-of-type(2n),.sage-world__sage.is-roaming:nth-of-type(3n){animation:none}.sage-world__sage.is-drop-target::before{outline:3px dashed var(--sw-gold);outline-offset:5px}
.sage-world__pennant,.sage-world__sage-badge{position:absolute;z-index:14;right:-9px;top:-9px;min-width:20px;min-height:20px;display:grid;place-items:center;padding:2px 5px;border:1px solid rgba(255,255,255,.75);border-radius:999px;color:#19132a;background:var(--sw-gold);font-size:10px;font-weight:900;line-height:1;box-shadow:0 3px 8px rgba(0,0,0,.25)}.sage-world__pennant.is-showing{animation:sw-badge 640ms cubic-bezier(.2,.85,.3,1) both}.sage-world__score,.sage-world__stat{position:absolute;z-index:15;pointer-events:none;color:var(--sw-gold);font-size:12px;font-weight:900;text-shadow:0 1px 2px #090b16;animation:sw-score 1.1s ease-out both}.sage-world__sparks{position:absolute;inset:0;z-index:12;pointer-events:none}.sage-world__spark{position:absolute;width:5px;height:5px;border-radius:50%;background:var(--sw-gold);animation:sw-spark 700ms ease-out both}
.sage-world__caption,.sage-world__message{margin:10px 12px 0;padding:10px 12px;border:1px solid rgba(100,241,206,.32);border-radius:13px;color:var(--sw-ink);background:linear-gradient(130deg,rgba(37,43,75,.98),rgba(22,28,54,.98))}.sage-world__caption-head{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-bottom:4px}.sage-world__caption-speaker,.sage-world__caption-badge{color:var(--sw-mint);font-size:11px;font-weight:900;letter-spacing:.08em;text-transform:uppercase}.sage-world__caption-text,.sage-world__message{margin:0;font-size:13px;line-height:1.45}.sage-world__caption.is-speaking{animation:sw-caption 2.5s ease-in-out infinite}.sage-world__transcript{max-height:126px;margin:8px 12px 0;overflow:auto;border-left:2px solid #4a3f69;padding-left:10px}.sage-world__transcript-item{padding:6px 2px;color:var(--sw-muted);font-size:12px}.sage-world__transcript-item+.sage-world__transcript-item{border-top:1px solid rgba(210,187,255,.12)}.sage-world__transcript-item.is-current{color:var(--sw-ink)}
.sage-world__dossier,.sage-world__quest-panel{margin:10px 12px;padding:12px;border:1px solid var(--sw-line);border-radius:14px;background:#151a34}.sage-world__dossier-head,.sage-world__quest-head,.sage-world__section-head{display:flex;align-items:baseline;justify-content:space-between;gap:10px}.sage-world__dossier-name,.sage-world__quest-title{margin:0;font-size:14px;font-weight:900}.sage-world__dossier-class,.sage-world__quest-label{color:var(--sw-gold);font-size:10px;font-weight:800;letter-spacing:.09em;text-transform:uppercase}.sage-world__dossier-copy,.sage-world__quest-copy{margin:7px 0 0;color:var(--sw-muted);font-size:12px}.sage-world__power-grid,.sage-world__quest-list{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:7px;margin-top:10px}.sage-world__power,.sage-world__quest{padding:8px;border:1px solid rgba(210,187,255,.18);border-radius:10px;background:rgba(36,42,76,.72)}.sage-world__power strong,.sage-world__quest strong{display:block;font-size:11px}.sage-world__power span,.sage-world__quest span{display:block;margin-top:2px;color:var(--sw-muted);font-size:10px}.sage-world__mastery{height:8px;margin-top:10px;overflow:hidden;border:1px solid rgba(255,255,255,.18);border-radius:99px;background:#0c1024}.sage-world__mastery-fill{display:block;width:var(--mastery,55%);height:100%;border-radius:inherit;background:linear-gradient(90deg,var(--sw-mint),var(--sw-violet),var(--sw-gold))}
.sage-world__section{padding:12px;border-top:1px solid var(--sw-line)}.sage-world__section-title{margin:0;font-size:13px}.sage-world__countries,.sage-world__portals{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:7px;margin-top:9px}.sage-world__country,.sage-world__portal{min-height:44px;display:flex;align-items:center;gap:7px;padding:8px;border:1px solid rgba(210,187,255,.18);border-radius:10px;color:var(--sw-ink);background:#1b2040;text-decoration:none}.sage-world__portal{position:relative;overflow:hidden}.sage-world__portal::after{position:absolute;inset:0 auto 0 0;width:3px;content:"";background:var(--sw-mint);opacity:.75}.sage-world__portal:hover{border-color:var(--sw-mint);transform:translateY(-1px)}.sage-world__portal.is-active::after,.sage-world__portal.is-hot::after{width:100%;opacity:.1;transition:width 550ms ease}.sage-world__country-name,.sage-world__portal-name{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:11px;font-weight:800}.sage-world__country-value,.sage-world__portal-value{margin-left:auto;color:var(--sw-mint);font-size:11px;font-weight:900}.sage-world__clock,.sage-world__timezones{display:flex;flex-wrap:wrap;gap:6px;margin-top:9px}.sage-world__timezone{min-height:32px;padding:7px 8px;border:1px solid rgba(210,187,255,.18);border-radius:9px;color:var(--sw-muted);background:#171b35;font-size:11px}.sage-world__footer{padding:11px 12px 13px;color:var(--sw-quiet);font-size:10px}.sage-world__note{margin:0}
.sage-world.is-view-pulse .sage-world__universe{animation:sw-scene-pulse 720ms ease-out both}.sage-world.is-sparking .sage-world__threads :is(path,line),.sage-world.is-completing .sage-world__threads :is(path,line){stroke:var(--sw-gold)}.sage-world.is-outbound-wave .sage-world__orbit--one{border-color:var(--sw-gold);animation-duration:1.3s}.sage-world[data-presence="low"] .sage-world__dust{opacity:.22}.sage-world[data-mode="private"] .sage-world__universe::before{opacity:.25}
@keyframes sw-aurora{from{transform:translate3d(-2%,1%,0) rotate(-3deg) scale(1.04)}to{transform:translate3d(2%,-1%,0) rotate(3deg) scale(1.1)}}@keyframes sw-drift{from{transform:translate3d(-8px,6px,0)}to{transform:translate3d(14px,-10px,0)}}@keyframes sw-comet{0%,52%,100%{opacity:0;transform:translate3d(0,0,0) rotate(-19deg)}58%{opacity:.85}72%{opacity:0;transform:translate3d(620px,80px,0) rotate(-19deg)}}@keyframes sw-orbit{to{transform:translate(-50%,-50%) rotate(348deg)}}@keyframes sw-thread{to{stroke-dashoffset:-36}}@keyframes sw-halo{0%,100%{transform:scale(.86);opacity:.28}50%{transform:scale(1.07);opacity:.88}}@keyframes sw-badge{from{transform:scale(.2) rotate(-25deg);opacity:0}65%{transform:scale(1.15) rotate(6deg);opacity:1}to{transform:scale(1)}}@keyframes sw-score{from{transform:translateY(8px) scale(.8);opacity:0}25%{opacity:1}to{transform:translateY(-29px) scale(1);opacity:0}}@keyframes sw-spark{from{transform:translate(0,0) scale(.4);opacity:1}to{transform:translate(var(--spark-x,18px),var(--spark-y,-22px)) scale(0);opacity:0}}@keyframes sw-caption{0%,100%{border-color:rgba(100,241,206,.32)}50%{border-color:rgba(255,211,106,.76)}}@keyframes sw-scene-pulse{0%{box-shadow:inset 0 0 0 rgba(100,241,206,0)}45%{box-shadow:inset 0 0 34px rgba(100,241,206,.3)}100%{box-shadow:inset 0 0 0 rgba(100,241,206,0)}}
/* Runtime controls pause hidden/offscreen scenes before doing any work. */
.sage-world.is-paused *,.sage-world.is-offscreen *,.sage-world.is-closed *,.sage-world[data-motion="paused"] *,.sage-world[data-motion="reduced"] *,.sage-world[data-reduced-motion="true"] *,.sage-world.is-reduced-motion *{animation-play-state:paused!important}.sage-world.is-offscreen .sage-world__universe,.sage-world.is-closed .sage-world__universe{content-visibility:auto;contain-intrinsic-size:240px}.sage-world[data-motion="reduced"] *,.sage-world[data-reduced-motion="true"] *,.sage-world.is-reduced-motion *{transition-duration:1ms!important}
@media (prefers-reduced-motion:reduce){.sage-world *,.sage-world *::before,.sage-world *::after{animation-duration:1ms!important;animation-iteration-count:1!important;scroll-behavior:auto!important;transition-duration:1ms!important}.sage-world__universe::after,.sage-world__nebula,.sage-world__aurora{transform:none}.sage-world__sage.is-roaming,.sage-world__sage[data-roaming="true"],.sage-world__sage[data-motion="autonomous"]{--sage-scale:1}}
@media (prefers-contrast:more){.sage-world{--sw-line:rgba(255,255,255,.72);--sw-muted:#f0eaff;--sw-quiet:#ddd4ef}.sage-world__panel,.sage-world__caption,.sage-world__dossier,.sage-world__country,.sage-world__portal{border-width:2px}}
@media (forced-colors:active){.sage-world__panel,.sage-world__caption,.sage-world__dossier,.sage-world__country,.sage-world__portal,.sage-world__control{forced-color-adjust:auto;border:1px solid CanvasText}.sage-world__sage::before{box-shadow:none;border-color:CanvasText}}
@media (max-width:560px){.sage-world{right:8px;bottom:8px}.sage-world__panel{width:calc(100vw - 16px);max-height:min(760px,calc(100vh - 16px))}.sage-world__universe{min-height:208px;height:222px}.sage-world__header{padding:12px}.sage-world__power-grid,.sage-world__quest-list,.sage-world__countries,.sage-world__portals{grid-template-columns:1fr}}

/* Semantic-DOM integration: preserve live positions and make every state legible. */
.sage-world{isolation:isolate}.sage-world:not(.is-open):not([data-open="true"]) .sage-world__panel{display:none}.sage-world.is-open .sage-world__panel,.sage-world[data-open="true"] .sage-world__panel{display:block;animation:sw-panel-in 240ms cubic-bezier(.2,.82,.28,1) both}.sage-world__dock{width:auto;min-width:52px;min-height:52px;grid-template-columns:auto minmax(0,1fr) auto;gap:8px;padding:6px 10px 6px 8px;text-align:left}.sage-world__dock::before{display:none}.sage-world__mark{display:grid;place-items:center;width:34px;height:34px;border:1px solid rgba(255,255,255,.34);border-radius:50%;color:var(--sw-gold);background:radial-gradient(circle at 35% 30%,#fff4ba 0 5%,#ffd36a 14%,#a56ff1 47%,#1a1640 70%);font-size:17px;line-height:1;text-shadow:0 0 13px rgba(255,211,106,.82);box-shadow:0 0 0 3px rgba(184,140,255,.16),0 0 20px rgba(100,241,206,.16)}.sage-world__dock-copy{min-width:0;display:grid;gap:0}.sage-world__dock-title{overflow:hidden;color:var(--sw-ink);font-size:11px;font-weight:900;letter-spacing:.055em;text-overflow:ellipsis;text-transform:uppercase;white-space:nowrap}.sage-world__dock-status{overflow:hidden;color:var(--sw-muted);font-size:10px;text-overflow:ellipsis;white-space:nowrap}.sage-world__signal{width:8px;height:8px;border-radius:50%;background:var(--sw-mint);box-shadow:0 0 0 3px rgba(100,241,206,.15),0 0 12px var(--sw-mint)}.sage-world[data-presence="quiet"] .sage-world__signal,.sage-world[data-mode="quiet"] .sage-world__signal{background:var(--sw-quiet);box-shadow:none}.sage-world[data-mode="loading"] .sage-world__signal,.sage-world[data-presence="gathering"] .sage-world__signal{animation:sw-signal 1.3s ease-in-out infinite}

.sage-world__panel{border-color:rgba(207,182,255,.46);background:linear-gradient(145deg,rgba(26,29,57,.99),rgba(11,14,31,.99));box-shadow:0 26px 70px rgba(0,0,0,.58),0 0 0 1px rgba(100,241,206,.07) inset}.sage-world__header{background:linear-gradient(105deg,rgba(32,32,66,.98),rgba(15,18,42,.98))}.sage-world__header::after{grid-column:1/-1;height:1px;content:"";background:linear-gradient(90deg,transparent,var(--sw-mint),var(--sw-violet),transparent);opacity:.55}.sage-world__message{position:relative;overflow:hidden}.sage-world__message::before{position:absolute;inset:0 auto 0 0;width:3px;content:"";background:linear-gradient(var(--sw-mint),var(--sw-violet),var(--sw-gold))}

.sage-world__universe{background:radial-gradient(ellipse at 50% 120%,rgba(100,241,206,.2),transparent 49%),radial-gradient(circle at 14% 26%,rgba(184,140,255,.35),transparent 23%),radial-gradient(circle at 87% 16%,rgba(255,131,158,.22),transparent 19%),linear-gradient(150deg,#181334 0%,#090e22 52%,#140e2b 100%)}.sage-world__universe::before{opacity:.78;background-image:radial-gradient(rgba(255,255,255,.72) .8px,transparent 1.6px),radial-gradient(rgba(100,241,206,.55) 1px,transparent 1.8px),radial-gradient(rgba(255,211,106,.4) .7px,transparent 1.5px);background-position:6px 11px,29px 35px,18px 6px;background-size:47px 47px,71px 71px,29px 29px}.sage-world__constellation::before,.sage-world__constellation::after{position:absolute;left:50%;top:50%;width:72%;aspect-ratio:1;content:"";border:1px solid rgba(184,140,255,.22);border-radius:48% 52% 47% 53%;transform:translate(-50%,-50%) rotate(17deg);box-shadow:0 0 32px rgba(184,140,255,.12) inset}.sage-world__constellation::after{width:43%;border-color:rgba(100,241,206,.29);border-style:dashed;transform:translate(-50%,-50%) rotate(-31deg);animation:sw-portal-spin 18s linear infinite}.sage-world__sparks{background:radial-gradient(circle at 18% 25%,rgba(255,211,106,.9) 0 1px,transparent 2px),radial-gradient(circle at 78% 35%,rgba(100,241,206,.8) 0 1px,transparent 2px),radial-gradient(circle at 58% 81%,rgba(184,140,255,.85) 0 1px,transparent 2px);opacity:.86}.sage-world__constellation.is-sparking::before,.sage-world.is-sparking .sage-world__constellation::before{animation:sw-constellation-bloom 720ms cubic-bezier(.2,.82,.25,1) both}.sage-world__constellation.is-sparking::after,.sage-world.is-sparking .sage-world__constellation::after{border-color:var(--sw-gold);animation:sw-portal-spin 1.1s linear infinite,sw-constellation-bloom 720ms ease-out both}

.sage-world__sage{left:var(--sage-left,50%);top:var(--sage-top,50%);pointer-events:auto;transform:translate(calc(-50% + var(--sage-x,0px) + var(--sage-drag-x,0px)),calc(-50% + var(--sage-y,0px) + var(--sage-drag-y,0px))) rotate(var(--sage-tilt,0deg)) scale(var(--sage-scale,1));filter:drop-shadow(0 5px 7px rgba(0,0,0,.35));will-change:transform}.sage-world__sage::before{background:radial-gradient(circle at 35% 31%,rgba(255,255,255,.96) 0 7%,transparent 8%),radial-gradient(circle at 38% 46%,#15142c 0 1.5px,transparent 2px),radial-gradient(circle at 63% 46%,#15142c 0 1.5px,transparent 2px),radial-gradient(ellipse at 50% 67%,#15142c 0 2px,transparent 2.7px),radial-gradient(circle at 50% 40%,rgba(255,255,255,.58) 0 17%,transparent 18%),var(--sage-color)}.sage-world__sage[data-sage-id="marketlens"]{--sage-color:#b88cff;--sage-glow:rgba(184,140,255,.67)}.sage-world__sage[data-sage-id="munch"]{--sage-color:#64f1ce;--sage-glow:rgba(100,241,206,.62)}.sage-world__sage[data-sage-id="macmagical"]{--sage-color:#ffd36a;--sage-glow:rgba(255,211,106,.65)}.sage-world__sage[data-sage-id="privatedesk"]{--sage-color:#ff839e;--sage-glow:rgba(255,131,158,.63)}.sage-world__sage[data-sage-id="lumina"]{--sage-color:#73c7ff;--sage-glow:rgba(115,199,255,.64)}.sage-world__sage[data-sage-id="quantdash"]{--sage-color:#a7ffcf;--sage-glow:rgba(167,255,207,.62)}.sage-world__sage[data-sage-id="genesis"]{--sage-color:#ffac68;--sage-glow:rgba(255,172,104,.64)}.sage-world__sage[data-sage-id="prime"]{--sage-color:#f1a4ff;--sage-glow:rgba(241,164,255,.65)}.sage-world__sage:hover,.sage-world__sage:focus-visible,.sage-world__sage:active{--sage-scale:1.13}.sage-world__sage.is-dragging,.sage-world__sage[data-dragging="true"]{z-index:16;--sage-scale:1.19;animation:none!important}.sage-world__sage.is-selected,.sage-world__sage.is-active,.sage-world__sage.is-awake,.sage-world__sage[data-selected="true"],.sage-world__sage[data-active="true"],.sage-world__sage[aria-pressed="true"]{z-index:10;filter:drop-shadow(0 0 13px var(--sage-glow))}.sage-world__sage.is-roaming,.sage-world__sage[data-roaming="true"],.sage-world__sage[data-motion="autonomous"]{animation:none}.sage-world__sage.is-direct-activation,.sage-world__sage.is-activated,.sage-world__sage[data-activated="true"]{animation:sw-sage-breathe 920ms cubic-bezier(.18,.8,.26,1) both}.sage-world__sage.is-paused,.sage-world__sage[data-paused="true"],.sage-world__sage[data-pause="true"],.sage-world__sage[data-motion="paused"]{animation-play-state:paused!important}.sage-world__sage-label{position:absolute;left:50%;top:calc(100% + 2px);min-width:max-content;padding:2px 5px;border:1px solid rgba(255,255,255,.23);border-radius:999px;color:var(--sw-ink);background:rgba(9,11,22,.78);font-size:8px;font-weight:900;letter-spacing:.04em;opacity:0;pointer-events:none;text-transform:uppercase;transform:translateX(-50%) translateY(-3px);transition:opacity 150ms ease,transform 150ms ease}.sage-world__sage:hover .sage-world__sage-label,.sage-world__sage:focus-visible .sage-world__sage-label,.sage-world__sage.is-selected .sage-world__sage-label,.sage-world__sage[data-selected="true"] .sage-world__sage-label,.sage-world__sage[data-active="true"] .sage-world__sage-label,.sage-world__sage[aria-pressed="true"] .sage-world__sage-label{opacity:1;transform:translateX(-50%) translateY(0)}.sage-world__sage-speech,.sage-world__speech,.sage-world__tooltip{position:absolute;z-index:18;left:50%;bottom:calc(100% + 8px);width:max-content;max-width:164px;padding:7px 9px;border:1px solid color-mix(in srgb,var(--sage-color) 70%,white);border-radius:10px;color:var(--sw-ink);background:rgba(15,17,40,.94);box-shadow:0 10px 22px rgba(0,0,0,.36);font-size:10px;font-weight:700;line-height:1.3;pointer-events:none;transform:translateX(-50%);animation:sw-bubble 2.8s ease-in-out infinite}.sage-world__sage-speech::after,.sage-world__speech::after,.sage-world__tooltip::after{position:absolute;left:50%;bottom:-5px;width:8px;height:8px;content:"";border-right:1px solid color-mix(in srgb,var(--sage-color) 70%,white);border-bottom:1px solid color-mix(in srgb,var(--sage-color) 70%,white);background:rgba(15,17,40,.94);transform:translateX(-50%) rotate(45deg)}

.sage-world__score{position:relative;z-index:4;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:7px;margin:10px 12px 0;pointer-events:auto}.sage-world__stat{position:relative;z-index:auto;display:grid;align-content:center;min-height:57px;padding:8px 9px;border:1px solid rgba(210,187,255,.21);border-radius:12px;color:var(--sw-ink);background:linear-gradient(145deg,rgba(38,43,79,.86),rgba(23,27,57,.86));font-size:11px;font-weight:700;text-shadow:none;animation:none}.sage-world__stat strong,.sage-world__stat b{display:block;color:var(--sw-gold);font-size:16px;line-height:1.1}.sage-world__stat span{display:block;overflow:hidden;color:var(--sw-muted);font-size:9px;letter-spacing:.045em;text-overflow:ellipsis;text-transform:uppercase;white-space:nowrap}.sage-world__caption{display:grid;grid-template-columns:auto minmax(0,1fr);column-gap:8px;align-items:start;list-style:none}.sage-world__caption-speaker{grid-column:1;grid-row:1}.sage-world__caption-copy{grid-column:2;grid-row:1;color:var(--sw-ink);font-size:12px;line-height:1.4}.sage-world__caption-source{grid-column:1/-1;margin-top:3px;color:var(--sw-quiet);font-size:9px;letter-spacing:.045em;text-transform:uppercase}.sage-world__transcript-wrap{margin-top:4px}.sage-world__transcript{padding-bottom:4px;scrollbar-color:#655381 transparent}.sage-world__transcript li{list-style:none}.sage-world__dossier{position:relative;overflow:hidden;background:linear-gradient(135deg,rgba(31,35,71,.98),rgba(17,21,48,.98))}.sage-world__dossier::before{position:absolute;right:-38px;top:-58px;width:140px;height:140px;content:"";border:1px solid rgba(100,241,206,.28);border-radius:50%;box-shadow:0 0 0 17px rgba(184,140,255,.06),0 0 0 34px rgba(255,211,106,.04)}.sage-world__dossier>*{position:relative}.sage-world__dossier-power{margin:4px 0 0;color:var(--sw-gold);font-size:10px;font-weight:900;letter-spacing:.09em;text-transform:uppercase}.sage-world__quest{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:8px;align-items:center;margin-top:10px;padding:9px;border:1px solid rgba(100,241,206,.24);border-radius:11px;background:rgba(7,12,31,.43)}.sage-world__quest-title{color:var(--sw-mint);font-size:11px}.sage-world__quest-action{min-width:36px;min-height:36px;border-radius:10px}.sage-world__quest-link{color:var(--sw-mint);font-size:11px;font-weight:800;text-decoration-thickness:1px;text-underline-offset:3px}.sage-world__locked{display:inline-flex;align-items:center;gap:4px;color:var(--sw-quiet);font-size:10px}.sage-world__controls{padding:10px 12px;border-top:1px solid rgba(210,187,255,.16);border-bottom:1px solid rgba(210,187,255,.16);background:rgba(10,13,31,.44)}.sage-world__captions{min-height:40px;padding:7px 10px;border:1px solid var(--sw-line);border-radius:10px;color:var(--sw-ink);background:#202442;cursor:pointer}.sage-world__captions[aria-pressed="true"]{color:#102021;border-color:var(--sw-mint);background:var(--sw-mint)}.sage-world__portal{background:linear-gradient(135deg,#20264b,#141a38)}.sage-world__portal::before{position:absolute;right:-14px;top:50%;width:34px;height:34px;content:"";border:1px solid rgba(184,140,255,.34);border-radius:50%;transform:translateY(-50%);box-shadow:0 0 18px rgba(100,241,206,.16)}.sage-world__portal:hover::before,.sage-world__portal:focus-visible::before{animation:sw-portal-spin 1.2s linear infinite}.sage-world[data-presence="gathering"] .sage-world__dust,.sage-world[data-presence="active"] .sage-world__dust{opacity:.8}.sage-world[data-presence="quiet"] .sage-world__dust,.sage-world[data-mode="quiet"] .sage-world__dust{opacity:.18}.sage-world[data-mode="private"] .sage-world__privacy{color:var(--sw-mint)}

@keyframes sw-panel-in{from{opacity:0;transform:translateY(10px) scale(.985)}to{opacity:1;transform:translateY(0) scale(1)}}@keyframes sw-signal{0%,100%{box-shadow:0 0 0 3px rgba(100,241,206,.12),0 0 5px var(--sw-mint)}50%{box-shadow:0 0 0 7px rgba(100,241,206,.05),0 0 17px var(--sw-mint)}}@keyframes sw-portal-spin{to{transform:translate(-50%,-50%) rotate(377deg)}}@keyframes sw-constellation-bloom{0%{opacity:.2;transform:translate(-50%,-50%) rotate(17deg) scale(.65)}62%{opacity:1;transform:translate(-50%,-50%) rotate(29deg) scale(1.18)}100%{opacity:.72;transform:translate(-50%,-50%) rotate(17deg) scale(1)}}@keyframes sw-sage-breathe{0%,100%{filter:drop-shadow(0 5px 7px rgba(0,0,0,.35))}50%{filter:drop-shadow(0 0 13px var(--sage-glow))}}@keyframes sw-bubble{0%,100%{transform:translateX(-50%) translateY(0)}50%{transform:translateX(-50%) translateY(-3px)}}
@media (max-width:560px){.sage-world__dock-copy{display:none}.sage-world__dock{padding:7px;width:52px}.sage-world__score{gap:5px;margin-inline:9px}.sage-world__stat{min-height:52px;padding:7px}.sage-world__stat strong,.sage-world__stat b{font-size:14px}.sage-world__stat span{font-size:8px}.sage-world__caption,.sage-world__message{margin-inline:9px}.sage-world__dossier{margin-inline:9px}.sage-world__section{padding-inline:9px}.sage-world__quest{grid-template-columns:minmax(0,1fr) auto}.sage-world__sage-speech,.sage-world__speech,.sage-world__tooltip{max-width:126px;font-size:9px}}
@media (prefers-reduced-motion:reduce){.sage-world__sage,.sage-world__sage:hover,.sage-world__sage:focus-visible,.sage-world__sage.is-dragging,.sage-world__sage[data-dragging="true"],.sage-world__sage.is-roaming,.sage-world__sage[data-roaming="true"],.sage-world__sage[data-motion="autonomous"],.sage-world__sage.is-activated,.sage-world__sage[data-activated="true"]{animation:none!important}.sage-world__constellation::after,.sage-world__portal::before{animation:none!important}}

/* Keep each Sage's live caption within the rendered constellation.  Runtime
   placement attributes are intentionally supported so roaming code can select
   the safe side after it has measured the Sage's transformed position. */
.sage-world__universe,.sage-world__constellation{container-type:inline-size}
.sage-world__sage{--sage-bubble-anchor-left:50%;--sage-bubble-anchor-right:auto;--sage-bubble-top:auto;--sage-bubble-bottom:calc(100% + 8px);--sage-bubble-shift-x:-50%;--sage-bubble-shift-y:0px;--sage-bubble-tail-left:50%;--sage-bubble-tail-right:auto;--sage-bubble-tail-top:auto;--sage-bubble-tail-bottom:-5px;--sage-bubble-tail-shift-x:-50%;--sage-bubble-tail-turn:45deg;--sage-bubble-max:164px}
.sage-world__sage-speech,.sage-world__speech,.sage-world__tooltip{left:var(--sage-bubble-anchor-left);right:var(--sage-bubble-anchor-right);top:var(--sage-bubble-top);bottom:var(--sage-bubble-bottom);width:var(--sage-bubble-max);max-width:var(--sage-bubble-max);max-inline-size:var(--sage-bubble-max);overflow-wrap:anywhere;transform:translateX(var(--sage-bubble-shift-x));animation:sw-bubble-edge-safe 2.8s ease-in-out infinite}
.sage-world__sage-speech::after,.sage-world__speech::after,.sage-world__tooltip::after{left:var(--sage-bubble-tail-left);right:var(--sage-bubble-tail-right);top:var(--sage-bubble-tail-top);bottom:var(--sage-bubble-tail-bottom);transform:translateX(var(--sage-bubble-tail-shift-x)) rotate(var(--sage-bubble-tail-turn))}

/* The default grid has a stable first frame: upper Sages speak down into the
   scene, lower Sages speak up, and outside columns point inward. */
.sage-world__sage[data-sage-id="marketlens"],.sage-world__sage[data-sage-id="munch"],.sage-world__sage[data-sage-id="macmagical"],.sage-world__sage[data-sage-id="privatedesk"]{--sage-bubble-top:calc(100% + 8px);--sage-bubble-bottom:auto;--sage-bubble-tail-top:-5px;--sage-bubble-tail-bottom:auto;--sage-bubble-tail-turn:225deg}
.sage-world__sage[data-sage-id="marketlens"],.sage-world__sage[data-sage-id="lumina"]{--sage-bubble-anchor-left:0;--sage-bubble-shift-x:0;--sage-bubble-tail-left:18px;--sage-bubble-tail-shift-x:0}
.sage-world__sage[data-sage-id="privatedesk"],.sage-world__sage[data-sage-id="prime"]{--sage-bubble-anchor-left:auto;--sage-bubble-anchor-right:0;--sage-bubble-shift-x:0;--sage-bubble-tail-left:auto;--sage-bubble-tail-right:18px;--sage-bubble-tail-shift-x:0}

/* JS may set either the descriptive placement API or these concise aliases
   when a Sage crosses a viewport edge while roaming or being dragged. */
.sage-world__sage[data-tooltip-placement="top-start"],.sage-world__sage[data-tooltip-side="start"],.sage-world__sage.is-tooltip-start{--sage-bubble-anchor-left:0;--sage-bubble-anchor-right:auto;--sage-bubble-shift-x:0;--sage-bubble-tail-left:18px;--sage-bubble-tail-right:auto;--sage-bubble-tail-shift-x:0}
.sage-world__sage[data-tooltip-placement="top-end"],.sage-world__sage[data-tooltip-side="end"],.sage-world__sage.is-tooltip-end{--sage-bubble-anchor-left:auto;--sage-bubble-anchor-right:0;--sage-bubble-shift-x:0;--sage-bubble-tail-left:auto;--sage-bubble-tail-right:18px;--sage-bubble-tail-shift-x:0}
.sage-world__sage[data-tooltip-placement="bottom"],.sage-world__sage[data-tooltip-placement="bottom-start"],.sage-world__sage[data-tooltip-placement="bottom-end"],.sage-world__sage[data-tooltip-vertical="bottom"],.sage-world__sage.is-tooltip-bottom{--sage-bubble-top:calc(100% + 8px);--sage-bubble-bottom:auto;--sage-bubble-tail-top:-5px;--sage-bubble-tail-bottom:auto;--sage-bubble-tail-turn:225deg}
.sage-world__sage[data-tooltip-placement="top"],.sage-world__sage[data-tooltip-placement="top-start"],.sage-world__sage[data-tooltip-placement="top-end"],.sage-world__sage[data-tooltip-vertical="top"],.sage-world__sage.is-tooltip-top{--sage-bubble-top:auto;--sage-bubble-bottom:calc(100% + 8px);--sage-bubble-tail-top:auto;--sage-bubble-tail-bottom:-5px;--sage-bubble-tail-turn:45deg}
@keyframes sw-bubble-edge-safe{0%,100%{transform:translateX(var(--sage-bubble-shift-x)) translateY(var(--sage-bubble-shift-y))}50%{transform:translateX(var(--sage-bubble-shift-x)) translateY(calc(var(--sage-bubble-shift-y) - 3px))}}
@supports (width:1cqw){.sage-world__sage{--sage-bubble-max:min(164px,calc(100cqw - 28px))}}
@media (max-width:560px){.sage-world__sage{--sage-bubble-max:126px}}
@media (max-width:560px){@supports (width:1cqw){.sage-world__sage{--sage-bubble-max:min(126px,calc(100cqw - 20px))}}}
@media (prefers-reduced-motion:reduce){.sage-world__sage-speech,.sage-world__speech,.sage-world__tooltip{animation:none!important}}

/* Captions are their own bounded reading region. Direct Sage choices reveal
   the paired guide and aggregate card; background polls append without moving
   a reader's current position or scrolling the surrounding page. */
.sage-world__caption-stack{display:flow-root;box-sizing:border-box;max-block-size:min(300px,38dvh);overflow-y:auto;overscroll-behavior:contain;scrollbar-gutter:stable;scroll-padding-block:10px 16px;padding-block:10px 16px;scrollbar-color:#655381 transparent}
.sage-world__caption-stack:empty{display:none}
@media (max-height:640px) and (orientation:landscape){.sage-world__caption-stack{max-block-size:min(150px,30dvh)}}

/* Keep live telemetry responsive while direct manipulation remains immediate. */
.sage-world__sage{transition:transform 120ms linear,opacity 180ms ease}
.sage-world__sage.is-dragging,.sage-world__sage[data-dragging="true"],.sage-world__sage.is-roaming,.sage-world__sage[data-roaming="true"],.sage-world__sage[data-motion="autonomous"]{transition:none}
.sage-world__sage:focus-visible{outline-color:#fff;filter:drop-shadow(0 0 13px var(--sage-glow))}
.sage-world.is-open .sage-world__dock,.sage-world__dock[aria-expanded="true"]{border-color:var(--sw-mint);box-shadow:0 0 0 3px rgba(100,241,206,.16),0 14px 34px rgba(1,2,12,.46)}
@media (max-width:560px){.sage-world{--sw-safe-top:max(8px,env(safe-area-inset-top,0px));--sw-safe-right:max(8px,env(safe-area-inset-right,0px));--sw-safe-bottom:max(8px,env(safe-area-inset-bottom,0px));--sw-safe-left:max(8px,env(safe-area-inset-left,0px))}.sage-world__panel{width:calc(100vw - var(--sw-safe-left) - var(--sw-safe-right));max-height:min(760px,calc(100dvh - var(--sw-safe-top) - var(--sw-safe-bottom) - 58px))}}
@media (max-height:640px) and (orientation:landscape){.sage-world__panel{max-height:calc(100dvh - var(--sw-safe-top) - var(--sw-safe-bottom) - 54px);border-radius:15px}.sage-world__header{padding:11px 13px 9px}.sage-world__universe{min-height:142px;height:min(34dvh,184px)}.sage-world__section{padding-block:9px}.sage-world__sage-speech,.sage-world__speech,.sage-world__tooltip{--sage-bubble-max:138px;font-size:9px}}
@media (max-height:640px) and (orientation:landscape){@supports (width:1cqw){.sage-world__sage-speech,.sage-world__speech,.sage-world__tooltip{--sage-bubble-max:min(138px,calc(100cqw - 20px))}}}
@media (prefers-reduced-motion:reduce){.sage-world__dock:hover,.sage-world__portal:hover{transform:none}.sage-world__sage,.sage-world__sage:hover,.sage-world__sage:focus-visible,.sage-world__sage:active{--sage-scale:1}}

/* Conversational rhythm and direct-manipulation feedback.  These animations
   deliberately live on the Sage artwork, never the positioned Sage container:
   runtime coordinates remain authoritative while the constellation feels alive. */
.sage-world__sage.is-roaming:not(.is-dragging):not([data-paused="true"])::before,
.sage-world__sage[data-roaming="true"]:not(.is-dragging):not([data-paused="true"])::before,
.sage-world__sage[data-motion="autonomous"]:not(.is-dragging):not([data-paused="true"])::before{
  animation:sw-sage-face-float var(--sage-float-duration,4.8s) cubic-bezier(.45,0,.55,1) infinite;
  animation-delay:var(--sage-float-delay,0s)
}
.sage-world__sage.is-roaming:not(.is-dragging):not([data-paused="true"])::after,
.sage-world__sage[data-roaming="true"]:not(.is-dragging):not([data-paused="true"])::after,
.sage-world__sage[data-motion="autonomous"]:not(.is-dragging):not([data-paused="true"])::after{
  animation:sw-sage-tail-sway var(--sage-float-duration,4.8s) ease-in-out infinite;
  animation-delay:var(--sage-float-delay,0s)
}
.sage-world__sage.is-roaming:not(.is-dragging):not([data-paused="true"])>:is(.sage-world__sage-tail,.sage-world__tail),
.sage-world__sage[data-roaming="true"]:not(.is-dragging):not([data-paused="true"])>:is(.sage-world__sage-tail,.sage-world__tail),
.sage-world__sage[data-motion="autonomous"]:not(.is-dragging):not([data-paused="true"])>:is(.sage-world__sage-tail,.sage-world__tail){
  animation:sw-sage-tail-sway-child var(--sage-float-duration,4.8s) ease-in-out infinite;
  animation-delay:var(--sage-float-delay,0s)
}
@keyframes sw-sage-face-float{0%,100%{transform:translate3d(0,0,0)}45%{transform:translate3d(0,-2px,0)}72%{transform:translate3d(1px,-1px,0)}}
@keyframes sw-sage-tail-sway{0%,100%{transform:rotate(-26deg) scaleX(1)}50%{transform:rotate(-14deg) scaleX(.92)}}
@keyframes sw-sage-tail-sway-child{0%,100%{transform:rotate(-28deg) scaleX(1)}50%{transform:rotate(-15deg) scaleX(.92)}}

.sage-world__caption.is-speaking{
  position:relative;
  overflow:hidden;
  box-shadow:0 0 0 1px rgba(248,242,207,.24) inset,0 12px 24px rgba(3,8,17,.25);
  animation:sw-caption 2.5s ease-in-out infinite,sw-caption-presence 1.45s ease-in-out infinite
}
.sage-world__caption.is-speaking::after{
  content:"";
  position:absolute;
  inset:0;
  pointer-events:none;
  background:linear-gradient(105deg,transparent 36%,rgba(255,255,255,.12) 48%,transparent 61%);
  transform:translateX(-125%);
  animation:sw-caption-scan 3.8s ease-in-out infinite
}
.sage-world__caption.is-speaking :is(.sage-world__caption-text,.sage-world__caption-copy)::after{
  content:"";
  display:inline-block;
  width:.42em;
  height:1em;
  margin-left:.18em;
  vertical-align:-.14em;
  background:var(--sw-mint);
  box-shadow:0 0 7px var(--sw-mint);
  animation:sw-caption-cursor .9s steps(2,end) infinite
}
.sage-world__transcript-item.is-current,
.sage-world__transcript-item[data-current="true"]{
  position:relative;
  padding-left:10px;
  color:#f8f2cf;
  background:linear-gradient(90deg,rgba(78,232,192,.14),transparent 84%)
}
.sage-world__transcript-item.is-current::before,
.sage-world__transcript-item[data-current="true"]::before{
  content:"";
  position:absolute;
  left:0;
  top:.65em;
  width:4px;
  height:4px;
  border-radius:50%;
  background:var(--sw-mint);
  box-shadow:0 0 0 3px rgba(78,232,192,.16),0 0 12px var(--sw-mint);
  animation:sw-transcript-beat 1.3s ease-in-out infinite
}
@keyframes sw-caption-presence{50%{box-shadow:0 0 0 1px rgba(248,242,207,.42) inset,0 16px 32px rgba(3,8,17,.38),0 0 22px rgba(78,232,192,.1)}}
@keyframes sw-caption-scan{0%,35%{transform:translateX(-125%)}58%,100%{transform:translateX(125%)}}
@keyframes sw-caption-cursor{50%{opacity:0}}
@keyframes sw-transcript-beat{50%{transform:scale(1.55);box-shadow:0 0 0 6px rgba(78,232,192,0),0 0 16px var(--sw-mint)}}

.sage-world__sage:is(.is-selected,.is-active,.is-awake,[data-selected="true"],[data-active="true"],[aria-pressed="true"]) :is(.sage-world__sage-speech,.sage-world__speech,.sage-world__tooltip){
  border-color:rgba(242,199,113,.75);
  box-shadow:0 0 0 1px rgba(242,199,113,.17) inset,0 14px 32px rgba(3,8,17,.35),0 0 24px rgba(242,199,113,.14)
}
.sage-world__sage.is-dragging::before,
.sage-world__sage[data-dragging="true"]::before{
  outline:2px solid rgba(248,242,207,.9);
  outline-offset:5px;
  box-shadow:0 0 0 7px rgba(78,232,192,.18),0 0 24px rgba(78,232,192,.58)
}
.sage-world__sage.is-dragging :is(.sage-world__sage-label,.sage-world__sage-name),
.sage-world__sage[data-dragging="true"] :is(.sage-world__sage-label,.sage-world__sage-name){
  opacity:1;
  transform:translateY(-2px);
  text-shadow:0 0 12px rgba(248,242,207,.7)
}
.sage-world__sage.is-dragging :is(.sage-world__sage-speech,.sage-world__speech,.sage-world__tooltip),
.sage-world__sage[data-dragging="true"] :is(.sage-world__sage-speech,.sage-world__speech,.sage-world__tooltip){
  opacity:.9;
  animation:none
}
@supports selector(:has(*)){
  .sage-world__universe:has(.sage-world__sage.is-dragging,.sage-world__sage[data-dragging="true"]){box-shadow:inset 0 0 0 1px rgba(78,232,192,.28),inset 0 0 80px rgba(78,232,192,.08)}
}

@media (forced-colors:active){
  .sage-world__sage.is-dragging::before,.sage-world__sage[data-dragging="true"]::before{outline:3px solid Highlight;box-shadow:none}
  .sage-world__transcript-item.is-current,.sage-world__transcript-item[data-current="true"]{outline:1px solid Highlight}
}
@media (prefers-reduced-motion:reduce){
  .sage-world__sage.is-roaming::before,.sage-world__sage[data-roaming="true"]::before,.sage-world__sage[data-motion="autonomous"]::before,
  .sage-world__sage.is-roaming::after,.sage-world__sage[data-roaming="true"]::after,.sage-world__sage[data-motion="autonomous"]::after,
  .sage-world__sage.is-roaming>:is(.sage-world__sage-tail,.sage-world__tail),.sage-world__sage[data-roaming="true"]>:is(.sage-world__sage-tail,.sage-world__tail),.sage-world__sage[data-motion="autonomous"]>:is(.sage-world__sage-tail,.sage-world__tail),
  .sage-world__caption.is-speaking,.sage-world__caption.is-speaking :is(.sage-world__caption-text,.sage-world__caption-copy)::after,
  .sage-world__transcript-item.is-current::before,.sage-world__transcript-item[data-current="true"]::before{animation:none!important}
  .sage-world__caption.is-speaking::after{display:none}
}
