/* Compact, translucent application chrome. No independent title bar or empty hero strip. */
.studio-shell{--rail-width:64px;--sidebar:var(--rail-width);min-height:100dvh}.studio-shell.nav-expanded{--rail-width:208px}.navigation-rail{position:fixed;inset:0 auto 0 0;width:var(--rail-width);display:flex;flex-direction:column;gap:7px;padding:16px 10px 14px;z-index:60;border-right:1px solid var(--hair);background:rgba(240,240,234,.56);backdrop-filter:blur(28px) saturate(1.05);-webkit-backdrop-filter:blur(28px) saturate(1.05);transition:width .2s ease,padding .2s ease}.rail-brand{display:flex;align-items:center;gap:9px;height:39px;padding:5px 4px;margin-bottom:5px;flex:none;overflow:hidden;min-width:0;border-radius:11px}.rail-mark{display:block;width:32px;height:32px;object-fit:contain;flex:none}.rail-wordmark{display:none;width:121px;height:auto;max-height:28px;object-fit:contain}.nav-expanded .rail-wordmark{display:block}.rail-action{position:relative;display:flex;align-items:center;justify-content:center;gap:11px;min-height:42px;width:100%;padding:10px;border-radius:12px;color:var(--muted);text-align:left;flex:none;transition:background .17s,color .17s,transform .17s}.rail-action>.icon{width:19px;height:19px}.rail-action:hover{background:rgba(255,255,255,.52);color:var(--ink)}.rail-action.active{color:var(--ink);background:rgba(255,255,255,.75);box-shadow:0 2px 10px rgba(25,25,20,.025);border:1px solid rgba(255,255,255,.7);padding:9px}.rail-action.active:after{content:"";position:absolute;right:-7px;top:17px;width:3px;height:8px;background:var(--ink);border-radius:4px}.rail-action:focus-visible,.rail-brand:focus-visible,.rail-project:focus-visible{outline:2px solid var(--ink);outline-offset:3px}.rail-label{display:none;white-space:nowrap;font-size:calc(14px + var(--ui-font-offset, 0px))}.nav-expanded .rail-action{justify-content:flex-start;padding-left:13px}.nav-expanded .rail-action.active{padding-left:12px}.nav-expanded .rail-label{display:block}.rail-divider{height:1px;background:var(--hair);margin:7px 9px 8px}.rail-pages{display:grid;gap:8px}.rail-tooltip{position:absolute;left:calc(100% + 15px);top:50%;transform:translateY(-50%) translateX(-3px);font-size:calc(14px + var(--ui-font-offset, 0px));white-space:nowrap;border:1px solid var(--hair);border-radius:8px;padding:7px 10px;background:var(--surface);box-shadow:var(--glass-shadow);backdrop-filter:blur(20px);color:var(--ink);opacity:0;visibility:hidden;pointer-events:none;transition:opacity .15s,transform .15s;z-index:100}.studio-shell:not(.nav-expanded) .rail-action:hover .rail-tooltip,.studio-shell:not(.nav-expanded) .rail-action:focus-visible .rail-tooltip{opacity:1;visibility:visible;transform:translateY(-50%)}.rail-projects{display:none;padding:22px 4px 0;overflow:auto;min-height:0}.nav-expanded .rail-projects{display:block}.rail-projects>.eyebrow{font-size:calc(14px + var(--ui-font-offset, 0px));padding:0 9px 10px;letter-spacing:1px}.rail-project{display:flex;align-items:center;gap:9px;font-size:calc(14px + var(--ui-font-offset, 0px));color:var(--muted);text-align:left;max-width:100%;width:100%;padding:10px 9px;border-radius:8px}.rail-project>span{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.rail-project:hover{background:var(--subtle);color:var(--ink)}.rail-bottom{margin-top:auto;display:grid;gap:6px;padding-top:18px}.rail-demo{display:none;color:var(--muted);font-size:calc(14px + var(--ui-font-offset, 0px));padding:0 13px 8px}.nav-expanded .rail-demo{display:block}.navigation-scrim{display:none}.studio-shell>.main{margin-left:var(--rail-width);padding:22px 30px 20px;min-height:100dvh;max-width:none;transition:margin-left .2s ease}.studio-shell .page-head{padding:0;min-height:0;margin:0 0 16px;align-items:center;justify-content:flex-end;border:0;background:none}.studio-shell .page-head .page-actions{align-items:center;flex-wrap:wrap;justify-content:flex-end}.studio-shell .page-head:has(.page-actions:empty){margin:0}.studio-shell .page-head:has(.page-actions:empty) .page-actions{display:none}.studio-shell .sectionbar{margin-bottom:16px}.studio-shell .canvas-page-head{margin-bottom:14px}.studio-shell .canvas-page-head~.wm-create-control{margin-top:0}.studio-shell .preview-panel{top:22px}.studio-shell .chat-layout{grid-template-columns:minmax(0,1fr);gap:0;min-height:calc(100dvh - 44px);position:relative;align-items:stretch}.studio-shell.chat-panel-open .chat-layout{grid-template-columns:230px minmax(0,1fr);gap:26px}.studio-shell .chat-history{display:none;min-width:0;padding:17px 14px 18px;margin:-10px 0 -8px -18px;border:1px solid rgba(255,255,255,.68);border-radius:18px;background:rgba(247,247,241,.56);box-shadow:0 4px 24px rgba(25,25,20,.025);backdrop-filter:blur(25px) saturate(1.06);-webkit-backdrop-filter:blur(25px) saturate(1.06);align-self:stretch;overflow:auto}.studio-shell.chat-panel-open .chat-history{display:block}.history-panel-heading{display:flex;align-items:center;justify-content:space-between;gap:10px;font-size:calc(14px + var(--ui-font-offset, 0px));margin-bottom:18px;padding:0 3px}.history-panel-heading strong{font-weight:450}.history-panel-heading .icon-btn{width:30px;height:30px}.studio-shell .chat-history>.btn{margin-bottom:21px;background:rgba(255,255,255,.65);border-color:var(--hair)}.studio-shell .chat-history .channel-select{flex-wrap:wrap}.studio-shell .chat-history .info-box{font-size:calc(14px + var(--ui-font-offset, 0px))!important}.studio-shell .chat-center{max-width:970px;width:100%;min-width:0}.studio-shell .chat-top{min-height:40px;margin-bottom:16px;justify-content:flex-start;gap:9px;flex-wrap:wrap}.studio-shell .chat-top>.tag{margin-left:auto;font-size:calc(14px + var(--ui-font-offset, 0px))}.history-toggle{display:inline-flex!important;border:1px solid transparent;background:transparent;color:var(--body);min-width:36px;min-height:36px;gap:7px}.history-toggle:hover{border-color:var(--hair);background:var(--surface)}.history-toggle span{font-size:calc(14px + var(--ui-font-offset, 0px))}.studio-shell .chat-top>.select{font-size:calc(14px + var(--ui-font-offset, 0px));width:170px}.studio-shell .chat-mobile-tools{display:flex;gap:5px;margin-left:auto}.studio-shell .chat-mobile-tools .select{font-size:calc(14px + var(--ui-font-offset, 0px));max-width:90px}.studio-shell .chat-top>.tag{display:none}.studio-shell .chat-empty{max-width:640px;padding:24px 0 36px}.studio-shell .chat-composer{width:min(100%,850px);align-self:center}.studio-shell .messages{width:min(100%,850px);align-self:center}.studio-shell .chat-extra-tools{justify-content:center;flex-wrap:wrap}.studio-shell .page-foot{margin-top:28px}.studio-shell .mobile-nav{display:none}.sr-only{position:absolute!important;width:1px!important;height:1px!important;padding:0!important;margin:-1px!important;overflow:hidden!important;clip:rect(0,0,0,0)!important;white-space:nowrap!important;border:0!important}
[data-theme=dark] .navigation-rail{background:rgba(29,31,27,.62);border-color:rgba(215,215,195,.1)}[data-theme=dark] .rail-brand{background:rgba(248,248,242,.96)}[data-theme=dark] .rail-action:hover{background:rgba(210,214,199,.07)}[data-theme=dark] .rail-action.active{background:rgba(230,231,218,.09);border-color:rgba(220,224,205,.1)}[data-theme=dark] .studio-shell .chat-history{background:rgba(38,41,34,.58);border-color:rgba(215,217,197,.1)}[data-theme=dark] .studio-shell .chat-history>.btn{background:rgba(230,230,208,.04)}
@media(min-width:1500px){.studio-shell>.main{padding:25px 38px 22px}.studio-shell.chat-panel-open .chat-layout{grid-template-columns:250px minmax(0,1fr);gap:36px}}
@media(min-width:741px) and (max-width:1050px){.studio-shell.nav-expanded{--rail-width:188px}.rail-wordmark{width:103px}.studio-shell>.main{padding:20px}.studio-shell.chat-panel-open .chat-layout{grid-template-columns:205px minmax(0,1fr);gap:18px}.studio-shell .chat-history{margin-left:-8px;padding:14px 10px}.studio-shell .chat-top>.select{width:136px}.history-toggle span{display:none}.studio-shell.nav-expanded .create-grid{grid-template-columns:minmax(265px,.85fr) minmax(0,1.15fr)}.studio-shell.nav-expanded .sectionbar p{display:none}.studio-shell.nav-expanded .settings-layout{grid-template-columns:130px minmax(0,1fr)}}
@media(max-width:740px){.studio-shell,.studio-shell.nav-expanded{--rail-width:0px}.studio-shell>.main{margin-left:0;padding:16px 16px 100px;min-height:100dvh;transition:none}.navigation-rail{width:min(264px,calc(100vw - 48px));transform:translateX(-105%);visibility:hidden;pointer-events:none;padding:20px 17px;transition:transform .2s ease,visibility .2s;border-right:1px solid var(--line);background:rgba(244,245,237,.87);z-index:90;box-shadow:14px 0 45px rgba(15,20,10,.06)}.mobile-nav-open .navigation-rail{transform:translateX(0);visibility:visible;pointer-events:auto}.navigation-rail .rail-wordmark{display:block;width:143px}.navigation-rail .rail-action{justify-content:flex-start;padding-left:13px;min-height:46px}.navigation-rail .rail-action.active{padding-left:12px}.navigation-rail .rail-label{display:block;font-size:calc(14px + var(--ui-font-offset, 0px))}.navigation-rail .rail-projects,.navigation-rail .rail-demo{display:block}.navigation-rail .rail-tooltip{display:none}.rail-brand{padding:5px 8px;height:44px}.rail-action.active:after{right:0}.navigation-scrim:not([hidden]){display:block;position:fixed;inset:0;background:rgba(25,28,22,.2);backdrop-filter:blur(4px);-webkit-backdrop-filter:blur(4px);z-index:85}.studio-shell .mobile-nav{display:flex;z-index:75;left:12px;right:12px;bottom:max(10px,env(safe-area-inset-bottom));height:66px;gap:3px}.studio-shell .mobile-nav button{flex:1;min-width:0;font-size:calc(14px + var(--ui-font-offset, 0px));gap:5px;padding:7px 3px;min-height:45px}.studio-shell .mobile-nav .icon{width:19px;height:19px}.studio-shell .page-head{margin-bottom:13px}.studio-shell .page-actions{width:100%;gap:7px}.studio-shell .page-actions .btn{font-size:calc(14px + var(--ui-font-offset, 0px));padding:8px 10px}.studio-shell .creation-view-toggle{margin-left:auto}.studio-shell .chat-layout,.studio-shell.chat-panel-open .chat-layout{grid-template-columns:minmax(0,1fr);gap:0;min-height:calc(100dvh - 130px)}.studio-shell .chat-history,.studio-shell.chat-panel-open .chat-history{display:block;position:fixed;inset:10px auto 10px 10px;width:min(300px,calc(100vw - 40px));max-width:none;margin:0;padding:20px 16px;border-radius:18px;z-index:90;transform:translateX(-115%);visibility:hidden;pointer-events:none;background:rgba(247,248,240,.88);transition:transform .2s ease,visibility .2s;overflow-y:auto}.studio-shell.mobile-history-open .chat-history{transform:translateX(0);visibility:visible;pointer-events:auto}.studio-shell .chat-top{gap:5px;flex-wrap:wrap;margin-bottom:18px}.studio-shell .chat-top>.select{width:124px;font-size:calc(14px + var(--ui-font-offset, 0px))}.studio-shell .chat-top>.history-toggle{min-width:34px;min-height:34px;padding:5px}.history-toggle span{display:none}.studio-shell .chat-mobile-tools{margin-left:auto;gap:2px}.studio-shell .chat-mobile-tools .select{width:73px;font-size:calc(14px + var(--ui-font-offset, 0px));padding:5px}.studio-shell .chat-mobile-tools .icon-btn{width:30px;height:34px}.studio-shell .chat-composer{bottom:84px;width:100%}.studio-shell .chat-empty{padding-top:18px}.studio-shell .chat-empty h1{font-size:calc(26px + var(--ui-font-offset, 0px))}.studio-shell .page-foot{margin-top:22px}.studio-shell .canvas-page-head .page-actions{justify-content:flex-end}.studio-shell .preview-panel{top:16px}.studio-shell .settings-layout{grid-template-columns:minmax(0,1fr)}[data-theme=dark] .navigation-rail{background:rgba(30,33,27,.9)}[data-theme=dark] .studio-shell .chat-history{background:rgba(34,38,30,.91)}}
@supports not (backdrop-filter:blur(1px)){.navigation-rail,.studio-shell .chat-history{background:#eeeee7}.navigation-scrim:not([hidden]){background:rgba(25,28,22,.4)}[data-theme=dark] .navigation-rail,[data-theme=dark] .studio-shell .chat-history{background:#252821}}
@media(prefers-reduced-motion:reduce){.navigation-rail,.studio-shell>.main,.rail-action,.rail-tooltip,.studio-shell .chat-history{transition:none!important}}
/* Lightweight edge controls sit in the content, without a full-width application header. */
.studio-shell.nav-expanded{--rail-width:var(--expanded-rail-width,208px)}.studio-shell.chat-panel-open .chat-layout{grid-template-columns:var(--history-panel-width,230px) minmax(0,1fr)}.workspace-edge{display:flex;align-items:center;justify-content:space-between;gap:12px;margin:-8px 0 10px;min-height:28px;background:none;border:0}.edge-buttons{display:flex;align-items:center;gap:3px}.edge-buttons .icon-btn{width:29px;height:29px;color:var(--muted)}.interaction-spec-link{font-size:calc(14px + var(--ui-font-offset, 0px));color:var(--muted);padding:5px 0;white-space:nowrap}.interaction-spec-link:hover{text-decoration:underline;text-underline-offset:3px}.panel-resize-handle{position:absolute;right:-4px;top:8px;bottom:8px;width:8px;cursor:col-resize;touch-action:none;z-index:65;border-radius:6px}.panel-resize-handle:after{content:"";position:absolute;top:8px;bottom:8px;left:3px;width:2px;border-radius:3px;background:transparent;transition:background .15s}.panel-resize-handle:hover:after,.panel-resize-handle:focus-visible:after{background:var(--muted)}.panel-resize-handle:focus-visible{outline:2px solid var(--ink);outline-offset:0}.rail-resize{display:none}.nav-expanded .rail-resize{display:block}.studio-shell .chat-history{position:relative;overflow:visible}.studio-shell .chat-history .history-resize{right:-5px}.studio-shell .chat-layout{min-height:calc(100dvh - 83px)}
@media(min-width:801px){.studio-shell.canvas-panel-hidden .cv-shell{grid-template-columns:minmax(0,1fr)}.studio-shell.canvas-panel-hidden .cv-inspector{display:none}}
@media(min-width:741px) and (max-width:1000px){.studio-shell.nav-expanded .create-grid{grid-template-columns:minmax(0,1fr)}.studio-shell.nav-expanded .settings-layout{grid-template-columns:minmax(0,1fr)}.studio-shell.nav-expanded .settings-nav{display:flex;flex-wrap:wrap;gap:4px}.studio-shell.nav-expanded .settings-nav button{width:auto}}
@media(max-width:740px){.studio-shell,.studio-shell.nav-expanded{--rail-width:0px}.studio-shell.chat-panel-open .chat-layout{grid-template-columns:minmax(0,1fr)}.workspace-edge{margin:-3px 0 8px;min-height:26px}.edge-buttons .icon-btn{width:29px;height:29px}.panel-resize-handle{display:none!important}.studio-shell .chat-history{position:fixed;overflow-y:auto}.studio-shell .chat-layout{min-height:calc(100dvh - 166px)}}
/* Representative interaction states: hover is a hint; selection remains persistent. */
.rail-action,.edge-buttons .icon-btn,.wm-manager .btn,.wm-create-control .btn{transition:background-color 150ms ease,border-color 150ms ease,color 150ms ease,opacity 150ms ease}.edge-buttons .icon-btn{position:relative}.edge-buttons .icon-btn:after{content:attr(data-tooltip);position:absolute;left:0;top:calc(100% + 8px);padding:7px 10px;border:1px solid var(--hair);border-radius:8px;background:var(--ink);color:var(--canvas);font-size:calc(14px + var(--ui-font-offset, 0px));line-height:1.5;white-space:nowrap;opacity:0;visibility:hidden;pointer-events:none;z-index:75;transition:opacity 150ms ease}.edge-buttons .icon-btn:hover,.edge-buttons .icon-btn[aria-expanded=true]{background:var(--subtle);color:var(--ink)}.edge-buttons .icon-btn:hover:after,.edge-buttons .icon-btn:focus-visible:after{opacity:1;visibility:visible}.edge-buttons .icon-btn:focus-visible{outline:2px solid var(--ink);outline-offset:3px}.rail-action:active:not(:disabled),.edge-buttons .icon-btn:active:not(:disabled){background:color-mix(in srgb,var(--ink) 11%,transparent);color:var(--ink)}.rail-action.active:hover{background:color-mix(in srgb,var(--surface) 88%,var(--ink) 5%)}.wm-manager .btn:hover:not(:disabled),.wm-create-control .btn:hover:not(:disabled){border-color:var(--line);background:var(--subtle);color:var(--ink)}.wm-manager .btn.primary:hover:not(:disabled){background:var(--accent-hover);color:var(--canvas)}.wm-manager .btn:active:not(:disabled),.wm-create-control .btn:active:not(:disabled){opacity:.82}.rail-action:disabled,.edge-buttons .icon-btn:disabled,.wm-manager .btn:disabled{opacity:.38;cursor:not-allowed;box-shadow:none;pointer-events:none}
@media(hover:none){.rail-tooltip,.edge-buttons .icon-btn:after{display:none!important}.rail-action:hover:not(.active){background:transparent;color:var(--muted)}.edge-buttons .icon-btn:hover:not([aria-expanded=true]){background:transparent;color:var(--muted)}.wm-manager .btn:hover:not(:disabled):not(.primary),.wm-create-control .btn:hover:not(:disabled){background:var(--surface);border-color:var(--hair)}}
@media(prefers-reduced-motion:reduce){.rail-action,.edge-buttons .icon-btn,.edge-buttons .icon-btn:after,.wm-manager .btn,.wm-create-control .btn{transition:none!important}}

/* Expanded navigation remains fully reachable in short viewports. */
.navigation-rail{overscroll-behavior:contain;scrollbar-width:thin;scrollbar-color:var(--line) transparent}.studio-shell.nav-expanded .navigation-rail,.studio-shell.mobile-nav-open .navigation-rail{overflow-y:auto}
.navigation-rail>.rail-brand,.navigation-rail>.rail-toggle,.navigation-rail>.rail-divider,.navigation-rail>.rail-pages,.navigation-rail>.rail-bottom{flex-shrink:0}
.navigation-rail>.rail-bottom{margin-top:auto}
@media(max-width:740px){.navigation-rail{max-height:100dvh}.studio-shell.mobile-nav-open .navigation-rail{overflow-y:auto}.navigation-rail>.rail-bottom{padding-bottom:max(8px,env(safe-area-inset-bottom))}}
