body,
#workspace,
#stage {
  height: 100dvh;
}
#connection {
  display: none;
}
.web-home {
  color: var(--key);
  text-decoration: none;
  font-size: 13px;
  font-weight: 600;
}
.web-home:hover {
  text-decoration: underline;
}
.web-home.login-home {
  position: absolute;
  top: 22px;
  right: 26px;
}
.brandpanel {
  background: #302f53;
}
#close-rail,
#web-shade {
  display: none;
}
#modelname {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
#toggleRail {
  flex: none;
}
:focus-visible {
  outline-offset: 2px;
}
@media (max-width: 720px) {
  body {
    margin: 0;
    min-width: 0;
  }
  #login {
    display: flex;
    flex-direction: column;
    height: 100dvh;
    overflow: auto;
  }
  #login .brandpanel {
    flex: none;
    min-height: 76px;
    display: flex;
    justify-content: center;
    padding: 18px 25px;
  }
  .brandword {
    font-size: 24px;
  }
  .brandpanel .portrait,
  .brandpanel .brandfoot {
    display: none;
  }
  .authpane {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 58px clamp(20px, 8vw, 50px) 30px;
  }
  .web-home.login-home {
    top: 15px;
    right: 24px;
  }
  .authpane form {
    max-width: 390px;
    min-width: 0;
  }
  input,
  textarea,
  select {
    font-size: 16px;
  }
  #workspace,
  #workspace.fold {
    display: block;
    position: relative;
    overflow: hidden;
  }
  #stage {
    width: 100%;
    height: 100dvh;
  }
  #rail {
    position: absolute;
    inset: 0 auto 0 0;
    width: min(84%, 310px);
    z-index: 5;
    box-shadow: 4px 0 34px #11142925;
  }
  #workspace.fold #rail {
    visibility: hidden;
  }
  #close-rail {
    display: inline-flex;
    margin-left: auto;
  }
  #web-shade:not([hidden]) {
    display: block;
    background: #11142665;
    position: absolute;
    inset: 0;
    z-index: 4;
    border: 0;
    border-radius: 0;
    padding: 0;
  }
  .top {
    height: 54px;
    padding: 0 8px;
  }
  .top .controls {
    min-width: 0;
  }
  .top .controls:last-child {
    flex: none;
  }
  .top .modelbtn {
    min-width: 0;
    padding: 8px 5px;
    font-size: 14px;
  }
  #temp span,
  .keys,
  .wide kbd,
  .search kbd {
    display: none;
  }
  .railbrand {
    margin-bottom: 20px;
  }
  .measure {
    width: calc(100% - 24px);
  }
  #composerWrap {
    padding-bottom: max(10px, env(safe-area-inset-bottom));
  }
  .composerbar {
    gap: 2px;
  }
  .composerbar .controls {
    gap: 2px;
  }
  .composerbar button {
    padding: 5px;
  }
  .composer textarea {
    max-height: 128px;
  }
  #panel {
    max-width: calc(100vw - 18px);
    width: calc(100vw - 18px);
    max-height: 88dvh;
    margin: auto;
  }
  #panelbody {
    max-width: 100%;
    overflow-x: hidden;
  }
  #toast {
    max-width: 94vw;
  }
}
@media (max-width: 400px) {
  .top .web-home {
    font-size: 12px;
    margin-inline: 2px;
  }
  #temp,
  #chatmenu {
    width: 29px;
  }
}
[hidden] {
  display: none !important;
}
