* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body, html {
    height: 100%;
    font-family: Inter, system-ui, -apple-system, "Segoe UI", sans-serif;
    background: #fafafa;
    color: var(--color);
    overflow: hidden;
}
#app-shell {
    width: 1800px;
    min-width: 1800px;
    min-height: 100vh;
    position: relative;
    transform-origin: top left;
}
h1{
    position: absolute;
    left: 16.6rem;
    top: 1.3rem;
    font-size: 1.9rem;
}
.protocol-scope-toggle {
    position: absolute;
    right: 4rem;
    top: 1.3rem;
    z-index: 12;
    display: flex;
    align-items: center;
    gap: 1.2rem;
}
.protocol-scope-toggle.hidden {
    display: none;
}
.protocol-scope-toggle button {
    width: 120px;
    min-width: 120px;
    max-width: 120px;
    height: 36px;
    margin: 0;
    padding: 0 .6rem;
    border: none;
    border-radius: 6px;
    background-color: var(--bg-hover);
    color: var(--color);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.protocol-scope-toggle button:hover {
    background-color: var(--bg-hover);
    color: var(--color);
}
.protocol-scope-toggle button.active,
.protocol-scope-toggle button.active:hover {
    background-color: var(--bg-active);
    color: var(--color-active);
}
#logo{
    width: 10rem;
    position: absolute;
    left: 2rem;
    top: 2rem;
}
#sidebar_toggle {
    position: absolute;
    left: 12.9rem;
    top: 50%;
    transform: translateY(-50%);
    z-index: 20;
    width: 2rem;
    min-width: 2rem;
    height: 2rem;
    padding: 0;
    border: 1px solid #e1e1e1;
    border-radius: 5px;
    background: #fafafa;
    color: var(--color);
    box-shadow: 0 1px 5px rgba(0, 0, 0, .08);
    cursor: pointer;
    font-size: 1.1rem;
    font-weight: 700;
    line-height: 1;
}
#sidebar_toggle:hover {
    background: #eee;
}
#app-shell.sidebar-collapsed #sidebar_toggle {
    left: 0.2rem;
}
#app-shell.sidebar-collapsed h1 {
    left: 16.6rem;
}
/* Layout mit Sidebar und Main */
#formular_frame{
    max-width: 1804px;
}
.layout {
  display: flex;
  height: 100vh;
  height: calc(100% - 3rem);
}

/* Seitenmenü */
.sidebar {
  width: 14rem;
  min-width: 14rem;
  color: var(--color);
  background: white;
  box-shadow: 0px 0px 4px #e5e5e5 inset;
  border-right: 1px solid #e5e5e5;
  padding: 1.3rem;
  display: flex;
  flex-direction: column;
  padding-top: 32px;
  height: 100%;
  overflow: hidden;
  transition: width .18s ease, min-width .18s ease, padding .18s ease;
}
#app-shell.sidebar-collapsed .sidebar {
  width: 0;
  min-width: 0;
  padding-left: 0;
  padding-right: 0;
  border-right: 0;
  box-shadow: none;
}
#app-shell.sidebar-collapsed .sidebar nav,
#app-shell.sidebar-collapsed .sidebar .info {
  opacity: 0;
  pointer-events: none;
}
nav{
    margin: 6rem 0;
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    padding-bottom: 1rem;
    scrollbar-width: none;
    -ms-overflow-style: none;
}
nav::-webkit-scrollbar {
    display: none;
}
.sidebar nav button {
    font-weight: 500;
    font-size: 1.1rem;
    line-height: 1.2rem;    
    border: none;
    padding: 0.8rem 1rem;
    margin-bottom: 0.3rem;
    width: 100%;
    text-align: left;
    border-radius: 6px;
    cursor: pointer;
    background: white;
    border: none;
}

.sidebar nav button:hover{
  background: white;
  color: var(--color);
  font-weight: 700;
}

.sidebar nav button.active {
    background: white;
    color: var(--color);
    font-weight: 700;
    font-size: 1.1rem;
}

.sidebar nav button.sub{
    margin-left: 0;
}

.sidebar nav button.sub::before{
    content: "- ";
}

.info{
    position: static;
    flex-shrink: 0;
    margin: 0 auto 4rem auto;
    color: var(--color);
    font-size: 1rem;
    line-height: 1.5rem;
    font-weight: 500;
    width: 100%;
}

.info button {
    display: block;
    width: 100%;
    min-width: 0;
    margin: 0 0 .2rem 0;
    padding: .2rem 0;
    border: 0;
    background: white;
    color: var(--color);
    font-size: 1rem;
    line-height: 1.3rem;
    font-weight: 500;
    text-align: left;
}

.info button:hover,
.info button.active {
    background: white;
    color: var(--color);
    font-weight: 700;
    text-decoration: none;
}

/* Hauptbereich */
.main {
  flex: 1;
  min-width: 0;
  /*border: 1px solid #f0f0f0;*/
  margin-top: 5.8rem;
  height: calc(100% - 5.8rem);
  position: relative;
  border-top-left-radius: 6px;
  background-color: #fafafa;
  overflow: hidden;
}

iframe {
  width: 100%;
  height: 100%;
  border: none;
  border-top-left-radius: 6px;
}
#formular_frame.loading {
  visibility: hidden;
}
#main-loader {
  position: absolute;
  inset: 0;
  z-index: 5;
  display: none;
  align-items: center;
  justify-content: center;
  background: #fafafa;
  border-top-left-radius: 6px;
}
#main-loader.active {
  display: flex;
}
.loader-spinner {
  width: 42px;
  height: 42px;
  border: 7px solid #ddd;
  border-top-color: var(--button);
  border-radius: 50%;
  animation: loader-spin 1s linear infinite;
}
@keyframes loader-spin {
  to {
    transform: rotate(360deg);
  }
}
#top{
    padding: 2.3rem 0 0rem 2.8rem;
    margin-left: -3rem;
    width: 300%;
   height: 134px;
}
