/* Forge Digital Media Workspace · camada de animações */
@keyframes fx-rise{from{opacity:0;transform:translateY(14px)}to{opacity:1;transform:none}}
@keyframes fx-slide{from{opacity:0;transform:translateX(-22px)}to{opacity:1;transform:none}}
@keyframes fx-pop{from{opacity:0;transform:translateY(12px) scale(.88)}to{opacity:1;transform:none}}
@keyframes fx-glow{0%{box-shadow:0 0 0 0 #e1062a99}100%{box-shadow:0 0 0 16px #e1062a00}}
@keyframes fx-toast{from{opacity:0;transform:translateX(40px) scale(.95)}to{opacity:1;transform:none}}
@keyframes fx-beat{0%,100%{transform:scale(1)}50%{transform:scale(1.18)}}
@keyframes fx-modal{from{opacity:0;transform:translateY(26px) scale(.94)}to{opacity:1;transform:none}}
@keyframes fx-fade{from{opacity:0}to{opacity:1}}
@keyframes fx-drop{from{opacity:.2;transform:translateY(-14px)}to{opacity:1;transform:none}}
@keyframes fx-avatar{0%{transform:rotate(-180deg) scale(.3)}70%{transform:rotate(12deg) scale(1.12)}100%{transform:none}}
@keyframes fx-fly{0%{transform:none}45%{transform:translate(14px,-12px) rotate(-18deg);opacity:0}46%{transform:translate(-14px,12px);opacity:0}100%{transform:none;opacity:1}}
@keyframes fx-ring{to{transform:scale(3.2);opacity:0}}
@keyframes fx-ignite{0%{opacity:0;transform:scale(.7);filter:blur(12px)}60%{opacity:1;filter:blur(0) drop-shadow(0 0 40px #ff1f3d)}100%{opacity:1;transform:none}}

.boot-screen{background:#000!important}
.boot-screen img{width:min(60vw,300px);animation:fx-ignite 1.4s both;filter:drop-shadow(0 0 28px #e1062a)}
.brand-logo{object-fit:contain;filter:drop-shadow(0 0 8px #e1062a88)}
.contact-row{transition:background .2s,transform .2s,box-shadow .25s}
.contact-row:hover{transform:translateX(5px)}
.contact-row.fx-select{animation:fx-glow .75s ease-out}
.bubble.fx-in,.bubble.fx-new{animation:fx-pop .45s cubic-bezier(.2,1.4,.4,1) both;animation-delay:calc(var(--i,0)*55ms)}
.bubble.outgoing{transform-origin:100% 100%}.bubble.incoming{transform-origin:0 100%}
.bubble.fx-new.outgoing{box-shadow:0 0 0 0 #e1062a88;animation:fx-pop .45s cubic-bezier(.2,1.4,.4,1) both,fx-glow .9s .1s}
.composer .button.primary.fx-sent svg{animation:fx-fly .55s ease}
.unread-count{animation:fx-beat 1.8s ease-in-out infinite}
.toast{animation:fx-toast .45s cubic-bezier(.2,1.2,.4,1) both}
#modal[open]:not(.dialog-leaving){animation:fx-modal .32s cubic-bezier(.2,1.2,.4,1)}
#modal[open]::backdrop{animation:fx-fade .3s both}
.fx-page{animation:fx-rise .5s cubic-bezier(.2,.8,.2,1) both}
#workspace-header.fx-header{animation:fx-drop .42s cubic-bezier(.2,.8,.2,1) both}
.funnel-details.fx-stage>*{animation:fx-rise .42s both}
.funnel-details.fx-stage>*:nth-child(2){animation-delay:.06s}.funnel-details.fx-stage>*:nth-child(3){animation-delay:.12s}
.funnel-slice{transition:transform .25s,filter .25s,box-shadow .25s}.funnel-slice:hover{transform:translateX(6px);filter:brightness(1.15)}
.channel-tab,.icon-button,.button,.sidebar nav a{position:relative;overflow:hidden;transition:transform .15s,box-shadow .25s,background .25s,border-color .25s}
.button:hover,.channel-tab:hover{transform:translateY(-2px);box-shadow:0 8px 24px #e1062a40}
.button:active,.channel-tab:active,.icon-button:active{transform:scale(.95)}
.sidebar nav a:hover{transform:translateX(4px)}
.channel-tab[aria-pressed=true]{animation:fx-glow .7s}
.fx-ripple{position:absolute;width:24px;height:24px;margin:-12px 0 0 -12px;border-radius:50%;background:#ff4a5c66;pointer-events:none;animation:fx-ring .6s ease-out forwards}
.fx-sound{position:fixed;left:12px;bottom:12px;z-index:2147482000;border:1px solid var(--border);background:var(--panel);color:var(--muted);border-radius:999px;padding:6px 12px;font:inherit;font-size:.75rem;cursor:pointer;opacity:.8;transition:.2s}
.fx-sound:hover{opacity:1;color:var(--text);border-color:#e1062a}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{animation:none!important}#fx-fire,#fx-trail{display:none}}

/* Paleta vermelha: cromo do app em vermelho; status continua verde */
html[data-palette=red]{--theme-detail:#ff7a45}

html[data-palette=red] .badge.green,html[data-palette=red] .mini-dot.live,html[data-palette=red] .status-ok{--green:#2fbf71}
html[data-palette=red] .auth-feature-line{background:linear-gradient(#e1062a,#ff7a45)}
html[data-palette=red] .button.primary{background:linear-gradient(135deg,#e1062a,#9b0a22);border-color:#ff3b4f;color:#fff}

/* Keep the longer Forge wordmark and audio control clear of mobile navigation. */
.fx-sound{display:inline-flex;align-items:center;gap:6px}.fx-sound>svg{width:15px;height:15px;flex:none}
@media(max-width:760px){
 .mobile-masthead .wordmark{flex:1;min-width:0;gap:7px}.mobile-masthead .brand-copy{min-width:0}.mobile-masthead .brand-copy strong{font-size:11px;letter-spacing:.5px;line-height:1.2;white-space:normal;max-width:90px}.mobile-masthead .brand-logo{width:26px;height:26px;flex:none}
 .mobile-masthead>div{flex:none;gap:3px}.mobile-masthead .fx-sound{position:static;left:auto;bottom:auto;width:28px;height:32px;padding:5px;justify-content:center;flex:none;border-radius:8px}.mobile-masthead .fx-sound>span{display:none}
 .inbox-rail>.fx-sound{position:static;left:auto;bottom:auto;padding:4px 7px;min-height:28px;font-size:9px;line-height:1.3;border-radius:8px;margin-left:5px;flex:none}
 .auth-layout .auth-brand{position:relative}.auth-layout .auth-brand .wordmark{padding-right:30px}.auth-layout .auth-brand .brand-copy strong{font-size:clamp(12px,4vw,16px);letter-spacing:.7px;white-space:nowrap}
 .auth-brand>.fx-sound{position:absolute;top:8px;right:8px;left:auto;bottom:auto;padding:5px;width:28px;height:28px;justify-content:center}.auth-brand>.fx-sound>span{display:none}
}
