/* Live profile decoration and the wallet. */
.rodnie-profile-card .rodnie-decor-avatar{width:max-content;overflow:visible}
.rodnie-profile-card[data-frame]:not([data-frame=""]) .rodnie-decor-avatar,
.rodnie-decor-demo[data-frame]:not([data-frame=""]) .rodnie-decor-avatar{
 outline:2px solid var(--rodnie-jewel);outline-offset:4px
}
.rodnie-profile-card .rodnie-decor-crown,.rodnie-decor-demo .rodnie-decor-crown{z-index:3;pointer-events:none}
.rodnie-profile-card[data-accent]:not([data-accent=""]) :is(.ux-profile-head h2,h2,[data-decor-title]){color:var(--rodnie-accent)!important}
.rodnie-profile-card [data-decor-title][hidden]{display:none}
.wallet7 nav{display:flex;flex-wrap:wrap;gap:.5rem;margin-bottom:1rem}
.wallet7 nav [aria-pressed=true]{border-color:var(--studio-accent);background:var(--studio-active);color:var(--studio-ink)}
.wallet7-balances{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,150px),1fr));gap:12px}
.wallet7-balances article,.wallet7-operation{background:var(--studio-surface);color:var(--studio-ink);border:1px solid var(--studio-line);border-radius:16px;padding:14px}
.wallet7-balances strong{display:block;font-size:clamp(20px,5vw,28px)}
.wallet7-balances small,.wallet7-operation small{color:var(--studio-muted)}
.wallet7-filters [data-dates]:not([hidden]){display:flex;flex-wrap:wrap;gap:.65rem}
.wallet7-operation{display:flex;align-items:center;justify-content:space-between;gap:.65rem;margin:.5rem 0}
.wallet7-operation small{display:block}
.wallet7-operation strong{white-space:nowrap}
@media(max-width:850px){
 #shell.chat-open:not(.mode-open){height:var(--rodnie-visible-height,100dvh);grid-template-rows:minmax(0,1fr);padding:0;gap:0}
 #shell.chat-open:not(.mode-open)>#chat-area{grid-area:1/1;display:flex;height:100%;min-height:0;max-height:none;padding-top:0}
 #shell.chat-open:not(.mode-open) .chat-timeline{flex:1 1 0;min-height:0}
 #shell.chat-open:not(.mode-open) .composer-shell{flex:0 0 auto;margin:0}
 #shell.chat-open:not(.mode-open)>:is(.mobile-nav,.mobile-back-chats){display:none}
}
.story-cosmos-editor .r7-drawing-layer{position:absolute;inset:0;width:100%;height:100%;z-index:19;pointer-events:none}
.story-cosmos-editor .r7-drawing-layer.drawing{pointer-events:all;touch-action:none;cursor:crosshair}
.r7-drawing-layer polyline{fill:none;stroke:#d8b7ff;stroke-width:4;vector-effect:non-scaling-stroke;stroke-linecap:round;stroke-linejoin:round}
.r7-story-panel-head{position:sticky;top:-1px;z-index:2;display:flex;justify-content:flex-end;background:#0b1935;padding:.15rem 0 .45rem}
.r7-story-panel-head button{background:#273a65;color:#f3f6ff;border:1px solid #7586b3;border-radius:9px;min-height:40px;padding:0 .75rem}
.story-cosmos-editor .rs8-inline-panel[hidden]{display:none!important}

/* Every landscape is assembled from a sky gradient, an illustration and a tonal veil. */
:root[data-wallpaper=mountains],.r7-theme-picker [data-scene=mountains]{--r7-art:url('./mountains7.svg');--r7-sky:#263957;--r7-base:#141f35;--r7-veil:#14244050;--r7-accent:#9ab9f7;--r7-bubble:#2f4874;--r7-light:#eaf1ff;--r7-day:#bed7f4}
:root[data-wallpaper=nature],.r7-theme-picker [data-scene=nature]{--r7-art:url('./nature7.svg');--r7-sky:#184f4d;--r7-base:#142d2d;--r7-veil:#102f294e;--r7-accent:#8adbb3;--r7-bubble:#255e50;--r7-light:#e6f6e9;--r7-day:#c0e7c8}
:root[data-wallpaper=ocean],.r7-theme-picker [data-scene=ocean]{--r7-art:url('./ocean7.svg');--r7-sky:#215276;--r7-base:#10273d;--r7-veil:#0c304a4f;--r7-accent:#87e6ea;--r7-bubble:#205875;--r7-light:#e0f5fb;--r7-day:#abe3eb}
:root:is([data-wallpaper=mountains],[data-wallpaper=nature],[data-wallpaper=ocean]){
 --bubble-in:var(--r7-base);--bubble-out:var(--r7-bubble);--render-panel:var(--r7-base);
 --r7-scene:linear-gradient(var(--r7-veil),var(--r7-base)),var(--r7-art),linear-gradient(var(--r7-sky),var(--r7-base))
}
:root[data-theme=light]:is([data-wallpaper=mountains],[data-wallpaper=nature],[data-wallpaper=ocean]){
 --bubble-in:var(--r7-light);--render-panel:var(--r7-light);
 --r7-scene:linear-gradient(#fff3,var(--r7-light)),var(--r7-art),linear-gradient(var(--r7-day),var(--r7-light))
}
:root:is([data-wallpaper=mountains],[data-wallpaper=nature],[data-wallpaper=ocean]) body::before,
:root:is([data-wallpaper=mountains],[data-wallpaper=nature],[data-wallpaper=ocean]) #shell.render-workspace>.chat-area::before{
 background-image:var(--r7-scene)!important;background-position:center!important;background-size:cover!important;
 background-repeat:no-repeat!important;opacity:1!important;filter:none!important
}
:root:is([data-wallpaper=mountains],[data-wallpaper=nature],[data-wallpaper=ocean]) #shell.render-workspace>.chat-area:after{background:none!important}
:root:is([data-wallpaper=mountains],[data-wallpaper=nature],[data-wallpaper=ocean]) #shell.render-workspace :is(.chat-head,.composer,.composer-shell,.mobile-nav){background:var(--render-panel)!important}
:root:is([data-wallpaper=mountains],[data-wallpaper=nature],[data-wallpaper=ocean]) #shell.render-workspace .message.own{background:var(--r7-bubble);color:#fff}
:root[data-theme=light]:is([data-wallpaper=mountains],[data-wallpaper=nature],[data-wallpaper=ocean]) #shell.render-workspace .mobile-nav button{color:#254054}
.r7-theme-picker{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;margin:8px 0;border:0;padding:0}
.r7-theme-picker legend{margin-bottom:8px;font-weight:700}
.r7-theme-picker label{position:relative;min-height:105px;display:flex;align-items:flex-end;justify-content:space-between;gap:.5rem;padding:10px;border:1px solid var(--studio-line);border-radius:14px;overflow:hidden;color:#fff;background:linear-gradient(transparent,#071728df),var(--r7-art,url('../cosmos-r1/nebula.webp')) center/cover,var(--r7-sky,#233257)}
.r7-theme-picker label:has(:checked){outline:2px solid var(--studio-accent);outline-offset:2px}
.r7-theme-picker label span{font-weight:700;text-shadow:0 1px 4px #000}

.r7-live-subtitle{font-size:.82rem;line-height:1.35;margin:.2rem 0 0}
.story-cosmos-editor .rs8-canvas-toolbar{
 z-index:25;left:8px;right:auto;bottom:8px;transform:none;width:max-content;max-width:calc(100% - 16px)
}
