:root{
  --moonga-shell-bg:#070910;
  --moonga-shell-panel:#10141d;
  --moonga-shell-panel-2:#111722;
  --moonga-shell-line:rgba(255,255,255,.10);
  --moonga-shell-line-strong:rgba(255,255,255,.18);
  --moonga-shell-text:#f5f7fb;
  --moonga-shell-muted:#9ba6ba;
  --moonga-shell-green:#53fc18;
  --moonga-shell-purple:#9146ff;
  --moonga-shell-width:1680px;
  --moonga-shell-header-height:72px;
  --moonga-shell-header-padding:32px;
  --moonga-shell-logo-width:172px;
}

html{background:var(--moonga-shell-bg)!important}
html,body{min-height:100%}
body.moonga-site-background,
html body.moonga-site-background.moonga-site-background.moonga-site-background{
  min-height:100vh!important;
  margin:0!important;
  position:relative!important;
  isolation:isolate!important;
  color:var(--moonga-shell-text);
  background:transparent!important;
}
body.moonga-site-background::before{
  content:"";
  position:fixed;
  inset:0;
  z-index:-1;
  pointer-events:none;
  background-color:var(--moonga-shell-bg);
  background-image:
    radial-gradient(circle at 8% 0%,rgba(145,70,255,.22),transparent 32%),
    radial-gradient(circle at 94% 5%,rgba(83,252,24,.12),transparent 29%),
    linear-gradient(180deg,#070910 0%,#090c14 46%,#070910 100%);
  background-repeat:no-repeat,no-repeat,no-repeat;
  background-position:left top,right top,center top;
  background-size:auto,auto,cover;
  transform:translateZ(0);
}

/* Make the index background visible through the common page wrappers. */
body.moonga-site-background .app,
body.moonga-site-background .main,
body.moonga-site-background .content,
body.moonga-site-background .page-shell,
body.moonga-site-background .public-shell,
body.moonga-site-background .standalone-shell{
  background-color:transparent!important;
}

/* Reserve header space while the login state is being resolved. */
.moonga-unified-header-placeholder{
  display:block!important;
  width:100%!important;
  height:var(--moonga-shell-header-height)!important;
  min-height:var(--moonga-shell-header-height)!important;
  margin:0!important;
  padding:0!important;
  visibility:hidden!important;
  overflow:hidden!important;
  border:0!important;
}

.moonga-unified-header{
  box-sizing:border-box!important;
  position:sticky!important;
  top:0!important;
  z-index:100000!important;
  display:block!important;
  width:100%!important;
  height:var(--moonga-shell-header-height)!important;
  min-height:var(--moonga-shell-header-height)!important;
  margin:0!important;
  padding:0!important;
  overflow:visible!important;
  border:0!important;
  border-bottom:1px solid var(--moonga-shell-line)!important;
  background:rgba(7,9,16,.90)!important;
  box-shadow:none!important;
  backdrop-filter:blur(20px)!important;
  -webkit-backdrop-filter:blur(20px)!important;
  font-family:Inter,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Arial,sans-serif!important;
}
.moonga-unified-header *{box-sizing:border-box}
.moonga-unified-header-inner{
  width:100%!important;
  max-width:var(--moonga-shell-width)!important;
  height:var(--moonga-shell-header-height)!important;
  min-height:var(--moonga-shell-header-height)!important;
  margin:0 auto!important;
  padding:0 var(--moonga-shell-header-padding)!important;
  display:flex!important;
  align-items:center!important;
  flex-wrap:nowrap!important;
  gap:24px!important;
  overflow:visible!important;
}
.moonga-unified-logo{
  width:var(--moonga-shell-logo-width)!important;
  min-width:var(--moonga-shell-logo-width)!important;
  max-width:var(--moonga-shell-logo-width)!important;
  height:34px!important;
  min-height:34px!important;
  padding:0!important;
  margin:0!important;
  display:flex!important;
  align-items:center!important;
  flex:0 0 var(--moonga-shell-logo-width)!important;
  border:0!important;
  background:transparent!important;
  text-decoration:none!important;
}
.moonga-unified-logo img{
  display:block!important;
  width:var(--moonga-shell-logo-width)!important;
  height:34px!important;
  max-height:34px!important;
  object-fit:contain!important;
}
.moonga-unified-nav{
  height:var(--moonga-shell-header-height)!important;
  min-height:var(--moonga-shell-header-height)!important;
  margin:0 0 0 auto!important;
  padding:0!important;
  display:flex!important;
  align-items:center!important;
  justify-content:flex-end!important;
  flex:1 1 auto!important;
  flex-wrap:nowrap!important;
  gap:5px!important;
  overflow:visible!important;
  white-space:nowrap!important;
}
.moonga-unified-link,
.moonga-unified-menu-button{
  appearance:none!important;
  -webkit-appearance:none!important;
  height:40px!important;
  min-height:40px!important;
  padding:0 13px!important;
  margin:0!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:6px!important;
  flex:0 0 auto!important;
  border:1px solid transparent!important;
  border-radius:10px!important;
  color:#cbd3e2!important;
  background:transparent!important;
  box-shadow:none!important;
  font:inherit!important;
  font-size:14px!important;
  font-weight:750!important;
  line-height:1!important;
  letter-spacing:0!important;
  text-decoration:none!important;
  text-transform:none!important;
  cursor:pointer!important;
  transition:background .15s ease,border-color .15s ease,color .15s ease!important;
}
.moonga-unified-link:hover,
.moonga-unified-link.is-active,
.moonga-unified-menu-button:hover,
.moonga-unified-menu.open .moonga-unified-menu-button{
  color:#fff!important;
  border-color:var(--moonga-shell-line)!important;
  background:rgba(255,255,255,.055)!important;
  transform:none!important;
}
.moonga-unified-login{
  color:#fff!important;
  border-color:var(--moonga-shell-line)!important;
  background:rgba(255,255,255,.035)!important;
}
.moonga-unified-dashboard{
  color:#cbd3e2!important;
  border-color:transparent!important;
  background:transparent!important;
}
.moonga-unified-dashboard.is-active{
  color:#fff!important;
  border-color:var(--moonga-shell-line)!important;
  background:rgba(255,255,255,.055)!important;
}
.moonga-unified-admin{font-weight:900!important;color:#fff!important}
.moonga-unified-menu{position:relative!important;display:block!important;flex:0 0 auto!important}
.moonga-unified-caret{font-size:10px!important;color:var(--moonga-shell-muted)!important;transform:translateY(1px)!important}
.moonga-unified-menu-panel{
  position:fixed!important;
  z-index:100100!important;
  top:80px;
  left:auto;
  width:min(340px,calc(100vw - 24px))!important;
  max-height:min(620px,calc(100vh - 96px))!important;
  padding:8px!important;
  display:none!important;
  overflow:auto!important;
  gap:3px!important;
  border:1px solid var(--moonga-shell-line-strong)!important;
  border-radius:14px!important;
  background:linear-gradient(180deg,rgba(17,22,34,.99),rgba(9,12,20,.99))!important;
  box-shadow:0 24px 75px rgba(0,0,0,.55)!important;
}
.moonga-unified-menu.open .moonga-unified-menu-panel{display:grid!important}
.moonga-unified-menu-panel>a,
.moonga-unified-menu-panel>button,
.moonga-unified-menu-item{
  width:100%!important;
  min-height:40px!important;
  padding:9px 11px!important;
  margin:0!important;
  display:flex!important;
  align-items:center!important;
  justify-content:flex-start!important;
  border:1px solid transparent!important;
  border-radius:9px!important;
  color:#d8deea!important;
  background:transparent!important;
  box-shadow:none!important;
  font:inherit!important;
  font-size:13px!important;
  font-weight:700!important;
  line-height:1.25!important;
  text-align:left!important;
  text-decoration:none!important;
  cursor:pointer!important;
}
.moonga-unified-menu-panel>a:hover,
.moonga-unified-menu-panel>button:hover,
.moonga-unified-menu-item:hover{
  color:#fff!important;
  border-color:var(--moonga-shell-line)!important;
  background:rgba(255,255,255,.055)!important;
  transform:none!important;
}
.moonga-unified-menu-item span{display:grid!important;gap:3px!important;min-width:0!important}
.moonga-unified-menu-item b{color:#fff!important;font-size:13px!important;overflow:hidden!important;text-overflow:ellipsis!important}
.moonga-unified-menu-item small{color:var(--moonga-shell-muted)!important;font-size:11px!important;text-transform:capitalize!important}
.moonga-unified-menu-user{
  padding:10px 11px!important;
  margin:0 0 4px!important;
  display:grid!important;
  gap:3px!important;
  border:1px solid var(--moonga-shell-line)!important;
  border-radius:9px!important;
  background:rgba(255,255,255,.025)!important;
}
.moonga-unified-menu-user b{color:#fff!important;font-size:13px!important}
.moonga-unified-menu-user small{color:var(--moonga-shell-muted)!important;font-size:11px!important;text-transform:capitalize!important}
.moonga-unified-menu-divider{height:1px!important;margin:5px 4px!important;background:var(--moonga-shell-line)!important}
.moonga-unified-menu-empty{padding:10px 11px!important;color:var(--moonga-shell-muted)!important;font-size:12px!important}

.moonga-unified-footer{
  width:100%!important;
  margin:auto 0 0!important;
  padding:0!important;
  display:block!important;
  border:0!important;
  border-top:1px solid var(--moonga-shell-line)!important;
  background:rgba(5,7,12,.72)!important;
  font-family:Inter,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Arial,sans-serif!important;
}
.moonga-unified-footer-inner{
  width:100%!important;
  max-width:var(--moonga-shell-width)!important;
  min-height:80px!important;
  margin:0 auto!important;
  padding:24px var(--moonga-shell-header-padding)!important;
  display:flex!important;
  align-items:center!important;
  justify-content:space-between!important;
  gap:22px!important;
  color:var(--moonga-shell-muted)!important;
  font-size:14px!important;
}
.moonga-unified-footer-links{display:flex!important;align-items:center!important;flex-wrap:wrap!important;gap:20px!important}
.moonga-unified-footer a{color:inherit!important;text-decoration:none!important}
.moonga-unified-footer a:hover{color:#fff!important}

/* The app shell was designed around an older 56px header. Keep it aligned to the shared 72px header. */
body.moonga-site-background:not(.embed-page):not(.chat-embed-mode) .app{
  min-height:calc(100vh - var(--moonga-shell-header-height))!important;
}
body.moonga-site-background:not(.embed-page):not(.chat-embed-mode) .sidebar{
  top:var(--moonga-shell-header-height)!important;
  height:calc(100vh - var(--moonga-shell-header-height))!important;
}

@media(max-width:1180px){
  :root{--moonga-shell-header-padding:20px;--moonga-shell-logo-width:150px}
  .moonga-unified-header-inner{gap:14px!important}
  .moonga-unified-nav{
    justify-content:flex-start!important;
    overflow-x:auto!important;
    overflow-y:hidden!important;
    scrollbar-width:none!important;
    overscroll-behavior-x:contain!important;
  }
  .moonga-unified-nav::-webkit-scrollbar{display:none!important}
  .moonga-unified-link,.moonga-unified-menu-button{padding:0 11px!important;font-size:13px!important}
}
@media(max-width:680px){
  :root{--moonga-shell-header-padding:14px;--moonga-shell-logo-width:132px}
  .moonga-unified-header-inner{gap:10px!important}
  .moonga-unified-footer-inner{align-items:flex-start!important;flex-direction:column!important;padding:26px 18px!important}
}
