/* Nexus adapter for stored Connect v41.5 / header-compact / sidebar-profile-v56.
   Scoped presentation: routes, permissions, client data and payment logic unchanged. */
html[data-theme="light"] body.nexus-template.nexus-bottom-layout { --nx-rail-space:108px;--nx-rail-width:90px;--nx-header-height:80px;--nx-dock-height:0px;--nx-connect-accent:#008f95;background:#f3f6fb!important; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .main.page-body { margin:0 0 0 var(--nx-rail-space)!important;width:calc(100% - var(--nx-rail-space))!important;height:100vh!important;height:100dvh!important;min-height:0!important;display:flex!important;flex-direction:column!important;overflow:hidden!important; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .main .topbar.page-main-header { flex:0 0 var(--nx-header-height)!important;min-height:var(--nx-header-height)!important;height:var(--nx-header-height)!important;background:#e5f2e8!important;border-bottom-color:#d7e8e7!important; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .content { padding:24px!important;min-height:0!important;flex:1 1 0%;overflow:auto!important;background:#f3f6fb!important; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .nx-dock { position:fixed;inset:12px auto 12px 10px;width:var(--nx-rail-width);height:calc(100vh - 24px);height:calc(100dvh - 24px);max-height:none;min-height:0;display:flex;flex-direction:column;align-items:center;padding:58px 12px 58px 6px;overflow:visible;box-sizing:border-box; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .nx-dock::before { inset:0;background:#e5f2e8;border:1px solid #d1e6dc;border-radius:0 100% 100% 0 / 0 50% 50% 0;box-shadow:none; }
.nx-left-rail .nx-dock-watermark { position:absolute;inset:50% auto auto 69px;transform:translate(-50%,-50%) rotate(-90deg);font-size:30px;line-height:1;font-weight:800;letter-spacing:4px;color:#008f95;opacity:.13;white-space:nowrap;z-index:0; }
.nx-left-rail .nx-dock-scroller { position:relative;z-index:1;flex:1 1 0%;width:100%;max-width:none;min-height:0;height:auto;margin:0;overflow-y:auto;overflow-x:hidden;scrollbar-width:thin;scrollbar-color:#a5c8bf transparent;overscroll-behavior:contain; }
.nx-left-rail .nx-dock-scroller::-webkit-scrollbar { display:block;width:4px;height:0; }
.nx-left-rail .nx-dock-scroller::-webkit-scrollbar-thumb { background:#a5c8bf;border-radius:3px; }
.nx-left-rail .nx-dock-items { display:flex;flex-direction:column;align-items:center;justify-content:flex-start;position:relative;width:100%;height:auto;min-height:min-content;margin:0;padding:4px 0;gap:7px; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .nx-left-rail .nx-dock-item { width:44px;height:44px;min-height:44px;flex:0 0 44px;padding:10px;border:0;border-radius:9px;background:transparent;color:#647e87;box-shadow:none; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .nx-left-rail .nx-dock-item:hover { background:#d7eeea;color:#008f95;border:0; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .nx-left-rail .nx-dock-item.active { background:#d3ebe7;color:#006d72;border:1px solid #b4d8d1; }
.nx-left-rail .nx-dock-item svg { width:22px;height:22px;stroke-width:1.8; }
.nx-left-rail .nx-dock-item:focus-visible { outline:2px solid #008f95;outline-offset:-2px; }
.nx-dock-tooltip { max-width:min(240px,calc(100vw - var(--nx-rail-space) - 20px));white-space:normal;overflow-wrap:anywhere; }
/* The non-JavaScript fallback is the same left navigation with readable labels. */
.nexus-dock-source { inset:12px auto 12px 10px;width:var(--nx-rail-width);max-height:calc(100dvh - 24px);overflow:auto;flex-direction:column;background:#e5f2e8; }
/* A top AND bottom inset stretched the toast grid over the editor. Keep intrinsic rows. */
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .nexus-toast-region { top:calc(var(--nx-header-height) + 10px)!important;bottom:auto!important;left:auto!important;right:16px!important;height:auto!important;max-height:min(42dvh,350px);width:min(360px,calc(100vw - var(--nx-rail-space) - 24px));display:grid;grid-auto-rows:max-content;align-content:start;align-items:start;gap:10px;overflow-y:auto;pointer-events:none; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .nexus-toast { height:auto!important;min-height:0!important;align-self:start;max-height:280px;overflow:auto!important;border-radius:9px!important;padding:12px!important;grid-template-columns:30px minmax(0,1fr) 28px;gap:9px;background:#fff!important; }
.nexus-toast .nexus-toast-icon { width:30px;height:30px;border-radius:7px; }.nexus-toast .nexus-toast-heading{flex-wrap:wrap;gap:4px}.nexus-toast .nexus-toast-heading strong{font-size:13px}.nexus-toast .nexus-toast-heading time{font-size:10px}.nexus-toast .nexus-toast-dismiss{width:28px;height:28px}.nexus-toast .nexus-toast-progress{overflow:hidden}
/* Editor remains one form: workflow buttons and schedule belong to the same submission. */
html[data-theme="light"] body.nexus-template.nexus-bottom-layout [data-marketing-editor] { min-width:0;max-width:1440px;margin:0 auto; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .enterprise-editor-layout { display:grid;grid-template-columns:minmax(0,1fr) minmax(270px,340px);gap:20px;align-items:start; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .enterprise-editor-main,
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .enterprise-editor-aside { min-width:0;display:flex;flex-direction:column;gap:18px;position:static!important;align-self:start; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .enterprise-editor-header { display:flex;align-items:flex-start;justify-content:space-between;gap:16px;flex-wrap:wrap; }
.enterprise-editor-header-actions { display:flex;gap:8px;flex-wrap:wrap;align-items:center; }.enterprise-editor-header>div:first-child{min-width:0;flex:1 1 430px}
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .enterprise-editor .panel { border:1px solid #dfe8ed!important;border-radius:8px!important;background:#fff!important; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .enterprise-editor .workflow-card { display:flex;flex-direction:column;gap:16px;padding:20px!important; }
.enterprise-editor .workflow-card-head p { margin:8px 0 0;font-size:12px;line-height:1.5; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .enterprise-editor .workflow-progress { display:grid;gap:0;padding:0; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .enterprise-editor .workflow-step { position:relative;display:grid;grid-template-columns:28px minmax(0,1fr);gap:12px;padding:0 0 20px;min-height:62px;align-items:start;opacity:1; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .enterprise-editor .workflow-step:last-child { padding-bottom:0;min-height:38px; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .enterprise-editor .workflow-step::before { content:"";position:absolute;left:13px;top:30px;bottom:3px;width:2px;background:#e1e9ed; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .enterprise-editor .workflow-step:last-child::before { display:none; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .enterprise-editor .workflow-step>span { display:grid;place-items:center;width:28px;height:28px;margin:0;padding:0;border:1px solid #d7e2e8;border-radius:50%;background:#f5f8fa!important;color:#6c8293!important;font-size:12px;font-weight:700; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .enterprise-editor .workflow-step.is-current>span { background:#008f95!important;color:#fff!important;border-color:#008f95; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .enterprise-editor .workflow-step.is-complete>span { background:#e2f2e8!important;color:#26704e!important;border-color:#b8d9c4; }
.enterprise-editor .workflow-step strong{display:block;font-size:13px;line-height:1.4}.enterprise-editor .workflow-step small{display:block;font-size:11px;line-height:1.4;margin-top:3px}
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .enterprise-editor .workflow-attention { margin:0;padding:10px;border:1px solid #ecd8ae;background:#fff8e8;color:#785d27!important;border-radius:6px;font-size:12px; }
.enterprise-editor .workflow-card .full{width:100%;margin-top:10px}.enterprise-editor .enterprise-editor-actions{position:static!important;display:flex;justify-content:space-between;gap:12px;flex-wrap:wrap}.enterprise-editor-actions>div:last-child{display:flex;gap:8px;flex-wrap:wrap}
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .enterprise-editor .nexus-creative-image-preview { min-height:180px;max-height:none; }.enterprise-editor .nexus-creative-image-preview img { max-height:380px!important; }
@media(max-width:1100px){html[data-theme="light"] body.nexus-template.nexus-bottom-layout .enterprise-editor-layout{grid-template-columns:minmax(0,1fr)}html[data-theme="light"] body.nexus-template.nexus-bottom-layout .enterprise-editor-aside{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);align-items:start}.enterprise-editor-aside>.editor-accordion{grid-column:1/-1}}
@media(max-width:700px){html[data-theme="light"] body.nexus-template.nexus-bottom-layout{--nx-rail-space:70px;--nx-rail-width:62px;--nx-header-height:64px}.nx-left-rail .nx-dock-watermark{left:47px;font-size:23px}.nx-left-rail .nx-dock-items{gap:6px}html[data-theme="light"] body.nexus-template.nexus-bottom-layout .nx-dock{left:4px;padding:28px 5px 28px 1px}html[data-theme="light"] body.nexus-template.nexus-bottom-layout .nx-left-rail .nx-dock-item{width:40px;flex-basis:40px;min-height:40px;height:40px;padding:9px}html[data-theme="light"] body.nexus-template.nexus-bottom-layout .content{padding:14px!important}html[data-theme="light"] body.nexus-template.nexus-bottom-layout .enterprise-editor-aside{display:flex}.enterprise-editor :is(.moc-form-row,.editor-schedule-fields){grid-template-columns:minmax(0,1fr)!important}.enterprise-editor .enterprise-editor-header h2{font-size:22px!important}.enterprise-editor .btn{white-space:normal!important}.enterprise-editor .editor-section{padding:16px!important}.enterprise-editor-header>div:first-child{flex-basis:auto}html[data-theme="light"] body.nexus-template.nexus-bottom-layout .topbar.page-main-header{padding:10px 12px!important}.nexus-header-brand>span{font-size:17px}.nexus-header-brand img{width:28px;height:28px}.nexus-header-brand{gap:6px!important}.topbar-actions{gap:6px!important}.signout-btn span{display:none!important}.signout-btn{min-width:32px!important;padding:7px!important}}
@media print{.nx-left-rail{display:none!important}html[data-theme="light"] body.nexus-template.nexus-bottom-layout .main.page-body{margin:0!important;width:100%!important;height:auto!important;overflow:visible!important}}
/* Geometry switches atomically; legacy sidebar margin animations can overlap the rail. */
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .main.page-body { transition:none!important; }
/* Replace the legacy offset connector rather than drawing two timelines. */
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .enterprise-editor .workflow-step { border:0!important;background:transparent!important;box-shadow:none!important; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .enterprise-editor .workflow-step::after { display:none!important; }
/* Rail refinement: hide only its scrollbar; wheel, touch and keyboard still scroll. */
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .nx-left-rail .nx-dock-scroller { scrollbar-width:none!important;-ms-overflow-style:none;overflow-y:auto;overflow-x:hidden; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .nx-left-rail .nx-dock-scroller::-webkit-scrollbar { display:none!important;width:0!important;height:0!important; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .nx-dock { padding-top:30px;padding-bottom:30px; }
.nx-left-rail .nx-dock-items { gap:5px; }
@media(max-width:700px){html[data-theme="light"] body.nexus-template.nexus-bottom-layout .nx-dock{padding-top:20px;padding-bottom:20px}.nx-left-rail .nx-dock-items{gap:5px}}
/* Header/rail v3: Connect-like menus and a guaranteed solid lane for every icon. */
html[data-theme="light"] body.nexus-template.nexus-bottom-layout { --nx-rail-space:120px;--nx-rail-width:96px;--nx-header-height:96px; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .content { background:#e7f3f2!important; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .nx-dock { left:0;top:12px;bottom:12px;width:96px;align-items:flex-start;padding:28px 32px 28px 0; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .nx-dock::before { inset:0 auto 0 0;width:64px;background:#fff;border:0;border-radius:0; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .nx-dock::after { content:"";position:absolute;z-index:-1;inset:0 0 0 64px;background:#fff;border-radius:0 100% 100% 0 / 0 50% 50% 0;pointer-events:none; }
.nx-left-rail .nx-dock-scroller { align-self:flex-start;width:56px;max-width:56px;margin:0 0 0 4px; }
.nx-left-rail .nx-dock-items { width:56px;padding:4px 0;gap:6px; }
.nx-left-rail .nx-dock-watermark { left:79px;font-size:30px;opacity:.10; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .nx-left-rail .nx-dock-item { width:44px;height:44px;flex:0 0 44px;border-radius:10px; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .main .topbar.page-main-header { height:auto!important;min-height:96px!important;flex:0 0 auto!important;display:flex!important;align-items:center;justify-content:space-between;flex-wrap:nowrap;gap:20px;padding:14px 24px!important;background:#e7f3f2!important;overflow:visible!important; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .topbar-left { flex:0 0 auto;gap:0!important; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .nexus-header-brand { display:flex;width:220px;height:66px;padding:0!important;background:transparent!important; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .nexus-header-brand img { width:220px!important;height:66px!important;max-width:100%!important;object-fit:contain;object-position:left center;background:transparent!important; }
.nx-header-menu { display:flex;align-items:center;justify-content:flex-start;gap:8px;flex:1 1 auto;min-width:0; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout button.nx-header-menu-button { display:inline-flex;align-items:center;justify-content:center;gap:8px;min-height:42px;padding:9px 10px;border:0!important;background:transparent!important;color:#617f88!important;font-size:13px;font-weight:600;border-radius:6px;white-space:nowrap;box-shadow:none!important;cursor:pointer; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout button.nx-header-menu-button:is(:hover,.active,[aria-expanded="true"]) { background:#d7eae8!important;color:#008f95!important; }
.nx-header-menu-button:focus-visible { outline:2px solid #008f95;outline-offset:2px; }.nx-menu-chevron{font-size:13px;line-height:1; }
.nx-header-dropdown { position:fixed;z-index:1900;background:#fff;border:1px solid #dbe6e8;border-radius:8px;padding:10px;overflow:auto;box-shadow:0 8px 24px #234d5315; }
.nx-header-dropdown[hidden] { display:none!important; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .nx-header-dropdown-link { display:flex;align-items:center;gap:12px;min-height:42px;padding:10px;border:0;border-radius:5px;background:#fff;color:#637386;font-size:12px;text-decoration:none; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .nx-header-dropdown-link:is(:hover,.active) { background:#eef7f6;color:#008f95; }
.nx-header-dropdown-link .nx-dock-label { position:static;width:auto;height:auto;clip-path:none;white-space:normal; }
.nx-header-dropdown-link svg { display:block;width:20px;height:20px;flex:0 0 20px;fill:none;stroke:#178bfb;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round; }
.nx-header-dropdown-link[aria-disabled="true"] { opacity:.55; }
.nx-header-dropdown-link:focus-visible { outline:2px solid #008f95;outline-offset:-2px; }
.nx-header-dropdown-link .nx-dock-badge { position:static;margin-left:auto;border:0; }
html[data-theme="light"] body.nexus-template.nexus-bottom-layout .content :is(.panel,.metric,.metric-card,.hero-panel,.moc-hero,.calendar-hero,.nx-content-card) { border-radius:10px!important;border-color:#d8e7ea!important; }
@media(max-width:1100px){html[data-theme="light"] body.nexus-template.nexus-bottom-layout .main .topbar.page-main-header { display:grid!important;grid-template-columns:minmax(0,1fr) auto;grid-template-areas:"brand actions" "menu menu";gap:8px 12px;padding:10px 18px!important;min-height:124px!important; }.topbar-left{grid-area:brand}.topbar-actions{grid-area:actions}.nx-header-menu{grid-area:menu;overflow-x:auto;scrollbar-width:none;justify-content:flex-start;padding-bottom:3px;}.nx-header-menu::-webkit-scrollbar{display:none}html[data-theme="light"] body.nexus-template.nexus-bottom-layout .nexus-header-brand,html[data-theme="light"] body.nexus-template.nexus-bottom-layout .nexus-header-brand img{width:200px!important;height:56px!important}}
@media(max-width:700px){html[data-theme="light"] body.nexus-template.nexus-bottom-layout{--nx-rail-space:72px;--nx-rail-width:62px;--nx-header-height:124px}html[data-theme="light"] body.nexus-template.nexus-bottom-layout .nx-dock{width:62px;left:0;padding:20px 14px 20px 0}html[data-theme="light"] body.nexus-template.nexus-bottom-layout .nx-dock::before{width:48px}html[data-theme="light"] body.nexus-template.nexus-bottom-layout .nx-dock::after{left:48px}.nx-left-rail .nx-dock-scroller{width:46px;max-width:46px;margin-left:0}.nx-left-rail .nx-dock-items{width:46px;gap:6px}.nx-left-rail .nx-dock-watermark{left:54px;font-size:22px}html[data-theme="light"] body.nexus-template.nexus-bottom-layout .nx-left-rail .nx-dock-item{width:40px;height:40px;flex-basis:40px;min-height:40px}html[data-theme="light"] body.nexus-template.nexus-bottom-layout .main .topbar.page-main-header{padding:8px 10px!important}html[data-theme="light"] body.nexus-template.nexus-bottom-layout .nexus-header-brand,html[data-theme="light"] body.nexus-template.nexus-bottom-layout .nexus-header-brand img{width:min(170px,100%)!important;height:54px!important}.nx-header-menu{gap:2px}html[data-theme="light"] body.nexus-template.nexus-bottom-layout button.nx-header-menu-button{font-size:11px;padding:8px}.topbar-actions{gap:5px!important}.nexus-header-brand{min-width:0!important}}
@media print{.nx-header-menu,.nx-header-dropdown{display:none!important}.nx-left-rail::after{display:none!important}}
.nx-left-rail .nx-dock-scroller { scroll-snap-type:y proximity;scroll-padding-top:4px; }
.nx-left-rail .nx-dock-item { scroll-snap-align:start; }
/* Use the same supplied transparent artwork on all authentication headers. */
html[data-theme="light"] body.auth-shell.nexus-template .auth-brand,
html[data-theme="light"] body.auth-shell.nexus-template .login-logo-header { background:transparent!important;background-image:none!important; }
html[data-theme="light"] body.auth-shell.nexus-template .auth-brand img,
html[data-theme="light"] body.auth-shell.nexus-template .nexus-centered-login .login-logo-header img { object-fit:contain!important;background:transparent!important; }

/* Center short menus; tall lists grow naturally and remain fully scrollable. */
.nx-left-rail .nx-dock-items { min-height:100%;box-sizing:border-box;justify-content:center; }
