/* Ruv AI — раскладка поверх ruv-ui. */
.ai-balance{height:46px;padding-left:var(--space-4);font-size:var(--fs-body);gap:var(--space-2)}
.ai-balance .rui-pillbtn__icon{width:36px;height:36px}
.ai-balance .rui-pillbtn__icon .rui-i{width:18px;height:18px}
.ai-chat-wrap{display:flex;flex-direction:column;gap:var(--space-4);min-height:calc(100dvh - var(--header-h) - var(--nav-h) - 80px - var(--safe-top) - var(--safe-bottom))}
.ai-intro{display:flex;flex-direction:column;gap:var(--space-3)}
.ai-intro__title{margin:var(--space-5) 0 var(--space-2)}
.ai-prompts{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:var(--space-3)}
.ai-messages{flex:1}
.ai-messages:empty{display:none}
.ai-composer{position:sticky;bottom:calc(var(--nav-h) + 24px + var(--safe-bottom));z-index:var(--z-sticky);margin-top:auto;background:var(--surface-elevated);box-shadow:var(--shadow-floating)}
.rui-msg.is-thinking{color:var(--text-secondary)}
.rui-msg.is-thinking::after{content:"";display:inline-block;width:1.2em;text-align:left;animation:ai-dots 1.2s steps(4) infinite}
@keyframes ai-dots{0%{content:""}25%{content:"."}50%{content:".."}75%{content:"..."}}
.ai-artifact{margin-top:var(--space-2);border-radius:var(--radius-md);overflow:hidden}
.ai-artifact img{width:100%;height:auto}
.ai-artifact audio{width:100%}
@media (max-width:359px){.ai-balance>span:first-child{display:none}.ai-balance{padding:0 5px}}
@media (min-width:1024px){.ai-prompts{grid-template-columns:repeat(4,minmax(0,1fr))}.ai-composer{bottom:var(--space-6)}.ai-chat-wrap{min-height:calc(100dvh - var(--header-h) - 120px)}}
